diff --git a/pages-userInfo/creatorAccount/createAccount.vue b/pages-userInfo/creatorAccount/createAccount.vue index 6e9588a..83b9e94 100644 --- a/pages-userInfo/creatorAccount/createAccount.vue +++ b/pages-userInfo/creatorAccount/createAccount.vue @@ -3,7 +3,7 @@ - 小贴士:
+ 小贴士:
1. 为了您的资金安全及合规,体现将通过第三方支付提供安全通道实现。
2. 应银行监管要求,每人每月限额10万元,最多绑定4个收款账户。
3. 一旦提现成功,设置的收款账户不可更改。 @@ -22,19 +22,33 @@ :clearable="false" :inputBorder="false" /> - + + + + + + + + + + + + -
@@ -57,20 +71,31 @@ getAccount,addCreatorAccount, checkAccountExist,checkAccountUpToFour } from '@/api/userInfo.js' + import {type} from "../../uni_modules/uni-forms/components/uni-forms/utils"; export default { data() { return { - iconColor: '#0b6375', + primaryColor: '#0b6375', userInfo: {}, existFlag: false, upToFourFlag: false, noClick:true, //防止重复提交 + fileList: [], accountInfo:{ name:'', idNo:'', accountNo:'', - phone:'' + phone:'', + imgUrl: '' }, + type: 0, + typeList: [{ + text: '微信', + value: 0 + }, { + text: '支付宝', + value: 2 + }], rules: { name: { rules: [{ @@ -204,7 +229,42 @@ }); }); }, - + selectImage(e) { + if (!e.tempFiles) { + return; + } + let that = this; + that.fileList = [...that.fileList, ...e.tempFilePaths]; + that.accountInfo.imgUrl = e.tempFilePaths[0]; + },//删除图片 + deleteImg(e) { + let that = this + that.fileList = []; + that.accountInfo.imgUrl = '' + }, + //图片上传 + uploadImg: async function (e) { + let that = this; + uni.showLoading({ + title: "上传中" + }); + const tempFilePaths = e; + for (let i = 0; i < tempFilePaths.length; i++) { + const [error, res] = await uni.uploadFile({ + url: `${that.$baseURL}${that.$uploadURL}`, + filePath: tempFilePaths[i], + name: `${that.$uploadType}`, + header:{ + "Content-Type": "multipart/form-data" + }, + }) + const back = JSON.parse(res.data); + if (back.code == 200) { + that.accountInfo.imgUrl = back.data; + } + } + uni.hideLoading() + }, //保存数据并跳转 submitAccount(){ let that = this; @@ -231,8 +291,11 @@ idNo: that.accountInfo.idNo, phone:that.accountInfo.phone, accountNo:that.accountInfo.accountNo, - type: '2' //此处默认先添加为支付宝账户,后续微信支付了即可添加微信 + type: that.type //此处默认先添加为支付宝账户,后续微信支付了即可添加微信 } + if (param.type === 0) { //上传收款码 + that.uploadImg(that.fileList); + } //新增艺术家账户 addCreatorAccount(param).then(res => { if (res.data.code === 200) { @@ -267,6 +330,14 @@ // }) }, }, + watch: { + type(newVal) { + if (newVal !== 0) { + this.fileList = []; + this.accountInfo.imgUrl = ''; + } + } + } } diff --git a/pages-userInfo/creatorAccount/creatorAccount.vue b/pages-userInfo/creatorAccount/creatorAccount.vue index fdc086a..1367c91 100644 --- a/pages-userInfo/creatorAccount/creatorAccount.vue +++ b/pages-userInfo/creatorAccount/creatorAccount.vue @@ -2,6 +2,7 @@ + 真实姓名:{{item.name}} 身份证号:{{item.idNo}} 微信账号:{{item.accountNo}} @@ -34,6 +35,23 @@ userInfo: {}, type: 0, noClick:true, //防止重复提交 + payType: [ + { + icon: 'icon-weixin', + title: '微信', + color: '#909399' + }, + { + icon: 'icon-yinhangka', + title: '银行卡', + color: '#909399' + }, + { + icon: 'icon-zhifubao', + title: '支付宝', + color: '#909399' + } + ], } }, @@ -173,6 +191,17 @@ border-width: 2rpx !important; } + ::v-deep .uni-group__content { + position: relative; + } + + .type-icon { + position: absolute; + right: 20rpx; + top: 20rpx; + opacity: .5; + } + } .foot { diff --git a/pages-userInfo/setting/setting.vue b/pages-userInfo/setting/setting.vue index adc0af7..96aa8e1 100644 --- a/pages-userInfo/setting/setting.vue +++ b/pages-userInfo/setting/setting.vue @@ -73,7 +73,7 @@ logout().then(res => { if (res.data.code === 200) { uni.reLaunch({ - url: '/pages/index/index', + url: '/pages/login/login', success() { uni.clearStorage(); uni.showToast({ diff --git a/pages-userInfo/withdraw/withdraw.vue b/pages-userInfo/withdraw/withdraw.vue index 6d75481..765dc76 100644 --- a/pages-userInfo/withdraw/withdraw.vue +++ b/pages-userInfo/withdraw/withdraw.vue @@ -7,7 +7,10 @@ ¥ - 当前余额为¥{{userInfo.amt}} + + 当前余额为¥{{userInfo.amt}} + 全部提现 + 小贴士:提现金额不少于1元 @@ -150,8 +153,12 @@ }else{ that.checkFlag = false; } - }, - + }, + allWithdraw() { + let that = this; + if (that.userInfo.amt > 0) + that.amt = that.userInfo.amt; + }, //提现 async withdraw(){ let that = this; @@ -311,6 +318,12 @@ font-weight: 400; color: $uni-secondary-color; margin-top: 18rpx; + display: flex; + justify-content: space-between; + + .all-withdraw { + color: $uni-primary; + } } .withdraw-amount-tip{ font-size: 28rpx; diff --git a/pages-userInfo/withdraw/withdrawIndex.vue b/pages-userInfo/withdraw/withdrawIndex.vue index 087d31c..5543c93 100644 --- a/pages-userInfo/withdraw/withdrawIndex.vue +++ b/pages-userInfo/withdraw/withdrawIndex.vue @@ -3,10 +3,17 @@ - @@ -23,6 +30,9 @@ @@ -110,10 +137,24 @@ export default { color: $uni-white; font-size: 28rpx; margin-top: 40rpx; + + .income-hidden-but { + margin-left: 30rpx; + } + } .account-balance-box { + display: flex; + justify-content: center; margin-bottom: 40rpx; + line-height: 80rpx; + height: 80rpx; + + .income-refresh-but { + margin-left: 30rpx; + } + } .withdrawBtn{ diff --git a/pages/login/login.vue b/pages/login/login.vue index e8b812b..a44e03a 100644 --- a/pages/login/login.vue +++ b/pages/login/login.vue @@ -149,6 +149,7 @@ } }); } else { + uni.hideLoading(); uni.showToast({ title: response.data.msg, icon: 'none' diff --git a/pages/profit/profit.vue b/pages/profit/profit.vue index f44b5ea..2ddd8c8 100644 --- a/pages/profit/profit.vue +++ b/pages/profit/profit.vue @@ -5,13 +5,18 @@ -
累计收益
+
+ 累计收益 + + + + +
-
- - -
+ + +
上月收入: @@ -183,10 +188,10 @@ export default { endProfitInfo: {}, userInfo: {}, noticeList: [], - pageSize: 10, + pageSize: 5, pageNum: 1, active: 0, - hidden: false, + hidden: true, incomeBackground: '/static/income-background.png', advertIcon: "/static/advertIcon.png", inviteIcon: "/static/inviteIcon.png", @@ -367,6 +372,18 @@ export default { }, clickHidden() { this.hidden = !this.hidden; + }, + clickRefresh() { + uni.showLoading({ + title: "加载中" + }); + this.queryFrontProfitInfo(); + this.queryFrontPreDownloadAndInviteCount(); + this.queryFrontInAmt(); + this.queryFrontEndAmt(); + setTimeout(() => { + uni.hideLoading() + }, 500) } }, }; @@ -417,17 +434,25 @@ export default { align-items: flex-end; .accumulate-income-title { + line-height: 48rpx; font-size: 28rpx; + display: flex; + align-items: center; + + .income-hidden-but { + margin-left: 30rpx; + } } .income-num { width: 100%; + height: 96rpx; line-height: 90rpx; display: flex; //justify-content: space-between; - .income-hidden-but { + .income-refresh-but { margin-left: 30rpx; } diff --git a/pages/register/register.vue b/pages/register/register.vue index 847d8f4..18c9c88 100644 --- a/pages/register/register.vue +++ b/pages/register/register.vue @@ -344,6 +344,10 @@ }); } else { uni.hideLoading() + uni.showToast({ + title: response.data.msg, + icon: 'none' + }) } }).catch(error => { uni.hideLoading() diff --git a/pages/userInfo/userInfo.vue b/pages/userInfo/userInfo.vue index 5e13f3e..7adb4e0 100644 --- a/pages/userInfo/userInfo.vue +++ b/pages/userInfo/userInfo.vue @@ -23,25 +23,27 @@ - - - -
{{item.title}}
- - + + + + +
{{item.title}}
+ + +
-
- - - - - -
{{item.title}}
- + + + + + +
{{item.title}}
+ +
-
+
@@ -163,12 +165,12 @@ page { font-family: ‘Franklin Gothic Medium’, ‘Arial Narrow’, Arial, sans-serif; min-height: 100vh; background: $uni-bg-color; - + position: relative; } .top { width: 100vw; - height: 30vh; + height: calc(30vh + 40rpx); position: relative; .background-image-dim { @@ -196,7 +198,7 @@ page { .my-message { width: calc(100% - 80rpx); - height: calc(100% - 80rpx); + height: calc(100% - 120rpx); position: absolute; top: 0; left: 0; @@ -209,7 +211,7 @@ page { display: flex; justify-content: flex-start; align-items: flex-end; - padding: 40rpx; + padding: 40rpx 40rpx 80rpx; .left { width: 150rpx; @@ -258,6 +260,18 @@ page { } } + .content-box { + width: 100vw; + min-height: calc(100vh - 30vh); + background: $uni-bg-color; + border-radius: 40rpx 40rpx 0 0; + border: 2rpx solid $uni-bg-color; + position: absolute; + top: calc(30vh); + left: 0; + right: 0; + } + .middle { width: 670rpx; margin: 40rpx auto; diff --git a/utils/request.js b/utils/request.js index 4123a86..a726264 100644 --- a/utils/request.js +++ b/utils/request.js @@ -49,7 +49,7 @@ service.interceptors.response.use(res => { } }); } else { - return Promise.reject(res.data.msg); + return res; } }, error => { return Promise.reject(error)