提交 0c229c5e authored 作者: 贺阳's avatar 贺阳

转单号重复的提示和翻译优化

上级 c093c4a1
差异被折叠。
...@@ -575,12 +575,12 @@ class CcBL(models.Model): ...@@ -575,12 +575,12 @@ class CcBL(models.Model):
bl_no = self.env['common.common'].sudo().process_match_str(record.bl_no) bl_no = self.env['common.common'].sudo().process_match_str(record.bl_no)
transfer_bl_no = self.env['common.common'].sudo().process_match_str(record.transfer_bl_no) transfer_bl_no = self.env['common.common'].sudo().process_match_str(record.transfer_bl_no)
if bl_no and transfer_bl_no == bl_no: if bl_no and transfer_bl_no == bl_no:
raise ValidationError(_('The Transfer B/L No. cannot be the same as the B/L No.')) raise ValidationError(_('Transfer B/L No. cannot be the same as B/L No.'))#转单号不能与提单号重复
# 2. 不能与其他单据的提单号重复 # 2. 不能与其他单据的提单号重复
other = self.env['cc.bl'].deal_bl_no_and_transfer_bl_no(transfer_bl_no, other = self.env['cc.bl'].deal_bl_no_and_transfer_bl_no(transfer_bl_no,
domain=[('id', '!=', record.id)]) domain=[('id', '!=', record.id)])
if other: if other:
raise ValidationError(_('The Transfer B/L No. cannot be the same as the B/L No.')) raise ValidationError(_('Transfer B/L No. cannot be the same as B/L No. or Transfer B/L No.'))#转单号不能与提单号或转单号重复
@api.depends('big_package_ids', 'big_package_ids.tally_state', 'big_package_ids.is_cancel') @api.depends('big_package_ids', 'big_package_ids.tally_state', 'big_package_ids.is_cancel')
def cal_tally_big_package_qty(self): def cal_tally_big_package_qty(self):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论