cmy 2 tahun lalu
induk
melakukan
ed2a3bf60b
8 mengubah file dengan 877 tambahan dan 452 penghapusan
  1. 18 0
      api/new.js
  2. 2 2
      manifest.json
  3. 12 0
      pages.json
  4. 28 5
      pages/money/qudou.vue
  5. 3 1
      pages/user/award.vue
  6. 283 0
      pages/user/jfchange.vue
  7. 243 444
      pages/user/mygs.vue
  8. 288 0
      pages/user/yjchange.vue

+ 18 - 0
api/new.js

@@ -0,0 +1,18 @@
+import request from '@/utils/request'
+// 佣金转账
+export function trade(data) {
+	return request({
+		url: '/api/trade',
+		method: 'post',
+		data
+	});
+}
+// 积分转账
+export function tradeUser(data) {
+	return request({
+		url: '/api/user/trade',
+		method: 'post',
+		data
+	});
+}
+

+ 2 - 2
manifest.json

@@ -1,5 +1,5 @@
 {
-    "name" : "易趣CBB",
+    "name" : "XX",
     "appid" : "__UNI__9A7699F",
     "description" : "",
     "versionName" : "1.4.8",
@@ -102,7 +102,7 @@
         }
     },
     "h5" : {
-        "title" : "商城",
+        "title" : "XX",
         "domain" : "",
         "router" : {
             "base" : "/index/",

+ 12 - 0
pages.json

@@ -218,6 +218,18 @@
 			   		"navigationBarTitleText": "我的粉丝"
 			   	}
 			   },
+			   {
+			   	"path": "yjchange",
+			   	"style": {
+			   		"navigationBarTitleText": "佣金转账"
+			   	}
+			   },
+			   {
+			   	"path": "jfchange",
+			   	"style": {
+			   		"navigationBarTitleText": "积分转账"
+			   	}
+			   },
 			   {
 			   	"path": "shareQrCode",
 			   	"style": {

+ 28 - 5
pages/money/qudou.vue

@@ -1,6 +1,7 @@
 <template>
 	<view class="content">
 		<view class="content-money">
+			
 			<view class="status_bar"><!-- 这里是状态栏 --></view>
 			<view class="body-title">
 				<view class="goback-box" @click="toBack">
@@ -15,6 +16,9 @@
 				<view class="money">{{ userInfo.integral }}</view>
 				<view>当前余额</view>
 			</view>
+			<view class="changeHeader" @click="navTor(`/pages/user/jfchange`)">
+				积分转账
+			</view>
 		</view>
 		<view class="info-box flex">
 			<view class="info-item">
@@ -59,6 +63,9 @@
 				</scroll-view>
 			</swiper-item>
 		</swiper>
+		<navigator url="../user/jfchange">
+		<view class="action-btn">积分转账</view>
+		</navigator>
 	</view>
 </template>
 
@@ -126,7 +133,9 @@
 				money: ''
 			};
 		},
