diff --git a/h5/pages/buy/choose/choose.vue b/h5/pages/buy/choose/choose.vue index 57965ba..00619ce 100644 --- a/h5/pages/buy/choose/choose.vue +++ b/h5/pages/buy/choose/choose.vue @@ -46,7 +46,7 @@ // } // ]; // } else { - button_list.value = response.data.list; + button_list.value = response.data.list; // } }); }; @@ -74,10 +74,16 @@ const buttonClick = (info) => { if (!!info.url) { - if (info.id) { - $store.setCheckupTypeId({ - id: info.id - }); + if (!!info.id) { + if (Number(info.id) !== 6) { + $store.setCheckupTypeId({ + id: info.id + }); + } else { + $store.setCheckupTypeId({ + id: '' + }); + } } $store.setComboContrast([]); // 清空套餐对比 $store.setYytjInfo({}); diff --git a/h5/pages/main/ysdate/ysdate.vue b/h5/pages/main/ysdate/ysdate.vue index 3c85f06..ed65ca2 100644 --- a/h5/pages/main/ysdate/ysdate.vue +++ b/h5/pages/main/ysdate/ysdate.vue @@ -33,9 +33,7 @@ const setDefaultInfo = () => { yytjInfo.value = $store.getYytjInfo(); buyInfo.value = $store.getBuyInfo(); - $store.setCheckupTypeId({ - id: 1 - }) + // $store.setCheckupTypeId({}) yytjInfo.value = { nmr_list: [], doctor_date: "", @@ -56,16 +54,17 @@ getnmrList() } const getUserInfo = async () => { + uni.showLoading({ + title: "加载中", + }); const response = await $api('UserInfo') + uni.hideLoading(); $response(response, () => { $store.setUser(response.data.info); setDefaultInfo() }) } const mountedAction = async () => { - uni.showLoading({ - title: "加载中", - }); await getUserInfo() }; @@ -76,43 +75,23 @@ }); const getnmrList = async () => { - const response = await $api("BuyInfo", buyInfo.value); - $response(response, () => { - uni.hideLoading(); - let date = null - if (!!yytjInfo.value.doctor_date) { - date = yytjInfo.value.doctor_date - currentDate.value = yytjInfo.value.doctor_date - } else { - currentDate.value = getToday(); - yytjInfo.value.doctor_date = currentDate.value; - } - moreTime(date, 1); - }); + let date = null + if (!!yytjInfo.value.doctor_date) { + date = yytjInfo.value.doctor_date + currentDate.value = yytjInfo.value.doctor_date + } else { + currentDate.value = getToday(); + yytjInfo.value.doctor_date = currentDate.value; + } + moreTime(date, 1); }; const moreTime = async (m, status) => { - uni.showLoading({ - title: "加载中" - }); const [year, month, day] = currentDate.value.split("-"); let dqmonth = m || `${year}-${month}`; //年 月份 let obj = {}; let methods = ""; - obj = { - hospital: buyInfo.value.hospital, - person_id: buyInfo.value.person_id, - month: dqmonth, //月份 - use_type: 1, - checkup_type_id: 1, - amount: 0, - }; - const response = await $api("GetMonthPlanCount", obj); - $response(response, () => { - rl_list.value = []; - calendarShow.value = true; - uni.hideLoading(); - }); + calendarShow.value = true; }; const monthSwitch = (givenDate) => { diff --git a/h5/pages/main/yytjsj/yytjsj.vue b/h5/pages/main/yytjsj/yytjsj.vue index ab78402..6367b61 100755 --- a/h5/pages/main/yytjsj/yytjsj.vue +++ b/h5/pages/main/yytjsj/yytjsj.vue @@ -391,7 +391,8 @@ if (item.status == 2) { uni.$lu.toast("该号源已被其他人预约"); return; - } + } + let pick_day = 3 let active_item = yytjInfo.value.nmr_list[nmrIndex.value] if (active_item.item_id !== -1) { // 这个是 核磁项目 判断时间 @@ -399,7 +400,6 @@ let doctor_time = new Date(yytjInfo.value.doctor_date) / 1 let choose_time = new Date(item.date) / 1 let day_check = '' - let pick_day = 3 if (doctor_time > choose_time) { day_check = `请选择${yytjInfo.value.doctor_date}之后${pick_day}天以内的日期` } else { @@ -425,7 +425,6 @@ let heci_time = new Date(heci_item.time.split(' ')[0]) / 1 let choose_time = new Date(item.date) / 1 let day_check = '' - let pick_day = 3 if (choose_time > heci_time) { day_check = `请选择${heci_item.time.split(' ')[0]}之前${pick_day}天以内的日期` } else {