1
This commit is contained in:
+18
-7
@@ -23,8 +23,10 @@ layout("/layouts/platform_h5.html"){
|
|||||||
<van-button round type="primary" size="large" color="#2cabdd" class="buttonClass" @click="selectPhysicalExaminationHospital"><van-icon name="records-o" size="27px"/> 选择体检医院</van-button>
|
<van-button round type="primary" size="large" color="#2cabdd" class="buttonClass" @click="selectPhysicalExaminationHospital"><van-icon name="records-o" size="27px"/> 选择体检医院</van-button>
|
||||||
<van-button round type="primary" size="large" color="#eca807" class="buttonClass" @click="minePhysicalExaminationHospital"><van-icon name="idcard" size="27px"/> 我的体检医院</van-button>
|
<van-button round type="primary" size="large" color="#eca807" class="buttonClass" @click="minePhysicalExaminationHospital"><van-icon name="idcard" size="27px"/> 我的体检医院</van-button>
|
||||||
</div>
|
</div>
|
||||||
<van-dialog v-model="show" title="温馨提醒" v-if="show" @confirm="confirmClick"
|
<van-dialog v-model="show" title="温馨提醒" @confirm="confirmClick"
|
||||||
:confirm-button-text="confirmButtonText">
|
:confirm-button-text="confirmButtonText"
|
||||||
|
:before-close="test"
|
||||||
|
:confirm-button-disabled="confirmDisabled">
|
||||||
<div class="dialog-content">
|
<div class="dialog-content">
|
||||||
<div style="white-space: pre-line">{{project.friendlyReminderText}}</div>
|
<div style="white-space: pre-line">{{project.friendlyReminderText}}</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -46,9 +48,18 @@ layout("/layouts/platform_h5.html"){
|
|||||||
friendlyReminderText: "",
|
friendlyReminderText: "",
|
||||||
},
|
},
|
||||||
baseLoc: "",
|
baseLoc: "",
|
||||||
|
count: 5,
|
||||||
|
confirmDisabled: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
test(action, done) {
|
||||||
|
if (action === 'confirm' && this.count > 0) {
|
||||||
|
done(false);
|
||||||
|
} else {
|
||||||
|
done();
|
||||||
|
}
|
||||||
|
},
|
||||||
userMessage() {
|
userMessage() {
|
||||||
this.$pjaxReplace("/platform/healthCheckup/h5/userBaseMessage?projectId=" + this.project.id);
|
this.$pjaxReplace("/platform/healthCheckup/h5/userBaseMessage?projectId=" + this.project.id);
|
||||||
},
|
},
|
||||||
@@ -77,12 +88,12 @@ layout("/layouts/platform_h5.html"){
|
|||||||
let friendlyReminderStatus = sessionStorage.getItem("friendlyReminderStatus");
|
let friendlyReminderStatus = sessionStorage.getItem("friendlyReminderStatus");
|
||||||
if (friendlyReminderStatus == "0" ) {
|
if (friendlyReminderStatus == "0" ) {
|
||||||
this.show = true;
|
this.show = true;
|
||||||
let count = 5;
|
this.confirmButtonText = '已悉知(' + this.count + ')'
|
||||||
this.confirmButtonText = '已悉知(' + count + ')'
|
|
||||||
let timer = setInterval(() => {
|
let timer = setInterval(() => {
|
||||||
count--;
|
this.count--;
|
||||||
this.confirmButtonText = '已悉知(' + count + ')'
|
this.confirmButtonText = '已悉知(' + this.count + ')'
|
||||||
if (count <= 0) {
|
if (this.count <= 0) {
|
||||||
|
this.confirmDisabled = false;
|
||||||
this.confirmButtonText = '已悉知';
|
this.confirmButtonText = '已悉知';
|
||||||
clearInterval(timer);
|
clearInterval(timer);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user