From cec6ea62dfe8394ae03b2eb06d35e54888357174 Mon Sep 17 00:00:00 2001
From: YeMingfei666 <1619116647@qq.com>
Date: Fri, 7 Mar 2025 19:29:10 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E7=BE=8E=E5=9B=A2?=
=?UTF-8?q?=E6=8A=96=E9=9F=B3=E6=89=AB=E7=A0=81=E6=A0=B8=E9=94=80?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/store/modules/carts.ts | 6 +-
src/utils/request-php.js | 2 +-
src/views/login/index.vue | 2 -
.../Instead/components/choose-quan-goods.vue | 160 +++++++++++++
.../components/douyin-quan-bind-shop.vue | 208 +++++++++++++++++
.../Instead/components/popup-quan-hexiao.vue | 217 ++++++++++++++++++
src/views/tool/Instead/index.vue | 11 +-
7 files changed, 600 insertions(+), 6 deletions(-)
create mode 100644 src/views/tool/Instead/components/choose-quan-goods.vue
create mode 100644 src/views/tool/Instead/components/douyin-quan-bind-shop.vue
create mode 100644 src/views/tool/Instead/components/popup-quan-hexiao.vue
diff --git a/src/store/modules/carts.ts b/src/store/modules/carts.ts
index 23139c6..13b2238 100644
--- a/src/store/modules/carts.ts
+++ b/src/store/modules/carts.ts
@@ -432,8 +432,10 @@ export const useCartsStore = defineStore("carts", () => {
// console.log('oldOrder.detailMap', oldOrder.value.detailMap)
// const cache_table_code = localStorage.getItem('cache_table_code');
// const randomTableCode = cache_table_code ? cache_table_code : ('APC' + (1000 + Math.floor(Math.random() * 9000)))
- initParams.table_code = initParams.table_code ? initParams.table_code : ''
- table_code.value = initParams.table_code
+ if (initParams) {
+ initParams.table_code = initParams.table_code ? initParams.table_code : ''
+ table_code.value = initParams.table_code
+ }
// localStorage.setItem('cache_table_code', table_code.value);
WebSocketManager.subscribeToTopic(initParams, (msg) => {
diff --git a/src/utils/request-php.js b/src/utils/request-php.js
index d3928f5..8e70537 100644
--- a/src/utils/request-php.js
+++ b/src/utils/request-php.js
@@ -35,7 +35,7 @@ service.interceptors.response.use(
});
return;
}
- if (data.code == 439) {
+ if (data.code == 439 || data.code == 303) {
ElNotification.error({
title: "请登录",
duration: 5000,
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index 0e86cc5..94a1203 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -193,9 +193,7 @@ function handleLogin() {
.then(async (res) => {
await userStore.getUserInfo();
await $douyin_checkIn();
-
const { path, queryParams } = parseRedirect();
- console.log(res, "Denglv返回");
router.push({ path: path, query: queryParams });
})
.catch(() => {
diff --git a/src/views/tool/Instead/components/choose-quan-goods.vue b/src/views/tool/Instead/components/choose-quan-goods.vue
new file mode 100644
index 0000000..c959879
--- /dev/null
+++ b/src/views/tool/Instead/components/choose-quan-goods.vue
@@ -0,0 +1,160 @@
+
+