跳至内容
菜单
此问题已终结

I have a new form which is integrated with a customized button on sale order lines.

I have product_id and partner_id on my new form just as they are on sale.order.I want to automatically fill my form fields . But instead of inheriting one field it is inheriting the whole sale.view_order_form into my new form

Inheritence code is 

class ManufactureForm(models.Model):
_inherit = {"sale.order": "product_id"}
_name = 'manufacturing'
In my XML file

<record id="manufacturing_form_view" model="ir.ui.view">
<field name="name">Manufacturing Form View</field>
<field name="model">manufacturing</field>
<field name="inherit_id" ref="sale.view_order_form" />
<field name="arch" type="xml">

Please guide me thru it because m a beginner
形象
丢弃
编写者

Someone please reply

编写者 最佳答案

No i have already added a button in sale.order.line which opens a new form. Now i want that the product which i select in sale order will be fetched automatically into new form and user do not have to fill a field twice.

形象
丢弃
最佳答案

Hello ,

In your Question you define you want to add new button in sale order line  but in you're inherit sale order

so Change this on.


形象
丢弃
相关帖文 回复 查看 活动
2
8月 23
3301
3
4月 23
2401
3
12月 22
34001
1
11月 22
3425
2
3月 18
4873