diff options
Diffstat (limited to 'indoteknik_custom/models')
| -rw-r--r-- | indoteknik_custom/models/account_move.py | 5 | ||||
| -rw-r--r-- | indoteknik_custom/models/automatic_purchase.py | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/indoteknik_custom/models/account_move.py b/indoteknik_custom/models/account_move.py index 66726c8d..4553e446 100644 --- a/indoteknik_custom/models/account_move.py +++ b/indoteknik_custom/models/account_move.py @@ -62,6 +62,11 @@ class AccountMove(models.Model): so_delivery_amt = fields.Char(string="SO Delivery Amount", compute='compute_so_shipping_paid_by') flag_delivery_amt = fields.Boolean(string="Flag Delivery Amount", compute='compute_flag_delivery_amt') nomor_kwitansi = fields.Char(string="Nomor Kwitansi") + other_subtotal = fields.Float(string="Other Subtotal", compute='compute_other_subtotal') + + def compute_other_subtotal(self): + for rec in self: + rec.other_subtotal = rec.amount_untaxed * (11 / 12) @api.model def generate_attachment(self, record): diff --git a/indoteknik_custom/models/automatic_purchase.py b/indoteknik_custom/models/automatic_purchase.py index 4e96e6d4..09d283eb 100644 --- a/indoteknik_custom/models/automatic_purchase.py +++ b/indoteknik_custom/models/automatic_purchase.py @@ -255,6 +255,7 @@ class AutomaticPurchase(models.Model): 'suggest': product._get_po_suggest(line.qty_purchase), 'product_uom_qty': line.qty_purchase, 'price_unit': line.last_price, + 'ending_price': line.last_price, 'taxes_id': [line.taxes_id.id] if line.taxes_id else None, 'so_line_id': sales_match[0].sale_line_id.id if sales_match else None, 'so_id': sales_match[0].sale_id.id if sales_match else None |
