From 359eae14cc355bbda5619ed83d88d1da2917a0d6 Mon Sep 17 00:00:00 2001 From: yuxianghui <3437689193@qq.com> Date: Thu, 13 Mar 2025 15:32:12 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E5=AE=8C=E6=88=90=20=E5=88=B6?= =?UTF-8?q?=E9=80=A0=E8=AE=A2=E5=8D=95=E5=86=85=E5=A4=96=E5=8D=8F=E8=B0=83?= =?UTF-8?q?=E6=8B=A8=E5=8D=95=E8=B4=A8=E9=87=8F=E6=A3=80=E6=9F=A5=E4=B8=8D?= =?UTF-8?q?=E9=80=9A=E8=BF=87=EF=BC=8C=E7=82=B9=E5=87=BB=E8=B7=B3=E8=BD=AC?= =?UTF-8?q?=E8=B4=A8=E9=87=8F=E6=A3=80=E6=9F=A5=E9=A1=B5=E9=9D=A2=E6=8A=A5?= =?UTF-8?q?=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mrp_workorder/models/quality.py | 1 - quality_control/models/stock_picking.py | 8 ++------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/mrp_workorder/models/quality.py b/mrp_workorder/models/quality.py index 7867c029..a0797b61 100644 --- a/mrp_workorder/models/quality.py +++ b/mrp_workorder/models/quality.py @@ -190,7 +190,6 @@ class QualityCheck(models.Model): # doubly linked chain for tablet view navigation next_check_id = fields.Many2one('quality.check') previous_check_id = fields.Many2one('quality.check') - # is_produced = fields.Boolean(string="Has Been Produced") # For components registration move_id = fields.Many2one( diff --git a/quality_control/models/stock_picking.py b/quality_control/models/stock_picking.py index bc8638d7..243ffd18 100644 --- a/quality_control/models/stock_picking.py +++ b/quality_control/models/stock_picking.py @@ -108,15 +108,11 @@ class StockPicking(models.Model): def action_open_quality_check_picking(self): action = self.env["ir.actions.actions"]._for_xml_id("quality_control.quality_check_action_picking") - action['context'] = self.env.context.copy() - keys_to_remove = [key for key in action['context'] if key.startswith('default_')] - for key in keys_to_remove: - del action['context'][key] - action['context'].update({ + action['context'] = { 'search_default_picking_id': [self.id], 'default_picking_id': self.id, 'show_lots_text': self.show_lots_text, - }) + } return action def button_quality_alert(self):