2312970463@qq.com 3 年之前
父节点
当前提交
8ee205321a
共有 21 个文件被更改,包括 2194 次插入856 次删除
  1. 44 36
      api/index.js
  2. 16 3
      pages.json
  3. 370 370
      pages/money/pay.vue
  4. 113 65
      pages/money/paySuccess.vue
  5. 6 6
      pages/money/wallet.vue
  6. 114 5
      pages/order/createOrder.vue
  7. 0 178
      pages/order/orderDetail.vue
  8. 16 5
      pages/product/product.vue
  9. 381 180
      pages/user/extension.vue
  10. 791 0
      pages/user/refundAdmin.vue
  11. 11 3
      pages/user/scoreAccumulate.vue
  12. 5 4
      pages/user/user.vue
  13. 326 0
      pages/user/wipe.vue
  14. 二进制
      static/icon/close.png
  15. 二进制
      static/icon/sm.png
  16. 二进制
      static/icon/sr.png
  17. 二进制
      static/img/agreebg.png
  18. 二进制
      static/img/hxbg.png
  19. 二进制
      static/img/payok.png
  20. 二进制
      static/img/tgbg.png
  21. 1 1
      uni.scss

+ 44 - 36
api/index.js

@@ -1,36 +1,44 @@
-import request from '@/utils/request'
-
-// 促销商品
-export function groom4(data) {
-	return request({
-		url: '/api/groom/list/4',
-		method: 'get',
-		data
-	});
-}
-// 精品推荐
-export function groom1(data) {
-	return request({
-		url: '/api/groom/list/1',
-		method: 'get',
-		data
-	});
-}
-// 新品首发
-export function groom3(data) {
-	return request({
-		url: '/api/groom/list/3',
-		method: 'get',
-		data
-	});
-}
-
-// 获取首页信息
-export function loadIndexs(data) {
-	return request({
-		url: '/api/index',
-		method: 'get',
-		data
-	});
-}
-
+import request from '@/utils/request'
+
+// 促销商品
+export function groom4(data) {
+	return request({
+		url: '/api/groom/list/4',
+		method: 'get',
+		data
+	});
+}
+// 精品推荐
+export function groom1(data) {
+	return request({
+		url: '/api/groom/list/1',
+		method: 'get',
+		data
+	});
+}
+// 新品首发
+export function groom3(data) {
+	return request({
+		url: '/api/groom/list/3',
+		method: 'get',
+		data
+	});
+}
+
+// 获取首页信息
+export function loadIndexs(data) {
+	return request({
+		url: '/api/index',
+		method: 'get',
+		data
+	});
+}
+
+/**
+ * 获取主页数据 无需授权
+ * 
+*/
+export function getIndexData()
+{
+  return request.get("common/home",{},{ noAuth : true});
+}

+ 16 - 3
pages.json

@@ -359,7 +359,8 @@
 		{
 			"path": "pages/user/extension",
 			"style": {
-				"navigationBarTitleText": "我的推广"
+				"navigationBarTitleText": "我的推广",
+				"navigationStyle": "custom"
 			}
 		},
 		{
@@ -489,8 +490,20 @@
 			"path": "pages/order/choisestore",
 			"style": {
 				"navigationBarTitleText": "选择门店",
-				"navigationBarBackgroundColor":"#fff",
-				"navigationBarTextStyle":"black"
+				"navigationBarBackgroundColor": "#fff",
+				"navigationBarTextStyle": "black"
+			}
+		},
+		{
+			"path": "pages/user/refundAdmin",
+			"style": {
+				"navigationBarTitleText": "退款管理"
+			}
+		},
+		{
+			"path": "pages/user/wipe",
+			"style": {
+				"navigationBarTitleText": "自提管理"
 			}
 		}
 	],

+ 370 - 370
pages/money/pay.vue

