summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAzka Nathan <darizkyfaz@gmail.com>2023-09-15 16:14:40 +0700
committerAzka Nathan <darizkyfaz@gmail.com>2023-09-15 16:14:40 +0700
commit075e6b1612ce6171838c8e5932a5a539669b5f34 (patch)
treef5d15fd514fb89730898518d52d0fe58802e2e06
parent0ace4356bdbe27c3acd75c33d5259ef950eecb24 (diff)
can't create product on sale order line and purchase order line
-rwxr-xr-xindoteknik_custom/views/purchase_order.xml3
-rwxr-xr-xindoteknik_custom/views/sale_order.xml3
2 files changed, 6 insertions, 0 deletions
diff --git a/indoteknik_custom/views/purchase_order.xml b/indoteknik_custom/views/purchase_order.xml
index 7d436c46..999b9fd1 100755
--- a/indoteknik_custom/views/purchase_order.xml
+++ b/indoteknik_custom/views/purchase_order.xml
@@ -52,6 +52,9 @@
<field name="product_id" position="before">
<field name="line_no" attrs="{'readonly': 1}" optional="hide"/>
</field>
+ <field name="product_id" position="attributes">
+ <attribute name="options">{'no_create': True}</attribute>
+ </field>
<field name="product_qty" position="before">
<field name="qty_available_store"/>
<field name="suggest"/>
diff --git a/indoteknik_custom/views/sale_order.xml b/indoteknik_custom/views/sale_order.xml
index f2cab699..c505644d 100755
--- a/indoteknik_custom/views/sale_order.xml
+++ b/indoteknik_custom/views/sale_order.xml
@@ -96,6 +96,9 @@
<xpath expr="//form/sheet/notebook/page/field[@name='order_line']/tree/field[@name='product_id']" position="before">
<field name="line_no" readonly="1" optional="hide"/>
</xpath>
+ <xpath expr="//form/sheet/notebook/page/field[@name='order_line']/tree/field[@name='product_id']" position="attributes">
+ <attribute name="options">{'no_create': True}</attribute>
+ </xpath>
<field name="amount_total" position="after">
<field name="grand_total"/>
<label for="amount_voucher_disc" string="Voucher" />