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

Error while adding an additional Tab on res.partner view Odoo v8

By
Da3oub
on 6/6/16, 10:05 AM 342 views

Hello,

i've been Trying to add some new Tabs with 'Sales & Purchasing' and 'internal note' but no luck.i kept getting invalid view definition.

Here's my xml FIle:

<openerp>

<data>

<record model="ir.ui.view" id="view_partner_odepo_form">

<field name="name">res.partner.form.inherit1</field>

<field name="model">res.partner</field>

<field name="inherit_id" ref="base.view_partner_form"/>

<field name="arch" type="xml">

<field name="phone" position="after">

<field name="phone2"/>

</field>

<field name="mobile" position="after">

<field name="mobile2"/>

</field>

<field name="email" position="after">

<field name="email2"/>

</field>

<field name="title" position="after">

<field name="meet"/>

</field>

<field name="email2" position="after">

<field name="skype"/>

</field>

<field name="website" position="after">

<field name="customer"/>

</field>

<!-- Rename Customer to Acheteur -->

<xpath expr="//field[@name='customer']" position="attributes">

<attribute name="string">Acheteur</attribute>

</xpath>

<field name="customer" position="after">

<field name="seller"/>

</field>

<field name="seller" position="after">

<field name="supplier"/>

</field>

<field name="supplier" position="after">

<field name="backOffice"/>

</field>

<field name="backOffice" position="after">

<field name="active"/>

</field>

<field name="active" position="after">

<field name="verifiedDate"/>

</field>

<!--

<field name="verifiedDate" position="after">

<field name="verifiedBy"/>

</field>

<xpath expr="//page[@string='internal_notes']" position="after">

<page name="dependance" string="Dépendances">

</page>

</xpath>-->

<!--

<xpath expr="//page[@string='sales_purchases']" position="after">

<page name="acheteur" string="Acheteur">

</page>

</xpath>

<xpath expr="//page[@string='sales_purchases']" position="after">

<page name="vendeur" string="Vendeur">

</page>

</xpath>

<xpath expr="//page[@string='sales_purchases']" position="after">

<page name="fournisseur" string="Fournisseur">

</page>

</xpath>

-->

</field>

</record>

</data>

</openerp>


please include error too.

Baiju
on 6/6/16, 11:06 PM
1

Jusab Sida (jsi)

--Jusab Sida (jsi)--
Tiny ERP Pvt Ltd
http://www.odoo.com
874
| 2 1 5
Gandhinagar, India
--Jusab Sida (jsi)--


Jusab Sida (jsi)
On 6/9/16, 6:23 AM

Problem is "sales_purchases" is a name not a string. Do like...

<xpath expr="//page[@name='sales_purchases']" position="after">
<page name="fournisseur" string="Fournisseur">
</page>
</xpath>
1
Krupesh Laiya
On 6/7/16, 2:19 AM

You can put fields togather which you want after active field don't write twise you can add field like this:

<field name="active" position="after">

<field name="verifiedDate"/>

<field name="verifiedBy"/>

</field>

and please paste your error.

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

1 follower(s)

Stats

Asked: 6/6/16, 10:05 AM
Seen: 342 times
Last updated: 6/10/16, 3:14 AM