summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/purchase_order.py
diff options
context:
space:
mode:
authorAzka Nathan <darizkyfaz@gmail.com>2024-05-03 10:28:31 +0700
committerAzka Nathan <darizkyfaz@gmail.com>2024-05-03 10:28:31 +0700
commit7bf5ed2c7892da0b56554b1d6fa8badd687080e7 (patch)
tree9efe5cb37ba4b43bd245e5790f7a17a618556c4a /indoteknik_custom/models/purchase_order.py
parent181357dc01f84a47fd63209bc6a6dd4f085a718b (diff)
change request add so on stock picking and fix bug double so on po
Diffstat (limited to 'indoteknik_custom/models/purchase_order.py')
-rwxr-xr-xindoteknik_custom/models/purchase_order.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/indoteknik_custom/models/purchase_order.py b/indoteknik_custom/models/purchase_order.py
index be971307..5946399d 100755
--- a/indoteknik_custom/models/purchase_order.py
+++ b/indoteknik_custom/models/purchase_order.py
@@ -1,5 +1,6 @@
from odoo import fields, models, api, _
from odoo.exceptions import AccessError, UserError, ValidationError
+from dateutil.relativedelta import relativedelta
from datetime import datetime, timedelta
import logging
from pytz import timezone, utc
@@ -315,6 +316,7 @@ class PurchaseOrder(models.Model):
'qty_available_store': qty_available,
# 'suggest': suggest,
'so_line_id': order_line.id,
+ 'so_id': order_line.order_id.id,
}
self.order_line.create(values)
for order_line in self.order_line: