Community mailing list archives

Re: problem with view inheritance

- 03/12/2015 11:53:48
Hi Nuria,
i wanted to obtain a structure like this
<group colspan="4">
  <field name="anno" string="Anno" /> <- this from product_template by the view product.product_template_custom_form_view
  <field name="venduto_euro" /> <- this from product_product by the view product.product_product_custom_form_view
  <field name="codicebarre" /> <- this from product_product by the view product.product_product_custom_form_view
  <field name="codicebarreext" /> <- this from product_product by the view product.product_product_custom_form_view

This is because i've not set the col
the view i want to modify is this 
and inject my fields just after this group

Hi gustavo,
thanks for your remarks

you are inheriting from the product template view instead of the product one (in fact both views are derived from the same parent view)
you are modifing directly the product views (id = "product.product_template_custom_form_view") instead of defining new views in your module (if I understood right, two new ids)

for the first point if you look at this code, there's no problem doing this.
for the second point, i'm modifying the view i've just created because i want to create a new group inside that view. If i inherith from a different view, the group i've just created is not present. Or am i wrong?
As i said to nuria, i want to visualize different fields from different models.

Josef, i think it's possible if odoo has done this! :D 
but if i've misunderstood the code please correct me

​thanks to everyone.
​If i won't solve this problem, probably i will try a new strategy and i won't group these fields together.