summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/purchase_order_line.py
diff options
context:
space:
mode:
authorFIN-IT_AndriFP <it@fixcomart.co.id>2025-10-23 09:50:40 +0700
committerFIN-IT_AndriFP <it@fixcomart.co.id>2025-10-23 09:50:40 +0700
commit310f92c9b825a458618daa3b00581b790f8e009e (patch)
tree2b8957db596c86525c009ef5e62e23ccd6397f8f /indoteknik_custom/models/purchase_order_line.py
parent58a6ca75b9b1bb07ea958ab4bfb553140daeb8f8 (diff)
parent8d649f97dade329859b5770d1f3972cdd7233f97 (diff)
Merge branch 'odoo-backup' of https://bitbucket.org/altafixco/indoteknik-addons into pum-v3
Diffstat (limited to 'indoteknik_custom/models/purchase_order_line.py')
-rwxr-xr-xindoteknik_custom/models/purchase_order_line.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/indoteknik_custom/models/purchase_order_line.py b/indoteknik_custom/models/purchase_order_line.py
index a3c3a33b..8c72887d 100755
--- a/indoteknik_custom/models/purchase_order_line.py
+++ b/indoteknik_custom/models/purchase_order_line.py
@@ -51,6 +51,12 @@ class PurchaseOrderLine(models.Model):
contribution_cost_service = fields.Float(string='Contribution Cost Service', compute='_compute_doc_delivery_amt')
ending_price = fields.Float(string='Ending Price', compute='_compute_doc_delivery_amt')
show_description = fields.Boolean(string='Show Description', help="Show Description when print po", default=True)
+ price_unit_before = fields.Float(string='Unit Price Before', help="Harga awal yang sebelumnya telah diinputkan")
+
+ @api.onchange('price_unit')
+ def _onchange_price_unit_before(self):
+ if self._origin:
+ self.price_unit_before = self._origin.price_unit
def _compute_doc_delivery_amt(self):
for line in self: