修改文件名字,修复因为url长导致页面卡死的问题

wenjuan
刘佳宇 1 year ago
parent d46dae45a6
commit 6a2db40e55

@ -60,7 +60,7 @@
} }
}, },
{ {
"path": "pages/main/optionalProject/optionalProject", "path": "pages/main/tj/tjzx",
"style": { "style": {
"navigationBarTitleText": "体检套餐加项", "navigationBarTitleText": "体检套餐加项",
"navigationBarBackgroundColor": "#D8EDF2", "navigationBarBackgroundColor": "#D8EDF2",
@ -74,7 +74,7 @@
} }
}, },
{ {
"path": "pages/main/optionalProject/optionalDetails", "path": "pages/main/tj/tjxq",
"style": { "style": {
"navigationBarTitleText": "套餐详情", "navigationBarTitleText": "套餐详情",
"navigationBarBackgroundColor": "#239EA3", "navigationBarBackgroundColor": "#239EA3",
@ -97,14 +97,14 @@
} }
}, },
{ {
"path": "pages/main/optionalProject/choose", "path": "pages/main/tj/choose",
"style": { "style": {
"navigationBarTitleText": "团检预约", "navigationBarTitleText": "团检预约",
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
}, },
{ {
"path": "pages/main/optionalProject/selectType", "path": "pages/main/tj/selectType",
"style": { "style": {
"navigationBarTitleText": "团检预约", "navigationBarTitleText": "团检预约",
"enablePullDownRefresh": false "enablePullDownRefresh": false

@ -166,7 +166,7 @@ const buyClick = async (item) => {
// ID // ID
// / // /
uni.navigateTo({ uni.navigateTo({
url: "/pages/main/optionalProject/optionalDetails" + query, url: "/pages/main/tj/tjxq" + query,
}); });
}; };
</script> </script>

@ -67,13 +67,13 @@ const getGroupCombo = async (info) => {
if (!data.items.length && data.tongshou_xiane > 0) { if (!data.items.length && data.tongshou_xiane > 0) {
// //
uni.navigateTo({ uni.navigateTo({
url: "/pages/main/optionalProject/selectType" url: "/pages/main/tj/selectType"
}); });
} else { } else {
// //
uni.navigateTo({ uni.navigateTo({
url: url:
"/pages/main/optionalProject/optionalDetails?groupId=" + "/pages/main/tj/tjxq?groupId=" +
info.group_id info.group_id
}); });
} }

@ -36,7 +36,7 @@ const toDetails = (type) => {
if(type == 1){ if(type == 1){
url = "/pages/main/combo/combo?groupId=" + groupInfo.value.group_id; url = "/pages/main/combo/combo?groupId=" + groupInfo.value.group_id;
}else{ }else{
url = "/pages/main/optionalProject/optionalProject?groupId=" + groupInfo.value.group_id; url = "/pages/main/tj/tjzx?groupId=" + groupInfo.value.group_id;
} }
uni.navigateTo({ uni.navigateTo({
url: url, url: url,

@ -159,7 +159,7 @@ const addCombo = () => {
query += "&groupId=" + groupId.value; query += "&groupId=" + groupId.value;
} }
uni.navigateTo({ uni.navigateTo({
url: "/pages/main/optionalProject/optionalProject?" + query, url: "/pages/main/tj/tjzx?" + query,
}); });
}; };

@ -199,7 +199,7 @@ const toDetails = (state) => {
() => { () => {
clearTimeout(time); clearTimeout(time);
uni.navigateTo({ uni.navigateTo({
url: "/pages/main/optionalProject/optionalDetails" + query, url: "/pages/main/tj/tjxq" + query,
}); });
}, },
delta == 2 ? 800 : 500 delta == 2 ? 800 : 500
@ -247,26 +247,20 @@ const mountedAction = async () => {
await getAllItems(); // await getAllItems(); //
// await getComboRecommend(); // await getComboRecommend();
getBuyInfo(); // await getBuyInfo(); //
}; };
const config_ref = ref(null); const config_ref = ref(null);
const configRef = (e) => { const configRef = (e) => {
if (!config_ref.value) { if (!config_ref.value) {
config_ref.value = e; config_ref.value = e;
let time = setTimeout(() => { mountedAction();
clearTimeout(time);
mountedAction();
}, 500);
} }
}; };
onShow(() => { onShow(() => {
if (!!config_ref.value) { if (!!config_ref.value) {
let time = setTimeout(() => { mountedAction();
clearTimeout(time);
mountedAction();
}, 500);
} }
}); });
</script> </script>

@ -70,27 +70,30 @@ const comfrimyy = async () => {
// uni.$lu.toast(""); // uni.$lu.toast("");
// return; // return;
// } // }
console.log(yytjInfo.value?.nmr_list); // console.log(yytjInfo.value?.nmr_list);
for(let i = 0; i < yytjInfo.value?.nmr_list?.length; i++){ // for(let i = 0; i < yytjInfo.value?.nmr_list?.length; i++){
if(!yytjInfo.value?.nmr_list[i].time){ // if(!yytjInfo.value?.nmr_list[i].time){
uni.$lu.toast("请选择预约时间"); // uni.$lu.toast("");
return; // return;
} // }
} // }
if(yytjInfo.value?.nmr_list?.length > 1){ // if(yytjInfo.value?.nmr_list?.length > 1){
plan_nmr_id = yytjInfo.value?.nmr_list[0]?.id; // plan_nmr_id = yytjInfo.value?.nmr_list[0]?.id;
} // }
if(yytjInfo.value?.nmr_list?.length > 1){ // if(yytjInfo.value?.nmr_list?.length > 1){
plan_id = yytjInfo.value?.nmr_list[yytjInfo.value?.nmr_list.length - 1]?.id; // plan_id = yytjInfo.value?.nmr_list[yytjInfo.value?.nmr_list.length - 1]?.id;
} // }
console.log(groupInfo.value);
let obj = { let obj = {
person_id: buyInfo.value.person_id, person_id: buyInfo.value.person_id,
type: buyInfo.value.group_id ? 2 : 1, type: buyInfo.value.group_id ? 2 : 1,
hospital: buyInfo.value.hospital, hospital: buyInfo.value.hospital,
combo_id: buyInfo.value?.combo_id || userInfo.value?.combo_id, group_id: buyInfo.value.group_id,
combo_id: buyInfo.value?.combo_id || (groupInfo.value?.combo_id?"":userInfo.value?.combo_id) || "",
item_ids: buyInfo.value.item_ids, item_ids: buyInfo.value.item_ids,
plan_id: plan_id, plan_id: plan_id,
$plan_nmr_id: plan_nmr_id, $plan_nmr_id: plan_nmr_id,
@ -98,6 +101,7 @@ const comfrimyy = async () => {
console.log(obj); console.log(obj);
const response = await $api("OrderCreate", obj); const response = await $api("OrderCreate", obj);
// return
$response(response, () => { $response(response, () => {
if(response.status){ if(response.status){
if(response.data.action == "pay"){ if(response.data.action == "pay"){

Loading…
Cancel
Save