From 20bbafde9f231c1d5cef318fe4bd0c26ca99fa79 Mon Sep 17 00:00:00 2001 From: pengm <674192343@qq.com> Date: Tue, 24 Jun 2025 18:04:30 +0800 Subject: [PATCH] 1.处理格式不正确翻译 --- src/components/Common/CommonComponent/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/Common/CommonComponent/index.js b/src/components/Common/CommonComponent/index.js index c270fe7..0791836 100644 --- a/src/components/Common/CommonComponent/index.js +++ b/src/components/Common/CommonComponent/index.js @@ -340,6 +340,7 @@ export default class CommonComponent extends Component { const sDateFormatTypeList = ['phone', 'mobile', 'mail', 'postcode']; const { sName, showName, sDateFormat } = this.props.showConfig; const { record } = this.props; + const IncorrectFormat = commonFunc.showLocalMessage(this.props, 'IncorrectFormat', '格式不正确'); const value = record[sName]; if ( value !== undefined && value !== '' && sDateFormatTypeList.includes(sDateFormat) @@ -372,8 +373,8 @@ export default class CommonComponent extends Component { } if (flag) { - this.props.onChange(this.props.name, 'verificationFailed', { verificationFailed: true, verificationFailedMsg: `【${showName}】【${sName}】格式不正确!` }, this.props.sId, []); - message.warning(`【${showName}】【${sName}】格式不正确!`); + this.props.onChange(this.props.name, 'verificationFailed', { verificationFailed: true, verificationFailedMsg: `【${showName}】【${sName}】${IncorrectFormat}!` }, this.props.sId, []); + message.warning(`【${showName}】【${sName}】${IncorrectFormat}!`); } else if (record.verificationFailed) { record.verificationFailed = undefined; } -- libgit2 0.22.2