0

First of all, everything i make is working on my local computer but this error happen when i tried to update this module inside of a server.

I add some fields to res.company

class InheritAccountMove(models.Model):
    _inherit = 'res.company'

    tax_office = fields.Many2one('tax.office', string='Tax Office')
    building_no = fields.Char(string='Building Number')
    district_name = fields.Char(string='District/Town')
    e_invoice_username = fields.Char(string="E-Invoice API Username")
    e_invoice_password = fields.Char(string="E-Invoice API Password")
    e_invoice_catalog = fields.Char(string="E-Invoice API Catalog")
    e_invoice_isyeri = fields.Char(string="E-Invoice API Isyeri")
    e_invoice_wsdl = fields.Char(string="E-Invoice API wsdl")

This is the XML looklike

<record id="view_company_form_inherit" model="ir.ui.view">
    <field name="name">company.form</field>
    <field name="model">res.company</field>
    <field name="inherit_id" ref="base.view_company_form"/>
    <field name="arch" type="xml">
        <xpath expr="//field[@name='vat']" position="after">
            <field name="tax_office"/>
            <field name="building_no"/>
            <field name="district_name"/>
            <field name="e_invoice_username"/>
            <field name="e_invoice_password"/>
            <field name="e_invoice_catalog"/>
            <field name="e_invoice_isyeri"/>
            <field name="e_invoice_wsdl"/>
        </xpath>
    </field>
</record>

Its returning:

***THERE IS NO FIELD "e_invoice_username" inside of res.company.***

this fields starting with e_invoice is new ones. tax_office, building_no and district name was created 1 week ago and only with them it was working good.

Error started when i add this e_invoice fields.

I tried uninstall whole module and upload again but nothing changed.

I didn't understand why this is happening ?

Any idea for this problem ?

Selman
  • 274
  • 2
  • 4
  • 17

1 Answers1

1

Uninstall and Install module will not solve the issue. When you modify python code, you need to restart the Odoo service and then activate developer mode then go to Apps-> click update app list.

Waleed Mohsen
  • 965
  • 6
  • 8