对接接口

This commit is contained in:
wangxiaowei
2025-12-17 23:34:08 +08:00
parent 018a784a8c
commit df863a2f41
19 changed files with 792 additions and 389 deletions

View File

@ -164,7 +164,6 @@
})
const Index = {
handleInit: async() => {
await Index.handleGetStoreList()
@ -175,13 +174,9 @@
* 获取门店列表
*/
handleGetStoreList: async() => {
console.log("🚀 ~ Index.handleGetStoreList:", 'Index.handleGetStoreLis123')
const storeLists = await getStoreList()
// 保证 storeList.value 一定为数组
storeList.value = Array.isArray(storeLists.list) ? storeLists.list : Object.values(storeLists.list || {})
console.log("🚀 ~ storeList.value:", storeList.value)
console.log("🚀 ~ storeList.value:", storeList.value.length)
if (storeList.value.length > 0) {
useStore.setStoreList(storeList.value)
@ -204,14 +199,12 @@
if (!defaultStore.value) return
const storeDetails = await getStoreDetails(useStore.defaultStore.id)
store.value = storeDetails.details
console.log("🚀 ~ storeDetails:", storeDetails)
},
/**
* 选择扫码验券菜单
*/
handleSelectScanMenu: (item: { item: { name: string }}) => {
console.log("🚀 ~ item:", item)
if (item.item.name === '扫码验券') {
Index.handleScanCode()
} else if (item.item.name === '输入券码') {
@ -234,13 +227,6 @@
console.log('scanCode err:', err)
}
})
},
/**
* 一键续订时间
*/
handleChooseRenewTime: (item) => {
console.log("🚀 ~ item:", item)
}
}
</script>