From ecb9144a2ec9bae1ab6a29fc550b31409e68851e Mon Sep 17 00:00:00 2001 From: "lenovo008\\lenovo" Date: Thu, 25 Jul 2024 09:01:51 +0800 Subject: [PATCH 1/4] feat(prize): add lucky five selection page and API - Add new pages for lucky five selection in user center. - Implement API endpoints for getting today's lucky five results and ranking. - Update menu list in user/discounts page to include lucky five selection. - Refactor prize API to include new endpoints for lucky five functionality. --- yudao-mall-uniapp-master/pages.json | 24 +++ .../pages/user/alternative.vue | 152 ++++++++++++++++++ .../pages/user/discounts.vue | 81 ++++++++++ .../sheep/api/prize/index.js | 29 +++- 4 files changed, 279 insertions(+), 7 deletions(-) create mode 100644 yudao-mall-uniapp-master/pages/user/alternative.vue create mode 100644 yudao-mall-uniapp-master/pages/user/discounts.vue diff --git a/yudao-mall-uniapp-master/pages.json b/yudao-mall-uniapp-master/pages.json index 77c041b..9761d30 100644 --- a/yudao-mall-uniapp-master/pages.json +++ b/yudao-mall-uniapp-master/pages.json @@ -273,6 +273,30 @@ "group": "用户中心" } }, + { + "path": "discounts", + "style": { + "navigationBarTitleText": "活动" + }, + "meta": { + "auth": true, + "sync": true, + "title": "活动", + "group": "用户中心" + } + }, + { + "path": "alternative", + "style": { + "navigationBarTitleText": "幸运五选一" + }, + "meta": { + "auth": true, + "sync": true, + "title": "幸运五选一", + "group": "用户中心" + } + }, { "path": "PrizesWon", "style": { diff --git a/yudao-mall-uniapp-master/pages/user/alternative.vue b/yudao-mall-uniapp-master/pages/user/alternative.vue new file mode 100644 index 0000000..c0faf10 --- /dev/null +++ b/yudao-mall-uniapp-master/pages/user/alternative.vue @@ -0,0 +1,152 @@ + + + + + diff --git a/yudao-mall-uniapp-master/pages/user/discounts.vue b/yudao-mall-uniapp-master/pages/user/discounts.vue new file mode 100644 index 0000000..b510b1a --- /dev/null +++ b/yudao-mall-uniapp-master/pages/user/discounts.vue @@ -0,0 +1,81 @@ + + + + + diff --git a/yudao-mall-uniapp-master/sheep/api/prize/index.js b/yudao-mall-uniapp-master/sheep/api/prize/index.js index 6210c2c..6c3daac 100644 --- a/yudao-mall-uniapp-master/sheep/api/prize/index.js +++ b/yudao-mall-uniapp-master/sheep/api/prize/index.js @@ -1,7 +1,6 @@ import request from '@/sheep/request'; const PayOrderApi = { - // 开始抽奖 lottery: (id) => { return request({ @@ -18,16 +17,12 @@ const PayOrderApi = { params: { activityId: id }, }); }, - - - - -// 获得抽奖照片 + // 获得抽奖照片 prizeImg: (id) => { return request({ url: '/promotion/prize-draw/activity-prize/list-by-activity-id', method: 'GET', - params: { activityId:id }, + params: { activityId: id }, }); }, // 规则 @@ -38,6 +33,26 @@ const PayOrderApi = { params, }); }, + + // 五占一接口-------------------------------- + + // 今日已出线列表 + wzyycx: (params) => { + return request({ + url: '/member/distribution-log/outTodaypage', + method: 'GET', + params, + }); + }, + + // 排名 + ranking: (params) => { + return request({ + url: '/member/distribution-log/getUserId', + method: 'GET', + params, + }); + }, }; export default PayOrderApi; From f2a0dba1d2cd6e11b03c3be16b1adc49c6f68a8f Mon Sep 17 00:00:00 2001 From: "lenovo008\\lenovo" Date: Thu, 25 Jul 2024 13:30:36 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=90=8E=E5=8F=B0?= =?UTF-8?q?=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yudao-mall-uniapp-master/.env.development | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yudao-mall-uniapp-master/.env.development b/yudao-mall-uniapp-master/.env.development index 7854d99..ee5e7ed 100644 --- a/yudao-mall-uniapp-master/.env.development +++ b/yudao-mall-uniapp-master/.env.development @@ -2,4 +2,4 @@ # SHOPRO_DEV_BASE_URL = http://192.168.1.114:48080 # 线上地址 - SHOPRO_DEV_BASE_URL = https://zda.huamar.com \ No newline at end of file + SHOPRO_DEV_BASE_URL = https://zd.huamar.com \ No newline at end of file From cd53d818b887a49b59ec49e6a7ff23ec88cf270e Mon Sep 17 00:00:00 2001 From: "lenovo008\\lenovo" Date: Fri, 26 Jul 2024 14:07:13 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E6=88=91=E7=9A=84=E5=9B=A2=E9=98=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yudao-mall-uniapp-master/pages/commission/team.vue | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/yudao-mall-uniapp-master/pages/commission/team.vue b/yudao-mall-uniapp-master/pages/commission/team.vue index 82a492e..2ca062b 100644 --- a/yudao-mall-uniapp-master/pages/commission/team.vue +++ b/yudao-mall-uniapp-master/pages/commission/team.vue @@ -25,10 +25,10 @@ - 一级({{ state.summary.firstBrokerageUserCount || 0 }}) + 直属下级({{ state.summary.firstBrokerageUserCount || 0 }}) - 二级({{ state.summary.secondBrokerageUserCount || 0 }}) + 我的团队({{ state.summary.secondBrokerageUserCount || 0 }}) {{ item.brokerageUserCount || 0 }} 人 - {{ item.orderCount || 0 }}{{ item.brokerageOrderCount || 0 }}单 - {{ item.brokeragePrice || 0 }}{{ Number(item.brokeragePrice|| 0 )/100 }}元 @@ -282,7 +282,7 @@ let { code, data } = await BrokerageApi.getBrokerageUserChildSummaryPage({ pageNo: state.pagination.pageNo, pageSize: state.pagination.pageSize, - level: state.level, + level: state.level== 1 ? state.level : '', 'sortingField.order': state.isAsc, 'sortingField.field': state.sortKey, nickname: state.nickname, From 027e6609db7319283bd081866fbdff20af182678 Mon Sep 17 00:00:00 2001 From: "lenovo008\\lenovo" Date: Fri, 26 Jul 2024 14:24:08 +0800 Subject: [PATCH 4/4] =?UTF-8?q?fix(commission=E5=9B=A2=E9=98=9F=E9=A1=B5):?= =?UTF-8?q?=20=E4=BC=98=E5=8C=96=E6=A0=B7=E5=BC=8F=E5=92=8C=E8=AF=84?= =?UTF-8?q?=E8=AE=BA=E6=B8=85=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 优化了团队页的样式,包括搜索框和排序项的布局,以提升用户体验。 - 移除了无用的注释和代码,提高了代码的可读性和维护性。 - 调整了团队人数和订单数量的显示逻辑,确保在没有数据时显示为0。 - 在用户页面添加了页面内顶部间距的样式,改善了页面的整体布局。 通过这些改动,我们旨在改善页面的用户界面和交互细节,同时简化代码结构,使之更易于管理和维护。 --- .../pages/commission/team.vue | 82 +++++-------------- yudao-mall-uniapp-master/pages/index/user.vue | 6 +- 2 files changed, 26 insertions(+), 62 deletions(-) diff --git a/yudao-mall-uniapp-master/pages/commission/team.vue b/yudao-mall-uniapp-master/pages/commission/team.vue index 2ca062b..1bf30b3 100644 --- a/yudao-mall-uniapp-master/pages/commission/team.vue +++ b/yudao-mall-uniapp-master/pages/commission/team.vue @@ -2,17 +2,18 @@