提交 46732f7b 编写于 作者: yi.li's avatar yi.li

预约校验增加是否超过发送时间范围的字段

上级 74828ec3
......@@ -192,22 +192,27 @@
//校验额度是否不够
getCheckReservation({
content: '',
validContents: this.validContents
validContents: _self.validContents
}).then(({data}) => {
const sendFlagLast = data.sendFlag;
const inServiceTimeFlag = data.inServiceTimeFlag;
if(sendFlagLast){ //额度还可用
sendReservation({
...this.reservationForm,
patientAppointList: this.selectList
patientAppointList: _self.selectList
}).then(({data}) => {
this.$refs['reservationForm'].resetFields();
this.$emit('closeSendReserve',false);
_self.$refs['reservationForm'].resetFields();
_self.$emit('closeSendReserve',false);
})
}else {
console.log('余额不足')
// 额度不足
this.isNoEnoughShow = true;
return;
if(!inServiceTimeFlag) {
_self.$message.warning('已超过发送时间范围!');
return;
}else {
// 额度不足
_self.isNoEnoughShow = true;
return;
}
}
})
} else {
......
......@@ -281,12 +281,17 @@
content: '',
validContents:this.validContents
})
const { sendFlag } = this.checkRevervationData
const { sendFlag, inServiceTimeFlag } = this.checkRevervationData
//判断短信余额是否不足
if(sendFlag){
this.isDialogShow = true;
}else {
this.isNoEnoughShow = true;
if(!inServiceTimeFlag) {
this.$message.warning('已超过发送时间范围!');
return;
}else {
this.isNoEnoughShow = true;
}
}
},
sendReservation() {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册