This commit is contained in:
zmj 2024-06-24 14:07:32 +08:00
parent 242cc21a92
commit 57fa7980cf
2 changed files with 15 additions and 23 deletions

View File

@ -1,8 +1,8 @@
let BASE_URL
import store from "@/store/user.js"
// 环境
// let env = "dev"
let env = "prod"
let env = "dev"
// let env = "prod"
// let env = "liu";
switch (env) {

View File

@ -247,8 +247,8 @@
import useUserStore from "@/store/user";
const userStore = useUserStore();
const STORE_INFO = reactive({
id: 23,
store_name: "农(特)产品直营店"
id: '',
store_name: ""
})
const getStoreInfoFn = () => {
@ -370,8 +370,7 @@
name: '',
order: '',
store_name: '',
// store_id: 23
store_id: 4
store_id: ''
})
const loading = ref(true);
@ -387,8 +386,7 @@
if (class_all) class_id = ""; //
if (loadmore) where.value.page_no++;
else where.value.page_no = 1;
// where.value.store_id = 23
where.value.store_id = 4
console.log('where------------', where.value)
goodListApi({
...where.value,
class_all: class_all,
@ -397,11 +395,6 @@
}).then(res => {
if (loadmore) goodList.value.push(...res.data.lists);
else goodList.value = res.data.lists;
//
// if (!STORE_INFO.store_name || !STORE_INFO.detailed_address) {
// STORE_INFO.store_name = res.data.store.name;
// STORE_INFO.value.detailed_address = res.data.store.detailed_address;
// }
})
}
@ -423,9 +416,7 @@
page_no: page_no,
page_size: 30,
level: three,
// store_id: STORE_INFO.id // id
// store_id: 23 // id
store_id: 4 // id
store_id: STORE_INFO.id // id
}).then(res => {
if (pid == 0) { //
if (!res.data?.lists?.length) return;
@ -527,10 +518,7 @@
const openGoodPopup = (item) => { // /
goodData.value = item;
goodRef.value.setData(item);
// goodRef.value.founcsFn();
showGoodPopup.value = true;
//访
productLogApi({
product_id: item.product_id,
@ -609,13 +597,17 @@
getShareInfo()
onLoad(async (opt) => {
where.value.store_id = opt.id || STORE_INFO.id;
// id
if (opt.id) {
where.value.store_id = (opt.id == 'undefined' ? STORE_INFO.id : opt.id);
} else {
where.value.store_id = STORE_INFO.id
}
// id
if (opt.id && opt.id != 'undefined') {
console.log(opt.id, opt.id != 'undefined', "进来了这里")
where.value.store_id = opt.id;
const info = await shopDetailApi({
store_id: 4
// store_id: 23
store_id: where.value.store_id
});
//
if (opt.spread_uid) {