0

I'm new to Odoo and I'm looking for a way to add/edit columns in the overview of customer invoices.

Does anyone know which files to edit? Or how this "overview screen" is called so I can look it up better?

Link to screenshot of overview screen: http://oi58.tinypic.com/2prtyk0.jpg

Thanks in advance!

RobbeM
  • 727
  • 7
  • 16
  • 36
  • Now that i discovered where the tree view is located, i want to add my field "levertermijn". I tried the following code: ` account.invoice.tree.inherit account.invoice ` This gives the error: ParseError: "External ID not found in the system: account.invoice_tree_view" while parsing... – RobbeM Jul 08 '15 at 07:43

2 Answers2

0

The VIEW of this "TREE" is defined in

addons/account/views/account_invoice_view.xml 

Which has the code like this:

        <record id="invoice_tree" model="ir.ui.view">
        <field name="name">account.invoice.tree</field>
        <field name="model">account.invoice</field>
        <field name="arch" type="xml">
            <tree decoration-info="state == 'draft'" decoration-muted="state == 'cancel'" string="Invoice">
                <field name="partner_id" groups="base.group_user" string="Customer"/>
                <field name="date_invoice"/>
                <field name="number"/>
                <field name="commercial_partner_id" invisible="1"/>
                <field name="reference" invisible="1"/>
                <field name="name" invisible="1"/>
                <field name="journal_id" invisible="1"/>
                <field name="company_id" groups="base.group_multi_company" options="{'no_create': True}"/>
                <field name="user_id"/>
                <field name="date_due"/>
                <field name="origin"/>
                <field name="amount_total_signed" sum="Total Amount"/>
                <field name="residual_signed" sum="Residual Amount"/>
                <field name="currency_id" invisible="1"/>
                <field name="company_currency_id" invisible="1"/>
                <field name="state"/>
                <field name="type" invisible="context.get('type',True)"/>
            </tree>
        </field>
    </record>
Rutul Raval
  • 313
  • 2
  • 10
0

I recommend you use developer mode to know the name of the view what you want change/edit/inherit/..etc,

Go to Administrator => About Odoo => Activate Developer Mode then return to the view and you will see near to the name of the current view a Drop-down list with name Debug View#xx click there and choice Edit TreeView/FormView/...etc after that you are going to see the definition of the current view, in this way you will know what view you need to inherit/edit/..etc

I hope this will help you!

Juan Salcedo
  • 1,598
  • 1
  • 16
  • 28
  • Thank you, this is convenient to find this quickly! – RobbeM Jul 08 '15 at 07:41
  • ` my.invoice.tree.inherit account.invoice ` **1. The id should be different to the original, in this case the original id is invoice_tree thats why I called it my_invoice_tree_inherit, 2. The ref should be the id of the original view invoice_tree** – Juan Salcedo Jul 08 '15 at 21:35