From 79194fb5023cb8a0a7f4749e852c95bbdb30df86 Mon Sep 17 00:00:00 2001
From: dzc <2388224167@qq.com>
Date: Wed, 29 Oct 2025 10:07:02 +0800
Subject: [PATCH] =?UTF-8?q?feat:=E4=B8=83=E7=89=9B=E4=BA=91=E4=B8=8A?=
=?UTF-8?q?=E4=BC=A0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/components/Upload/qnImages.vue | 282 ++++++++++++++++++
src/components/index.ts | 3 +
src/views/hard/hard-spu/form.vue | 9 +-
src/views/panel/index.vue | 9 +-
.../setting/components/nutrition-setting.vue | 16 +
5 files changed, 309 insertions(+), 10 deletions(-)
create mode 100644 src/components/Upload/qnImages.vue
diff --git a/src/components/Upload/qnImages.vue b/src/components/Upload/qnImages.vue
new file mode 100644
index 0000000..dafe90b
--- /dev/null
+++ b/src/components/Upload/qnImages.vue
@@ -0,0 +1,282 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/index.ts b/src/components/index.ts
index edd8a95..d91f00b 100644
--- a/src/components/index.ts
+++ b/src/components/index.ts
@@ -6,6 +6,8 @@ import UploadExcel from "/@/components/Upload/Excel.vue"
import UploadFile from "/@/components/Upload/index.vue"
import UploadImg from "/@/components/Upload/Image.vue"
import UploadImgs from "/@/components/Upload/Images.vue"
+import UploadQnImgs from "/@/components/Upload/qnImages.vue"
+
import DelWrap from "/@/components/DelWrap/index.vue"
import Editor from "/@/components/Editor/index.vue"
import Tip from "/@/components/Tip/index.vue"
@@ -67,6 +69,7 @@ export default {
app.component("UploadFile", UploadFile)
app.component("UploadImg", UploadImg)
app.component("UploadImgs", UploadImgs)
+ app.component("UploadQnImgs", UploadQnImgs)
app.component("Editor", Editor)
app.component("Tip", Tip)
app.component("DelWrap", DelWrap)
diff --git a/src/views/hard/hard-spu/form.vue b/src/views/hard/hard-spu/form.vue
index c14a7bd..29a7add 100644
--- a/src/views/hard/hard-spu/form.vue
+++ b/src/views/hard/hard-spu/form.vue
@@ -1,6 +1,7 @@
-
+
@@ -14,12 +15,12 @@
-
+
-
+
@@ -149,7 +150,7 @@ const openDialog = (id: string) => {
// 提交
const onSubmit = async () => {
- const valid = await dataFormRef.value.validate().catch(() => {})
+ const valid = await dataFormRef.value.validate().catch(() => { })
if (!valid) return false
try {
diff --git a/src/views/panel/index.vue b/src/views/panel/index.vue
index 710c205..6ce87b8 100644
--- a/src/views/panel/index.vue
+++ b/src/views/panel/index.vue
@@ -14,12 +14,9 @@ const loading = ref(false)
onMounted(async () => {
try {
- // 是否生成环境
- if (import.meta.env.VITE_ENV === "prod") {
- openPlanUrl("https://stgl.pj.gov.cn/cockpit/#/canteen")
- } else {
- openPlanUrl("http://localhost:5173/#/canteen")
- }
+ const isDev = import.meta.env.MODE === "development"
+ const url = isDev ? "http://localhost:5173/#/canteen" : "https://stgl.pj.gov.cn/cockpit/#/canteen"
+ openPlanUrl(url)
loading.value = true
router.back()
} catch (error: any) {
diff --git a/src/views/panel/setting/components/nutrition-setting.vue b/src/views/panel/setting/components/nutrition-setting.vue
index 8a31b28..9bc8df9 100644
--- a/src/views/panel/setting/components/nutrition-setting.vue
+++ b/src/views/panel/setting/components/nutrition-setting.vue
@@ -42,6 +42,19 @@
+
+
+ 今日菜品复购排行
+
+
+
+ 需要排除的菜品分类
+
+
+
+
+
@@ -66,6 +79,8 @@ const form = reactive({
scCategoryIds: [],
// 主食菜品分类
zsCategoryIds: [],
+ // 复购排行需要排除的菜品分类
+ repurchaseTopExcludeCategoryIds: [],
},
})
@@ -91,6 +106,7 @@ async function getSetting() {
hcCategoryIds: [],
scCategoryIds: [],
zsCategoryIds: [],
+ repurchaseTopExcludeCategoryIds: [],
}
}
if (data) {