summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/update_date_planned_po_wizard.py
diff options
context:
space:
mode:
authorIndoteknik . <it@fixcomart.co.id>2025-08-09 14:45:48 +0700
committerIndoteknik . <it@fixcomart.co.id>2025-08-09 14:45:48 +0700
commit979ffc90fffe2f09788016376d71a940a28f8fed (patch)
treea5408296eb204a0a5066578664ed0acb13174f27 /indoteknik_custom/models/update_date_planned_po_wizard.py
parent33621956bdb9d807b480eda44ce7f2152f508695 (diff)
parentdf5ff0fc9bcd45c19b74288d8e5cfee018ba5bdd (diff)
Merge branch 'odoo-backup' of https://bitbucket.org/altafixco/indoteknik-addons into pum-v2
Diffstat (limited to 'indoteknik_custom/models/update_date_planned_po_wizard.py')
-rw-r--r--indoteknik_custom/models/update_date_planned_po_wizard.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/indoteknik_custom/models/update_date_planned_po_wizard.py b/indoteknik_custom/models/update_date_planned_po_wizard.py
new file mode 100644
index 00000000..a0d241c8
--- /dev/null
+++ b/indoteknik_custom/models/update_date_planned_po_wizard.py
@@ -0,0 +1,14 @@
+from odoo import models, fields, api
+
+class PurchaseOrderUpdateDateWizard(models.TransientModel):
+ _name = 'purchase.order.update.date.wizard'
+ _description = 'Wizard to Update Receipt Date on Purchase Order Lines'
+
+ date_planned = fields.Datetime(string="New Receipt Date", required=True)
+
+ def action_update_date(self):
+ active_ids = self.env.context.get('active_ids', [])
+ orders = self.env['purchase.order'].browse(active_ids)
+ for order in orders:
+ order.write({'date_planned': self.date_planned})
+ return {'type': 'ir.actions.act_window_close'}