From 05ccf0ffa9cd4ace7b7a37734717946f8df4786b Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 16 Jun 2025 21:30:14 +0800 Subject: [PATCH] 333 --- common/common.js | 4 +- common/config.js | 8 +- common/request.js | 4 +- pages.json | 8 +- pages/index/index.vue | 2 +- pages/infinite/benefit.vue | 2 +- pages/kit/kit.vue | 85 +------------------ pages/main/danye.vue | 1 - pages/main/{huanxiang.vue => hx.vue} | 0 pages/main/index.vue | 6 +- pages/main/{invite_ranking.vue => invite.vue} | 0 pages/main/{detail.vue => xq.vue} | 4 +- pages/main/{detail_wuxian.vue => xq_wx.vue} | 2 +- pages/users/collect.vue | 4 +- pages/users/fhjl.vue | 2 +- pages/users/index.vue | 4 +- 16 files changed, 29 insertions(+), 107 deletions(-) rename pages/main/{huanxiang.vue => hx.vue} (100%) rename pages/main/{invite_ranking.vue => invite.vue} (100%) rename pages/main/{detail.vue => xq.vue} (99%) rename pages/main/{detail_wuxian.vue => xq_wx.vue} (99%) diff --git a/common/common.js b/common/common.js index 7aa4e1e..76a5956 100644 --- a/common/common.js +++ b/common/common.js @@ -118,7 +118,7 @@ export default { if (item.ttype == 2) { /* 一番赏 */ this.to({ - url: '/pages/main/detail', + url: '/pages/main/xq', query: { goods_id: item.goods_id } @@ -128,7 +128,7 @@ export default { /* 无限赏 */ if (item.ttype == 3) { this.to({ - url: '/pages/main/detail_wuxian', + url: '/pages/main/xq_wx', query: { goods_id: item.goods_id } diff --git a/common/config.js b/common/config.js index 829fb21..5d28d1e 100644 --- a/common/config.js +++ b/common/config.js @@ -14,10 +14,10 @@ const wx_version = "117"; export const whiteList = [ "pages/main/index", // 首页 "pages/index/index", - "pages/main/detail", // 详情页 - "pages/main/huanxiang", // 换箱页面 + "pages/main/xq", // 详情页 + "pages/main/hx", // 换箱页面 "pages/shangcheng/index", // 商城首页 - "pages/main/detail_wuxian", // 无限详情页 + "pages/main/xq_wx", // 无限详情页 "pages/kit/kit", // 盒柜页面 "pages/infinite/index", // 福利首页 "pages/users/index", // 用户中心 @@ -27,7 +27,7 @@ export const whiteList = [ "pages/main/danye", // 单页 "pages/guize/guize", // 规则页面 "pages/main/dada_ranking", // 达达排行榜 - "pages/main/invite_ranking", // 邀请排行榜 + "pages/main/invite", // 邀请排行榜 "pages/users/login", // 登录页面 "pages/main/slots", "pages/other/web-pay-order", // 网页支付订单 diff --git a/common/request.js b/common/request.js index 658bca9..97d07e8 100644 --- a/common/request.js +++ b/common/request.js @@ -242,7 +242,7 @@ class RequestManager { title: '加载中...' }) } - + let startDate = Date.now(); // 发起网络请求 uni.request({ url: requestUrl, @@ -250,6 +250,8 @@ class RequestManager { header: header, data: data, success: res => { + let endDate = Date.now(); + console.log(requestUrl, "请求时间", endDate - startDate); res = normalizeResponseKeys(res); console.log("res.data.status", res.data.status) var pages = getCurrentPages() diff --git a/pages.json b/pages.json index d3eaf56..7c7a15f 100644 --- a/pages.json +++ b/pages.json @@ -22,14 +22,14 @@ } }, { - "path": "pages/main/detail", + "path": "pages/main/xq", "style": { "navigationStyle": "custom", "navigationBarTextStyle": "black" } }, { - "path": "pages/main/detail_wuxian", + "path": "pages/main/xq_wx", "style": { "navigationStyle": "custom", "navigationBarBackgroundColor": "#222222", @@ -37,7 +37,7 @@ } }, { - "path": "pages/main/huanxiang", + "path": "pages/main/hx", "style": { "navigationBarTitleText": "换箱", "navigationBarBackgroundColor": "#222222", @@ -175,7 +175,7 @@ }, { - "path": "pages/main/invite_ranking", + "path": "pages/main/invite", "style": { "navigationBarTitleText": "", "enablePullDownRefresh": false, diff --git a/pages/index/index.vue b/pages/index/index.vue index a8dfe51..bd94952 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -28,7 +28,7 @@ export default { icon: icon, login_icon: login_icon, tips: "正在加载中。。。", - neverTrue: false, + neverTrue: false } }, onLoad() { diff --git a/pages/infinite/benefit.vue b/pages/infinite/benefit.vue index 39a311d..21f0be5 100644 --- a/pages/infinite/benefit.vue +++ b/pages/infinite/benefit.vue @@ -58,7 +58,7 @@ export default { methods: { items(item) { this.$common.to({ - url: '/pages/main/detail', + url: '/pages/main/xq', query: { goods_id: item.id, type_text: '积分赏' diff --git a/pages/kit/kit.vue b/pages/kit/kit.vue index 7503359..26649ae 100644 --- a/pages/kit/kit.vue +++ b/pages/kit/kit.vue @@ -371,14 +371,7 @@ export default { zhanshiMoney: 0, isAgree: false, is_exchange: '0', - show_dadajuan: false, - _unusedData: { - tempValue: 123, - dummyArray: [1, 2, 3], - unusedObject: { key: 'value' } - }, - _hiddenCounter: 0, - _unusedFlag: false + show_dadajuan: false } }, onShow() { @@ -772,10 +765,7 @@ export default { data.status = this.tabList[this.tabCur].status } try { - // let l = { "goods_title": "一生爱干净的你Y", "goods_id": 1037, "orderlist": [{ "shang_title": "普通", "id": 49368, "goodslist_title": "哪吒贴纸", "goodslist_imgurl": "https://image.zfunbox.cn/topic/20250424/6294f30d70b3a90a744c0b8d11237501.png", "goodslist_money": 25, "goods_id": 1037, "shang_id": 38, "prize_code": "qMjx4Jnb10_1744275374", "prize_num": 2, "order_list_ids": [49368, 49370], "chooseNum": 0 }], "orderlist_total": 2, "orderlist_length": 1 }; - // this.listData.push(l); - // this.mescroll.endByPage(1,1) - // return; + this.req({ url, data, @@ -797,11 +787,6 @@ export default { if (res.data.show_dadajuan != null) { this.show_dadajuan = res.data.show_dadajuan } - // console.log(res.data.data, res.data.data.length); - - // this.listData.push(res.data.data[0]); - // console.log(JSON.stringify(res.data.data[0])); - this.listData = this.listData.concat(res.data.data) console.log(this.GetOrderList); @@ -895,21 +880,8 @@ export default { return "#FFFFFF"; break; } - }, - _unusedMethod() { - const temp = 1 + 2; - console.log('这是一个未使用的方法'); - return temp; - }, - _dummyCalculation() { - const x = 10; - const y = 20; - return x * y; - }, - _unusedHelper() { - const arr = [1, 2, 3, 4, 5]; - return arr.map(item => item * 2); } + } } @@ -1883,55 +1855,4 @@ export default { } } } - -.unused-container { - display: none; - opacity: 0; - transform: scale(0); -} - -.hidden-text { - visibility: hidden; - position: absolute; - left: -9999px; -} - -@keyframes spin { - from { transform: rotate(0deg); } - to { transform: rotate(360deg); } -} - -@keyframes bounce { - 0%, 100% { transform: translateY(0); } - 50% { transform: translateY(-20px); } -} - -.spinning-box { - width: 50px; - height: 50px; - background: #f00; - animation: spin 2s linear infinite; -} - -.bouncing-ball { - width: 30px; - height: 30px; - background: #0f0; - animation: bounce 1s ease-in-out infinite; -} - -$unused-color: #ff0000; -$dummy-spacing: 20px; -$hidden-opacity: 0; - -@mixin unused-mixin { - padding: $dummy-spacing; - background: $unused-color; - opacity: $hidden-opacity; -} - -.unused-class { - @include unused-mixin; - display: none; -} \ No newline at end of file diff --git a/pages/main/danye.vue b/pages/main/danye.vue index 08e9675..8bfe972 100644 --- a/pages/main/danye.vue +++ b/pages/main/danye.vue @@ -1,7 +1,6 @@ diff --git a/pages/main/huanxiang.vue b/pages/main/hx.vue similarity index 100% rename from pages/main/huanxiang.vue rename to pages/main/hx.vue diff --git a/pages/main/index.vue b/pages/main/index.vue index 5a9fc90..4e72766 100644 --- a/pages/main/index.vue +++ b/pages/main/index.vue @@ -340,14 +340,14 @@ }, todetails(e) { // 无限赏 - let url = "/pages/main/detail"; + let url = "/pages/main/xq"; let params = { goods_id: e.id, // type_text: e.type_text }; if (e.type == 2 || e.type == 8 || e.type == 16) { - url = "/pages/main/detail_wuxian"; + url = "/pages/main/xq_wx"; } if (e.type == 9) { @@ -372,7 +372,7 @@ this.$customRouter.navigateTo("/pages/main/ranking"); }, toyaqingRanking() { - this.$customRouter.navigateTo("/pages/main/invite_ranking"); + this.$customRouter.navigateTo("/pages/main/invite"); }, jumapSlots() { diff --git a/pages/main/invite_ranking.vue b/pages/main/invite.vue similarity index 100% rename from pages/main/invite_ranking.vue rename to pages/main/invite.vue diff --git a/pages/main/detail.vue b/pages/main/xq.vue similarity index 99% rename from pages/main/detail.vue rename to pages/main/xq.vue index d542a79..ee2ebda 100644 --- a/pages/main/detail.vue +++ b/pages/main/xq.vue @@ -249,7 +249,7 @@ export default { title: this.$config.getAppSetting("app_name") + `${this.pageData.goods.title}系列 第${this.pageData.goods.num}套`, imageUrl: this.pageData.goods.imgurl_detail, - path: "/pages/main/detail" + + path: "/pages/main/xq" + this.$common.qs({ goods_id: this.pageData.goods.id, goods_num: this.pageData.goods.num, @@ -572,7 +572,7 @@ export default { changeBox() { this.$common.to({ - url: "/pages/main/huanxiang", + url: "/pages/main/hx", query: { id: this.pageData.goods.id, type_text: this.optData.type_text, diff --git a/pages/main/detail_wuxian.vue b/pages/main/xq_wx.vue similarity index 99% rename from pages/main/detail_wuxian.vue rename to pages/main/xq_wx.vue index db4e830..b81a8ff 100644 --- a/pages/main/detail_wuxian.vue +++ b/pages/main/xq_wx.vue @@ -314,7 +314,7 @@ export default { return { title: this.$config.getAppSetting("app_name") + `${this.pageData.goods.title}系列`, imageUrl: this.pageData.goods.imgurl_detail, - path: '/pages/main/detail_wuxian' + + path: '/pages/main/xq_wx' + this.$common.qs({ goods_id: this.pageData.goods.id, goods_num: this.pageData.goods.num, diff --git a/pages/users/collect.vue b/pages/users/collect.vue index 392d875..94d2e97 100644 --- a/pages/users/collect.vue +++ b/pages/users/collect.vue @@ -106,11 +106,11 @@ export default { * @param {Object} item 商品项 */ toDetail(item) { - let url = "/pages/main/detail"; + let url = "/pages/main/xq"; // 根据商品类型跳转到不同详情页 if (item.type === 2 || item.type === 8) { - url = "/pages/main/detail_wuxian"; + url = "/pages/main/xq_wx"; } else if (item.type === 9) { url = "/package/index/lian-ji"; } diff --git a/pages/users/fhjl.vue b/pages/users/fhjl.vue index f55a0fb..c26b440 100644 --- a/pages/users/fhjl.vue +++ b/pages/users/fhjl.vue @@ -219,7 +219,7 @@ export default { }) }, toorder(e) { - this.$customRouter.navigateTo('/pages/main/detail', { + this.$customRouter.navigateTo('/pages/main/xq', { goods_id: e, goods_num: 1 }) diff --git a/pages/users/index.vue b/pages/users/index.vue index 569ad8c..4e5c087 100644 --- a/pages/users/index.vue +++ b/pages/users/index.vue @@ -300,11 +300,11 @@ export default { }, todetail(a) { if (a.type == 2) { - this.$customRouter.navigateTo('/pages/main/detail_wuxian', { + this.$customRouter.navigateTo('/pages/main/xq_wx', { goods_id: a.goods_id }); } else { - this.$customRouter.navigateTo('/pages/main/detail', { + this.$customRouter.navigateTo('/pages/main/xq', { goods_id: a.goods_id, goods_num: a.num });