From 63b22f4c86aae1d5509bc57295e4bb6c5cd37030 Mon Sep 17 00:00:00 2001 From: "pikachu1995@126.com" Date: Mon, 16 Oct 2023 16:00:15 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=88=86=E9=94=80=E7=BB=93=E6=9E=84?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- buyer/src/api/distribution.js | 110 +++++ buyer/src/api/member.js | 85 ---- .../pages/home/memberCenter/Distribution.vue | 438 ++++++++++-------- manager/src/api/distribution.js | 11 +- manager/src/router/router.js | 14 +- .../src/views/distribution/distribution.vue | 67 ++- .../views/distribution/distributionGoods.vue | 5 - .../views/distribution/distributionGroup.vue | 103 ++++ .../views/distribution/distributionMember.vue | 114 +++++ .../views/distribution/distributionOrder.vue | 4 +- .../distribution/distributionSetting.vue | 154 +++++- seller/src/api/distribution.js | 63 +-- .../distribution/distributionSetting.vue | 96 ++++ 13 files changed, 891 insertions(+), 373 deletions(-) create mode 100644 buyer/src/api/distribution.js create mode 100644 manager/src/views/distribution/distributionGroup.vue create mode 100644 manager/src/views/distribution/distributionMember.vue create mode 100644 seller/src/views/distribution/distributionSetting.vue diff --git a/buyer/src/api/distribution.js b/buyer/src/api/distribution.js new file mode 100644 index 00000000..34e4f379 --- /dev/null +++ b/buyer/src/api/distribution.js @@ -0,0 +1,110 @@ +import request, {Method} from '@/plugins/request.js'; + +/** + * 获取当前会员分销信息 + */ +export function distribution () { + return request({ + url: `/buyer/distribution/distribution`, + method: Method.GET, + needToken: true + }); +} + +/** + * 申请成为分销员 + * @param idNumber 身份证号 + * @param name 名字 + */ +export function applyDistribution (params) { + return request({ + url: `/buyer/distribution/distribution`, + method: Method.POST, + needToken: true, + params + }); +} + +/** + * 获取分销员订单列表 + */ +export function getDistOrderList (params) { + return request({ + url: `/buyer/distribution/order`, + method: Method.GET, + needToken: true, + params + }); +} + +/** + * 获取分销员下级用户列表 + */ +export function getDistMemberList (params) { + return request({ + url: `/buyer/distribution/distribution/memberList`, + method: Method.GET, + needToken: true, + params + }); +} + +/** + * 获取分销商商品列表 + */ +export function getDistGoodsList (params) { + return request({ + url: `/buyer/distribution/goods`, + method: Method.GET, + needToken: true, + params + }); +} + +/** + * 分销员提现历史 + */ +export function distCashHistory (params) { + return request({ + url: `/buyer/distribution/cash`, + method: Method.GET, + needToken: true, + params + }); +} + +/** + * 分销员-团队列表 + */ +export function getDistGroupList (params) { + return request({ + url: `/buyer/distribution/distribution/groupList`, + method: Method.GET, + needToken: true, + params + }); +} + +/** + * 分销商提现 + */ +export function distCash (params) { + return request({ + url: `/buyer/distribution/cash`, + method: Method.POST, + needToken: true, + params + }); +} + +/** + * 绑定分销 + * @param distributionId 商品分销ID + */ +export function getGoodsDistribution (distributionId) { + return request({ + url: `/buyer/distribution/distribution/bindingDistribution/${distributionId}`, + method: Method.GET, + needToken: true + }); +} diff --git a/buyer/src/api/member.js b/buyer/src/api/member.js index eeb7de21..ed2da4bc 100644 --- a/buyer/src/api/member.js +++ b/buyer/src/api/member.js @@ -333,92 +333,7 @@ export function clearComplain (id) { }); } -/** - * 获取当前会员分销信息 - */ -export function distribution () { - return request({ - url: `/buyer/distribution/distribution`, - method: Method.GET, - needToken: true - }); -} -/** - * 申请成为分销商 - * @param idNumber 身份证号 - * @param name 名字 - */ -export function applyDistribution (params) { - return request({ - url: `/buyer/distribution/distribution`, - method: Method.POST, - needToken: true, - params - }); -} - -/** - * 获取分销商订单列表 - */ -export function getDistOrderList (params) { - return request({ - url: `/buyer/distribution/order`, - method: Method.GET, - needToken: true, - params - }); -} - -/** - * 获取分销商商品列表 - */ -export function getDistGoodsList (params) { - return request({ - url: `/buyer/distribution/goods`, - method: Method.GET, - needToken: true, - params - }); -} - -/** - * 绑定、解绑分销商品 - * @param distributionGoodsId 分销商品id - * @param checked 分销商品id,true为绑定,false为解绑 - */ -export function selectDistGoods (params) { - return request({ - url: `/buyer/distribution/goods/checked/${params.distributionGoodsId}`, - method: Method.GET, - needToken: true, - params - }); -} - -/** - * 分销商提现历史 - */ -export function distCashHistory (params) { - return request({ - url: `/buyer/distribution/cash`, - method: Method.GET, - needToken: true, - params - }); -} - -/** - * 分销商提现 - */ -export function distCash (params) { - return request({ - url: `/buyer/distribution/cash`, - method: Method.POST, - needToken: true, - params - }); -} /** * 我的足迹 diff --git a/buyer/src/pages/home/memberCenter/Distribution.vue b/buyer/src/pages/home/memberCenter/Distribution.vue index 1933950c..33aa7526 100644 --- a/buyer/src/pages/home/memberCenter/Distribution.vue +++ b/buyer/src/pages/home/memberCenter/Distribution.vue @@ -1,6 +1,6 @@
-

分销下线付款之后会生成分销订单。

-

- 冻结金额:用户提现金额即为冻结金额,审核通过后扣除冻结金额,审核拒绝之后冻结金额返回可提现金额。 -

-

可提现金额:分销订单佣金T+1解冻后可变为可提现金额。

- +

交易完成后返佣可提现。

- + + + + + + + +
+
+ +
+
+ + @@ -101,15 +116,8 @@ type="success" size="small" style="margin-right: 5px" - @click="fenxiao(row)" - >分销商品 - + @click="fenxiao(row)">邀请好友 +
@@ -124,48 +132,30 @@ >
- - - + From fb20cb32dad600f6582ef3c7f54d8cab454a45b3 Mon Sep 17 00:00:00 2001 From: "pikachu1995@126.com" Date: Wed, 24 Jan 2024 09:46:59 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E7=BB=93=E7=AE=97=E5=8D=95=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E8=B0=83=E4=BC=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- manager/src/api/shops.js | 6 + manager/src/libs/axios.js | 14 +- manager/src/views/seller/bill/bill-detail.vue | 923 ++++++++++-------- seller/src/api/shops.js | 4 + seller/src/views/shop/bill/billDetail.vue | 919 ++++++++--------- 5 files changed, 1037 insertions(+), 829 deletions(-) diff --git a/manager/src/api/shops.js b/manager/src/api/shops.js index 93d3493e..36cba3c3 100644 --- a/manager/src/api/shops.js +++ b/manager/src/api/shops.js @@ -81,3 +81,9 @@ export const getShopList = () => { export const getShopByMemberId = (id) => { return getRequest(`/store/store/${id}/member`) } + +//根据id获取店铺信息 +export const downloadBill = (id) => { + return getRequest(`/order/bill/downLoad/${id}`, {}, 'blob') +} + diff --git a/manager/src/libs/axios.js b/manager/src/libs/axios.js index e49d796c..79e7e5ff 100644 --- a/manager/src/libs/axios.js +++ b/manager/src/libs/axios.js @@ -171,18 +171,24 @@ function getTokenDebounce() { }; } -export const getRequest = (url, params) => { +export const getRequest = (url, params, resBlob) => { let accessToken = getStore("accessToken"); - return service({ + let data = { method: "get", url: `${url}`, params: params, headers: { accessToken: accessToken - } - }); + }, + responseType: "blob" + }; + if (resBlob != "blob") { + delete data.responseType; + } + return service(data); }; + export const postRequest = (url, params, headers) => { let accessToken = getStore("accessToken"); return service({ diff --git a/manager/src/views/seller/bill/bill-detail.vue b/manager/src/views/seller/bill/bill-detail.vue index b3743bcf..802e14a6 100644 --- a/manager/src/views/seller/bill/bill-detail.vue +++ b/manager/src/views/seller/bill/bill-detail.vue @@ -1,161 +1,252 @@ @@ -628,58 +622,109 @@ export default { .flex { justify-content: space-between; flex-wrap: wrap; + > p { width: 50%; margin: 15px 0; } } + .page { margin-top: 10px; } + .tips-status { padding: 10px; font-size: 14px; + > span { font-weight: bold; margin-right: 8px; } + > span:nth-of-type(2) { color: $theme_color; } } + table { font-size: 14px; margin-left: 20px; + tr { height: 40px; padding: 10px; + td:nth-child(1) { width: 120px; } } } + .bill-detail-price { width: 1200px; margin: 10px 0; padding: 10px; + /deep/ span { font-size: 14px; text-align: center; width: 200px; margin-bottom: 10px; } + .theme_color { color: $theme_color; } + .increase-color { color: green; } - div{ - margin: 20px 0; + div { + + margin: 20px 0; } } -.bill-item{ + +.bill-item { justify-content: flex-start; } + +.procedure { + display: flex; + align-items: center; + justify-content: flex-start; + font-size: 14px; + font-weight: bold; + margin: 12px 0 12px 20px; + .procedure_item { + width: 160px; + display: flex; + align-items: center; + justify-content: center; + .icon { + width: 24px; + height: 24px; + text-align: center; + line-height: 24px; + border-radius: 50%; + margin-right: 14px; + font-weight: normal; + background-color: #e6f7ff; + color: #1890ff; + } + .current { + background-color: #2d8cf0; + color: #ffffff; + } + .future { + background-color: #f7f7f7; + color: #515a6e; + } + .text { + + } + } +}