From 0c936ca87bd64dbdf431d0d3e81abdd64aeabe85 Mon Sep 17 00:00:00 2001 From: hejin Date: Sun, 17 Aug 2025 16:47:10 +0800 Subject: [PATCH] =?UTF-8?q?1.=20=E8=B0=83=E8=AF=95=E5=AE=8C=E6=88=90?= =?UTF-8?q?=E5=8D=95=E9=A1=B5=E9=9D=A2=E7=B1=BB=E5=9E=8B=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=202.=E7=BB=98=E5=88=B6=E5=AE=8C=E6=88=90=E4=BA=A7=E5=93=81?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E9=A1=B5=E9=9D=A2=E7=9A=84=E5=B7=A6=E4=BE=A7?= =?UTF-8?q?=E8=8F=9C=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/index.js | 16 ++++ src/assets/css/common.scss | 9 ++ src/locale/en.json | 4 +- src/locale/zh.json | 4 +- src/pages.json | 6 +- src/pages/index/index.vue | 1 + src/pages/inquiry/index.vue | 2 +- src/pages/products/index.vue | 171 ++++++++++++++++++++++++++++++++++- src/pages/separate/index.vue | 32 ++++++- 9 files changed, 235 insertions(+), 10 deletions(-) diff --git a/src/api/index.js b/src/api/index.js index 4a0b5ee..8ab97c4 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -47,4 +47,20 @@ export const formOptionsApi = () => { **/ export const submitFormApi = (data) => { return request.post('/web/inquirySave', data) +} + +/** + * @function 获取分类详情信息 + * @param {string} id 分类id +**/ +export const categoryInfoApi = (id) => { + return request.get(`/web/categoryInfo?id=${id}`) +} + +/** + * @function 获取产品新闻分类 + * @param {string} catgId 最上级id +**/ +export const prodOrNewsCatgApi = (catgId) => { + return request.get(`/web/prodCategory?catgId=${catgId}`) } \ No newline at end of file diff --git a/src/assets/css/common.scss b/src/assets/css/common.scss index 0af7481..dd47681 100644 --- a/src/assets/css/common.scss +++ b/src/assets/css/common.scss @@ -30,6 +30,15 @@ button { line-clamp: 2; -webkit-box-orient: vertical; //盒子中内容竖直排列 } +.rich-text { + margin-bottom: 1.25rem; + img { + max-width: 100%; + } + p { + text-align: left; + } +} .form-box { .label-box { margin-bottom: 12rpx; diff --git a/src/locale/en.json b/src/locale/en.json index f414ebe..11b7d76 100644 --- a/src/locale/en.json +++ b/src/locale/en.json @@ -44,7 +44,9 @@ "Go": "Go", "Center": "Center", "Quick": "Quick", - "viewmore": "view more" + "viewmore": "view more", + "ProductLabel": "Product", + "keywords": "keywords" }, "menu": { "Home": "Home", diff --git a/src/locale/zh.json b/src/locale/zh.json index 0b5762d..967ca51 100644 --- a/src/locale/zh.json +++ b/src/locale/zh.json @@ -44,7 +44,9 @@ "Go": "前往", "Center": "中心", "Quick": "快速", - "viewmore": "查看更多" + "viewmore": "查看更多", + "ProductLabel": "产品", + "keywords": "关键字" }, "menu": { "Home": "首页", diff --git a/src/pages.json b/src/pages.json index 6ca1f2c..feb0494 100644 --- a/src/pages.json +++ b/src/pages.json @@ -17,7 +17,8 @@ { "path": "pages/products/index", "style": { - "navigationBarTitleText": "Product" + "navigationBarTitleText": "Product", + "enablePullDownRefresh": true } }, { @@ -29,7 +30,8 @@ { "path": "pages/separate/index", "style": { - "navigationBarTitleText": "About Us" + "navigationBarTitleText": "About Us", + "enablePullDownRefresh": true } }, { diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 666d3eb..082a880 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -191,6 +191,7 @@ await getOrdinaryProduct() await getHotNews() } catch(err) { + console.log(err) } uni.stopPullDownRefresh() }) diff --git a/src/pages/inquiry/index.vue b/src/pages/inquiry/index.vue index 5a136a1..62411e2 100644 --- a/src/pages/inquiry/index.vue +++ b/src/pages/inquiry/index.vue @@ -1,6 +1,6 @@