From d5c82e4a28bbb80e7f5524aa5e82b654b27e8ed8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=83=A1=E5=B0=A7?= Date: Wed, 11 Sep 2024 10:40:26 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BB=A3=E7=A0=81=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/agv_scheduling.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sf_manufacturing/models/agv_scheduling.py b/sf_manufacturing/models/agv_scheduling.py index f758abd9..a18dc5ef 100644 --- a/sf_manufacturing/models/agv_scheduling.py +++ b/sf_manufacturing/models/agv_scheduling.py @@ -1,10 +1,10 @@ + +import logging import requests from odoo import models, fields, api, _ from odoo.exceptions import UserError -import logging - _logger = logging.getLogger(__name__) @@ -54,7 +54,7 @@ class AgvScheduling(models.Model): def web_search_read(self, domain=None, fields=None, offset=0, limit=None, order=None, count_limit=None): domain = domain or [] new_domain = [] - for index, item in enumerate(domain): + for item in domain: if isinstance(item, list): if item[0] == 'delivery_workpieces': new_domain.append('&') @@ -63,7 +63,7 @@ class AgvScheduling(models.Model): continue new_domain.append(item) - return super(AgvScheduling, self).web_search_read(new_domain, fields, limit=limit, offset=offset) + return super(AgvScheduling, self).web_search_read(new_domain, fields, offset, limit, order, count_limit) @api.depends('task_completion_time', 'task_delivery_time') def _compute_task_duration(self):