@@ -34,9 +34,6 @@
|
||||
<group>
|
||||
<field name="is_issues"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="related_issues_id" invisible="is_issues == False"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="is_this_department"/>
|
||||
</group>
|
||||
@@ -88,6 +85,7 @@
|
||||
</group>
|
||||
<group col="2">
|
||||
<group>
|
||||
<field name="related_issues_id" invisible="is_issues == False"/>
|
||||
<field name="reason_application"/>
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="department_ids" widget="many2many_tags" invisible="1"/>
|
||||
|
||||
@@ -9,6 +9,7 @@ class InheritPurchaseOrder(models.Model):
|
||||
_name = 'purchase.order'
|
||||
_inherit = ['purchase.order', 'soong.workflow.mixin']
|
||||
|
||||
|
||||
json_display = fields.Char(
|
||||
string="物品详情",
|
||||
compute='_compute_json_display',
|
||||
@@ -30,6 +31,7 @@ class InheritPurchaseOrder(models.Model):
|
||||
string="采购类型", default='fixed')
|
||||
pay_way = fields.Selection([('onetime', '一次性'), ('installment', '分期')], string="付款方式", default='onetime')
|
||||
reason_text = fields.Text(string="申请事由")
|
||||
pay_line_ids = fields.One2many('purchase.order.pay.line', 'order_id', string="付款详情")
|
||||
|
||||
def end_approval(self):
|
||||
self.button_confirm()
|
||||
|
||||
@@ -114,6 +114,7 @@ class PurchaseOrderPayLine(models.Model):
|
||||
_description = "付款详情"
|
||||
|
||||
purchase_id = fields.Many2one('purchase.workflow', string="关联采购工作流")
|
||||
order_id = fields.Many2one('purchase.order', string="关联采购工作流")
|
||||
payment_stage = fields.Char(string="付款阶段")
|
||||
amount = fields.Char(string="比例/金额")
|
||||
payment_date = fields.Date(string="付款日期")
|
||||
|
||||
@@ -8,6 +8,15 @@
|
||||
<xpath expr="//field[@name='partner_ref']" position="attributes">
|
||||
<attribute name="column_invisible">1</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='name']" position="attributes">
|
||||
<attribute name="string">事项</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='name']" position="after">
|
||||
<field name="code"/>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='partner_ref']" position="attributes">
|
||||
<attribute name="column_invisible">1</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='activity_ids']" position="attributes">
|
||||
<attribute name="column_invisible">1</attribute>
|
||||
</xpath>
|
||||
@@ -36,6 +45,12 @@
|
||||
<xpath expr="//field[@name='state']" position="attributes">
|
||||
<attribute name="invisible">1</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='date_order']" position="attributes">
|
||||
<attribute name="required">0</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='date_planned']" position="attributes">
|
||||
<attribute name="required">0</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='currency_id']" position="after">
|
||||
<field name="code" invisible="1"/>
|
||||
<field name="company_id" invisible="1"/>
|
||||
@@ -52,6 +67,24 @@
|
||||
<xpath expr="//field[@name='partner_id']" position="attributes">
|
||||
<attribute name="domain">[('is_employee', '=', False)]</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//page[@name='products']" position="after">
|
||||
<page string="付款详情" invisible="pay_way == 'onetime'">
|
||||
<field name="pay_line_ids">
|
||||
<tree editable="bottom">
|
||||
<field name="purchase_id" column_invisible="1"/>
|
||||
<field name="payment_stage" required="1"/>
|
||||
<field name="amount"/>
|
||||
<field name="payment_date"/>
|
||||
<field name="remake"/>
|
||||
</tree>
|
||||
</field>
|
||||
</page>
|
||||
</xpath>
|
||||
<xpath expr="//page[@name='purchase_delivery_invoice']" position="attributes">
|
||||
<attribute name="invisible">True</attribute>
|
||||
</xpath>
|
||||
</field>
|
||||
|
||||
<!-- <xpath expr="//page[@string='purchase_delivery_invoice']" position="after">-->
|
||||
<!-- <page string="关联流程">-->
|
||||
<!-- <field name="issue_library_approval_line_ids" readonly="1">-->
|
||||
@@ -68,6 +101,6 @@
|
||||
<!-- </field>-->
|
||||
<!-- </page>-->
|
||||
<!-- </xpath>-->
|
||||
</field>
|
||||
<!-- </field>-->
|
||||
</record>
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user