Commit 86e9f5c7 authored by honghy's avatar honghy Committed by wux

【后台-会员等级-新增/修改】“等级规则有效期”要限制当设置小于当前日期时不允许保存成功

parent 261cfe44
......@@ -315,6 +315,17 @@ export default {
},
//保存
handleSaveIntegralRule(){
var now = new Date();
var nowMidnight = new Date(now.getFullYear(), now.getMonth(), now.getDate());
var specificDate = new Date(this.queryParams.startTime);
if(specificDate<nowMidnight) {
this.$modal.msgWarning('等级规则日期大于等于当前日期')
return false
}
if(this.queryParams.startTime>this.queryParams.endTime) {
this.$modal.msgWarning('等级规则日期开始时间不能大于结束时间')
return false
}
this.$refs["queryForm"].validate((valid) => {
if (valid) {
let params = deepClone(this.queryParams)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment