Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Please Help , i'm getting this error while installing Module in OpenERP 7.0?

By
Ali Khan
on 3/25/14, 8:32 AM 1,414 views

This is the Error (
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\modules\loading.py", line 76, in <lambda>
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\modules\loading.py", line 124, in _load_data
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\convert.py", line 954, in convert_xml_import
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\convert.py", line 847, in parse
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\convert.py", line 805, in _tag_record
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\convert.py", line 824, in id_get
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\convert.py", line 833, in model_id_get
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\cache.py", line 18, in lookup File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\cache.py", line 46, in lookup File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server\openerp\addons\base\ir\ir_model.py", line 874, in get_object_reference
File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\cache.py", line 18, in lookup File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server.\openerp\tools\cache.py", line 46, in lookup File "C:\Program Files (x86)\OpenERP 7.0-20140227-001259\Server\server\openerp\addons\base\ir\ir_model.py", line 867, in _get_id ValueError: No such external ID currently defined in the system: sna.sna_aor_c1_form )

(My Configuration)

<openerp> <data>

<!-- ### Orphan START ### -->  
<!-- Orphan Form View -->   
<record model="ir.ui.view" id="sna_orphan_form">
    <field name="name">sna.orphan.form</field>
    <field name="model">sna.orphan</field>
    <field name="inherit_id" ref="sna.sna_aor_c1_form"/>
    <field name="type">form</field>
    <field name="arch" type="xml">
        <form string="Orphans" version="7.0">
            <field name="district_id" select="1"/>
            <field name="sub_district_id" select="2"/>
            <field name="area_id" select="3"/>
            <field name="address_id" select="5"/>
            <field name="officer_id" select="7"/>
            <field name="registration_date" select="9"/>
            <field name="chief" select="10"/>
            <field name="headman" select="11"/>
            <field name="court_president" select="12"/>
            <field name="councillor" select="13"/>
            <field name="vdc_chairman" select="14"/>
            <field name="placed_in_institution" select="15"/>
            <field name="date_placed" select="16"/>
            <field name="institute_id" select="17"/>
        </form>
    </field>
</record>
<!-- Orphan Tree View -->
<record model="ir.ui.view" id="sna_orphan_tree">
    <field name="name">sna.orphan.tree</field>
    <field name="model">sna.orphan</field>
    <field name="inherit_id" ref="sna.sna_aor_super_tree"/>
    <field name="arch" type="xml">
        <tree string="Orphan Setup" editable="bottom">
            <field name="district_id"/>
            <field name="sub_district_id"/>
            <field name="area_id"/>

            <field name="address_id"/>

            <field name="officer_id"/>

            <field name="registration_date"/>
            <field name="chief"/>
            <field name="headman"/>
            <field name="court_president"/>
            <field name="councillor"/>
            <field name="vdc_chairman"/>
            <field name="placed_in_institution"/>
            <field name="date_placed"/>
            <field name="institute_id"/>
        </tree>
    </field>
</record>   
<!-- Orphan Action -->
<record model='ir.actions.act_window' id='sna_orphan_act'>
    <field name="name">Orphan</field>
    <field name="res_model">sna.orphan</field>
    <field name="view_type">form</field>
    <field name="view_mode">tree,form</field>
    <field name="help" type="html">
      <p class="oe_view_nocontent_create">
        Click to create new Orphan.
      </p><p>
        a
      </p>
    </field>
</record>
<!-- Orphan Menu -->            
<menuitem action="sna_orphan_act" id="sna_orphan_menu" parent="sna_beneficiaries"/>
<!-- ### Orphan END ### -->

</data>

</openerp>

Have u define view having id="sna_aor_c1_form"? If no, you have to define it as you are inheriting that view(<field name="inherit_id" ref="sna.sna_aor_c1_form"/>).

Hiral Patel (hip)
on 3/25/14, 10:00 AM

yeah bro , i did defined it , now am inheriting it and i get the same error ... Spoiled my whole day :(

Ali Khan
on 3/25/14, 12:40 PM
0

Nehal

--Nehal--
2090
| 5 2 8
Ahmadabad, India
--Nehal--
Nehal
On 3/25/14, 8:47 AM

Hi,

You might be using "sna_aor_c1_form" somewhere as reference which does not exists anymore. Please recheck it.

Thanks ... But it does exist in the other view .. from which i'm inheriting this .. ??

Ali Khan
on 3/25/14, 9:01 AM

@Nehal ... I don't understand my dear friend :)

Ali Khan
on 3/25/14, 10:24 AM

sna.sna_aor_c1_form where sna = module_name and sna_aor_c1_form is id of your view. For example: base.view_partner_bank_form where base is module name. This may be a case for getting this error.

Nehal
on 3/25/14, 10:34 AM

yeah exactly that's the module name .. so where am doing mistake ??

Ali Khan
on 3/25/14, 12:43 PM

This is the only possibility for the error you encountered. Please check that the view with id "sna_aor_c1_form" is created or not. If not, upgrade the module which is having the id.

Nehal
on 3/26/14, 1:09 AM
0

Hiral Patel (hip)

--Hiral Patel (hip)--
Tiny ERP Pvt Ltd
http://www.odoo.com
913
| 2 1 5
India
--Hiral Patel (hip)--


Hiral Patel (hip)
On 3/26/14, 1:50 AM

sna module:

sna_view.xml:

<record model="ir.ui.view" id="sna_aor_c1_form">
    ...
    <field name="inherit_id" ref="sna.sna_aor_c1_form"/>
    ...
</record>

test module:(Module name you have written following code)

test_view.xml:

<record model="ir.ui.view" id="sna_orphan_form">
    ...
    <field name="inherit_id" ref="sna.sna_aor_c1_form"/>
    ...
</record>

Either add 'sna' in __openerp__.py file like : __openerp__.py:

'depends' : ['sna'],

Or install 'sna' module before 'test' module.

Hope it may help you.

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 3/25/14, 8:32 AM
Seen: 1414 times
Last updated: 3/16/15, 8:10 AM