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

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

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