-		onLoad(options) {},
+		onLoad(options) {
+			console.log(233);
+		},
 		onShow() {
 			this.loadData();
 			this.loadBaseData();
@@ -134,9 +143,13 @@
 		methods: {
 			...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
 			// 页面跳转
-			navto(e) {
+			navTor(e) {
+				console.log(e);
 				uni.navigateTo({
-					url: e
+					url: e,
+					fail(err) {
+						console.log(err);
+					}
 				});
 			},
 			loadBaseData() {
@@ -161,7 +174,6 @@
 				let index = this.tabCurrentIndex;
 				let navItem = this.navList[index];
 				let state = navItem.state;
-				console.log(source, 'iwiwiwiwi');
 				if (source === 'tabChange' && navItem.loaded === true) {
 					//tab切换只有第一次需要加载数据
 					return;
@@ -248,7 +260,18 @@
 	.content-money {
 		position: relative;
 		height: 480rpx;
-
+		.changeHeader{
+			position: absolute;
+			top: 100rpx;
+			right: 0rpx;
+			padding: 10rpx 20rpx 10rpx 30rpx;
+			color:#E6C79D;
+			background: #fff;
+			border: 2rpx solid #E6C79D;
+			border-top-left-radius: 100rpx;
+			border-bottom-left-radius: 100rpx;
+			z-index: 99;
+		}
 		.content-bg {
 			position: absolute;
 			top: 0;

+ 3 - 1
pages/user/award.vue

@@ -134,7 +134,9 @@ export default {
 		},
 		// 点击返回 我的页面
 		toBack() {
-			uni.navigateBack({});
+			uni.reLaunch({
+				url:'/pages/user/user'
+			})
 		},
 		//获取收入支出信息
 		async loadData(source) {

+ 283 - 0
pages/user/jfchange.vue

@@ -0,0 +1,283 @@
+<template>
+	<view class="content">
+		<view class="content-money">
+			<view class="flex " style="width: 750rpx;justify-content: space-around;margin-left: 0;">
+				<view class="buttom">
+					<view class="icon">{{ userInfo.integral | getMoneyStyle }}</view>
+					<text class="text">可转账积分</text>
+				</view>
+			</view>
+		</view>
+
+		<view class="row-box margin-t-20">
+			<view class="title">转账积分</view>
+			<view class="row">
+				<input class="input" type="number" v-model="withdrawal" placeholder="请输入转账积分"
+					placeholder-class="placeholder" />
+				<view class="buttom" @click="withdrawal = userInfo.integral">全部积分</view>
+			</view>
+		</view>
+		<view class="row-box margin-t-20">
+			<view class="title">用户ID</view>
+			<view class="row">
+				<input class="input" type="number" v-model="uid" placeholder="请填写转账到的用户ID"
+					placeholder-class="placeholder" />
+			</view>
+		</view>
+		<button class="add-btn up" @click="confirm">提交申请</button>
+		<!-- <button class="add-btn modified" v-if="!weichatBsrowser" @click="navTo('/pages/money/account')">账号管理</button> -->
+	</view>
+</template>
+
+<script>
+	import {
+		getMoneyStyle
+	} from '@/utils/rocessor.js';
+	import {
+		tradeUser
+	} from '@/api/new.js';
+	import {
+		getUserInfo
+	} from '@/api/user.js';
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	export default {
+		filters: {
+			getMoneyStyle
+		},
+		computed: {
+			...mapState('user', ['userInfo', 'hasLogin'])
+		},
+		data() {
+			return {
+				type: 'bank', //提现方式
+				money: '0.00', //可提现金额
+				freeze: '0.0', //冻结金额
+				withdrawal: '',
+				uid: '', //提现金额
+			};
+		},
+		onLoad(options) {},
+		methods: {
+			...mapMutations('user', ['setUserInfo']),
+			// 跳转
+			navTo(url) {
+				uni.navigateTo({
+					url: url
+				});
+			},
+			// 提交
+			confirm() {
+				let obj = this
+				let data = {
+					num: this.withdrawal, //金额
+					uid: this.uid //0佣金1余额
+				};
+				tradeUser(data)
+					.then(e => {
+						getUserInfo({})
+							.then(({
+								data
+							}) => {
+								this.setUserInfo(data);
+							})
+							.catch(e => {
+								console.log(e);
+							});
+						uni.showToast({
+							title: '申请成功!',
+							duration: 2000,
+							position: 'top'
+						});
+					})
+					.catch(e => {
+						console.log();
+					});
+			}
+		}
+	};
+</script>
+
+<style lang="scss">
+	page {
+		height: 100%;
+	}
+
+	.content-money {
+		padding: 30rpx 0;
+		background: #ffffff;
+	}
+
+	.flex {
+		background-color: #ffffff;
+		text-align: center;
+		margin: 0 30rpx;
+		border-radius: $border-radius-sm;
+
+		.buttom {
+			font-size: $font-lg;
+			width: 50%;
+		}
+
+		.interval {
+			width: 2px;
+			height: 60rpx;
+			background-color: #eeeeee;
+		}
+
+		.icon {
+			background-size: 100%;
+			font-size: 42rpx;
+			color: $font-color-dark;
+			font-weight: bold;
+			background-repeat: no-repeat;
+			background-position: center;
+		}
+
+		.text {
+			color: $font-color-light;
+		}
+	}
+
+	.row-box {
+		padding: 20rpx 30rpx;
+		background: #fff;
+
+		.title {
+			font-size: $font-base + 2rpx;
+			color: $font-color-dark;
+		}
+
+		.row {
+			display: flex;
+			align-items: center;
+			position: relative;
+			height: 80rpx;
+
+			.tit {
+				flex-shrink: 0;
+				width: 40rpx;
+				font-size: 30rpx;
+				color: $font-color-dark;
+			}
+
+			.input {
+				flex: 1;
+				font-size: 30rpx;
+				color: $font-color-dark;
+			}
+
+			.iconlocation {
+				font-size: 36rpx;
+				color: $font-color-light;
+			}
+
+			.buttom {
+				font-size: $font-base;
+			}
+		}
+	}
+
+	.add-btn {
+		background: linear-gradient(-90deg, #FAC545, #FFE000);
+		border-radius: 10px;
+		width: 690rpx;
+		height: 80rpx;
+		margin: 0 auto;
+		margin-top: 30rpx;
+		font-size: $font-lg;
+		border-radius: 10rpx;
+		color: #6B4216;
+
+		&.up {
+			background-color: $base-color;
+			color: #fff;
+		}
+	}
+
+	.list {
+		padding-left: 30rpx;
+		margin-top: 30rpx;
+		background-color: #ffffff;
+
+		.box {
+			display: flex;
+			align-items: center;
+			width: 100%;
+			height: 120rpx;
+			border-bottom: 1px solid $border-color-light;
+
+			.icon {
+				font-size: 48rpx;
+				padding-right: 20rpx;
+
+				.icon-img {
+					height: 50rpx;
+					width: 50rpx;
+				}
+			}
+
+			.iconweixin1 {
+				color: #18bf16;
+			}
+
+			.iconzhifubao {
+				color: #08aaec;
+			}
+
+			.title-box {
+				flex-grow: 1;
+				text-align: left;
+
+				.title {
+					font-size: $font-base + 2rpx;
+					color: $font-color-base;
+				}
+
+				.node {
+					font-size: $font-sm;
+					color: $font-color-light;
+				}
+			}
+		}
+	}
+
+	/deep/ .uni-radio-input {
+		width: 45rpx;
+		height: 45rpx;
+	}
+
+	.row {
+		display: flex;
+		align-items: center;
+		position: relative;
+		padding: 0 30upx;
+		height: 110upx;
+		background: #fff;
+
+		.tit {
+			flex-shrink: 0;
+			width: 250upx;
+			font-size: 30upx;
+			color: $font-color-dark;
+		}
+
+		.input {
+			flex: 1;
+			font-size: 30upx;
+			color: $font-color-dark;
+		}
+
+		.iconlocation {
+			font-size: 36upx;
+			color: $font-color-light;
+		}
+	}
+
+	.tip {
+		padding: 20rpx;
+		color: #FD3B39;
+	}
+</style>

+ 243 - 444
pages/user/mygs.vue

@@ -3,10 +3,14 @@
 		<view class="content-money">
 			<view class="status_bar"><!-- 这里是状态栏 --></view>
 			<view class="body-title">
-				<view class="goback-box" @click="toBack"><image class="goback" src="../../static/icon/fanhui.png" mode=""></image></view>
+				<view class="goback-box" @click="toBack">
+					<image class="goback" src="../../static/icon/fanhui.png" mode=""></image>
+				</view>
 				<view class="header">我的奖金</view>
 			</view>
-			<view class="content-bg"><image src="../../static/img/myfans.png" mode=""></image></view>
+			<view class="content-bg">
+				<image src="../../static/img/myfans.png" mode=""></image>
+			</view>
 			<view class="money-box">
 				<view class="money">{{ userInfo.brokerage_price || 0 }}</view>
 				<view>当前余额</view>
@@ -32,510 +36,305 @@
 							<text class="price">{{ moneyNum(item.price) }}</text>
 						</view>
 					</view>
-
-					<!-- <view class="price-box">
-						共
-						<text class="num">1</text>
-						件商品 邮费
-						<text class="price">0</text>
-						实付款
-						<text class="price">{{ moneyNum(item.price) }}</text>
-					</view> -->
 				</view>
 				<uni-load-more :status="loadingType"></uni-load-more>
 			</view>
 		</scroll-view>
+		<navigator url="./yjchange">
+		<view class="action-btn">佣金转账</view>
+		</navigator>
 	</view>
 </template>
 
 <script>
-import { seller } from '@/api/order.js';
-import { getMoneyStyle } from '@/utils/rocessor.js';
-import { mapState, mapMutations } from 'vuex';
-import uniLoadMore from '@/uview-ui/components/u-loadmore/u-loadmore.vue';
-import empty from '@/uview-ui/components/u-empty/u-empty.vue';
-export default {
-	filters: {
+	import {
+		seller
+	} from '@/api/order.js';
+	import {
 		getMoneyStyle
-	},
-	computed: {
-		...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
-	},
-	components: {
-		empty,
-		uniLoadMore
-	},
-	data() {
-		return {
-			loadingType: 'more',
-			orderList: [],
-			page: 1, //当前页数
-			limit: 10 //每次信息条数
-		};
-	},
-	filters: {
-		moneyNum(value) {
-			return +value;
-		}
-	},
-	onShow() {
-		this.loadData();
-	},
-	methods: {
-		// 转换金额为数字
-		moneyNum(value) {
-			return +value;
+	} from '@/utils/rocessor.js';
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	import uniLoadMore from '@/uview-ui/components/u-loadmore/u-loadmore.vue';
+	import empty from '@/uview-ui/components/u-empty/u-empty.vue';
+	export default {
+		filters: {
+			getMoneyStyle
 		},
-		// 页面跳转
-		navto(e) {
-			uni.navigateTo({
-				url: e
-			});
+		computed: {
+			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
 		},
-		// 点击返回 我的页面
-		toBack() {
-			uni.navigateBack({});
+		components: {
+			empty,
+			uniLoadMore
 		},
-		//获取收入支出信息
-		async loadData(source) {
-			let obj = this;
-			seller({
-				type: 3,
-				page: obj.page,
-				limit: obj.limit
-			})
-				.then(({ data }) => {
-					let arr = data.map(e => {
-						e.stateTip = '已完成';
-						e.stateTipColor = '#909399';
-						return e;
-					});
-					obj.orderList = obj.orderList.concat(arr);
-
-					// console.log(navItem.orderList);
-					obj.page++;
-					if (obj.limit == data.length) {
-						//判断是否还有数据, 有改为 more, 没有改为noMore
-						obj.loadingType = 'more';
-						return;
-					} else {
-						//判断是否还有数据, 有改为 more, 没有改为noMore
-						obj.loadingType = 'noMore';
-					}
-					uni.hideLoading();
-				})
-				.catch(e => {
-					console.log(e);
-				});
+		data() {
+			return {
+				loadingType: 'more',
+				orderList: [],
+				page: 1, //当前页数
+				limit: 10 //每次信息条数
+			};
 		},
-
-		//swiper 切换
-		changeTab(e) {
-			this.tabCurrentIndex = e.target.current;
-			this.loadData('tabChange');
+		filters: {
+			moneyNum(value) {
+				return +value;
+			}
 		},
-		//顶部tab点击
-		tabClick(index) {
-			this.tabCurrentIndex = index;
+		onShow() {
+			this.loadData();
+		},
+		methods: {
+			// 转换金额为数字
+			moneyNum(value) {
+				return +value;
+			},
+			// 页面跳转
+			navto(e) {
+				uni.navigateTo({
+					url: e
+				});
+			},
+			// 点击返回 我的页面
+			toBack() {
+				uni.reLaunch({
+					url:'/pages/user/user'
+				})
+			},
+			//获取收入支出信息
+			async loadData(source) {
+				let obj = this;
+				seller({
+						type: 3,
+						page: obj.page,
+						limit: obj.limit
+					})
+					.then(({
+						data
+					}) => {
+						let arr = data.map(e => {
+							e.stateTip = '已完成';
+							e.stateTipColor = '#909399';
+							return e;
+						});
+						obj.orderList = obj.orderList.concat(arr);
+
+						// console.log(navItem.orderList);
+						obj.page++;
+						if (obj.limit == data.length) {
+							//判断是否还有数据, 有改为 more, 没有改为noMore
+							obj.loadingType = 'more';
+							return;
+						} else {
+							//判断是否还有数据, 有改为 more, 没有改为noMore
+							obj.loadingType = 'noMore';
+						}
+						uni.hideLoading();
+					})
+					.catch(e => {
+						console.log(e);
+					});
+			},
+
+			//swiper 切换
+			changeTab(e) {
+				this.tabCurrentIndex = e.target.current;
+				this.loadData('tabChange');
+			},
+			//顶部tab点击
+			tabClick(index) {
+				this.tabCurrentIndex = index;
+			}
 		}
-	}
-};
+	};
 </script>
 
 <style lang="scss">
-page {
-	background: #f1f1f1;
-	height: 100%;
-}
-.status_bar {
-	height: var(--status-bar-height);
-	width: 100%;
-}
-.content-money {
-	position: relative;
-	height: 400rpx;
-	.content-bg {
-		position: absolute;
-		top: 0;
-		left: 0;
-		right: 0;
-		width: 750rpx;
-		height: 400rpx;
-		image {
-			width: 100%;
-			height: 100%;
-		}
+	page {
+		background: #f1f1f1;
+		height: 100%;
 	}
-	.body-title {
-		height: 80rpx;
-		text-align: center;
-		font-size: 35rpx;
-		position: relative;
-		.header {
-			position: absolute;
-			left: 0;
-			top: 0;
-			width: 100%;
-			font-size: 36rpx;
-			font-family: PingFang SC;
-			font-weight: bold;
-			color: #fffeff;
-			height: 80rpx;
-			font-size: 36rpx;
-			font-weight: 700;
-			z-index: 9;
-			display: flex;
-			justify-content: center;
-			align-items: center;
-		}
-		.goback-box {
-			position: absolute;
-			left: 18rpx;
-			top: 0;
-			height: 80rpx;
-			display: flex;
-			align-items: center;
-		}
 
-		.goback {
-			z-index: 100;
-			width: 34rpx;
-			height: 34rpx;
-		}
+	.status_bar {
+		height: var(--status-bar-height);
+		width: 100%;
 	}
-}
-.info-box {
-	width: 670rpx;
-	height: 186rpx;
-	background: #ffffff;
-	box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.06);
-	border-radius: 20rpx;
-	margin: -100rpx auto 0;
-	position: relative;
-	z-index: 2;
-	.info-item {
-		width: 50%;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		line-height: 1;
-		.info-font {
-			font-size: 30rpx;
-			font-family: PingFang SC;
-			font-weight: bold;
-			color: #999999;
-		}
-		.info-num {
-			margin-top: 30rpx;
-			font-size: 30rpx;
-			font-family: PingFang SC;
-			font-weight: bold;
-			color: #181818;
-		}
-	}
-	.shu {
-		width: 2rpx;
-		height: 74rpx;
-		background: #dcdfe6;
-	}
-}
-.money-box {
-	position: relative;
-	z-index: 2;
-	padding-top: 90rpx;
-	color: #ffffff;
-	text-align: center;
-	.money {
-		font-size: 72rpx;
-		font-family: PingFang SC;
-		font-weight: bold;
-		color: #ffffff;
-	}
-	.text {
-		font-size: 30rpx;
-	}
-}
-.list-scroll-content {
-	height: calc(100% - 175px);
-	padding-top: 30rpx;
-}
-.order-item {
-	display: flex;
-	flex-direction: column;
-	border-radius: 20rpx;
-	background: #fff;
-	margin: 0rpx 30rpx 30rpx 30rpx;
-	
-
-	.i-top {
-		display: flex;
-		align-items: center;
-		height: 80rpx;
-		font-size: $font-base;
-		color: $font-color-dark;
+
+	.content-money {
 		position: relative;
-		padding: 0 30rpx;
+		height: 400rpx;
 
-		.time {
-			flex: 1;
-		}
+		.content-bg {
+			position: absolute;
+			top: 0;
+			left: 0;
+			right: 0;
+			width: 750rpx;
+			height: 400rpx;
 
-		.state {
-			color: $base-color;
+			image {
+				width: 100%;
+				height: 100%;
+			}
 		}
 
-		.del-btn {
-			padding: 10rpx 0 10rpx 36rpx;
-			font-size: $font-lg;
-			color: $font-color-light;
+		.body-title {
+			height: 80rpx;
+			text-align: center;
+			font-size: 35rpx;
 			position: relative;
 
-			&:after {
-				content: '';
-				width: 0;
-				height: 30rpx;
-				border-left: 1px solid $border-color-dark;
+			.header {
 				position: absolute;
-				left: 20rpx;
-				top: 50%;
-				transform: translateY(-50%);
+				left: 0;
+				top: 0;
+				width: 100%;
+				font-size: 36rpx;
+				font-family: PingFang SC;
+				font-weight: bold;
+				color: #fffeff;
+				height: 80rpx;
+				font-size: 36rpx;
+				font-weight: 700;
+				z-index: 9;
+				display: flex;
+				justify-content: center;
+				align-items: center;
 			}
-		}
-	}
 
-	/* 多条商品 */
-	.goods-box {
-		height: 160rpx;
-		padding: 20rpx 0;
-		white-space: nowrap;
-
-		.goods-item {
-			width: 120rpx;
-			height: 120rpx;
-			display: inline-block;
-			margin-right: 24rpx;
-		}
+			.goback-box {
+				position: absolute;
+				left: 18rpx;
+				top: 0;
+				height: 80rpx;
+				display: flex;
+				align-items: center;
+			}
 
-		.goods-img {
-			display: block;
-			width: 100%;
-			height: 100%;
+			.goback {
+				z-index: 100;
+				width: 34rpx;
+				height: 34rpx;
+			}
 		}
 	}
 
-	/* 单条商品 */
-	.goods-box-single {
-		display: flex;
-		padding: 20rpx 30rpx;
-		// background: #f7f7f7;
-		.goods-img {
-			display: block;
-			width: 120rpx;
-			height: 120rpx;
-		}
 
-		.right {
-			flex: 1;
-			display: flex;
-			flex-direction: column;
-			padding: 0 0 0 24rpx;
-			overflow: hidden;
+	.money-box {
+		position: relative;
+		z-index: 2;
+		padding-top: 90rpx;
+		color: #ffffff;
+		text-align: center;
 
-			.row {
-				margin-top: 10rpx;
-			}
+		.money {
+			font-size: 72rpx;
+			font-family: PingFang SC;
+			font-weight: bold;
+			color: #ffffff;
+		}
 
-			.row_title {
-				padding: 5rpx 10rpx;
-				background-color: #dddddd;
-				border-radius: 10rpx;
-				font-size: 22rpx;
-				color: #ffffff;
-			}
+		.text {
+			font-size: 30rpx;
+		}
+	}
 
-			.title {
-				font-size: $font-base + 2rpx;
-				color: $font-color-dark;
-				line-height: 1;
-				width: 80%;
-			}
+	.list-scroll-content {
+		height: calc(100% - 175px);
+		padding-top: 30rpx;
+	}
 
-			.attr-box {
-				display: flex;
-				justify-content: flex-end;
-				font-size: $font-sm + 2rpx;
-				color: $font-color-light;
-			}
+	.order-item {
+		display: flex;
+		flex-direction: column;
+		border-radius: 20rpx;
+		background: #fff;
+		margin: 0rpx 30rpx 30rpx 30rpx;
 
-			.price {
-				display: inline;
-				font-size: $font-base + 2rpx;
-				color: $font-color-dark;
 
-				&:before {
-					content: '¥';
-					font-size: $font-sm;
-				}
-			}
-		}
-	}
-	.buy-box {
-		height: 84rpx;
-		padding: 0 22rpx;
-		background-color: #ffffff;
-		.buy-info {
-			height: 100%;
+		.i-top {
 			display: flex;
 			align-items: center;
-			.font {
-				font-size: 32rpx;
-				font-family: PingFang SC;
-				font-weight: 500;
-				color: #333333;
-			}
-			.avter {
-				margin-left: 10rpx;
-				width: 46rpx;
-				height: 46rpx;
-				border-radius: 50%;
-			}
-			.buy-name {
-				margin-left: 10rpx;
-				font-size: 32rpx;
-				font-family: PingFang SC;
-				font-weight: bold;
-				color: #333333;
+			height: 80rpx;
+			font-size: $font-base;
+			color: $font-color-dark;
+			position: relative;
+			padding: 0 30rpx;
+
+			.time {
+				flex: 1;
 			}
-			.phone {
-				margin-left: 12rpx;
-				font-size: 24rpx;
-				font-family: PingFang SC;
-				font-weight: 500;
-				color: #999999;
+
+			.state {
+				color: $base-color;
 			}
-		}
-	}
-	.upimg {
-		padding-left: 20rpx;
-		padding-top: 10rpx;
-		padding-bottom: 10rpx;
-		display: flex;
 
-		.up-tit {
-			display: inline-block;
-			font-size: 26rpx;
-			font-family: PingFang SC;
-			font-weight: 500;
-			color: #6d7c88;
 		}
 
-		.img-wrap {
-			width: 153rpx;
-			height: 152rpx;
-
-			border-radius: 20rpx;
+		/* 单条商品 */
+		.goods-box-single {
+			display: flex;
+			padding: 20rpx 30rpx;
 
-			image {
-				border-radius: 20rpx;
-				width: 153rpx;
-				height: 152rpx;
-				background-color: #ccc;
+			// background: #f7f7f7;
+			.goods-img {
+				display: block;
+				width: 120rpx;
+				height: 120rpx;
 			}
-		}
-	}
-	.price-box {
-		display: flex;
-		justify-content: flex-end;
-		align-items: baseline;
-		padding: 20rpx 30rpx;
-		font-size: $font-sm + 2rpx;
-		color: $font-color-light;
-
-		.num {
-			margin: 0 8rpx;
-			color: $font-color-dark;
-		}
 
-		.price {
-			font-size: $font-lg;
-			color: $font-color-dark;
+			.right {
+				flex: 1;
+				display: flex;
+				flex-direction: column;
+				padding: 0 0 0 24rpx;
+				overflow: hidden;
 
-			&:before {
-				content: '¥';
-				font-size: $font-sm;
-				margin: 0 2rpx 0 8rpx;
-			}
-		}
-	}
+				.row {
+					margin-top: 10rpx;
+				}
 
-	.action-box {
-		padding: 0 30rpx;
-		display: flex;
-		justify-content: flex-end;
-		align-items: center;
-		height: 100rpx;
-		position: relative;
-	}
 
-	.refuse {
-		margin: 0;
-		padding: 0;
-		width: 160rpx;
-		height: 60rpx;
-		border: 2rpx solid #ebebeb;
-		border-radius: 28rpx;
-		text-align: center;
-		line-height: 60rpx;
-		font-size: 26rpx;
-		font-family: PingFang SC;
-		font-weight: 500;
-		color: #999999;
-		&:after {
-			border-radius: 100px;
-		}
+				.title {
+					font-size: $font-base + 2rpx;
+					color: $font-color-dark;
+					line-height: 1;
+					width: 80%;
+				}
 
-		&.recom {
-			color: #999999;
+				.attr-box {
+					display: flex;
+					justify-content: flex-end;
+					font-size: $font-sm + 2rpx;
+					color: $font-color-light;
+				}
 
-			&:after {
-				border-color: #999999;
+				.price {
+					display: inline;
+					font-size: $font-base + 2rpx;
+					color: $font-color-dark;
+
+					&:before {
+						content: '¥';
+						font-size: $font-sm;
+					}
+				}
 			}
 		}
 	}
 
 	.action-btn {
-		width: 160rpx;
-		height: 60rpx;
-		margin: 0;
-		margin-left: 24rpx;
-		padding: 0;
+		position: fixed;
+		bottom: 0rpx;
+		left: 0rpx;
+		width: 750rpx;
 		text-align: center;
-		line-height: 60rpx;
-		font-size: $font-sm + 2rpx;
-		color: $font-color-dark;
+		font-size: $font-lg;
+		color:#E6C79D;
 		background: #fff;
-		border-radius: 100px;
-		border: 2rpx solid #fd3b39;
-		border-radius: 28px;
-		&:after {
-			border-radius: 100px;
-		}
-
-		&.recom {
-			color: $base-color;
-
-			&:after {
-				border-color: $base-color;
-			}
-		}
-
-		&.evaluate {
-			color: $color-yellow;
-
-			&:after {
-				border-color: $color-yellow;
-			}
-		}
+		border: 2rpx solid #E6C79D;
+		padding: 20rpx;
 	}
-}
-</style>
+</style>

+ 288 - 0
pages/user/yjchange.vue

@@ -0,0 +1,288 @@
+<template>
+	<view class="content">
+		<!-- <uni-notice-bar single="true" text="实际到账98%"></uni-notice-bar> -->
+		<view class="content-money">
+			<view class="flex " style="width: 750rpx;justify-content: space-around;margin-left: 0;">
+				<view class="buttom">
+					<view class="icon">{{ userInfo.brokerage_price | getMoneyStyle }}</view>
+					<text class="text">可转账奖金</text>
+				</view>
+			</view>
+		</view>
+
+		<view class="row-box margin-t-20">
+			<view class="title">转账奖金(¥)</view>
+			<view class="row">
+				<input class="input" type="number" v-model="withdrawal" placeholder="请输入转账奖金"
+					placeholder-class="placeholder" />
+				<view class="buttom" @click="withdrawal = userInfo.brokerage_price">全部转账</view>
+			</view>
+		</view>
+		<view class="row-box margin-t-20">
+			<view class="title">用户ID</view>
+			<view class="row">
+				<input class="input" type="number" v-model="uid" placeholder="请填写转账到的用户ID"
+					placeholder-class="placeholder" />
+			</view>
+		</view>
+		<button class="add-btn up" @click="confirm">提交申请</button>
+		<!-- <button class="add-btn modified" v-if="!weichatBsrowser" @click="navTo('/pages/money/account')">账号管理</button> -->
+	</view>
+</template>
+
+<script>
+	import {
+		getMoneyStyle
+	} from '@/utils/rocessor.js';
+	import {
+		trade
+	} from '@/api/new.js';
+	import {
+		getUserInfo
+	} from '@/api/user.js';
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	import uniNoticeBar from '@/components/uni-notice-bar/uni-notice-bar.vue';
+	export default {
+		filters: {
+			getMoneyStyle
+		},
+		components: {
+			uniNoticeBar
+		},
+		computed: {
+			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
+		},
+		data() {
+			return {
+				type: 'bank', //提现方式
+				money: '0.00', //可提现金额
+				freeze: '0.0', //冻结金额
+				withdrawal:'',
+				uid: '', //提现金额
+			};
+		},
+		onLoad(options) {},
+		methods: {
+			...mapMutations('user', ['setUserInfo']),
+			// 跳转
+			navTo(url) {
+				uni.navigateTo({
+					url: url
+				});
+			},
+			// 提交
+			confirm() {
+				let obj = this
+				let data = {
+					num: this.withdrawal, //金额
+					to_uid: this.uid //0佣金1余额
+				};
+				trade(data)
+					.then(e => {
+						getUserInfo({})
+							.then(({
+								data
+							}) => {
+								this.setUserInfo(data);
+							})
+							.catch(e => {
+								console.log(e);
+							});
+						uni.showToast({
+							title: '申请成功!',
+							duration: 2000,
+							position: 'top'
+						});
+					})
+					.catch(e => {
+						console.log();
+					});
+			}
+		}
+	};
+</script>
+
+<style lang="scss">
+	page {
+		height: 100%;
+	}
+
+	.content-money {
+		padding: 30rpx 0;
+		background: #ffffff;
+	}
+
+	.flex {
+		background-color: #ffffff;
+		text-align: center;
+		margin: 0 30rpx;
+		border-radius: $border-radius-sm;
+
+		.buttom {
+			font-size: $font-lg;
+			width: 50%;
+		}
+
+		.interval {
+			width: 2px;
+			height: 60rpx;
+			background-color: #eeeeee;
+		}
+
+		.icon {
+			background-size: 100%;
+			font-size: 42rpx;
+			color: $font-color-dark;
+			font-weight: bold;
+			background-repeat: no-repeat;
+			background-position: center;
+		}
+
+		.text {
+			color: $font-color-light;
+		}
+	}
+
+	.row-box {
+		padding: 20rpx 30rpx;
+		background: #fff;
+
+		.title {
+			font-size: $font-base + 2rpx;
+			color: $font-color-dark;
+		}
+
+		.row {
+			display: flex;
+			align-items: center;
+			position: relative;
+			height: 80rpx;
+
+			.tit {
+				flex-shrink: 0;
+				width: 40rpx;
+				font-size: 30rpx;
+				color: $font-color-dark;
+			}
+
+			.input {
+				flex: 1;
+				font-size: 30rpx;
+				color: $font-color-dark;
+			}
+
+			.iconlocation {
+				font-size: 36rpx;
+				color: $font-color-light;
+			}
+
+			.buttom {
+				font-size: $font-base;
+			}
+		}
+	}
+
+	.add-btn {
+		background: linear-gradient(-90deg, #FAC545, #FFE000);
+		border-radius: 10px;
+		width: 690rpx;
+		height: 80rpx;
+		margin: 0 auto;
+		margin-top: 30rpx;
+		font-size: $font-lg;
+		border-radius: 10rpx;
+		color: #6B4216;
+		
+		&.up {
+			background-color: $base-color;
+			color: #fff;
+		}
+	}
+
+	.list {
+		padding-left: 30rpx;
+		margin-top: 30rpx;
+		background-color: #ffffff;
+
+		.box {
+			display: flex;
+			align-items: center;
+			width: 100%;
+			height: 120rpx;
+			border-bottom: 1px solid $border-color-light;
+
+			.icon {
+				font-size: 48rpx;
+				padding-right: 20rpx;
+
+				.icon-img {
+					height: 50rpx;
+					width: 50rpx;
+				}
+			}
+
+			.iconweixin1 {
+				color: #18bf16;
+			}
+
+			.iconzhifubao {
+				color: #08aaec;
+			}
+
+			.title-box {
+				flex-grow: 1;
+				text-align: left;
+
+				.title {
+					font-size: $font-base + 2rpx;
+					color: $font-color-base;
+				}
+
+				.node {
+					font-size: $font-sm;
+					color: $font-color-light;
+				}
+			}
+		}
+	}
+
+	/deep/ .uni-radio-input {
+		width: 45rpx;
+		height: 45rpx;
+	}
+
+	.row {
+		display: flex;
+		align-items: center;
+		position: relative;
+		padding: 0 30upx;
+		height: 110upx;
+		background: #fff;
+
+		.tit {
+			flex-shrink: 0;
+			width: 250upx;
+			font-size: 30upx;
+			color: $font-color-dark;
+		}
+
+		.input {
+			flex: 1;
+			font-size: 30upx;
+			color: $font-color-dark;
+		}
+
+		.iconlocation {
+			font-size: 36upx;
+			color: $font-color-light;
+		}
+	}
+
+	.tip {
+		padding: 20rpx;
+		color: #FD3B39;
+	}
+</style>