fix: 修复营销计划兑换码验证

This commit is contained in:
zhangds 2022-10-27 16:33:17 +08:00
parent d0a88f6726
commit 6e0cf6c90a
3 changed files with 6 additions and 2 deletions

View File

@ -506,6 +506,7 @@ const UseCouponAddEdit = forwardRef((props, ref) => {
validator = true;
} else {
validator = false;
return validator;
}
//
@ -514,6 +515,7 @@ const UseCouponAddEdit = forwardRef((props, ref) => {
validator = true;
} else {
validator = false;
return validator;
}
if (validator) {

View File

@ -186,18 +186,20 @@ const UseExchangeAddEdit = forwardRef((props, ref) => {
const submit = () => {
let validator = false;
if (codeInfoEl.current.validator()) {
validator = true;
} else {
validator = false;
return validator;
}
if (codeRuleEl.current.validator()) {
validator = true;
} else {
validator = false;
return validator;
}
if (validator) {
if (state.rank.length > 0) {
let arr = state.tableData.filter((item) => item.checked);

View File

@ -233,7 +233,7 @@ export default class add extends React.Component {
}
async onNextStep() {
if (this.state.curstep >= 1) {
if ((await this.refs.step1.submit()) == true) {
if (await this.refs.step1.submit()) {
this.setState({ isload: true });
this.setState({ curstep: 2 });
} else {