去掉对审批的跳过

This commit is contained in:
mgw
2024-12-26 15:42:43 +08:00
parent 9ac60ae283
commit 158ca95dbb

View File

@@ -18,18 +18,18 @@ class jikimo_purchase_tier_validation(models.Model):
# 是否已上传合同文件
is_upload_contract_file = fields.Boolean(string='是否已上传合同文件', default=False)
def button_confirm(self):
self = self.with_context(skip_validation=True)
return super().button_confirm()
def _check_state_conditions(self, vals):
self.ensure_one()
if self._context.get('skip_validation'):
return False
return (
self._check_state_from_condition()
and vals.get(self._state_field) in self._state_to
)
# def button_confirm(self):
# self = self.with_context(skip_validation=True)
# return super().button_confirm()
#
# def _check_state_conditions(self, vals):
# self.ensure_one()
# if self._context.get('skip_validation'):
# return False
# return (
# self._check_state_from_condition()
# and vals.get(self._state_field) in self._state_to
# )
def request_validation(self):
for record in self: