Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
4989 มุมมอง

I want to create extra fields in acounting-> customer invoice.....i want to create two fields below fiscal positon field and three fields below Amount field....plese some body help me

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด
        hi sri,

        .py file

            _inherit = 'account.invoice'
            _columns = {
                    'test1':fields.char('Test1', size=64),
                    'test2':fields.char('Test2', size=64),
                    }


            _inherit = 'account.invoice.line'
            _columns = {
                    'line1':fields.char('Line1', size=64),
                    'line2':fields.char('Line2', size=64),
                    'line3':fields.char('Line3', size=64),
                }
       ****** XML file
<xpath expr="//form/sheet/group/group//field[@name='fiscal_position']" position="after">
             <field name="test1"/>
             <field name="test2"/>
</xpath>
<xpath expr="//form/sheet/notebook/page//field/tree//field[@name='price_subtotal']" position="before">
              <field name="line1"/>
              <field name="line2"/>
              <field name="line3"/>
</xpath>
อวตาร
ละทิ้ง

this code is work perfectly use it

ผู้เขียน

wow thankyou very much

Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ส.ค. 23
3137
3
เม.ย. 23
2252
3
ธ.ค. 22
33764
Inheriting attributes from Fields แก้ไขแล้ว
1
ก.พ. 23
7928
Change the string of an inherited field แก้ไขแล้ว
7
ธ.ค. 23
26196