@@ -1,370 +1,370 @@
-<template>
-	<view class="app">
-		<view class="price-box">
-			<text>支付金额</text>
-			<text class="price">{{ money }}</text>
-		</view>
-		<view class="pay-type-list">
-			<view class="type-item b-b" @click="changePayType(1)">
-				<text class="icon iconfont iconweixin"></text>
-				<view class="con">
-					<text class="tit">微信支付</text>
-					<text>推荐使用微信支付</text>
-				</view>
-				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 1"></radio></label>
-			</view>
-			<!-- #ifdef APP-PLUS -->
-			<view class="type-item b-b" @click="changePayType(2)">
-				<text class="icon iconfont iconzhifubao"></text>
-				<view class="con"><text class="tit">支付宝支付</text></view>
-				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 2"></radio></label>
-			</view>
-			<!-- #endif -->
-			<view class="type-item" @click="changePayType(3)">
-				<text class="icon iconfont iconyue"></text>
-				<view class="con">
-					<text class="tit">余额支付</text>
-					<text>可用余额 ¥{{ now_money }}</text>
-				</view>
-				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 3"></radio></label>
-			</view>
-		</view>
-		<text class="mix-btn" :class="{ clickbg: payLoding }" @click="!payLoding ? confirm() : ''">确认支付</text>
-	</view>
-</template>
-
-<script>
-import { balance } from '@/api/wallet.js';
-import { createOrderkey,computedOrderkey,orderPay } from '@/api/order.js';
-import { mapState } from 'vuex';
-export default {
-	data() {
-		return {
-			payType: 1, //支付类型
-			// #ifdef H5
-			payName: 'weixin',
-			// #endif
-			// #ifdef MP-WEIXIN
-			payName: 'weixin',
-			// #endif
-			orderInfo: {},
-			money: 0.0, //订单金额
-			now_money: 0.0, //余额
-			orderKey: '',
-			orderId: '', //保存订单id
-			payLoding: false, //判断是否支付中
-			type: '', //判断是否从订单中进入
-			// #ifdef H5
-			froms: '', //保存h5中数据来源对象
-			// #endif
-			pinkid: '' //保存拼团商品id
-		};
-	},
-	computed: {
-		// #ifdef H5
-		...mapState(['weichatObj'])
-		// #endif
-	},
-	onLoad(options) {
-		if (options.type == 1) {
-			this.type = 1;
-			this.orderId = options.ordid;
-			this.money = options.money;
-		} else {
-			this.orderKey = options.key;
-			let prepage = this.$api.prePage();
-			computedOrderkey({
-				orderkey: this.orderKey,
-				couponId: prepage.couponChecked.id, //优惠券编号
-				addressId: prepage.addressData.id, //地址编号
-				useIntegral: prepage.checkedPoints ? 1 : 0
-			}).then(({ data }) => {
-				// 获取支付金额
-				this.money = data.result.pay_price;
-			});
-		}
-		// 保存pinkid
-		if (options.pinkid) {
-			this.pinkid = options.pinkid;
-		}
-		// 载入余额
-		balance({}).then(({ data }) => {
-			// 获取余额
-			this.now_money = data.now_money;
-		});
-	},
-	methods: {
-		//选择支付方式
-		changePayType(type) {
-			this.payType = type;
-			if (this.payType == 1) {
-				this.payName = 'weixin';
-			}
-			if (this.payType == 2) {
-				this.payName = 'ali';
-			}
-			if (this.payType == 3) {
-				this.payName = 'yue';
-			}
-		},
-		// 支付金额
-		orderMoneyPay() {
-			let obj = this;
-			orderPay({
-				uni: obj.orderId,
-				// #ifdef H5
-				from: obj.froms ? 'weixin' : 'H5', //来源
-				// #endif
-				// #ifdef MP-WEIXIN
-				from: 'routine', //来源
-				// #endif
-				// #ifdef APP-PLUS
-				from: 'app', //来源
-				// #endif
-				paytype: obj.payName //支付类型  weixin-微信 yue-余额
-			})
-				.then(e => {
-					// 判断是否为余额支付
-					if (obj.payName == 'yue' && e.data.status == 'SUCCESS') {
-						if (e.status == 200) {
-							obj.paySuccessTo();
-						} else {
-							obj.$api.msg(msg);
-						}
-					}
-					if (obj.payName == 'weixin' || obj.payName == 'routine') {
-						let da = e.data.result.jsConfig;
-						let data = {
-							// #ifdef H5
-							timestamp: da.timestamp,
-							// #endif
-							// #ifdef MP
-							timeStamp: da.timestamp,
-							// #endif
-							nonceStr: da.nonceStr,
-							package: da.package,
-							signType: da.signType,
-							paySign: da.paySign,
-							success: function(res) {
-								obj.paySuccessTo();
-							},
-							fail: () => {
-								uni.navigateTo({
-									url: '/pages/order/order?state=0'
-								});
-							}
-						};
-						// #ifdef H5
-						if(obj.payName == 'weixin'){
-						obj.weichatObj.chooseWXPay(data);
-						}
-						// #endif
-						// #ifdef MP-WEIXIN
-						if(obj.payName == 'routine'){
-							wx.requestPayment(data);
-						}
-						// #endif
-					}
-					uni.hideLoading();
-					obj.payLoding = false;
-				})
-				.catch(e => {
-					// 支付完成
-					uni.hideLoading();
-					obj.payLoding = false;
-					console.log(e);
-				});
-		},
-		// 支付成功跳转
-		paySuccessTo() {
-			uni.hideLoading();
-			uni.redirectTo({
-				url: '/pages/money/paySuccess?orderid=' + this.orderId
-			});
-		},
-		//确认支付
-		confirm: async function() {
-			let obj = this;
-			uni.showLoading({
-				title: '支付中',
-				mask: true
-			})
-			// 判断是否余额不足
-			if (obj.payName == 'yue' && +obj.now_money < obj.money) {
-				uni.showModal({
-					title: '提示',
-					content: '账户余额不足!',
-					showCancel: false,
-					success: res => {},
-					fail: () => {},
-					complete: () => {}
-				});
-				return;
-			}
-			// 支付中
-			obj.payLoding = true;
-			// #ifdef H5
-			// 获取当前是否为微信浏览器
-			obj.froms = uni.getStorageSync('weichatBrowser') || '';
-			// #endif
-			// 判断是否为未支付订单中跳转进入
-			if (obj.type != 1) {
-				// 初次生成订单
-				obj.firstCreateOrder();
-			} else {
-				// 已经生成订单未支付
-				obj.orderMoneyPay();
-			}
-		},
-		// 初次订单创建
-		firstCreateOrder() {
-			let obj = this;
-			// 获取下单页面数据
-			let prepage = obj.$api.prePage();
-
-			let data = {
-				real_name: prepage.addressData.real_name, //联系人名称
-				phone: prepage.addressData.phone, //联系人号码
-				couponId: prepage.couponChecked.id, //优惠券编号
-				addressId: prepage.addressData.id, //支付地址id
-				useIntegral: prepage.checkedPoints ? 1 : 0, //是否积分抵扣1为是0为否
-				payType: obj.payName, //支付类型  weixin-微信 yue-余额
-				mark: prepage.desc, //备注
-				// #ifdef H5
-				from: obj.froms ? 'weixin' : 'H5', //来源
-				// #endif
-				// #ifdef MP-WEIXIN
-				from: 'routine', //来源
-				// #endif
-				// #ifdef APP-PLUS
-				from: 'app', //来源
-				// #endif
-				shipping_type: 1 //提货方式 1 快递 2自提
-			};
-			// 判断是否拼团商品
-			if (obj.pinkid) {
-				data.pinkId = obj.pinkid;
-			}
-			// 生成订单
-			createOrderkey(data, obj.orderKey)
-				.then(({ data, status, msg }) => {
-					// 判断是否支付失败
-					if (data.status == 'ORDER_EXIST') {
-						uni.showModal({
-							title: '提示',
-							content: msg,
-							showCancel: false
-						});
-						uni.hideLoading();
-						obj.payLoding = false;
-						return;
-					}
-					// 保存订单号
-					obj.orderId = data.result.orderId;
-					// 判断是否为余额支付
-					if (obj.payName == 'yue') {
-						if (status == 200 && data.status == 'SUCCESS') {
-							obj.paySuccessTo();
-						} else {
-							obj.$api.msg(msg);
-						}
-					} else {
-						// 立即支付
-						obj.orderMoneyPay();
-					}
-				})
-				.catch(e => {
-					uni.hideLoading();
-					obj.payLoding = false;
-					console.log(e);
-				});
-		}
-	}
-};
-</script>
-
-<style lang="scss">
-.app {
-	width: 100%;
-}
-
-.price-box {
-	background-color: #fff;
-	height: 265upx;
-	display: flex;
-	flex-direction: column;
-	justify-content: center;
-	align-items: center;
-	font-size: 28upx;
-	color: #909399;
-
-	.price {
-		font-size: 50upx;
-		color: #303133;
-		margin-top: 12upx;
-		&:before {
-			content: '¥';
-			font-size: 40upx;
-		}
-	}
-}
-
-.pay-type-list {
-	margin-top: 20upx;
-	background-color: #fff;
-	padding-left: 60upx;
-	.type-item {
-		height: 120upx;
-		padding: 20upx 0;
-		display: flex;
-		justify-content: space-between;
-		align-items: center;
-		padding-right: 60upx;
-		font-size: 30upx;
-		position: relative;
-	}
-
-	.icon {
-		width: 100upx;
-		font-size: 52upx;
-	}
-	.iconyue {
-		color: #fe8e2e;
-	}
-	.iconweixin {
-		color: #36cb59;
-	}
-	.iconzhifubao {
-		color: #01aaef;
-	}
-	.tit {
-		font-size: $font-lg;
-		color: $font-color-dark;
-		margin-bottom: 4upx;
-	}
-	.con {
-		flex: 1;
-		display: flex;
-		flex-direction: column;
-		font-size: $font-sm;
-		color: $font-color-light;
-	}
-}
-.mix-btn {
-	display: flex;
-	align-items: center;
-	justify-content: center;
-	width: 630upx;
-	height: 80upx;
-	margin: 80upx auto 30upx;
-	font-size: $font-lg;
-	color: #fff;
-	background-color: $base-color;
-	border-radius: 10upx;
-	/* box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4); */
-}
-
-.clickbg {
-	background-color: $color-gray !important;
-}
-</style>
+<template>
+	<view class="app">
+		<view class="price-box">
+			<text>支付金额</text>
+			<text class="price">{{ money }}</text>
+		</view>
+		<view class="pay-type-list">
+			<view class="type-item b-b" @click="changePayType(1)">
+				<text class="icon iconfont iconweixin"></text>
+				<view class="con">
+					<text class="tit">微信支付</text>
+					<text>推荐使用微信支付</text>
+				</view>
+				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 1"></radio></label>
+			</view>
+			<!-- #ifdef APP-PLUS -->
+			<view class="type-item b-b" @click="changePayType(2)">
+				<text class="icon iconfont iconzhifubao"></text>
+				<view class="con"><text class="tit">支付宝支付</text></view>
+				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 2"></radio></label>
+			</view>
+			<!-- #endif -->
+			<view class="type-item" @click="changePayType(3)">
+				<text class="icon iconfont iconyue"></text>
+				<view class="con">
+					<text class="tit">余额支付</text>
+					<text>可用余额 ¥{{ now_money }}</text>
+				</view>
+				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 3"></radio></label>
+			</view>
+		</view>
+		<text class="mix-btn" :class="{ clickbg: payLoding }" @click="!payLoding ? confirm() : ''">确认支付</text>
+	</view>
+</template>
+
+<script>
+import { balance } from '@/api/wallet.js';
+import { createOrderkey,computedOrderkey,orderPay } from '@/api/order.js';
+import { mapState } from 'vuex';
+export default {
+	data() {
+		return {
+			payType: 1, //支付类型
+			// #ifdef H5
+			payName: 'weixin',
+			// #endif
+			// #ifdef MP-WEIXIN
+			payName: 'weixin',
+			// #endif
+			orderInfo: {},
+			money: 0.0, //订单金额
+			now_money: 0.0, //余额
+			orderKey: '',
+			orderId: '', //保存订单id
+			payLoding: false, //判断是否支付中
+			type: '', //判断是否从订单中进入
+			// #ifdef H5
+			froms: '', //保存h5中数据来源对象
+			// #endif
+			pinkid: '' //保存拼团商品id
+		};
+	},
+	computed: {
+		// #ifdef H5
+		...mapState(['weichatObj'])
+		// #endif
+	},
+	onLoad(options) {
+		if (options.type == 1) {
+			this.type = 1;
+			this.orderId = options.ordid;
+			this.money = options.money;
+		} else {
+			this.orderKey = options.key;
+			let prepage = this.$api.prePage();
+			computedOrderkey({
+				orderkey: this.orderKey,
+				couponId: prepage.couponChecked.id, //优惠券编号
+				addressId: prepage.addressData.id, //地址编号
+				useIntegral: prepage.checkedPoints ? 1 : 0
+			}).then(({ data }) => {
+				// 获取支付金额
+				this.money = data.result.pay_price;
+			});
+		}
+		// 保存pinkid
+		if (options.pinkid) {
+			this.pinkid = options.pinkid;
+		}
+		// 载入余额
+		balance({}).then(({ data }) => {
+			// 获取余额
+			this.now_money = data.now_money;
+		});
+	},
+	methods: {
+		//选择支付方式
+		changePayType(type) {
+			this.payType = type;
+			if (this.payType == 1) {
+				this.payName = 'weixin';
+			}
+			if (this.payType == 2) {
+				this.payName = 'ali';
+			}
+			if (this.payType == 3) {
+				this.payName = 'yue';
+			}
+		},
+		// 支付金额
+		orderMoneyPay() {
+			let obj = this;
+			orderPay({
+				uni: obj.orderId,
+				// #ifdef H5
+				from: obj.froms ? 'weixin' : 'H5', //来源
+				// #endif
+				// #ifdef MP-WEIXIN
+				from: 'routine', //来源
+				// #endif
+				// #ifdef APP-PLUS
+				from: 'app', //来源
+				// #endif
+				paytype: obj.payName //支付类型  weixin-微信 yue-余额
+			})
+				.then(e => {
+					// 判断是否为余额支付
+					if (obj.payName == 'yue' && e.data.status == 'SUCCESS') {
+						if (e.status == 200) {
+							obj.paySuccessTo();
+						} else {
+							obj.$api.msg(msg);
+						}
+					}
+					if (obj.payName == 'weixin' || obj.payName == 'routine') {
+						let da = e.data.result.jsConfig;
+						let data = {
+							// #ifdef H5
+							timestamp: da.timestamp,
+							// #endif
+							// #ifdef MP
+							timeStamp: da.timestamp,
+							// #endif
+							nonceStr: da.nonceStr,
+							package: da.package,
+							signType: da.signType,
+							paySign: da.paySign,
+							success: function(res) {
+								obj.paySuccessTo();
+							},
+							fail: () => {
+								uni.navigateTo({
+									url: '/pages/order/order?state=0'
+								});
+							}
+						};
+						// #ifdef H5
+						if(obj.payName == 'weixin'){
+						obj.weichatObj.chooseWXPay(data);
+						}
+						// #endif
+						// #ifdef MP-WEIXIN
+						if(obj.payName == 'routine'){
+							wx.requestPayment(data);
+						}
+						// #endif
+					}
+					uni.hideLoading();
+					obj.payLoding = false;
+				})
+				.catch(e => {
+					// 支付完成
+					uni.hideLoading();
+					obj.payLoding = false;
+					console.log(e);
+				});
+		},
+		// 支付成功跳转
+		paySuccessTo() {
+			uni.hideLoading();
+			uni.redirectTo({
+				url: '/pages/money/paySuccess?orderid=' + this.orderId  +"&mun=" + this.money
+			});
+		},
+		//确认支付
+		confirm: async function() {
+			let obj = this;
+			uni.showLoading({
+				title: '支付中',
+				mask: true
+			})
+			// 判断是否余额不足
+			if (obj.payName == 'yue' && +obj.now_money < obj.money) {
+				uni.showModal({
+					title: '提示',
+					content: '账户余额不足!',
+					showCancel: false,
+					success: res => {},
+					fail: () => {},
+					complete: () => {}
+				});
+				return;
+			}
+			// 支付中
+			obj.payLoding = true;
+			// #ifdef H5
+			// 获取当前是否为微信浏览器
+			obj.froms = uni.getStorageSync('weichatBrowser') || '';
+			// #endif
+			// 判断是否为未支付订单中跳转进入
+			if (obj.type != 1) {
+				// 初次生成订单
+				obj.firstCreateOrder();
+			} else {
+				// 已经生成订单未支付
+				obj.orderMoneyPay();
+			}
+		},
+		// 初次订单创建
+		firstCreateOrder() {
+			let obj = this;
+			// 获取下单页面数据
+			let prepage = obj.$api.prePage();
+
+			let data = {
+				real_name: prepage.addressData.real_name, //联系人名称
+				phone: prepage.addressData.phone, //联系人号码
+				couponId: prepage.couponChecked.id, //优惠券编号
+				addressId: prepage.addressData.id, //支付地址id
+				useIntegral: prepage.checkedPoints ? 1 : 0, //是否积分抵扣1为是0为否
+				payType: obj.payName, //支付类型  weixin-微信 yue-余额
+				mark: prepage.desc, //备注
+				// #ifdef H5
+				from: obj.froms ? 'weixin' : 'H5', //来源
+				// #endif
+				// #ifdef MP-WEIXIN
+				from: 'routine', //来源
+				// #endif
+				// #ifdef APP-PLUS
+				from: 'app', //来源
+				// #endif
+				shipping_type: 1 //提货方式 1 快递 2自提
+			};
+			// 判断是否拼团商品
+			if (obj.pinkid) {
+				data.pinkId = obj.pinkid;
+			}
+			// 生成订单
+			createOrderkey(data, obj.orderKey)
+				.then(({ data, status, msg }) => {
+					// 判断是否支付失败
+					if (data.status == 'ORDER_EXIST') {
+						uni.showModal({
+							title: '提示',
+							content: msg,
+							showCancel: false
+						});
+						uni.hideLoading();
+						obj.payLoding = false;
+						return;
+					}
+					// 保存订单号
+					obj.orderId = data.result.orderId;
+					// 判断是否为余额支付
+					if (obj.payName == 'yue') {
+						if (status == 200 && data.status == 'SUCCESS') {
+							obj.paySuccessTo();
+						} else {
+							obj.$api.msg(msg);
+						}
+					} else {
+						// 立即支付
+						obj.orderMoneyPay();
+					}
+				})
+				.catch(e => {
+					uni.hideLoading();
+					obj.payLoding = false;
+					console.log(e);
+				});
+		}
+	}
+};
+</script>
+
+<style lang="scss">
+.app {
+	width: 100%;
+}
+
+.price-box {
+	background-color: #fff;
+	height: 265upx;
+	display: flex;
+	flex-direction: column;
+	justify-content: center;
+	align-items: center;
+	font-size: 28upx;
+	color: #909399;
+
+	.price {
+		font-size: 50upx;
+		color: #303133;
+		margin-top: 12upx;
+		&:before {
+			content: '¥';
+			font-size: 40upx;
+		}
+	}
+}
+
+.pay-type-list {
+	margin-top: 20upx;
+	background-color: #fff;
+	padding-left: 60upx;
+	.type-item {
+		height: 120upx;
+		padding: 20upx 0;
+		display: flex;
+		justify-content: space-between;
+		align-items: center;
+		padding-right: 60upx;
+		font-size: 30upx;
+		position: relative;
+	}
+
+	.icon {
+		width: 100upx;
+		font-size: 52upx;
+	}
+	.iconyue {
+		color: #fe8e2e;
+	}
+	.iconweixin {
+		color: #36cb59;
+	}
+	.iconzhifubao {
+		color: #01aaef;
+	}
+	.tit {
+		font-size: $font-lg;
+		color: $font-color-dark;
+		margin-bottom: 4upx;
+	}
+	.con {
+		flex: 1;
+		display: flex;
+		flex-direction: column;
+		font-size: $font-sm;
+		color: $font-color-light;
+	}
+}
+.mix-btn {
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	width: 630upx;
+	height: 80upx;
+	margin: 80upx auto 30upx;
+	font-size: $font-lg;
+	color: #fff;
+	background-color: $base-color;
+	border-radius: 10upx;
+	/* box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4); */
+}
+
+.clickbg {
+	background-color: $color-gray !important;
+}
+</style>

