点击选择医生时,如果号源没选,返回时不展示日期(年月日),但默认把医生的日期设为默认

wenjuan
刘佳宇 1 year ago
parent c281c3b5f9
commit 6642a61f39

@ -182,6 +182,9 @@ const getTjTimeList = async (val) => {
}; };
apiText = "NMRGetDayPlanList"; apiText = "NMRGetDayPlanList";
} }
uni.showLoading({
title: "加载中",
});
const response = await $api(apiText, obj); const response = await $api(apiText, obj);
$response(response, () => { $response(response, () => {
console.log(response, "response"); console.log(response, "response");
@ -221,8 +224,8 @@ const changerl = (e) => {
if (isClickDoctor.value == 1) { if (isClickDoctor.value == 1) {
// //
status.value = 0; status.value = 0;
yytjInfo.value.nmr_list[yytjInfo.value.nmr_list.length - 1].time = // yytjInfo.value.nmr_list[yytjInfo.value.nmr_list.length - 1].time =
e.fulldate; // e.fulldate;
yytjInfo.value.doctor_date = e.fulldate; yytjInfo.value.doctor_date = e.fulldate;
$store.setYytjInfo(yytjInfo.value); $store.setYytjInfo(yytjInfo.value);
uni.navigateTo({ uni.navigateTo({
@ -233,9 +236,9 @@ const changerl = (e) => {
calendarShow.value = false; calendarShow.value = false;
return; return;
} }
uni.showLoading({ // uni.showLoading({
title: "加载中", // title: "",
}); // });
currentDate.value = e.fulldate; currentDate.value = e.fulldate;
time.value = ""; time.value = "";
timeIndex.value = null; timeIndex.value = null;
@ -264,9 +267,9 @@ const getCurrentClick = (item, i) => {
return { return {
...val, ...val,
time: "", time: "",
id: "" id: "",
} };
}) });
} }
time.value = ""; time.value = "";
timeIndex.value = null; timeIndex.value = null;
@ -308,9 +311,17 @@ const xmmcClick = (val, index) => {
timeIndex.value = null; timeIndex.value = null;
if (val.time) { if (val.time) {
currentDate.value = val.time.split(" ")[0]; currentDate.value = val.time.split(" ")[0];
} else {
if (
((yytjInfo.value.nmr_list.length > 1 && index == 1) ||
(yytjInfo.value.nmr_list.length == 1 && index == 0)) &&
yytjInfo.value.doctor_date
) {
currentDate.value = yytjInfo.value.doctor_date;
} else { } else {
currentDate.value = getToday(); currentDate.value = getToday();
} }
}
// //
getTjTimeList(val); getTjTimeList(val);
}; };

Loading…
Cancel
Save