summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAzka Nathan <darizkyfaz@gmail.com>2025-05-16 09:27:25 +0700
committerAzka Nathan <darizkyfaz@gmail.com>2025-05-16 09:27:25 +0700
commit4360e1fd9f3af2c18b19463773047d9939716069 (patch)
tree59d26be91b5d64562f53b2715e83e36e3ab4e592
parentb8acd5ee5521228eb7c9033d9a234ee2b965db1a (diff)
revisi shipment group
-rw-r--r--indoteknik_custom/models/shipment_group.py6
-rw-r--r--indoteknik_custom/views/shipment_group.xml3
2 files changed, 2 insertions, 7 deletions
diff --git a/indoteknik_custom/models/shipment_group.py b/indoteknik_custom/models/shipment_group.py
index a4bea9c4..48a3fa21 100644
--- a/indoteknik_custom/models/shipment_group.py
+++ b/indoteknik_custom/models/shipment_group.py
@@ -87,9 +87,6 @@ class ShipmentGroupLine(models.Model):
if self.picking_id:
picking = self.env['stock.picking'].browse(self.picking_id.id)
- if self.shipment_id.partner_id and self.shipment_id.partner_id != picking.partner_id:
- raise UserError('Partner must be same as shipment group')
-
if self.shipment_id.carrier_id and self.shipment_id.carrier_id != picking.carrier_id:
raise UserError('carrier must be same as shipment group')
@@ -101,9 +98,6 @@ class ShipmentGroupLine(models.Model):
self.carrier_id = picking.carrier_id.id
self.total_colly = picking.total_mapping_koli
- if not self.shipment_id.partner_id:
- self.shipment_id.partner_id = picking.partner_id
-
if not self.shipment_id.carrier_id:
self.shipment_id.carrier_id = picking.carrier_id
diff --git a/indoteknik_custom/views/shipment_group.xml b/indoteknik_custom/views/shipment_group.xml
index d2c661ba..a4f82e27 100644
--- a/indoteknik_custom/views/shipment_group.xml
+++ b/indoteknik_custom/views/shipment_group.xml
@@ -18,8 +18,9 @@
<field name="model">shipment.group.line</field>
<field name="arch" type="xml">
<tree editable="bottom">
- <field name="sale_id" readonly="1"/>
+ <field name="partner_id" readonly="1"/>
<field name="picking_id" required="1"/>
+ <field name="sale_id" readonly="1"/>
<field name="total_colly" readonly="1"/>
</tree>
</field>