odooloco / l10n_co_res_partner

La Localización tributaria para Colombia en Odoo: Terceros
1 stars 11 forks source link

ValueError: External ID not found in the system: website_sale.address_b2b #13

Open macagua opened 3 years ago

macagua commented 3 years ago

I am using the 12.0 branch for l10n_co_res_partner module on Odoo CE 12 version, and trying to install it, return this error:

Error:
Odoo Server Error

Traceback (most recent call last):
  File "/home/macagua/projects/odoo12x/odoo/tools/cache.py", line 88, in lookup
    r = d[key]
  File "/home/macagua/projects/odoo12x/odoo/tools/func.py", line 69, in wrapper
    return func(self, *args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/tools/lru.py", line 44, in __getitem__
    a = self.d[obj].me
KeyError: ('ir.model.data', <function IrModelData.xmlid_lookup at 0x7faf090746a8>, 'website_sale.address_b2b')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 758, in parse
    self._tags[rec.tag](rec, de, mode=mode)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 736, in _tag_template
    return self._tag_record(record, data_node)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 650, in _tag_record
    f_val = self.id_get(f_ref)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 741, in id_get
    res = self.model_id_get(id_str, raise_if_not_found)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 747, in model_id_get
    return self.env['ir.model.data'].xmlid_to_res_model_res_id(id_str, raise_if_not_found=raise_if_not_found)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_model.py", line 1427, in xmlid_to_res_model_res_id
    return self.xmlid_lookup(xmlid)[1:3]
  File "<decorator-gen-25>", line 2, in xmlid_lookup
  File "/home/macagua/projects/odoo12x/odoo/tools/cache.py", line 93, in lookup
    value = d[key] = self.method(*args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_model.py", line 1416, in xmlid_lookup
    raise ValueError('External ID not found in the system: %s' % xmlid)
ValueError: External ID not found in the system: website_sale.address_b2b

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 656, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 314, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/home/macagua/projects/odoo12x/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 698, in dispatch
    result = self._call_function(**self.params)
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 346, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/service/model.py", line 98, in wrapper
    return f(dbname, *args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 339, in checked_call
    result = self.endpoint(*a, **kw)
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 941, in __call__
    return self.method(*args, **kw)
  File "/home/macagua/projects/odoo12x/odoo/http.py", line 519, in response_wrap
    response = f(*args, **kw)
  File "/home/macagua/projects/odoo12x/addons/web/controllers/main.py", line 966, in call_button
    action = self._call_kw(model, method, args, {})
  File "/home/macagua/projects/odoo12x/addons/web/controllers/main.py", line 954, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/home/macagua/projects/odoo12x/odoo/api.py", line 759, in call_kw
    return _call_kw_multi(method, model, args, kwargs)
  File "/home/macagua/projects/odoo12x/odoo/api.py", line 746, in _call_kw_multi
    result = method(recs, *args, **kwargs)
  File "<decorator-gen-61>", line 2, in button_immediate_install
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_module.py", line 74, in check_and_log
    return method(self, *args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_module.py", line 445, in button_immediate_install
    return self._button_immediate_function(type(self).button_install)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_module.py", line 561, in _button_immediate_function
    modules.registry.Registry.new(self._cr.dbname, update_module=True)
  File "/home/macagua/projects/odoo12x/odoo/modules/registry.py", line 86, in new
    odoo.modules.load_modules(registry._db, force_demo, status, update_module)
  File "/home/macagua/projects/odoo12x/odoo/modules/loading.py", line 421, in load_modules
    loaded_modules, update_module, models_to_check)
  File "/home/macagua/projects/odoo12x/odoo/modules/loading.py", line 313, in load_marked_modules
    perform_checks=perform_checks, models_to_check=models_to_check
  File "/home/macagua/projects/odoo12x/odoo/modules/loading.py", line 222, in load_module_graph
    load_data(cr, idref, mode, kind='data', package=package, report=report)
  File "/home/macagua/projects/odoo12x/odoo/modules/loading.py", line 68, in load_data
    tools.convert_file(cr, package.name, filename, idref, mode, noupdate, kind, report)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 802, in convert_file
    convert_xml_import(cr, module, fp, idref, mode, noupdate, report)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 865, in convert_xml_import
    obj.parse(doc.getroot(), mode=mode)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 755, in parse
    self.parse(rec, mode)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 764, in parse
    exc_info[2]
  File "/home/macagua/projects/odoo12x/odoo/tools/pycompat.py", line 86, in reraise
    raise value.with_traceback(tb)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 758, in parse
    self._tags[rec.tag](rec, de, mode=mode)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 736, in _tag_template
    return self._tag_record(record, data_node)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 650, in _tag_record
    f_val = self.id_get(f_ref)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 741, in id_get
    res = self.model_id_get(id_str, raise_if_not_found)
  File "/home/macagua/projects/odoo12x/odoo/tools/convert.py", line 747, in model_id_get
    return self.env['ir.model.data'].xmlid_to_res_model_res_id(id_str, raise_if_not_found=raise_if_not_found)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_model.py", line 1427, in xmlid_to_res_model_res_id
    return self.xmlid_lookup(xmlid)[1:3]
  File "<decorator-gen-25>", line 2, in xmlid_lookup
  File "/home/macagua/projects/odoo12x/odoo/tools/cache.py", line 93, in lookup
    value = d[key] = self.method(*args, **kwargs)
  File "/home/macagua/projects/odoo12x/odoo/addons/base/models/ir_model.py", line 1416, in xmlid_lookup
    raise ValueError('External ID not found in the system: %s' % xmlid)
odoo.tools.convert.ParseError: "External ID not found in the system: website_sale.address_b2b" while parsing None:11, near
<data inherit_id="website_sale.address_b2b">
                <xpath expr="//input[@name='vat']" position="replace">
                    <t>  
                        <input type="hidden" name="partner_id" class="form-control website-partner_id" readonly="1" t-att-value="partner_id"/>                
                        <select name="doctype" id="doctype" t-attf-class="form-control #{error.get('doctype') and 'is-invalid' or ''}" t-att-readonly="'1' if 'vat' in checkout and checkout['vat'] and not can_edit_vat else None">
                            <option t-att-value="13" t-att-selected="'doctype' in checkout and checkout['doctype'] == '13'">13 - Cédula de ciudadanía</option>
                            <option t-att-value="31" t-att-selected="'doctype' in checkout and checkout['doctype'] == '31'">31 - NIT (Número de identificación tributaria)</option>
                            <option t-att-value="11" t-att-selected="'doctype' in checkout and checkout['doctype'] == '11'">11 - Registro civil de nacimiento</option>
                            <option t-att-value="41" t-att-selected="'doctype' in checkout and checkout['doctype'] == '41'">41 - Pasaporte</option>
                            <option t-att-value="12" t-att-selected="'doctype' in checkout and checkout['doctype'] == '12'">12 - Tarjeta de identidad</option>
                            <option t-att-value="21" t-att-selected="'doctype' in checkout and checkout['doctype'] == '21'">21 - Tarjeta de extranjería</option>
                            <option t-att-value="22" t-att-selected="'doctype' in checkout and checkout['doctype'] == '22'">22 - Cédula de extranjería</option>
                            <option t-att-value="42" t-att-selected="'doctype' in checkout and checkout['doctype'] == '42'">42 - Documento de identificación extranjero</option>
                        </select>
                    </t>
                     <t>
                        <div>
                            <input type="text" name="vat" class="form-control hidden-element" t-att-value="'xidentification' in checkout and checkout['xidentification']"/>
                        </div>
                         <div>
                            <table width="100%">
                                <tr>
                                    <td width="70%">
                                        <input type="text" name="xidentification" placeholder="24645765" class="form-control website-xidentification" t-att-value="'xidentification' in checkout and checkout['xidentification']"/>
                                    </td>
                                    <td width="73%">
                                        <input type="text" placeholder="Para N.I.T" name="verificationDigit" class="form-control website-verificationDigit" readonly="1" t-att-value="'verificationDigit' in checkout and checkout['verificationDigit']"/>
                                    </td>
                                </tr>

                            </table>
                        </div>
                    </t>
                </xpath>  
                <xpath expr="//form[@class='checkout_autoformat']//div//div" position="inside">
                     <div>
                            <input type="checkbox" t-att-value="'is_company' in checkout and checkout['is_company']" name="is_company" class="form-control website-is_company hidden-element"/>  
                            <input type="text" name="name" class="form-control website-name hidden-element" readonly="1" t-att-value="'name' in checkout and checkout['name']"/> 
                            <input type="text" name="pos_name" class="form-control website-name hidden-element" readonly="1" t-att-value="'name' in checkout and checkout['name']"/> 
                            <input type="text" name="companyBrandName" class="form-control website-name hidden-element" readonly="1" t-att-value="'company_name' in checkout and checkout['company_name']"/> 
                            <table class="form-full-width block-names">
                                <tr>
                                    <td>
                                        <label>Primer Nombre</label>
                                        <input t-att-value="'x_name1' in checkout and checkout['x_name1']" type="text" name="x_name1" placeholder="Jon" class="form-control website-x_name1"/>
                                    </td>
                                    <td>
                                        <label>Segundo Nombre</label>
                                        <input t-att-value="'x_name2' in checkout and checkout['x_name2']" type="text" name="x_name2" placeholder="Smith" class="form-control website-x_name2"/>
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        <label>Primer Apellido</label>
                                        <input t-att-value="'x_lastname2' in checkout and checkout['x_lastname1']" type="text" name="x_lastname1" placeholder="Gomez" class="form-control website-x_lastname1"/>
                                    </td>
                                    <td>
                                        <label>Segundo Apellido</label>
                                        <input t-att-value="'x_lastname2' in checkout and checkout['x_lastname2']" type="text" name="x_lastname2" placeholder="Giraldo" class="form-control website-x_lastname2"/>
                                    </td>
                                </tr>
                            </table>                        
                    </div>
                </xpath>
                 <xpath expr="//form[@class='checkout_autoformat']/div[@class='form-row']/div[12]" position="after">
                    <t> 
                        <div class="div_district form-group  col-lg-6">
                            <label class="col-form-label" for="xcity">Municipio</label>                 
                                <select name="xcity" class="form-control ">

                                </select>     
                        </div>  
                         <div class="div_zip_custom form-group  col-lg-6" style="max-width:200px">
                                <label class="col-form-label label-optional" for="zip">Zip Code</label>
                                <input type="text" name="zip" t-attf-class="form-control #{error.get('zip') and 'is-invalid' or ''}" t-att-value="'zip' in checkout and checkout['zip']" style="max-width:200px"/>
                        </div> 
                    </t>
                </xpath>            
        </data>
BrayhanJC commented 3 years ago

Hola el error lo puede solucionar instalando el modulo website_sale

Si desea omitir las modificaciones que se hacen para el sitio web, puede comentar las lineas que se encuentran en el manifest.py

'data': [
    'views/l10n_co_res_partner.xml',
    'views/ciiu.xml',
    #'views/website.xml',
    'data/ciiu.csv',
    'data/l10n_states_co_data.xml',
    'data/l10n_cities_co_data.xml',
    'security/ir.model.access.csv'