Browse Source

7.7下班提交

李万涛 2 years ago
parent
commit
5634e6cb6b

+ 3 - 3
pages/index/index.vue

xqd xqd
@@ -144,6 +144,9 @@
 					url: '/pages/user/signin'
 				})
 			}
+
+		},
+		async onShow() {
 			let ress = await taskList({
 				is_new: 1,
 				page: this.page,
@@ -194,9 +197,6 @@
 		},
 		onReady() {
 
-		},
-		onShow() {
-
 		},
 		onUnload() {
 

+ 7 - 10
pages/index/scoreDetail/index.scss

xqd xqd xqd
@@ -1,10 +1,12 @@
 page {
 		background: #F6F5F5;
+		// padding-bottom: 165rpx;
 		
 	}
 .container {
-	padding-bottom: 130rpx;
+	// padding-bottom: 165rpx;
 		.content{
+			// padding-bottom: 165rpx;
 			.pic{
 				overflow: hidden;
 				height: 500rpx;
@@ -50,18 +52,10 @@ page {
 				}
 				.desBox{
 					width: 100%;
-					height: calc(100vh - 550rpx);
-					margin-bottom: 20rpx;
+					min-height: 570rpx;
 					padding: 0 40rpx;
 					background: #fff;
-					// height: 800rpx;
-					// image{
-					// 	width: 100%;
-					// 	height: 100%;
-					// }
 				}
-				
-				
 			}
 			
 		}
@@ -113,4 +107,7 @@ page {
 		margin-bottom: 20rpx;
 		padding: 0 40rpx;
 	}
+	.pos{
+		height: 165rpx;
+	}
 	

+ 7 - 5
pages/index/scoreDetail/index.vue

xqd xqd
@@ -39,9 +39,11 @@
 					<!-- <image src="../../../static/posImg.png" mode=""></image> -->
 				</view>
 			</view>
+		</view>
+		<view class="pos">
+
 		</view>
 		<view class="kefuAndBtn">
-			<!-- <image src="../../../static/posImg.png" mode=""></image> -->
 			<view class="iconBox" @click="jumpToKefu">
 				<u-icon class="icon" name="server-fill" color="#26B3A0" size="22"></u-icon>
 			</view>
@@ -125,10 +127,10 @@
 				})
 				console.log('立即学习(下单)返回值', res1);
 				if (res1.code == 0) {
-					uni.showToast({
-						title: '下单成功',
-						icon: 'success'
-					})
+					// uni.showToast({
+					// 	title: '下单成功',
+					// 	icon: 'success'
+					// })
 
 					let res2 = await wxPayPamars({
 						order_id: res1.data.id

+ 6 - 0
pages/tusk/tuskDetail/index.scss

xqd xqd
@@ -84,6 +84,8 @@ page {
 		background: #fff;
 		padding: 30rpx;
 		width: 100%;
+		
+		border-top: 1rpx solid #ccc;
 		.iconBox{
 			background: #eee;
 			width: 100rpx;
@@ -110,4 +112,8 @@ page {
 			color: #fff;
 			font-weight: 600;
 		}
+	}
+	
+	.pos{
+		height: 165rpx;
 	}

+ 3 - 1
pages/tusk/tuskDetail/index.vue

xqd
@@ -45,7 +45,9 @@
 			<view class="bImg">
 				<u-parse :content="detail.receive_notice"></u-parse>
 			</view>
-			<!-- <image class="bImg" src="/static/posImg.png" mode=""></image> -->
+		</view>
+		<view class="pos">
+
 		</view>
 		<view class="kefuAndBtn">
 			<view class="iconBox">

+ 11 - 0
pages/user/commission/commission-log.vue

xqd xqd
@@ -50,6 +50,10 @@
 						</view>
 						<button class="u-reset-button draw-btn"
 							@tap="jump('/pages/user/commission/withdraw',{type:1})">提现</button>
+
+						<view class="cashTips">
+							注:可提现佣金/已提现佣金包含了任务佣金和推广佣金
+						</view>
 					</view>
 				</view>
 				<!-- 筛选 -->
@@ -359,6 +363,13 @@
 
 <style lang="scss">
 	// 分类
+
+	.cashTips {
+		margin-top: 20rpx;
+		color: white;
+		font-size: 12rpx;
+	}
+
 	.state-item {
 		height: 100%;
 		display: flex;

+ 40 - 1
pages/user/commission/commission-log2.vue

xqd xqd xqd xqd
@@ -49,6 +49,10 @@
 						</view>
 						<button class="u-reset-button draw-btn"
 							@tap="jump('/pages/user/commission/withdraw',{type:2})">提现</button>
+
+						<view class="cashTips">
+							注:可提现佣金/已提现佣金包含了任务佣金和推广佣金
+						</view>
 					</view>
 				</view>
 
@@ -62,6 +66,13 @@
 							<view class="">
 								<view class="log-name">{{ item.title }}</view>
 								<view class="log-notice">{{ item.created_at }}</view>
+
+								<!-- 	<view class="nextUser">
+									<image class="nextAvatar" src="../../../static/add.png" mode=""></image>
+									<view class="nextUserName">
+										张三
+									</view>
+								</view> -->
 							</view>
 						</view>
 						<view class="item-right">
@@ -357,6 +368,33 @@
 </script>
 
 <style lang="scss">
+	.nextUser {
+		display: flex;
+		align-items: center;
+		margin-top: 10rpx;
+		margin-bottom: 10rpx;
+
+		.nextAvatar {
+			width: 40rpx;
+			height: 40rpx;
+			border-radius: 50%;
+			margin-right: 20rpx;
+		}
+
+		.nextUserName {
+			font-size: 24rpx;
+			color: #ccc;
+			font-weight: 600;
+		}
+	}
+
+
+	.cashTips {
+		margin-top: 20rpx;
+		color: white;
+		font-size: 12rpx;
+	}
+
 	// 分类
 	.state-item {
 		height: 100%;
@@ -497,10 +535,11 @@
 	}
 
 	.log-item {
-		height: 142rpx;
+		// height: 200rpx;
 		background-color: #fff;
 		padding: 0 60rpx;
 		border-bottom: 1rpx solid #eee;
+		padding-top: 10rpx;
 
 		.item-left {
 			.log-img {

+ 81 - 36
pages/user/commission/withdraw.vue

xqd xqd xqd xqd xqd xqd xqd
@@ -130,12 +130,16 @@
 							size="22"></u-icon></view>
 
 					<view class="carmititle">添加提现信息</view>
-					<view class="kf_qrcode tn-flex justify-center">
-						<u--image :showLoading="true" :src="paymentcode" width="100px" height="100px"
-							@click="clickuimage()"></u--image>
-					</view>
-					<view class="u-text-center">
-						点击上传微信收款码
+					<view class="carmiinput" v-if="selectedWithdrawType==1"><u--input placeholder="请输入您的银行卡号"
+							border="surround" clearable v-model="cardNum"></u--input></view>
+					<view class="" v-else>
+						<view class="kf_qrcode tn-flex justify-center">
+							<u--image :showLoading="true" :src="paymentcode" width="100px" height="100px"
+								@click="clickuimage()"></u--image>
+						</view>
+						<view class="u-text-center">
+							点击上传{{selectedWithdrawType==2?"微信":'支付宝'}}收款码
+						</view>
 					</view>
 					<view class="carmiinput"><u--input placeholder="请输入您的真实姓名" border="surround" clearable
 							v-model="realname"></u--input></view>
@@ -238,7 +242,8 @@
 
 				minCash: 0,
 				dayCash: 0,
-				methods: []
+				methods: [],
+				cardNum: ''
 			};
 		},
 		computed: {
@@ -325,18 +330,23 @@
 						icon: 'none'
 					})
 				}
-
-
-				if (!this.paymentcode || !this.realname) {
-					this.$u.toast('请上传提现信息');
-					this.showBindForm = true
+				if (this.selectedWithdrawType == 1) {
+					this.$u.toast('银行卡提现暂未开通');
 					return;
 				}
-				// if (!this.realname) {
-				// 	this.$u.toast('请上传提现真实姓名信息');
-				// 	this.showBindForm = true
-				// 	return;
-				// }
+				if (this.selectedWithdrawType == 1) {
+					if (!this.cardNum || !this.realname) {
+						this.$u.toast('请上传提现信息');
+						this.showBindForm = true
+						return;
+					}
+				} else {
+					if (!this.paymentcode || !this.realname) {
+						this.$u.toast('请上传提现信息');
+						this.showBindForm = true
+						return;
+					}
+				}
 				console.log('申请提现参数', {
 					type: this.withDrawType,
 					method: this.selectedWithdrawType,
@@ -345,14 +355,27 @@
 					real_name: this.realname,
 					qrcode_url: this.paymentcode
 				});
-				let ress = await applyWithdraw({
-					type: this.withDrawType,
-					method: this.selectedWithdrawType,
-					amount: this.money,
+				let parms = {}
+				if (this.selectedWithdrawType == 1) {
+					parms = {
+						type: this.withDrawType,
+						method: this.selectedWithdrawType,
+						amount: this.money,
+
+						real_name: this.realname,
+						cardNum: this.cardNum
+					}
+				} else {
+					parms = {
+						type: this.withDrawType,
+						method: this.selectedWithdrawType,
+						amount: this.money,
 
-					real_name: this.realname,
-					qrcode_url: this.paymentcode
-				})
+						real_name: this.realname,
+						qrcode_url: this.paymentcode
+					}
+				}
+				let ress = await applyWithdraw(parms)
 				console.log('申请提现返回值', ress, ress.msg);
 				if (ress.code == 0) {
 					uni.showToast({
@@ -400,6 +423,9 @@
 			onSaveWithdrawType() {
 				// this.withdrawType = this.selectedWithdrawType;
 				this.showWithdrawList = false;
+				this.paymentcode = ''
+				this.cardNum = ''
+				console.log('this.paymentcode----------------', this.paymentcode);
 				console.log('this.selectedWithdrawType', this.selectedWithdrawType);
 				// this.getWithdrawInfo();
 			},
@@ -410,13 +436,24 @@
 			},
 			exchange() {
 				let that = this;
-				if (!that.paymentcode) {
-					uni.showToast({
-						title: '请上传微信收款码',
-						icon: 'none'
-					})
-					return;
+				if (this.selectedWithdrawType == 1) {
+					if (!that.cardNum) {
+						uni.showToast({
+							title: '请填写提现银行卡号',
+							icon: 'none'
+						})
+						return;
+					}
+				} else {
+					if (!that.paymentcode) {
+						uni.showToast({
+							title: '请上传收款码',
+							icon: 'none'
+						})
+						return;
+					}
 				}
+
 				if (!that.realname) {
 					uni.showToast({
 						title: '请填写您的真实姓名',
@@ -430,12 +467,20 @@
 					qrcode_wechat: that.paymentcode
 				});
 
-
-				if (that.realname && that.paymentcode) {
-					uni.showToast({
-						title: '保存成功'
-					})
-					that.showBindForm = false
+				if (this.selectedWithdrawType == 1) {
+					if (that.realname && that.cardNum) {
+						uni.showToast({
+							title: '保存成功'
+						})
+						that.showBindForm = false
+					}
+				} else {
+					if (that.realname && that.paymentcode) {
+						uni.showToast({
+							title: '保存成功'
+						})
+						that.showBindForm = false
+					}
 				}
 				return
 				that.$http('commission.update', {

+ 11 - 2
pages/user/score/index.vue

xqd xqd
@@ -26,7 +26,7 @@
 				<u-parse :content="detail.course ? detail.course.description : '暂无课程信息'"></u-parse>
 			</view>
 
-			<view class="topBtn" @click="downLoad">
+			<view class="topBtn" @click="downLoad(detail.status)">
 				查看学习资料
 			</view>
 
@@ -108,10 +108,19 @@
 			goPay() {
 				let pay = new ShoproPay(this.orderId);
 			},
-			downLoad() {
+			downLoad(status) {
 				// uni.navigateTo({
 				// 	url: '/pages/test/index'
 				// })
+				if (status == 0) {
+					uni.showToast({
+						title: '待支付课程不能查看学习资料',
+						icon: 'none',
+						duration: 1500
+					})
+					return
+				}
+
 				if (!this.detail.course.content) {
 					uni.showToast({
 						title: '当前课程暂无学习资料',

+ 4 - 4
pages/user/user.vue

xqd xqd
@@ -30,7 +30,7 @@
 							<block>
 								<view class="cell-text" style="color: #ffd465;font-size: 30rpx;font-weight: bold;">
 									<!-- 佣金: {{userInfo.commission }} -->
-									{{totalMoney.toFixed(2)}}
+									{{commissionMoney.toFixed(2)}}
 								</view>
 							</block>
 						</view>
@@ -238,9 +238,9 @@
 		computed: {
 			...mapGetters(['hasLogin']),
 
-			totalMoney() {
-				return this.commissionMoney + this.tuskMoney
-			}
+			// totalMoney() {
+			// 	return this.commissionMoney + this.tuskMoney
+			// }
 		},
 
 		async onShow() {

+ 6 - 6
pages/user/work/index.vue

xqd xqd xqd xqd
@@ -60,7 +60,7 @@
 
 					<!-- 待审核  -->
 					<view v-if="item.status == 2" class="tuskitem" @click="goDetail(item)">
-						<view class="title">
+						<view class="title" style="color: orange;">
 							{{ item.status_text }}
 						</view>
 						<view class="center">
@@ -100,8 +100,8 @@
 
 					<!-- 已审核  -->
 					<view v-if="item.status == 3" class="tuskitem" @click="goDetail(item)">
-						<view class="title">
-							{{ item.status_text }}
+						<view class="title" :style="{color:item.audit_status==1?'green':'red'}">
+							{{ item.audit_status==1?item.status_text+':成功':item.status_text+':失败'}}
 						</view>
 						<view class="center">
 							<image
@@ -214,7 +214,7 @@
 			<!-- 待审核  -->
 			<view class="" v-if="waitingTuskList.length!=0">
 				<view v-for="(item,index) in waitingTuskList" :key="item.id" class="tuskitem" @click="goDetail(item)">
-					<view class="title">
+					<view class="title" style="color: orange;">
 						{{ item.status_text }}
 					</view>
 					<view class="center">
@@ -255,8 +255,8 @@
 			<view class="" v-if="alreadyViewTuskList.length!=0">
 				<view v-for="(item,index) in alreadyViewTuskList" :key="item.id" class="tuskitem"
 					@click="goDetail(item)">
-					<view class="title">
-						{{ item.status_text }}
+					<view class="title" :style="{color:item.audit_status==1?'green':'red'}">
+						{{ item.audit_status==1?item.status_text+':成功':item.status_text+':失败'}}
 					</view>
 					<view class="center">
 						<image