+ 113 - 65
pages/money/paySuccess.vue

@@ -1,65 +1,113 @@
-<template>
-	<view class="content">
-		<text class="success-icon iconfont iconroundcheck"></text>
-		<text class="tit">支付成功</text>
-		<view class="btn-group">
-			<navigator :url="'/pages/order/orderDetail?id='+orderId" open-type="redirect" class="mix-btn">查看订单</navigator>
-			<navigator url="/pages/index/index" open-type="switchTab" class="mix-btn hollow">返回首页</navigator>
-		</view>
-	</view>
-</template>
-
-<script>
-	export default {
-		data() {
-			return {
-				orderId:''
-			}
-		},
-		onLoad(opt) {
-			// 保存订单号
-			this.orderId = opt.orderid;
-		},
-		methods: {
-			
-		}
-	}
-</script>
-
-<style lang='scss'>
-	.content{
-		display: flex;
-		flex-direction: column;
-		justify-content: center;
-		align-items: center;
-	}
-	.success-icon{
-		font-size: 160upx;
-		color: #5dbc7c;
-		margin-top: 100upx;
-	}
-	.tit{
-		font-size: 38upx;
-		color: #303133;
-	}
-	.btn-group{
-		padding-top: 100upx;
-	}
-	.mix-btn {
-		margin-top: 30upx;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		width: 600upx;
-		height: 80upx;
-		font-size: $font-lg;
-		color: #fff;
-		background-color: $base-color;
-		border-radius: 10upx;
-		&.hollow{
-			background: #fff;
-			color: #303133;
-			border: 1px solid #ccc;
-		}
-	}
-</style>
+<template>
+	<view class="content">
+		<!-- <text class="success-icon iconfont iconroundcheck"></text> -->
+		<image src="../../static/img/payok.png" mode="" class="okimg"></image>
+		<text class="tit">订单支付成功: <text>¥{{ money }}</text></text>
+<!-- 		<view class="btn-group">
+			<navigator :url="'/pages/order/orderDetail?id='+orderId" open-type="redirect" class="mix-btn">查看订单</navigator>
+			<navigator url="/pages/index/index" open-type="switchTab" class="mix-btn hollow">返回首页</navigator>
+		</view> -->
+		<view class="btn-wrapper">
+			<navigator :url="'/pages/order/orderDetail?id='+orderId" open-type="redirect" class="look-btn">查看订单</navigator>
+			<navigator url="/pages/index/index" open-type="switchTab" class="bank">返回首页</navigator>
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				orderId:'',
+				money: ''
+			}
+		},
+		onLoad(opt) {
+			// 保存订单号
+			this.orderId = opt.orderid;
+			// 保存金额
+			this.money = opt.mun
+		},
+		methods: {
+			
+		}
+	}
+</script>
+
+<style lang='scss'>
+	.content{
+		display: flex;
+		flex-direction: column;
+		justify-content: center;
+		align-items: center;
+	}
+	.success-icon{
+		font-size: 160upx;
+		color: #5dbc7c;
+		margin-top: 100upx;
+	}
+	.tit{
+		padding-top: 40rpx;
+		padding-bottom: 130rpx;
+		font-size: 32rpx;
+		color: #303133;
+		font-size: 32rpx;
+		font-weight: bold;
+		color: #333333;
+		line-height: 1;
+		text {
+			font-size: 36rpx;
+			font-weight: bold;
+			color: #333333;
+			line-height: 1;
+		}
+	}
+	.btn-group{
+		padding-top: 100upx;
+	}
+	.mix-btn {
+		margin-top: 30upx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		width: 600upx;
+		height: 80upx;
+		font-size: $font-lg;
+		color: #fff;
+		background-color: $base-color;
+		border-radius: 10upx;
+		&.hollow{
+			background: #fff;
+			color: #303133;
+			border: 1px solid #ccc;
+		}
+	}
+	.okimg {
+		margin-top: 100rpx;
+		width: 302rpx;
+		height: 302rpx;
+	}
+	.btn-wrapper {
+		display: flex;
+		.look-btn {
+			width: 301rpx;
+			height: 78rpx;
+			background: #901b21;
+			text-align: center;
+			line-height: 78rpx;
+			border-radius: 10rpx;
+			color: #fff;
+			margin-right: 37rpx;
+		}
+		.bank {
+			width: 301rpx;
+			height: 78rpx;
+			text-align: center;
+			line-height: 78rpx;
+			background: #FFFFFF;
+			border: 2px solid #901B21;
+			border-radius: 10rpx;
+			color: #901b21;
+		}
+	}
+</style>

+ 6 - 6
pages/money/wallet.vue

