summaryrefslogtreecommitdiff
path: root/fixco_custom/models/purchase_order.py
diff options
context:
space:
mode:
Diffstat (limited to 'fixco_custom/models/purchase_order.py')
-rw-r--r--fixco_custom/models/purchase_order.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/fixco_custom/models/purchase_order.py b/fixco_custom/models/purchase_order.py
index a623ae4..06f4ef1 100644
--- a/fixco_custom/models/purchase_order.py
+++ b/fixco_custom/models/purchase_order.py
@@ -17,6 +17,7 @@ _logger = logging.getLogger(__name__)
class PurchaseOrder(models.Model):
_inherit = 'purchase.order'
+ sale_order_id = fields.Many2one('sale.order', string='Sales Order')
amount_discount = fields.Monetary(
string='Total Discount',
compute='_compute_amount_discount',
@@ -28,6 +29,13 @@ class PurchaseOrder(models.Model):
default=0.0,
tracking=True
)
+
+ source = fields.Selection([
+ ('requisition', 'Requisition'),
+ ('reordering', 'Reordering'),
+ ('purchasing_job', 'Purchasing Job'),
+ ('manual', 'Manual')
+ ], string='Source', default='manual')
@api.depends('order_line.price_total', 'biaya_lain_lain')
def _amount_all(self):