From bd867ce01af970dc9d715266cf9d47f2347f95f0 Mon Sep 17 00:00:00 2001 From: woody Date: Tue, 21 Oct 2025 14:50:01 +0800 Subject: [PATCH 1/5] =?UTF-8?q?feat(statistics):=20=E4=BC=9E=E4=B8=8B?= =?UTF-8?q?=E4=B8=9A=E7=BB=A9=E9=BB=98=E8=AE=A4=E6=97=B6=E9=97=B4=E6=AE=B5?= =?UTF-8?q?=E7=BB=93=E6=9D=9F=E6=97=A5=E6=9C=9F=E4=B8=BA=E5=89=8D=E4=B8=80?= =?UTF-8?q?=E5=A4=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 1 + src/router/index.js | 12 +- src/utils/date.js | 24 ++ src/views/statistics/underDirectAdd.vue | 322 ++++++++--------- src/views/statistics/underDirectAddNew.vue | 324 ++++++++---------- src/views/statistics/underPlacementPer.vue | 210 +++++------- src/views/statistics/underPlacementPerNew.vue | 220 ++++++------ 7 files changed, 520 insertions(+), 593 deletions(-) create mode 100644 src/utils/date.js diff --git a/package.json b/package.json index 384a29f..2bb1325 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,7 @@ "@riophae/vue-treeselect": "^0.4.0", "axios": "0.18.1", "core-js": "3.6.5", + "dayjs": "^1.11.18", "echarts": "^5.4.2", "element-ui": "2.13.2", "file-saver": "^2.0.5", diff --git a/src/router/index.js b/src/router/index.js index aef5151..4fb308a 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -2755,12 +2755,12 @@ export const constantRoutes = [ component: () => import('@/views/statistics/underBalance'), meta: { title: '伞下账户余额' } }, - { - path: 'underDirectPushBox', - name: 'UnderDirectPushBox', - component: () => import('@/views/statistics/underDirectPushBox'), - meta: { title: '伞下直推新增盒数' } - }, + // { + // path: 'underDirectPushBox', + // name: 'UnderDirectPushBox', + // component: () => import('@/views/statistics/underDirectPushBox'), + // meta: { title: '伞下直推新增盒数' } + // }, { path: 'realPerAddAwards', name: 'RealPerAddAwards', diff --git a/src/utils/date.js b/src/utils/date.js new file mode 100644 index 0000000..8c0331e --- /dev/null +++ b/src/utils/date.js @@ -0,0 +1,24 @@ +import dayjs from 'dayjs' + +export function getBeforeDays(n = 1) { + return dayjs().subtract(n, 'day').format('YYYY-MM-DD') +} + +// 获取本月第一天 +export function getMonthFirstDay() { + return dayjs().startOf('month').format('YYYY-MM-DD') +} + +// 获取本月最后一天 +export function getMonthLastDay() { + return dayjs().endOf('month').format('YYYY-MM-DD') +} + +// 获取本月第一天和当前天前一天的日期,如果当天为本月第一天,则返回上月第一天和上月最后一天 +export function getMonthFirstDayAndBeforeDay() { + const isFirstDate = new Date().getDate() === 1 + if (isFirstDate) { + return [dayjs().add(-1, 'month').startOf('month').format('YYYY-MM-DD'), dayjs().add(-1, 'month').endOf('month').format('YYYY-MM-DD')] + } + return [getMonthFirstDay(), getBeforeDays(1)] +} diff --git a/src/views/statistics/underDirectAdd.vue b/src/views/statistics/underDirectAdd.vue index 8878fc2..b0938ac 100644 --- a/src/views/statistics/underDirectAdd.vue +++ b/src/views/statistics/underDirectAdd.vue @@ -1,28 +1,22 @@ - @@ -175,74 +170,63 @@ prop="shortName" :label="'国家'" min-width="120px" - > - + /> - + /> - + /> - + /> - + /> - + /> - + /> - + /> - + /> - + /> - + /> + + + + + + + diff --git a/src/views/settlementCenter/totalBonus/index.vue b/src/views/settlementCenter/totalBonus/index.vue index 191663c..34271bc 100644 --- a/src/views/settlementCenter/totalBonus/index.vue +++ b/src/views/settlementCenter/totalBonus/index.vue @@ -162,12 +162,12 @@ width="200" :label="'结算时间'" /> - + + + + + + + Date: Mon, 27 Oct 2025 17:00:19 +0800 Subject: [PATCH 4/5] =?UTF-8?q?feat(performaceTotal):=20=20=E5=A5=96?= =?UTF-8?q?=E9=87=91=E4=B8=93=E5=8C=BA=E5=88=97=E6=94=B9=E5=90=8D=EF=BC=8C?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=B5=A0=E5=93=81=E4=B8=93=E5=8C=BA=E5=AD=97?= =?UTF-8?q?=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../performanceTotal/index.vue | 23 ++++++++++--- .../settlementCenter/topPerformance/index.vue | 32 +++++++++---------- 2 files changed, 35 insertions(+), 20 deletions(-) diff --git a/src/views/settlementCenter/performanceTotal/index.vue b/src/views/settlementCenter/performanceTotal/index.vue index f9074c6..943f965 100644 --- a/src/views/settlementCenter/performanceTotal/index.vue +++ b/src/views/settlementCenter/performanceTotal/index.vue @@ -172,14 +172,14 @@ prop="upgradeAmount" :formatter="stateFormat" width="160" - :label="'甄选金额'" + :label="'复购金额'" /> + + + Date: Mon, 27 Oct 2025 17:14:21 +0800 Subject: [PATCH 5/5] =?UTF-8?q?feat(member):=20=E4=BC=9A=E5=91=98=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E9=A1=B5=E6=B7=BB=E5=8A=A0=E4=BC=9A=E5=91=98=E7=AD=89?= =?UTF-8?q?=E7=BA=A7=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/information/member/index.vue | 32 ++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/src/views/information/member/index.vue b/src/views/information/member/index.vue index cbffd16..099936c 100644 --- a/src/views/information/member/index.vue +++ b/src/views/information/member/index.vue @@ -45,6 +45,22 @@ /> + + + + + + + + { + this.gradeRangList = res.data + }) + }, // 查询会员信息 getMemberList() {