@@ -97,7 +97,7 @@ export default {
 				},
 				{
 					state: 1,
-					text: '收入',
+					text: '支出',
 					loadingType: 'more',
 					orderList: [
 						// { title: 'hello word', add_time: '2021-02-03', pm: 0, number: 99},
@@ -109,7 +109,7 @@ export default {
 				},
 				{
 					state: 2,
-					text: '支出',
+					text: '收入',
 					loadingType: 'more',
 					orderList: [],
 					page: 1, //当前页数
@@ -121,11 +121,11 @@ export default {
 	},
 	onLoad(options) {},
 	onShow() {
-		// this.loadData();
+		this.loadData();
 		// 获取用户余额
-		// userBalance({}).then(({ data }) => {
-		// 	this.money = data.now_money;
-		// });
+		userBalance({}).then(({ data }) => {
+			this.money = data.now_money;
+		});
 	},
 	methods: {
 		// 页面跳转

+ 114 - 5
pages/order/createOrder.vue

@@ -32,7 +32,7 @@
 
 			<image class="a-bg" :src="addressImg"></image>
 		</navigator>
-		<navigator v-if="tabCurrentIndex == 1" url="/pages/address/shopList" class="address-section">
+		<!-- <navigator v-if="tabCurrentIndex == 1" url="/pages/address/shopList" class="address-section">
 			<view class="order-content" v-if="shopAddress.name">
 				<text class="iconfont iconlocation"></text>
 				<view class="cen">
@@ -52,7 +52,50 @@
 			</view>
 
 			<image class="a-bg" :src="addressImg"></image>
-		</navigator>
+		</navigator> -->
+<!-- 		<view class="qzsj" @click="sjshow = true">
+		{{bzsj || '请选择收货时间'}}	
+		</view> -->
+		<view class="list" v-if="isshop && tabCurrentIndex == 1" @click.stop="selectStore">
+			<view class="list-left">
+				<view class="left-1">
+					<view class="flex-start">
+						<view class="img-box">
+							<image :src="list.image" mode="" class="ava-img"></image>
+						</view>
+						<text class="left-name">{{ list.name }}</text>
+					</view>
+					<view class="right-1">门店</view>
+				</view>
+				<view class="left-2">地址 :{{ list.detailed_address }}</view>
+				<view class="flex1">
+					<view class="left-2">电话 : {{ list.phone }}</view>
+					<view class="left-2">距离 : {{ list.range }} kM</view>
+				</view>
+			</view>
+		</view>
+		<view id="list-box">
+			<view class="chose" v-if="!isshop &&tabCurrentIndex == 1" @click.stop="selectStore">
+				<view class="title">选择门店</view>
+				<view class="chose-name">
+					请选择下单门店
+					<view class="img">
+						<image src="https://bamboo.zfhzy.com/static/img/img39.png" mode=""></image>
+					</view>
+				</view>
+			</view>
+			<view class="personal" v-if="tabCurrentIndex == 1">
+				<view class="info">
+					<view class="name">提货人</view>
+					<input type="text" class="box-right" v-model="addressData.real_name" style="color: #000000" placeholder="请填写提货人" />
+				</view>
+				<view class="info">
+					<view class="name">手机号</view>
+					<input type="text" class="box-right" v-model="addressData.phone" style="color: #000000" size="8" maxlength="11"
+					 placeholder="请填写收货人手机号" />
+				</view>
+			</view>
+		</view>
 
 		<view class="goods-section" v-for="(ls, ind) in shopList" :key="ind">
 			<!-- <view class="g-header b-b">
@@ -206,7 +249,7 @@ export default {
 			],
 			maskState: 0, //优惠券面板显示状态
 			desc: '', //备注
-			payType: 1, //1微信 2支付宝
+			// payType: 1, //1微信 2支付宝
 			// 优惠券列表
 			couponList: [],
 			couponListshow: false, //是有可以显示优惠券列表
@@ -240,7 +283,8 @@ export default {
 			integralMoney: 0, //积分抵扣金额
 			integralShow: false, //是否显示积分抵扣金额
 			payType: true, //是否可支付
-			pinkid: '' //保存拼团商品id
+			pinkid: '', //保存拼团商品id
+			isshop:false
 		};
 	},
 	onLoad(option) {
@@ -900,5 +944,70 @@ page {
 		justify-content: space-between;
 		line-height: 36rpx;
 	}
-}
+}
+#list-box {
+		.chose {
+			margin-top: 25rpx;
+			background-color: #ffffff;
+			display: flex;
+			justify-content: space-between;
+			padding: 32rpx 24rpx;
+			font-size: 30rpx;
+
+			.title {
+				color: #333;
+			}
+
+			.chose-name {
+				display: flex;
+				align-items: center;
+				color: #fc4141;
+
+				.img {
+					width: 30rpx;
+					height: 24rpx;
+
+					image {
+						width: 30rpx;
+						height: 24rpx;
+						display: inline;
+					}
+				}
+			}
+		}
+
+		.personal {
+			margin-top: 15rpx;
+			display: flex;
+			flex-direction: column;
+			background-color: #ffffff;
+
+			.box-right {
+				width: 100%;
+				font-size: 30rpx;
+				text-align: right;
+				padding-right: 25rpx;
+			}
+
+			.info {
+				padding: 10rpx 25rpx;
+				display: flex;
+				align-items: center;
+				font-size: 30rpx;
+				justify-content: space-between;
+
+				.name {
+					width: 120rpx;
+				}
+
+				input {
+					margin-left: 12rpx;
+					width: 100%;
+					// background-color: pink;
+					display: block;
+					color: #999999;
+				}
+			}
+		}
+	}
 </style>

文件差异内容过多而无法显示
+ 0 - 178
pages/order/orderDetail.vue


+ 16 - 5
pages/product/product.vue

@@ -22,8 +22,8 @@
 			</view>
 		</view>
 		<!-- 标题 -->
-		<!-- <product-content :goodsObjact="goodsObjact" ></product-content> -->
-		<view class="good-title clamp2"  v-if="isSckill">{{goodsObjact.store_name}}</view>
+		<product-content :goodsObjact="goodsObjact" v-if="!isSckill"></product-content>
+		<view class="good-title clamp2"  v-if="isSckill">{{goodsObjact.title}}</view>
 		<!-- 选择数量 -->
 <!-- 		<view class="row b-b">
 			<text class="tit">选择</text>
@@ -307,6 +307,7 @@ export default {
 				obj.actionImage = obj.productValue[str].image;
 				obj.uniqueId = obj.productValue[str].unique;
 				obj.goodsStore = obj.productValue[str].stock;
+				console.log(obj.uniqueId,'++++++++obj.uniqueId')
 			} else {
 				(obj.buys_show = false), (obj.buys_shows = true);
 			}
@@ -357,8 +358,10 @@ export default {
 		//加入购物车
 		Addcar(item) {
 			let obj = this;
+			console.log("加入购物车",obj.goodsNumber)
 			cartAdd({
-				cartNum: '1', //商品数量
+				// cartNum: '1', //商品数量
+				cartNum: obj.goodsNumber,
 				uniqueId: '', //商品标签
 				new: 0, //商品是否新增加到购物车1为不加入0为加入
 				mer_id: '',
@@ -388,7 +391,7 @@ export default {
 				obj.reply = data.reply; //保存评论列表
 				let goods = data.storeInfo;
 				obj.goodsObjact = goods;
-				console.log(obj.goodsObjact)
+				console.log(obj.goodsObjact,"++++++++++++++")
 				if (obj.goodsObjact.description != null) {
 					obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
 				} //小程序商品详情图超出屏幕问题
@@ -445,6 +448,7 @@ export default {
 					obj.many = 2;
 					obj.specList = data.productAttr; //保存产品属性
 					obj.productValue = data.productValue; //保存属性值
+					console.log(obj.productValue,'obj.productValue++++++++')
 					obj.specSelected = []; //初始化默认选择对象
 					for (let i = 0; i < obj.specList.length; i++) {
 						// 设置默认数据
@@ -459,6 +463,7 @@ export default {
 					obj.goodsNumberMax = obj.productValue[str].stock;
 					obj.actionImage = obj.productValue[str].image;
 					obj.uniqueId = obj.productValue[str].unique;
+					console.log(obj.uniqueId,"obj.uniqueId+++默认")
 					obj.goodsStore = obj.productValue[str].quota;
 				} else {
 					obj.many = 1;
@@ -475,10 +480,15 @@ export default {
 		buy() {
 			let obj = this;
 			// 创建传值对象
+			let goodId = obj.goodsid
+			if(obj.isSckill) {
+				goodId = obj.product_id
+			}
+			console.log("添加的数量",obj.goodsNumber)
 			let data = {
 					cartNum: obj.goodsNumber, //商品数量
 					new: 1,
-					productId: obj.goodsid,//商品编号
+					productId: goodId,//商品编号
 					uniqueId:obj.uniqueId
 				};
 			
@@ -518,6 +528,7 @@ export default {
 		numberChange(e) {
 			//购买数量
 			this.chooseGoodsNumber = e.number;
+			this.goodsNumber = e.number
 		},
 		// getTime() {
 		// 	let start = new data()

+ 381 - 180
pages/user/extension.vue

@@ -1,180 +1,381 @@
-<template>
-	<view class="extension-wrapper">
-		<view class="top-wrapper">{{allNum||0.00}}<text> 人</text></view>
-		<view class="middle">
-			<view class="middle-left" @click="changeAction">
-				<view class="middle-num">9</view>
-				<view class="middle-title" :class="{'action': isAction}">一级推广</view>
-			</view>
-			<view class="middle-center">
-				
-			</view>
-			<view class="middle-right" @click="changeAction">
-				<view class="middle-num">55</view>
-				<view class="middle-title" :class="{'action': !isAction}">二级推广</view>
-			</view>
-		</view>
-		<scroll-view scroll-y="true" @scrolltolower="loadData" class="list-scroll-content">
-			<view class="list">
-				<view class="list-item">
-					<view class="item-left"><image src="../../static/error/missing-face.png" mode=""></image></view>
-					<view class="item-right">
-						<view class="item-name">假猪套天下第一</view>
-						<view class="item-time">2020-12-3 12:30:00</view>
-					</view>
-				</view>
-			</view>
-		</scroll-view>
-	</view>
-</template>
-
-<script>
-	import {getExtensionData} from '@/api/user.js'
-	export default {
-		data() {
-			return {
-				allNum: 0,//总推广人数
-				isAction: true
-			}
-		},
-		onShow() {
-			this.getInfo()
-		},
-		methods: {
-			getInfo() {
-				console.log('hello world')
-			},
-			changeAction() {
-				this.isAction = !this.isAction
-			},
-			loadData() {
-				console.log('ddddd')
-			}
-		}
-	}
-</script>
-
-<style lang="scss" scoped>
-	page {
-		background-color: #f8f8f8;
-		height: 100%;
-	}
-	.extension-wrapper {
-		// position: relative;
-		background-color: #f8f8f8;
-		height: 100%;
-		.top-wrapper {
-			width: 750rpx;
-			height: 265rpx;
-			background-image: url(../../static/img/wallertbg.png);
-			background-size: 100%;
-			background-position: bottom;
-			// font-size: ;
-			color: #FFFFFF;
-			font-size: 72rpx;
-			font-family: PingFang SC;
-			font-weight: bold;
-			color: #FFFFFF;
-			line-height: 265rpx;
-			text-align: center;
-			text {
-				font-size: 40rpx;
-			}
-		}
-		.middle {
-			width: 702rpx;
-			height: 120rpx;
-			background: #FFFFFF;
-			box-shadow: 0px 0px 20px 0px rgba(50, 50, 52, 0.06);
-			border-radius: 10rpx;
-			background-color: #fff;
-			display: flex;
-			position: relative;
-			left: 24rpx;
-			top: -60rpx;
-			margin-bottom: -40rpx;
-			.middle-center {
-				width: 2px;
-				height: 54rpx;
-				background: #EEEEEE;
-				position: absolute;
-				right: 0;
-				left: 0;
-				top: 0;
-				bottom: 0;
-				margin: auto;
-			}
-			.middle-left, .middle-right {
-				padding-top: 24rpx;
-				width: 50%;
-				height: 120rpx;
-				text-align: center;
-				line-height: 1;
-				// display: flex;
-				.middle-num {
-					font-size: 32rpx;
-					font-family: PingFang SC;
-					font-weight: bold;
-					color: #901B21;
-					padding-bottom: 17rpx;
-				}
-				.middle-title {
-					font-size: 28rpx;
-					font-family: PingFang SC;
-					font-weight: 500;
-					color: #666666;
-					display: inline-block;
-					padding-bottom: 15rpx;
-				}
-				.action {
-					border-bottom: 5rpx #901B21 solid;
-					
-				}
-			}
-		}
-		.list-scroll-content {
-			height: 100%;
-			background-color: #fff;
-			.list {
-				width: 100%;
-				// height: 20rpx;
-				background-color: #fff;
-				.list-item {
-					padding: 30rpx 0 19rpx 23rpx;
-					height: 129rpx;
-					display: flex;
-					.item-left {
-						width: 80rpx;
-						height: 80rpx;
-						border-radius: 50%;
-						background-color: #bfa;
-						image {
-							width: 100%;
-							height: 100%;
-						}
-					}
-					.item-right {
-						padding-left: 20rpx;
-						padding-top: 9rpx;
-						.item-name {
-							font-size: 30rpx;
-							line-height: 1;
-							font-family: PingFangSC;
-							font-weight: 500;
-							color: #3F454B;
-							padding-bottom: 10rpx;
-						}
-						.item-time {
-							font-size: 22rpx;
-							line-height: 1;
-							font-family: PingFang SC;
-							font-weight: 400;
-							color: #999999;
-						}
-					}
-				}
-			}
-		}
-		
-	}
-</style>
+ <template>
+ 	<view class="content">
+ 		<view class="content-money">
+ 			<view class="money-box">
+ 				<view class="goback-box" @click="toBack">
+ 					<image class="goback" src="https://37shop.liuniu946.com/front/img/fanhui.png" mode=""></image>
+ 				</view>
+ 				<view class="header">我的推广</view>
+ 				<image class="tuiguang_bg" src="../../static/img/tgbg.png"></image>
+ 			 <!--  <view class="money_img"><image :src="list.avatar || img"></image></view> -->
+ 			 <view class="money-frame">
+ 				 <!-- <view class="money_name">我的推广</view> -->
+ 				 <view class="money_num">
+ 					{{all || '0'}}
+ 					<text class="money_ren">人</text>
+ 				</view>
+ 			 </view>
+ 			</view>
+ 			<view class="flex buttom-box">
+ 				<view class="buttom"  @click="tabClick(0)">
+ 					<view class="money">{{total || 0}}</view>
+ 					<text class="text" :class="{ current: tabCurrentIndex === 0 }">一级推广</text>
+ 				</view>
+ 				<view class="buttom"  @click="tabClick(1)">
+ 					<view class="money">{{totalLevel || 0}}</view>
+ 					<text class="text" :class="{ current: tabCurrentIndex === 1 }">二级推广</text>
+ 				</view>
+ 			</view>
+ 		</view>
+ 		<swiper :current="tabCurrentIndex" :style="{ height: maxheight + 'px' }" class="swiper-box" duration="300" @change="changeTab">
+ 			<swiper-item class="tab-content" v-for="(tabItem, tabIndex) in navList" :key="tabIndex">
+ 				<scroll-view class="list-scroll-content" scroll-y @scrolltolower="loadData">
+ 					<!-- 空白页 -->
+ 					<empty v-if="tabItem.loaded === true && tabItem.orderList.length === 0"></empty>
+ 
+ 					<!-- 订单列表 -->
+ 					<view v-for="(item, index) in tabItem.orderList" :key="index" class="order-item flex">
+ 						<view class="title-box flex_item">
+ 							<view class="title-avatar"><image :src="item.avatar"></image></view>
+ 							<view class="list_tpl">
+ 								<view class="title">
+ 									<text>{{ item.nickname }}</text>
+ 								</view>
+ 								<view class="time">
+ 									<text>{{ item.time }}</text>
+ 								</view>
+ 							</view>
+ 						</view>
+ 					</view>
+ 					<uni-load-more :status="tabItem.loadingType"></uni-load-more>
+ 				</scroll-view>
+ 			</swiper-item>
+ 		</swiper>
+ 	</view>
+ </template>
+ <script>
+ import { getExtensionData } from '@/api/user.js';
+ import { mapState, mapMutations } from 'vuex';
+ import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+ import empty from '@/components/empty';
+ export default {
+ 	components: {
+ 		empty,
+ 		uniLoadMore,
+ 	},
+ 	onReady() {
+ 		// 初始化获取页面宽度
+ 		uni.createSelectorQuery()
+ 			.select('.content')
+ 			.fields(
+ 				{
+ 					size: true
+ 				},
+ 				data => {
+ 					// console.log(data);
+ 					// console.log(Math.floor((data.width / 750) * 300));
+ 					// 保存头部高度
+ 					this.maxheight = data.height - Math.floor((data.width / 750) * 470) - 44;
+ 					// console.log(this.maxheight);
+ 				}
+ 			)
+ 			.exec();
+ 	},
+ 	data() {
+ 		return {
+ 			// 头部图高度
+ 			maxheight: '',
+ 			tabCurrentIndex: 0,
+ 			navList: [
+ 				{
+ 					state: 0,
+ 					text: '一级推广',
+ 					loadingType: 'more',
+ 					orderList: [],
+ 					page: 1, //当前页数
+ 					limit: 10 //每次信息条数
+ 				},
+ 				{
+ 					state: 1,
+ 					text: '二级推广',
+ 					loadingType: 'more',
+ 					orderList: [],
+ 					page: 1, //当前页数
+ 					limit: 10 //每次信息条数
+ 				}
+ 			],
+ 			all:'',
+ 			list:'',
+ 			total:'',
+ 			totalLevel:'',
+ 			img:'http://kaifa.crmeb.net/uploads/attach/2019/08/20190807/723adbdd4e49a0f9394dfc700ab5dba3.png'
+ 		};
+ 	},
+ 	onLoad(options) {},
+ 	onShow() {
+ 		this.loadData();	
+ 	},
+ 	methods: {
+ 		// 页面跳转
+ 		navto(e) {
+ 			uni.navigateTo({
+ 				url: e
+ 			});
+ 		},
+ 		//获取推广人数信息
+ 		async loadData(source) {
+ 			//这里是将订单挂载到tab列表下
+ 			let index = this.tabCurrentIndex;
+ 			let navItem = this.navList[index];
+ 			let state = navItem.state;
+ 			if (source === 'tabChange' && navItem.loaded === true) {
+ 				//tab切换只有第一次需要加载数据
+ 				return;
+ 			}
+ 			if (navItem.loadingType === 'loading') {
+ 				//防止重复加载
+ 				return;
+ 			}
+ 			if (navItem.loadingType === 'noMore') {
+ 				//防止重复加载
+ 				return;
+ 			}
+ 			// 修改当前对象状态为加载中
+ 			navItem.loadingType = 'loading';
+ 			getExtensionData(
+ 				{
+ 					page: navItem.page,
+ 					limit: navItem.limit,
+ 					keyword:'',
+ 					sort:'uid desc',
+ 					grade:state
+ 				},
+ 			)
+ 				.then(({ data }) => {
+ 					console.log(data);
+ 					
+ 					this.total = data.total;
+ 					this.totalLevel =data.totalLevel;
+ 					this.all = this.total + this.totalLevel;
+ 					if (data.list.length > 0) {
+ 						this.list = data.list;
+ 						navItem.orderList = navItem.orderList.concat(data.list);
+ 						navItem.page++;
+ 					}
+ 					this.$nextTick(function(){
+ 						if (navItem.limit == data.list.length) {
+ 							//判断是否还有数据, 有改为 more, 没有改为noMore
+ 							navItem.loadingType = 'more';
+ 							return;
+ 						} else {
+ 							//判断是否还有数据, 有改为 more, 没有改为noMore
+ 							navItem.loadingType = 'noMore';
+ 						}
+ 					})
+ 					this.$set(navItem, 'loaded', true);
+ 				})
+ 				.catch(e => {
+ 					console.log(e);
+ 				});
+ 		},
+ 		//swiper 切换
+ 		changeTab(e) {
+ 			this.tabCurrentIndex = e.target.current;
+ 			this.loadData('tabChange');
+ 		},
+ 		//顶部tab点击
+ 		tabClick(index) {
+ 			this.tabCurrentIndex = index;
+ 		},
+ 		// 点击返回 我的页面
+ 		toBack(){
+ 			uni.switchTab({
+ 				url:'/pages/user/user'
+ 			})
+ 		}
+ 	}
+ };
+ </script>
+ 
+ <style lang="scss">
+ page {
+ 	background: #ffffff;
+ 	height: 100%;
+ }
+ .content-money {
+ 	padding-bottom: 30rpx;
+ 	background: $page-color-base;
+ 	.buttom-box {
+ 		position: relative;
+ 		background-color: #ffffff;
+ 		text-align: center;
+ 		margin: 0 30rpx;
+ 		padding: 30rpx 0;
+ 		box-shadow: 0px 0px 20px 0px rgba(50, 50, 52, 0.06);
+ 		border-radius: $border-radius-sm;
+ 		margin-top: -60rpx;
+ 		.buttom {
+ 			flex-grow: 1;
+ 		}
+ 		.money{
+ 			
+ 			font-size: 32rpx;
+ 			font-weight: bold;
+ 			color: #921a23;
+ 		}
+ 		.text {
+ 			padding-bottom: 26rpx;
+ 			font-size: 28rpx;
+ 			font-weight: 500;
+ 			color: #666666;
+ 			&.current {
+ 				border-bottom: 2px solid #921a23;
+ 			}
+ 		}
+ 		.icon {
+ 			height: 50rpx;
+ 			width: 48rpx;
+ 			margin: 0 auto;
+ 			.icon-img {
+ 				width: 100%;
+ 				height: 100%;
+ 			}
+ 		}
+ 	}
+ }
+ .money-box {
+ 	// background: $base-color;
+ 	height: 380rpx;
+ 	color: #ffffff;
+ 	text-align: center;
+ 	font-size: 35rpx;
+ 	position: relative;
+ 	// padding-top: 60rpx;
+ 	.header{
+ 		position: absolute;
+ 		left: 0;
+ 		top: 0;
+ 		width: 100%;
+ 		height: 80rpx;
+ 		font-size: 36rpx;
+ 		font-weight: bold;
+ 		z-index: 99;
+ 		display: flex;
+ 		justify-content: center;
+ 		align-items: center;
+ 	}
+ 	.goback-box{
+ 		position: absolute;
+ 		left: 29rpx;
+ 		top: 0;
+ 		height: 80rpx;
+ 		display: flex;
+ 		align-items: center;
+ 	}
+ 	.goback{
+ 		z-index: 100;
+ 		width: 34rpx;
+ 		height: 34rpx;
+ 	}
+ 	.tuiguang_bg {
+ 		width: 100%;
+ 		height: 400rpx;
+ 		position: relative;
+ 	}
+ 	.money_img{
+ 		width: 100%;
+ 		height: 120rpx;
+ 		text-align: center;
+ 		padding-top: 50rpx;
+ 		padding-bottom: 135rpx;
+ 		image{
+ 			width:120rpx;
+ 			height: 120rpx;
+ 			border: 4rpx solid #FD5F6F;
+ 			border-radius: 50%;
+ 		}
+ 	}
+ 	.money-frame {
+ 		position: absolute;
+ 		top: 0;
+ 		width: 100%;
+ 		padding-top: 120rpx;
+ 		// left: 30rpx;
+ 		// height: 460rpx;
+ 		// display: flex;
+ 		// align-items: flex-start;
+ 		// flex-direction: column;
+ 		// justify-content: center;
+ 	}
+ 	.money_name{
+ 		width: 100%;
+ 		text-align: center;
+ 		font-size: 32rpx;
+ 		font-family: PingFang SC;
+ 		font-weight: bold;
+ 		color: #FFFFFF;
+ 		
+ 	}
+ 	.money_num {
+ 		font-size: 72rpx;
+ 		font-family: PingFang SC;
+ 		font-weight: bold;
+ 		color: #FFFFFF;
+ 		.money_ren {
+ 			font-size: 36rpx;
+ 		}
+ 	}
+ }
+ 
+ // 列表
+ 
+ .swiper-box {
+ 	padding-top: 10rpx;
+ 	.order-item {
+ 		padding: 20rpx 30rpx;
+ 		line-height: 1.5;
+ 		.title-box {
+ 			width: 100%;
+ 			.title-avatar{
+ 				width: 100rpx;
+ 				height: 100rpx;
+ 				margin-right: 25rpx;
+ 				image{
+ 					width: 100%;
+ 					height: 100%;
+ 					border-radius: 100%;
+ 				}
+ 			}
+ 			.list_tpl{
+ 				width: 85%;
+ 				.title {
+ 					font-size: $font-lg;
+ 					color: $font-color-base;
+ 					overflow:hidden;            //超出的文本隐藏
+ 					text-overflow:ellipsis;     //溢出用省略号显示
+ 					white-space:nowrap; 
+ 				}
+ 				.time {
+ 					margin-top: 15rpx;
+ 					font-size: 22rpx;
+ 					color: $font-color-light;
+ 				}
+ 			}
+ 		}
+ 		.money {
+ 			color: #DB1935;
+ 			font-size: $font-lg;
+ 		}
+ 	}
+ }
+ .list-scroll-content {
+ 	height: 100%;
+ }
+ .content {
+ 	height: 100%;
+ 	.empty-content {
+ 		background-color: #ffffff;
+ 	}
+ }
+ </style>
+ 

+ 791 - 0
pages/user/refundAdmin.vue

@@ -0,0 +1,791 @@
+<template>
+	<!-- <view class="refund-admin">
+		<view class="nav-list">
+			<view class="nav-item" :class="{action:currentIndex === 0}" @click="navClick(0)">待退款</view>
+			<view class="nav-item" :class="{action:currentIndex === 1}" @click="navClick(1)">已退款</view>
+		</view>
+		<view class="ref-wrapper">
+			<view class="ref-item">
+				<view class="top">
+					
+				</view>
+			</view>
+		</view>
+	</view> -->
+	<view class="content">
+		<view class="navbar">
+			<view v-for="(item, index) in navList" :key="index" class="nav-item" :class="{ current: tabCurrentIndex === index }" @click="tabClick(index)">{{ item.text }}</view>
+		</view>
+		<swiper :current="tabCurrentIndex" class="swiper-box" duration="300" @change="changeTab">
+			<swiper-item class="tab-content" v-for="(tabItem, tabIndex) in navList" :key="tabIndex">
+				<scroll-view class="list-scroll-content" scroll-y @scrolltolower="loadData">
+					<!-- 空白页 -->
+					<empty v-if="tabItem.loaded === true && tabItem.orderList.length === 0"></empty>
+
+					<!-- 订单列表 -->
+					<view @click="goToOrderDetail(item)" v-for="(item, index) in tabItem.orderList" :key="index" class="order-item">
+						<view class="i-top b-b">
+							<!-- <view class=""></view> -->
+							<text class="time">订单编号:{{ item.id }}</text>
+							<text class="state" style=" color: #901b21; font-size: 26rpx;font-weight: 500; " v-if="tabCurrentIndex === 0">待退款</text>
+							<text class="state" style=" color: #901b21; " v-else>已退款</text>
+							<text v-if="item.status === 4" class="del-btn iconfont icondelete" @click="deleteOrder(index)"></text>
+						</view>
+
+						<scroll-view v-if="item.cartInfo.length > 1" class="goods-box" scroll-x>
+							<view v-for="(goodsItem, goodsIndex) in item.cartInfo" :key="goodsIndex" class="goods-item">
+								<image class="goods-img" :src="goodsItem.productInfo.image" mode="aspectFill"></image>
+							</view>
+						</scroll-view>
+						<!-- <view v-if="item.cartInfo.length === 1" class="goods-box-single" v-for="(goodsItem, goodsIndex) in item.cartInfo" :key="goodsIndex">
+							<image class="goods-img" :src="goodsItem.productInfo.image" mode="aspectFill"></image>
+							<view class="right">
+								<text class="title clamp">{{ goodsItem.productInfo.store_name }}</text>
+								<text class="attr-box">{{ goodsItem.attrInfo ? goodsItem.attrInfo.suk : '' }} x {{ goodsItem.cart_num }}</text>
+								<text class="price">{{ moneyNum(goodsItem.productInfo.price)}}</text>
+							</view>
+						</view> -->
+						<view class="goods-box-single" v-for="(goodsItem, goodsIndex) in item.cartInfo" :key="goodsIndex">
+							<image class="goods-img" :src="goodsItem.productInfo.image" mode="scaleToFill"></image>
+							<view class="right">
+								<view class="flex-start">
+									<text class="title clamp">{{ goodsItem.productInfo.store_name }}</text>
+									<text class="price" style="flex-grow: 1;text-align: right;color: #901B21;font-size: 30rpx;font-weight: bold;">
+										{{ goodsItem.productInfo.price | moneyNum }}
+									</text>
+								</view>
+								<view class="row flex">
+									<text class="row_title">{{ goodsItem.productInfo.attrInfo ? '商品退款' : '押金退款' }}</text>
+									<text class="attr-box">x {{ goodsItem.cart_num }}</text>
+								</view>
+							</view>
+						</view>
+
+						<view class="price-box">
+							<!-- 共 -->
+							<!-- <text class="num">{{ item.cartInfo.length }}</text> -->
+							退款金额:
+							<text class="price">{{ moneyNum(item.pay_price) }}</text>
+							<!-- (含运费
+							<text class="price">{{ moneyNum(item.pay_postage) }}</text>
+							) -->
+						</view>
+						<view class="action-box b-t" v-if="currentIndex === 0">
+<!-- 							<button v-if="item._status._title == '未支付'" class="action-btn" @click.stop="cancelOrder(item)">取消订单</button>
+							<button v-if="item._status._title == '未支付'" @click.stop="orderPay(item)" class="action-btn recom">立即支付</button>
+							<button v-if="item._status._title == '待评价'" class="action-btn">评价</button>
+							<button v-if="item._status._title == '待收货'" @click.stop="orderTake(item, index)" class="action-btn">确认收货</button> -->
+							<button  @click.stop="agreeRefund(item)" class="action-btn">同意退款</button>
+						</view>
+					</view>
+					<uni-load-more :status="tabItem.loadingType"></uni-load-more>
+				</scroll-view>
+			</swiper-item>
+		</swiper>
+		<uni-popup ref="popupagree" class="agree-wrapper">
+		    <view class="agree">
+		    	<image src="../../static/img/agreebg.png" mode=""></image>
+				<view class="tap1">确认同意该笔退款吗?</view>
+				<view class="tap2">一旦操作将无法撤销</view>
+				<view class="btn-wrapper flex">
+					<view @click="cansel">
+						取消
+					</view>
+					<view class="tybtn" @click="agree">
+						同意
+					</view>
+				</view>
+		    </view>
+		</uni-popup>
+	</view>
+</template>
+
+<script>
+import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+import empty from '@/components/empty';
+import { orderList, orderCancel, orderDel, orderTake } from '@/api/order.js';
+import uniPopup from '@/components/uni-popup/uni-popup.vue'
+// import empty from '@/components/empty.vue'
+export default {
+	components: {
+		uniLoadMore,
+		empty,
+		uniPopup
+	},
+	data() {
+		return {
+			currentIndex: 0,
+			refList: [], //退款列表
+			navList: [
+				{
+					state: 1,
+					text: '退款款',
+					loadingType: 'more',
+					orderList: [],
+					page: 1 //当前页数
+				},
+				{
+					state: 2,
+					text: '已退款',
+					loadingType: 'more',
+					orderList: [],
+					page: 1, //当前页数
+					limit: 10 //每次信息条数
+				}
+			],
+			tabCurrentIndex: 0
+		};
+	},
+	filters: {
+		moneyNum(value) {
+			return +value
+		}
+	},
+	onLoad(options) {
+		/**
+		 * 修复app端点击除全部订单外的按钮进入时不加载数据的问题
+		 * 替换onLoad下代码即可
+		 */
+		console.log(options);
+		this.isUser = options.isUser;
+		console.log(this.isUser);
+		this.tabCurrentIndex = +options.state;
+		// #ifndef MP
+		this.loadData();
+		// #endif
+		// #ifdef MP
+		if (options.state == 0) {
+			this.loadData();
+		}
+		// #endif
+	},
+	// #ifdef APP-PLUS || H5
+	onBackPress(e) {
+		uni.switchTab({
+			url: '/pages/user/user'
+		});
+		return true;
+	},
+	// #endif
+	methods: {
+		moneyNum(value) {
+			return +value;
+		},
+		// 确认收货
+		orderTake(item, index) {
+			let obj = this;
+			uni.showModal({
+				title: '是否确认收货?',
+				success: () => {
+					orderTake({
+						uni: item.order_id
+					})
+						.then(e => {
+							obj.navList[obj.tabCurrentIndex].orderList.splice(index, 1);
+							uni.showToast({
+								title: '收货成功'
+							});
+						})
+						.catch(e => {
+							console.log(e);
+						});
+				}
+			});
+		},
+		//跳转到订单详情
+		goToOrderDetail(e) {
+			uni.navigateTo({
+				url: '/pages/order/orderDetail?id=' + e.order_id
+			});
+		},
+		// 申请退款
+		orderRefund(e) {
+			uni.navigateTo({
+				url: '/pages/order/orderRefund?id=' + e.order_id
+			});
+		},
+		// 订单支付
+		orderPay(e) {
+			uni.navigateTo({
+				url: '/pages/money/pay?type=1&ordid=' + e.order_id + '&money=' + e.pay_price
+			});
+		},
+		//获取订单列表
+		loadData(source) {
+			//这里是将订单挂载到tab列表下
+			let index = this.tabCurrentIndex;
+			let navItem = this.navList[index];
+			let state = navItem.state;
+			if (source === 'tabChange' && navItem.loaded === true) {
+				//tab切换只有第一次需要加载数据
+				return;
+			}
+			if (navItem.loadingType === 'loading') {
+				//防止重复加载
+				return;
+			}
+			if (navItem.loadingType === 'noMore') {
+				//防止重复加载
+				return;
+			}
+			// 修改当前对象状态为加载中
+			navItem.loadingType = 'loading';
+
+			orderList({
+				type: state,
+				page: navItem.page,
+				limit: navItem.limit
+			})
+				.then(({ data }) => {
+					let arr = data.map(e => {
+						let b = this.orderStateExp(e.status);
+						e.stateTip = b.stateTip;
+						e.stateTipColor = b.stateTipColor;
+						return e;
+					});
+					navItem.orderList = navItem.orderList.concat(arr);
+					// console.log(navItem.orderList);
+					navItem.page++;
+					if (navItem.limit == data.length) {
+						//判断是否还有数据, 有改为 more, 没有改为noMore
+						navItem.loadingType = 'more';
+						return;
+					} else {
+						//判断是否还有数据, 有改为 more, 没有改为noMore
+						navItem.loadingType = 'noMore';
+					}
+					uni.hideLoading();
+					this.$set(navItem, 'loaded', true);
+				})
+				.catch(e => {
+					console.log(e);
+				});
+		},
+
+		//swiper 切换
+		changeTab(e) {
+			this.tabCurrentIndex = e.target.current;
+			this.loadData('tabChange');
+		},
+		//顶部tab点击
+		tabClick(index) {
+			this.tabCurrentIndex = index;
+		},
+		//删除订单
+		deleteOrder(index) {
+			uni.showLoading({
+				title: '请稍后'
+			});
+			setTimeout(() => {
+				this.navList[this.tabCurrentIndex].orderList.splice(index, 1);
+				uni.hideLoading();
+			}, 600);
+		},
+		//取消订单
+		cancelOrder(item) {
+			uni.showModal({
+				title: '订单取消',
+				content: '是否取消订单?',
+				success: e => {
+					if (e.confirm) {
+						uni.showLoading({
+							title: '请稍后'
+						});
+						orderCancel({ id: item.order_id })
+							.then(e => {
+								uni.showToast({
+									title: '取消成功',
+									duration: 2000,
+									position: 'top'
+								});
+							})
+							.catch(e => {
+								console.log(e);
+							});
+						//取消订单后删除待付款中该项
+						let list = this.navList[this.tabCurrentIndex].orderList;
+						let index = list.findIndex(val => val.id === item.id);
+						index !== -1 && list.splice(index, 1);
+						uni.hideLoading();
+					}
+				}
+			});
+		},
+
+		//订单状态文字和颜色
+		orderStateExp(state) {
+			let stateTip = '',
+				stateTipColor = '#fa436a';
+			switch (+state) {
+				case 0:
+					stateTip = '待付款';
+					break;
+				case 1:
+					stateTip = '待发货';
+					break;
+				case 2:
+					stateTip = '待收货';
+					break;
+				case 3:
+					stateTip = '待评价';
+					break;
+				case 4:
+					stateTip = '已完成';
+					stateTipColor = '#901b21';
+					break;
+				case 9:
+					stateTip = '订单已关闭';
+					stateTipColor = '#909399';
+					break;
+
+				//更多自定义
+			}
+			return { stateTip, stateTipColor };
+		},
+		agreeRefund() {
+			console.log('同意')
+			this.$refs.popupagree.open()
+		},
+		//取消
+		cansel() {
+			this.$refs.popupagree.close()
+		},
+		//同意退款
+		agree() {
+			this.$refs.popupagree.close()
+		}
+	}
+};
+</script>
+
+<style lang="scss" scoped>
+// page {
+// 	height: 100%;
+// 	background-color: #f7f5f5;
+// }
+// .nav-list {
+// 	display: flex;
+// 	justify-content: space-around;
+// 	height: 80rpx;
+// 	width: 750rpx;
+// 	line-height: 80rpx;
+// 	background-color: #fff;
+// 	.nav-item {
+// 		font-size: 30rpx;
+// 		font-weight: 500;
+// 		color: #333333;
+// 		font-size: 30rpx;
+// 		font-weight: 500;
+// 		&.action {
+// 			border-bottom: 5rpx #942328 solid;
+// 			color: #942328;
+// 		}
+// 	}
+// }
+// .ref-item {
+// 	width: 702rpx;
+// 	height: 304rpx;
+// 	background: #FFFFFF;
+// 	box-shadow: 0px 0px 20rpx 0rpx rgba(50, 50, 52, 0.06);
+// 	border-radius: 10rpx;
+// 	margin: 20rpx auto;
+// }
+page,
+.content {
+	background: $page-color-base;
+	height: 100%;
+}
+
+.swiper-box {
+	height: calc(100% - 40px);
+}
+.list-scroll-content {
+	height: 100%;
+}
+
+.navbar {
+	display: flex;
+	height: 40px;
+	padding: 0 5px;
+	background: #fff;
+	box-shadow: 0 1px 5px rgba(0, 0, 0, 0.06);
+	position: relative;
+	z-index: 10;
+	.nav-item {
+		flex: 1;
+		display: flex;
+		justify-content: center;
+		align-items: center;
+		height: 100%;
+		font-size: 15px;
+		color: $font-color-dark;
+		position: relative;
+		&.current {
+			color: $base-color;
+			&:after {
+				content: '';
+				position: absolute;
+				left: 50%;
+				bottom: 0;
+				transform: translateX(-50%);
+				width: 44px;
+				height: 0;
+				border-bottom: 2px solid $base-color;
+			}
+		}
+	}
+}
+
+.uni-swiper-item {
+	height: auto;
+}
+.order-item {
+	display: flex;
+	flex-direction: column;
+	padding-left: 30rpx;
+	background: #fff;
+	margin-top: 16rpx;
+	.i-top {
+		display: flex;
+		align-items: center;
+		height: 80rpx;
+		padding-right: 30rpx;
+		font-size: $font-base;
+		color: $font-color-dark;
+		position: relative;
+		.time {
+			flex: 1;
+		}
+		.state {
+			color: $base-color;
+		}
+		.del-btn {
+			padding: 10rpx 0 10rpx 36rpx;
+			font-size: $font-lg;
+			color: $font-color-light;
+			position: relative;
+			&:after {
+				content: '';
+				width: 0;
+				height: 30rpx;
+				border-left: 1px solid $border-color-dark;
+				position: absolute;
+				left: 20rpx;
+				top: 50%;
+				transform: translateY(-50%);
+			}
+		}
+	}
+	/* 多条商品 */
+	.goods-box {
+		height: 160rpx;
+		padding: 20rpx 0;
+		white-space: nowrap;
+		.goods-item {
+			width: 120rpx;
+			height: 120rpx;
+			display: inline-block;
+			margin-right: 24rpx;
+		}
+		.goods-img {
+			display: block;
+			width: 100%;
+			height: 100%;
+		}
+	}
+	/* 单条商品 */
+	.goods-box-single {
+		display: flex;
+		padding: 20rpx 0;
+		.goods-img {
+			display: block;
+			width: 120rpx;
+			height: 120rpx;
+		}
+		.right {
+			flex: 1;
+			display: flex;
+			flex-direction: column;
+			padding: 0 30rpx 0 24rpx;
+			overflow: hidden;
+			.row {
+				margin-top: 10rpx;
+			}
+			.row_title {
+				padding: 5rpx 10rpx;
+				background-color: #dddddd;
+				border-radius: 10rpx;
+				font-size: 22rpx;
+				color: #ffffff;
+				background: #ffeee9;
+				border-radius: 5rpx;
+				color: #f55e5c;
+			}
+			.title {
+				font-size: $font-base + 2rpx;
+				color: $font-color-dark;
+				line-height: 1;
+				width: 80%;
+			}
+			.attr-box {
+				display: flex;
+				justify-content: flex-end;
+				font-size: $font-sm + 2rpx;
+				color: $font-color-light;
+			}
+			.price {
+				display: inline;
+				font-size: $font-base + 2rpx;
+				color: $font-color-dark;
+				&:before {
+					content: '¥';
+					font-size: $font-sm;
+				}
+			}
+		}
+	}
+	.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: 26rpx;
+			color: #333;
+			&:before {
+				content: '¥';
+				font-size: $font-sm;
+				margin: 0 2rpx 0 8rpx;
+			}
+		}
+	}
+	.action-box {
+		display: flex;
+		justify-content: flex-end;
+		align-items: center;
+		height: 100rpx;
+		position: relative;
+		padding-right: 30rpx;
+	}
+	.action-btn {
+		display: inline-block;
+		// width: 150rpx;
+		height: 48rpx;
+		background: linear-gradient(90deg, #962C32, #942026);
+		border-radius: 24rpx;
+		// width: 160rpx;
+		// height: 60rpx;
+		margin: 0;
+		margin-left: 24rpx;
+		// padding: 0;
+		text-align: center;
+		line-height: 48rpx;
+		font-size: 26rpx;
+		color: #fff;
+		// background: #fff;
+		// border-radius: 100px;
+		&:after {
+			border-radius: 100px;
+		}
+		&.recom {
+			color: $base-color;
+			&:after {
+				border-color: $base-color;
+			}
+		}
+		&.evaluate {
+			color: $color-yellow;
+			&:after {
+				border-color: $color-yellow;
+			}
+		}
+	}
+}
+
+/* load-more */
+.uni-load-more {
+	display: flex;
+	flex-direction: row;
+	height: 80rpx;
+	align-items: center;
+	justify-content: center;
+}
+
+.uni-load-more__text {
+	font-size: 28rpx;
+	color: #999;
+}
+
+.uni-load-more__img {
+	height: 24px;
+	width: 24px;
+	margin-right: 10px;
+}
+
+.uni-load-more__img > view {
+	position: absolute;
+}
+
+.uni-load-more__img > view view {
+	width: 6px;
+	height: 2px;
+	border-top-left-radius: 1px;
+	border-bottom-left-radius: 1px;
+	background: #999;
+	position: absolute;
+	opacity: 0.2;
+	transform-origin: 50%;
+	animation: load 1.56s ease infinite;
+}
+
+.uni-load-more__img > view view:nth-child(1) {
+	transform: rotate(90deg);
+	top: 2px;
+	left: 9px;
+}
+
+.uni-load-more__img > view view:nth-child(2) {
+	transform: rotate(180deg);
+	top: 11px;
+	right: 0;
+}
+
+.uni-load-more__img > view view:nth-child(3) {
+	transform: rotate(270deg);
+	bottom: 2px;
+	left: 9px;
+}
+
+.uni-load-more__img > view view:nth-child(4) {
+	top: 11px;
+	left: 0;
+}
+
+.load1,
+.load2,
+.load3 {
+	height: 24px;
+	width: 24px;
+}
+
+.load2 {
+	transform: rotate(30deg);
+}
+
+.load3 {
+	transform: rotate(60deg);
+}
+
+.load1 view:nth-child(1) {
+	animation-delay: 0s;
+}
+
+.load2 view:nth-child(1) {
+	animation-delay: 0.13s;
+}
+
+.load3 view:nth-child(1) {
+	animation-delay: 0.26s;
+}
+
+.load1 view:nth-child(2) {
+	animation-delay: 0.39s;
+}
+
+.load2 view:nth-child(2) {
+	animation-delay: 0.52s;
+}
+
+.load3 view:nth-child(2) {
+	animation-delay: 0.65s;
+}
+
+.load1 view:nth-child(3) {
+	animation-delay: 0.78s;
+}
+
+.load2 view:nth-child(3) {
+	animation-delay: 0.91s;
+}
+
+.load3 view:nth-child(3) {
+	animation-delay: 1.04s;
+}
+
+.load1 view:nth-child(4) {
+	animation-delay: 1.17s;
+}
+
+.load2 view:nth-child(4) {
+	animation-delay: 1.3s;
+}
+
+.load3 view:nth-child(4) {
+	animation-delay: 1.43s;
+}
+
+@-webkit-keyframes load {
+	0% {
+		opacity: 1;
+	}
+
+	100% {
+		opacity: 0.2;
+	}
+}
+.agree-wrapper {
+	.agree {
+		width: 522rpx;
+		height: 605rpx;
+		background: #FFFFFF;
+		border-radius: 20rpx;
+		text-align: center;
+		image {
+			width: 522rpx;
+			height: 307rpx;
+			// background: linear-gradient(90deg, #962C32, #942026);
+			border-radius: 20rpx;
+		}
+		.tap1 {
+			padding-top: 47.5rpx;
+			font-size: 36rpx;
+			font-weight: 500;
+			color: #333333;
+			line-height: 1;
+		}
+		.tap2 {
+			padding-top: 22rpx;
+			font-size: 30rpx;
+			font-weight: 500;
+			color: #999999;
+			line-height: 1;
+		}
+		.btn-wrapper {
+			padding-top: 55.5rpx;
+			justify-content: center;
+			view {
+				width: 197rpx;
+				height: 61rpx;
+				border: 1px solid #901B21;
+				border-radius: 31px;
+				background: #FFFFFF;
+				font-size: 24rpx;
+				font-weight: 500;
+				color: #901B21;
+				line-height: 61rpx;
+			}
+			.tybtn {
+				margin-left: 22.8rpx;
+				color: #fff;
+				background-color: #901B21;
+			}
+		}
+	}
+}
+</style>

+ 11 - 3
pages/user/scoreAccumulate.vue

@@ -52,7 +52,7 @@ export default {
 			tabCurrentIndex: 0,
 			navList: [
 				{
-					state: 0,
+					state: 1,
 					text: '收入',
 					loadingType: 'more',
 					orderList: [],
@@ -60,7 +60,7 @@ export default {
 					limit: 10 //每次信息条数
 				},
 				{
-					state: 1,
+					state: 0,
 					text: '支出',
 					loadingType: 'more',
 					orderList: [],
@@ -107,8 +107,16 @@ export default {
 				state
 			)
 				.then(({ data }) => {
+					console.log(data)
+					
 					if (data.length > 0) {
-						navItem.orderList = navItem.orderList.concat(data);
+						let list = []
+						data.forEach((item) => {
+							if(item.pm === state){
+								list.push(item)
+							}
+						})
+						navItem.orderList = navItem.orderList.concat(list);
 						navItem.page++;
 					}
 					if (navItem.limit == data.length) {

+ 5 - 4
pages/user/user.vue

@@ -72,7 +72,7 @@
 					<view class="tj-item" @click="navTo('/pages/user/extension')">
 						<text>我的推广</text>
 						<!-- <text>我的佣金</text> -->
-						<text class="num">{{ userInfo.brokerage_price || '0' }}</text>
+						<text class="num">{{ userInfo.spread_count || '0' }}</text>
 					</view>
 				</view>
 			</view>
@@ -125,7 +125,7 @@
 							</view>
 							<text>待发货</text>
 						</view>
-						<view class="order-item" @click="navTo('/pages/order/order?state=3&isUser='+isUser)" hover-class="common-hover" :hover-stay-time="50">
+						<view class="order-item" @click="navTo('/pages/order/order?state=2&isUser='+isUser)" hover-class="common-hover" :hover-stay-time="50">
 							<view class="icon position-relative">
 								<image class="icon-img" src="/static/icon/i3.png" mode="aspectFit"></image>
 								<view class="corner" v-if="orderInfo.received_count > 0">
@@ -158,7 +158,7 @@
 							<view class="icon"><image class="icon-img" src="/static/icon/u6.png" mode="aspectFit"></image></view>
 							<text>提货管理</text>
 						</view>
-						<view class="order-item" @click="navTo('/pages/money/wallet')" hover-class="common-hover" :hover-stay-time="50" v-if="userIdentity">
+						<view class="order-item" @click="navTo('/pages/user/refundAdmin?state=0&isUser='+isUser)" hover-class="common-hover" :hover-stay-time="50" v-if="userIdentity">
 							<view class="icon"><image class="icon-img" src="/static/icon/u7.png" mode="aspectFit"></image></view>
 							<text>退货管理</text>
 						</view>
@@ -259,7 +259,8 @@ export default {
 	onShow() {
 		// 判断是否已经登录
 		if (this.hasLogin) {
-			this.loadBaseData();
+			this.loadBaseData();
+			// console.log(this.userInfo)
 		}
 	},
 	onReady() {

+ 326 - 0
pages/user/wipe.vue

@@ -0,0 +1,326 @@
+<template>
+	<view class="wipe-wrapper">
+		<view class="wipe-top flex">
+			<view class="top-left">
+				<image src="../../static/icon/sm.png" mode=""></image>
+				扫码核销
+			</view>
+			<view class="top-right" @click="srhx">
+				<image src="../../static/icon/sr.png" mode=""></image>
+				输入核销
+			</view>
+			<view class="top-jg"></view>
+		</view>
+
+		<scroll-view scroll-y="true" @scrolltolower="loadData" class="good-content">
+			<view>
+				<!-- <empty v-if="tabItem.loaded === true && tabItem.orderList.length === 0"></empty> -->
+				<empty v-if="goodList.length === 0"></empty>
+				<view class="good" v-for="item in goodList">
+					<view class="good-top">
+						<view class="top-num">订单编号:{{ item.id }}</view>
+						<view class="top-status">待核销</view>
+					</view>
+					<view class="goods-buttom">
+						<view class="good-img"><image src="../../static/img/good1.jpg" mode=""></image></view>
+						<view class="good-infos">
+							<view class="good-title clamp">{{ item.title }}</view>
+							<view class="shop-info">
+								<image src="../../static/img/shop.png" mode=""></image>
+								{{ item.shop || '子臣台州旗舰店' }}
+								<image src="../../static/img/point.png" mode=""></image>
+								{{ item.juli + 'm' || '200m' }}
+							</view>
+							<view class="good-tag">佣金¥{{ item.tag || 10 }}</view>
+						</view>
+					</view>
+					<view class="good-hj">一共{{ item.num }}件商品 合计:¥{{ item.paypri }}</view>
+					<view class="good-price">¥{{ item.price }}</view>
+					<view class="good-num">X{{ item.num }}</view>
+				</view>
+				<uni-load-more :status="goodList.loadingType"></uni-load-more>
+			</view>
+		</scroll-view>
+		<uni-popup ref="popuphx" class="agree-wrapper">
+		    <view class="hx-wrapper">
+		    	<view class="hx-img">
+		    		<image src="../../static/img/hxbg.png" mode=""></image>
+		    	</view>
+				<view class="hx-body">
+					<view class="hx-title">
+						输入核销码核销
+					</view>
+					<input type="text" value="" placeholder="请输入核销码" placeholder-class="hx-placeholder"/>
+					<view class="hx-btn">
+						立即核销
+					</view>
+				</view>
+				<view class="hx-close" @click="close">
+					<image src="../../static/icon/close.png" mode=""></image>
+				</view>
+		    </view>
+		</uni-popup>
+	</view>
+</template>
+
+<script>
+import empty from '@/components/empty';
+import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+import uniPopup from '@/components/uni-popup/uni-popup.vue'
+
+export default {
+	components: {
+		empty,
+		uniPopup
+	},
+	data() {
+		return {
+			goodList: [
+				{
+					id: '5577889955',
+					title: '湿热肝上火气肺痰煲汤材料',
+					shop: '子臣台州旗舰店',
+					juli: 300,
+					tag: 10,
+					num: 1,
+					price: 250,
+					paypri: 250
+				}
+			] //待核销商品,
+		};
+	},
+	methods: {
+		loadData() {
+			console.log('daodil ');
+		},
+		srhx() {
+			this.$refs.popuphx.open()
+		},
+		close() {
+			this.$refs.popuphx.close()
+		}
+	}
+};
+</script>
+
+<style lang="scss" scoped>
+page {
+	height: 100%;
+	background-color: #f8f6f6;
+}
+.wipe-wrapper {
+	.wipe-top {
+		justify-content: space-around;
+		width: 750rpx;
+		height: 80rpx;
+		background: #ffffff;
+		box-shadow: 0px 0px 20px 0px rgba(50, 50, 52, 0.06);
+		font-size: 28rpx;
+		font-weight: 500;
+		color: #ef041f;
+		line-height: 80rpx;
+		text-align: center;
+		position: relative;
+		z-index: 10;
+		.top-left {
+			vertical-align: middle;
+			width: 50%;
+			image {
+				width: 27rpx;
+				height: 25rpx;
+				margin-right: 10rpx;
+			}
+		}
+		.top-right {
+			vertical-align: middle;
+			width: 50%;
+			image {
+				width: 27rpx;
+				height: 25rpx;
+				margin-right: 10rpx;
+			}
+		}
+		.top-jg {
+			width: 2rpx;
+			height: 80rpx;
+			background: #f0f0f0;
+			position: absolute;
+			// background: red;
+		}
+	}
+}
+.good-content {
+	height: 100%;
+}
+.good {
+	width: 702rpx;
+	height: 304rpx;
+	background: #ffffff;
+	box-shadow: 0px 0px 20px 0px rgba(50, 50, 52, 0.06);
+	border-radius: 10rpx;
+	padding: 0 30rpx;
+	margin: 20rpx auto;
+	position: relative;
+	.good-top {
+		height: 85rpx;
+		font-size: 24rpx;
+		font-weight: 400;
+		color: #666666;
+		line-height: 85rpx;
+		display: flex;
+		justify-content: space-between;
+		.top-status {
+			font-size: 28rpx;
+			font-weight: 500;
+			color: #EF041F;
+		}
+	}
+	.goods-buttom {
+		height: 160rpx;
+		display: flex;
+		.good-img {
+			width: 160rpx;
+			height: 160rpx;
+			// overflow: hidden;
+			image {
+				width: 160rpx;
+				height: 160rpx;
+			}
+		}
+		.good-title {
+			width: 350rpx;
+			padding-top: 6rpx;
+			font-size: 26rpx;
+			font-weight: 500;
+			color: #3F454B;
+			line-height: 1;
+			padding-left: 10rpx;
+		}
+		.shop-info {
+			padding-top: 11rpx;
+			font-size: 24rpx;
+			font-weight: 500;
+			color: #DCB876;
+			line-height: 1;
+			// padding-left: 10rpx;
+			image {
+				width: 24rpx;
+				height: 24rpx;
+				margin-left: 14rpx;
+				margin-right: 4rpx;
+			}
+		}
+		.good-tag {
+			display: inline-block;
+			height: 36rpx;
+			background: #ffeee9;
+			// opacity: 0.2;
+			border-radius: 5rpx;
+			font-size: 20rpx;
+			font-weight: 500;
+			color: #F23030;
+			padding: 0 9rpx;
+			line-height: 36rpx;
+			margin-top: 15rpx;
+			margin-left: 10rpx;
+		}
+		
+	}
+	.good-hj {
+		line-height: 1;
+		height: 26rpx;
+		font-size: 26rpx;
+		font-weight: 500;
+		color: #333333;
+		text-align: right;
+	}
+	.good-price {
+		text-align: left;
+		font-size: 26rpx;
+		font-weight: 500;
+		line-height: 1;
+		color: #333333;
+		position: absolute;
+		right: 31rpx;
+		top:98rpx;
+	}
+	.good-num {
+		text-align: left;
+		font-size: 26rpx;
+		font-weight: 500;
+		line-height: 1;
+		color: #333333;
+		position: absolute;
+		right: 31rpx;
+		top:136rpx;
+	}
+}
+.hx-wrapper {
+	width: 536rpx;
+	height: 630rpx;
+	position: relative;
+	// background-color: #fff;
+	.hx-img {
+		width: 536rpx;
+		height: 281rpx;
+		image {
+			width: 536rpx;
+			height: 281rpx;
+		}
+	}
+	
+	.hx-close {
+		position: absolute;
+		left: 243rpx;
+		bottom: -80rpx;
+		width: 52rpx;
+		height: 52rpx;
+		image {
+			width: 52rpx;
+			height: 52rpx;
+		}
+	}
+	.hx-body {
+		width: 536rpx;
+		height: 349rpx;
+		background-color: #fff;
+		border-radius: 0 0 10rpx 10rpx;
+		.hx-title {
+			width: 536rpx;
+			font-size: 36rpx;
+			font-weight: 500;
+			color: #333333;
+			line-height: 1;
+			padding-top: 42rpx;
+			text-align: center;
+		}
+		input {
+			width: 439rpx;
+			height: 68rpx;
+			background: #eeddde;
+			border-radius: 10rpx;
+			margin: 39rpx auto 0;
+			padding-left: 26rpx;
+			.hx-placeholder {
+				font-size: 26rpx;
+				font-weight: 500;
+				color: #901b21;
+			}
+		}
+		.hx-btn {
+			margin: 44rpx auto 0;
+			width: 353rpx;
+			height: 71rpx;
+			background: #901b21;
+			border-radius: 34rpx;
+			font-size: 36rpx;
+			font-weight: 500;
+			color: #F8F9F9;
+			line-height: 71rpx;
+			text-align: center;
+		}
+		
+		
+	}
+}
+</style>

二进制
static/icon/close.png


二进制
static/icon/sm.png


二进制
static/icon/sr.png


二进制
static/img/agreebg.png


二进制
static/img/hxbg.png


二进制
static/img/payok.png


二进制
static/img/tgbg.png


+ 1 - 1
uni.scss

@@ -44,7 +44,7 @@ $box-shadow: 0rpx 0rpx 10rpx 10rpx #f3f3f3;
 // 圆角
 $border-radius-sm: 15rpx;
 // 渐变背景颜色
-$bg-green-gradual: linear-gradient(#5dbc7c, #71d094);
+$bg-green-gradual: linear-gradient(#901b21, #901b21);
 /* 功能栏字体大小 */
 %font-title {
 	font-size: $font-lg + 2rpx;

部分文件因为文件数量过多而无法显示