提交 8e975692 编写于 作者: 张敬贤's avatar 张敬贤

ADD

上级 a22e8723
...@@ -19,7 +19,9 @@ const loading = { ...@@ -19,7 +19,9 @@ const loading = {
instance.show = true; instance.show = true;
}, },
hide: () => { hide: () => {
instance.show = false; setTimeout(() => {
instance.show = false;
}, 300);
}, },
}; };
}, },
......
...@@ -144,11 +144,8 @@ export default { ...@@ -144,11 +144,8 @@ export default {
console.log(data); console.log(data);
getHospitalList(data).then(res => { getHospitalList(data).then(res => {
console.log('getHospitalList', res); console.log('getHospitalList', res);
if (isLoad) {
this.list = [...this.list, ...res.data.data]; this.list = res.data.data;
} else {
this.list = res.data.data;
}
if (res.data.data.length < this.pageSize) { if (res.data.data.length < this.pageSize) {
this.finished = true; this.finished = true;
} }
......
...@@ -13,7 +13,11 @@ ...@@ -13,7 +13,11 @@
及时接受检测结果检测报告 及时接受检测结果检测报告
</div> </div>
<div class="choose-section"> <div class="choose-section">
<van-form @submit="onSubmit"> <van-form
ref="dectionForm"
validate-first
@submit="onSubmit"
>
<van-field <van-field
name="checkboxGroup" name="checkboxGroup"
label="检测项目" label="检测项目"
...@@ -291,7 +295,7 @@ export default { ...@@ -291,7 +295,7 @@ export default {
}, },
mounted() { mounted() {
this.$loading.show();
const { yunOrderNo, projectEquityNo } = this.$route.query; const { yunOrderNo, projectEquityNo } = this.$route.query;
this.yunOrderNo = yunOrderNo; this.yunOrderNo = yunOrderNo;
this.projectEquityNo = projectEquityNo; this.projectEquityNo = projectEquityNo;
...@@ -344,6 +348,8 @@ export default { ...@@ -344,6 +348,8 @@ export default {
this.dectionForm.detectName = dectionData.detectionName; this.dectionForm.detectName = dectionData.detectionName;
this.dectionForm.goodsId = dectionData.goodsId; this.dectionForm.goodsId = dectionData.goodsId;
this.$store.dispatch('home/setInsuranceInfo', dectionData); this.$store.dispatch('home/setInsuranceInfo', dectionData);
this.$loading.hide();
} }
}); });
}, },
...@@ -356,6 +362,7 @@ export default { ...@@ -356,6 +362,7 @@ export default {
this.dectionForm.beneficiaryIdNum = res.data.beneficiaryIdNum; this.dectionForm.beneficiaryIdNum = res.data.beneficiaryIdNum;
this.isDisabled = (this.dectionForm.beneficiaryName != '' && this.dectionForm.beneficiaryPhone != '' && this.dectionForm.beneficiaryIdNum != '') && (this.dectionForm.beneficiaryName && this.dectionForm.beneficiaryPhone && this.dectionForm.beneficiaryIdNum ); this.isDisabled = (this.dectionForm.beneficiaryName != '' && this.dectionForm.beneficiaryPhone != '' && this.dectionForm.beneficiaryIdNum != '') && (this.dectionForm.beneficiaryName && this.dectionForm.beneficiaryPhone && this.dectionForm.beneficiaryIdNum );
this.$store.dispatch('home/setOrderInfo', res.data); this.$store.dispatch('home/setOrderInfo', res.data);
this.$loading.hide();
}); });
}, },
...@@ -392,30 +399,37 @@ export default { ...@@ -392,30 +399,37 @@ export default {
cancelSearch() {}, cancelSearch() {},
selectAddress() {}, selectAddress() {},
appointment() { appointment() {
console.log(this.dectionForm); this.$loading.show();
const data = { this.$refs.dectionForm.validate().then(result => {
appointmentTime: this.dectionForm.appointmentTime, console.log('this.dectionForm', result);
goodsId: this.dectionForm.goodsId, const data = {
hospitalId: this.hospitalId, appointmentTime: this.dectionForm.appointmentTime,
hospitalName: this.dectionForm.hospitalName, goodsId: this.dectionForm.goodsId,
patientIdNo: this.dectionForm.beneficiaryIdNum, hospitalId: this.hospitalId,
patientMobile: this.dectionForm.beneficiaryPhone, hospitalName: this.dectionForm.hospitalName,
patientName: this.dectionForm.beneficiaryName, patientIdNo: this.dectionForm.beneficiaryIdNum,
yunOrderNo:this.yunOrderNo, patientMobile: this.dectionForm.beneficiaryPhone,
}; patientName: this.dectionForm.beneficiaryName,
appointment(data).then(res => { yunOrderNo:this.yunOrderNo,
if (res.code === '000000') { };
this.$router.push({ appointment(data).then(res => {
path: '/appoint-details', this.$loading.hide();
query: { if (res.code === '000000') {
yunOrderNo: this.yunOrderNo, this.$router.push({
projectEquityNo:this.projectEquityNo path: '/appoint-details',
} query: {
}); yunOrderNo: this.yunOrderNo,
} projectEquityNo:this.projectEquityNo
}
});
}
});
}).catch(err => {
this.$loading.hide();
console.log(err);
}); });
}, },
getDetailByUnionId() { }, getDetailByUnionId() { },
confirm(values) { confirm(values) {
console.log('confirm', values); console.log('confirm', values);
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册