From 9a1a4b9c5054be232e9c76cb5852be67c0901eee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=94=90=E6=98=8E=E6=98=8E?= <970899069@qq.com> Date: Fri, 10 Jun 2022 12:14:02 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=A6=E6=88=B7=E8=AE=BE=E7=BD=AE=E5=AF=86?= =?UTF-8?q?=E7=A0=81=EF=BC=8C=E8=BD=AC=E8=B4=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apis/index.js | 4 +- apis/interfaces/account.js | 58 +- pages.json | 93 +- pages/account/code.vue | 124 ++ pages/account/dt.vue | 49 +- pages/account/log.vue | 90 + pages/account/recharge.vue | 2 +- pages/account/resetPassword.vue | 203 +++ pages/account/results.vue | 81 + pages/account/transfer.vue | 227 +++ pages/user/index.vue | 7 - static/background/wallet-code-background.png | Bin 0 -> 3474 bytes .../dist/dev/app-plus/app-config-service.js | 4 +- unpackage/dist/dev/app-plus/app-service.js | 1187 ++++++++++-- unpackage/dist/dev/app-plus/app-view.js | 1610 ++++++++++++++++- unpackage/dist/dev/app-plus/manifest.json | 2 +- .../background/wallet-code-background.png | Bin 0 -> 3474 bytes 17 files changed, 3510 insertions(+), 231 deletions(-) create mode 100644 pages/account/code.vue create mode 100644 pages/account/log.vue create mode 100644 pages/account/resetPassword.vue create mode 100644 pages/account/results.vue create mode 100644 pages/account/transfer.vue create mode 100644 static/background/wallet-code-background.png create mode 100644 unpackage/dist/dev/app-plus/static/background/wallet-code-background.png diff --git a/apis/index.js b/apis/index.js index 8ee84e6..f70741a 100644 --- a/apis/index.js +++ b/apis/index.js @@ -27,10 +27,12 @@ const request = (parameter, hideLoding = true) => { }) return } + console.log(store.getters.getToken) + console.log(uni.getStorageSync('token')) // 注入header config.header = { 'Accept': 'application/json', - 'Authorization': store.getters.getToken || '' + 'Authorization': store.getters.getToken || uni.getStorageSync('token') } // 加载提示 if(!hideLoding) uni.showLoading({ diff --git a/apis/interfaces/account.js b/apis/interfaces/account.js index ebf0494..58083c1 100644 --- a/apis/interfaces/account.js +++ b/apis/interfaces/account.js @@ -24,7 +24,7 @@ const recharge = (data) => { }) } -// 订单信息 +// 充值订单信息 const payment = (data) => { return request({ url: "user/transaction/recharge/payment", @@ -33,8 +33,62 @@ const payment = (data) => { }) } +// 充值记录 +const log = (data) => { + return request({ + url: 'user/transaction/recharge/lists' + }) +} + +// 获取钱包地址 +const code = () => { + return request({ + url: 'chain/account/code' + }) +} + +// 转账初始化 +const transfer = () => { + return request({ + url: 'user/transaction/transfer' + }) +} + +// 设置支付密码 +const setpassword = data => { + return request({ + url: 'user/transaction/setpassword', + method: 'POST', + data + }) +} + +// 获取验证码 +const getSms = data => { + return request({ + url: 'user/transaction/setpassword/sms', + method: 'POST' + }) +} + +// 提交转账 +const submitTransfer = data => { + return request({ + url: 'user/transaction/transfer/store', + method: 'POST', + data + }) +} + + export { dt, recharge, - payment + payment, + log, + code, + transfer, + setpassword, + getSms, + submitTransfer } diff --git a/pages.json b/pages.json index de9b122..fd4d82a 100644 --- a/pages.json +++ b/pages.json @@ -158,14 +158,14 @@ "navigationBarBackgroundColor": "#FFFFFF" } }, - { - "path": "pages/refund/list", - "name": "OrderRefund", - "style": { - "navigationBarTitleText": "退换货", - "navigationBarBackgroundColor": "#FFFFFF" - } - },{ + { + "path": "pages/refund/list", + "name": "OrderRefund", + "style": { + "navigationBarTitleText": "退换货", + "navigationBarBackgroundColor": "#FFFFFF" + } + }, { "path": "pages/refund/aftersale", "name": "AfterSale", "style": { @@ -216,7 +216,7 @@ "path": "pages/account/recharge", "name": "AccountRecharge", "style": { - "navigationBarTitleText": "DT积分充值", + "navigationBarTitleText": "充值", "navigationBarBackgroundColor": "#FFFFFF", "app-plus": { "titleNView": { @@ -243,28 +243,65 @@ "navigationBarTitleText": "共力会员协议" } }, { - "path": "pages/team/index", + "path": "pages/team/index", "name": "Team", "style": { - "navigationBarTitleText": "共力团队" + "navigationBarTitleText": "共力团队" } - }, - { - "path" : "pages/store/shop/shopDetail", - "name": "ShopDetail", - "style": { - "navigationStyle": "custom" - } - }, - { - "path": "pages/store/shop/shopList", - "name": "ShopList", - "style": { - "navigationBarTitleText": "更多店铺", - "navigationBarBackgroundColor": "#FFFFFF", - "enablePullDownRefresh": true - } + }, + { + "path": "pages/store/shop/shopDetail", + "name": "ShopDetail", + "style": { + "navigationStyle": "custom" + } + }, + { + "path": "pages/store/shop/shopList", + "name": "ShopList", + "style": { + "navigationBarTitleText": "店铺", + "navigationBarBackgroundColor": "#FFFFFF", + "enablePullDownRefresh": true + } + }, { + "path": "pages/account/log", + "name": "AccountLog", + "style": { + "navigationBarTitleText": "充值记录", + "navigationBarBackgroundColor": "#FFFFFF" + } + }, { + "path": "pages/account/transfer", + "name": "AccountTransfer", + "style": { + "navigationBarTitleText": "转账", + "navigationBarBackgroundColor": "#F3F6FB" + } + }, { + "path": "pages/account/resetPassword", + "name": "AccountResetPassword", + "style": { + "navigationBarTitleText": "钱包密码", + "navigationBarBackgroundColor": "#F3F6FB" + } + }, { + "path": "pages/account/results", + "name": "Accountresults", + "style": { + "navigationBarTitleText": "转账结果", + "navigationBarBackgroundColor": "#FFFFFF" + } + }, { + "path": "pages/account/code", + "name": "AccountCode", + "style": { + "navigationBarTitleText": "收款码", + "navigationBarBackgroundColor": "#34CE98", + "backgroundColorTop": "#34CE98", + "navigationBarTextStyle": "white" + } } ], "tabBar": { @@ -297,7 +334,7 @@ "easycom": { "^u-(.*)": "uview-ui/components/u-$1/u-$1.vue" }, - "condition" : { //模式配置,仅开发期间生效 + "condition": { //模式配置,仅开发期间生效 "current": 0 //当前激活的模式(list 的索引项) } } diff --git a/pages/account/code.vue b/pages/account/code.vue new file mode 100644 index 0000000..a29bb74 --- /dev/null +++ b/pages/account/code.vue @@ -0,0 +1,124 @@ + + + + + diff --git a/pages/account/dt.vue b/pages/account/dt.vue index c90ae08..adb4879 100644 --- a/pages/account/dt.vue +++ b/pages/account/dt.vue @@ -1,8 +1,12 @@