hwq 4 years ago
parent
commit
937feefd87

+ 19 - 0
api/merchant.js

@@ -0,0 +1,19 @@
+import request from '@/utils/request'
+
+//店铺订单列表
+export function merchantList(data) {
+	return request({
+		url: '/api/admin/order/list',
+		method: 'get',
+		data
+	});
+}
+
+//店铺订单详情
+export function detail(data,id) {
+	return request({
+		url: '/api/admin/order/detail/'+id,
+		method: 'get',
+		data
+	});
+}

+ 10 - 1
pages.json

@@ -240,7 +240,16 @@
 					"bounce": "none"
 					"bounce": "none"
 				}
 				}
 			}
 			}
-		}, {
+		}, 
+		{
+			"path": "pages/merchant/orderDetail",
+			"style": {
+				"navigationBarTitleText": "订单详情",
+				"app-plus": {
+					"bounce": "none"
+				}
+			}
+		},{
 			"path": "pages/order/orderRefund",
 			"path": "pages/order/orderRefund",
 			"style": {
 			"style": {
 				"navigationBarTitleText": "申请退款"
 				"navigationBarTitleText": "申请退款"

+ 2 - 1
pages/address/address.vue

@@ -72,7 +72,8 @@ export default {
 				},
 				},
 				detail: data.detail,
 				detail: data.detail,
 				is_default: 1,
 				is_default: 1,
-				id: data.id
+				id: data.id,
+				type: 1,
 			}).then(({ data }) => {
 			}).then(({ data }) => {
 				this.loadAddress();
 				this.loadAddress();
 			}).catch((e) => {
 			}).catch((e) => {

+ 45 - 47
pages/index/index.vue

@@ -9,7 +9,7 @@
 			<!-- 搜素栏 -->
 			<!-- 搜素栏 -->
 			<view class="search flex">
 			<view class="search flex">
 				<image src="../../static/icon/address.png" class="address"></image>
 				<image src="../../static/icon/address.png" class="address"></image>
-				<view class="shop-name clamp" @click.stop="nav('/pages/shoping/list')">{{storeInfo.name}}</view>
+				<view class="shop-name clamp" @click.stop="nav('/pages/shoping/list')">{{ storeInfo.name }}</view>
 				<view class="input-box flex" @click.stop="clickSearch">
 				<view class="input-box flex" @click.stop="clickSearch">
 					<view class=" input-content flex">
 					<view class=" input-content flex">
 						<view class="iconfont iconsearch"></view>
 						<view class="iconfont iconsearch"></view>
@@ -68,7 +68,7 @@
 					<image src="../../static/icon/fanhui.png" class="go" mode=""></image>
 					<image src="../../static/icon/fanhui.png" class="go" mode=""></image>
 				</view>
 				</view>
 				<view class="commodity flex">
 				<view class="commodity flex">
-					<view class="commodity-item" v-for="(item, index) in goodsList" :key="item.id">
+					<view class="commodity-item" v-for="(item, index) in goodsList" :key="item.id" @click="navToDetailPage(item)">
 						<image class="commodity-image" :src="item.image" mode=""></image>
 						<image class="commodity-image" :src="item.image" mode=""></image>
 						<view class="commodity-title clamp">{{ item.store_name }}</view>
 						<view class="commodity-title clamp">{{ item.store_name }}</view>
 						<view class="price">¥{{ item.ot_price }}</view>
 						<view class="price">¥{{ item.ot_price }}</view>
@@ -88,7 +88,7 @@
 				<view class="main-synopsis">买多赚多</view>
 				<view class="main-synopsis">买多赚多</view>
 			</view>
 			</view>
 			<view class="main-content ">
 			<view class="main-content ">
-				<view class="content-top flex xfq"  @click="nav('/pages/prefecture/voucher')">
+				<view class="content-top flex xfq" @click="nav('/pages/prefecture/voucher')">
 					<view class="content-font">
 					<view class="content-font">
 						<view class="content-title">精选好货 平台推荐</view>
 						<view class="content-title">精选好货 平台推荐</view>
 						<view class="content-synopsis">消费券兑换</view>
 						<view class="content-synopsis">消费券兑换</view>
@@ -96,7 +96,7 @@
 					<image src="../../static/icon/fanhui.png" class="go" mode=""></image>
 					<image src="../../static/icon/fanhui.png" class="go" mode=""></image>
 				</view>
 				</view>
 				<view class="commodity flex">
 				<view class="commodity flex">
-					<view class="commodity-item" v-for="(item, index) in bastList" :key="item.id">
+					<view class="commodity-item" v-for="(item, index) in bastList" :key="item.id" @click="navToDetailvoucher(item)">
 						<image class="commodity-image" :src="item.image" mode=""></image>
 						<image class="commodity-image" :src="item.image" mode=""></image>
 						<view class="commodity-title clamp">{{ item.store_name }}</view>
 						<view class="commodity-title clamp">{{ item.store_name }}</view>
 						<view class="price">¥{{ item.ot_price }}</view>
 						<view class="price">¥{{ item.ot_price }}</view>
@@ -110,15 +110,11 @@
 		</view>
 		</view>
 		<!-- 精选好货 -->
 		<!-- 精选好货 -->
 		<view class="bastgood-box">
 		<view class="bastgood-box">
-			<view class="bast-bg">
-				<image src="../../static/icon/jxhh.png" mode=""></image>
-			</view>
+			<view class="bast-bg"><image src="../../static/icon/jxhh.png" mode=""></image></view>
 			<view v-for="(item, index) in goodsList" :key="index" class="guess-item" @click="navToDetailPage(item)">
 			<view v-for="(item, index) in goodsList" :key="index" class="guess-item" @click="navToDetailPage(item)">
 				<image :src="item.image"></image>
 				<image :src="item.image"></image>
 				<view class="guess-box">
 				<view class="guess-box">
-					<view class="title clamp2">
-						{{ item.store_name }}
-					</view>
+					<view class="title clamp2">{{ item.store_name }}</view>
 					<view class="price-box flex">
 					<view class="price-box flex">
 						<view class="yuanprice">{{ item.ot_price }}</view>
 						<view class="yuanprice">{{ item.ot_price }}</view>
 						<image src="../../static/icon/down.png" mode=""></image>
 						<image src="../../static/icon/down.png" mode=""></image>
@@ -135,7 +131,7 @@
 <script>
 <script>
 import seckill from './seckill';
 import seckill from './seckill';
 import { openMap } from '@/utils/rocessor.js';
 import { openMap } from '@/utils/rocessor.js';
-import { loadIndexs,store_list } from '@/api/index.js';
+import { loadIndexs, store_list } from '@/api/index.js';
 import { interceptor } from '@/utils/loginUtils';
 import { interceptor } from '@/utils/loginUtils';
 import { userinfo } from '@/api/user.js';
 import { userinfo } from '@/api/user.js';
 import { mapState, mapMutations } from 'vuex';
 import { mapState, mapMutations } from 'vuex';
@@ -157,8 +153,8 @@ export default {
 			titleNViewBackground: '',
 			titleNViewBackground: '',
 			swiperCurrent: 0,
 			swiperCurrent: 0,
 			swiperLength: 0,
 			swiperLength: 0,
-			longitude:121.436289,//经度
-			latitude:28.651485,//纬度
+			longitude: 121.436289, //经度
+			latitude: 28.651485, //纬度
 			carouselList: [], //轮播列表
 			carouselList: [], //轮播列表
 			goodsList: [], //积分商品列表
 			goodsList: [], //积分商品列表
 			bastList: [], //消费券商品列表
 			bastList: [], //消费券商品列表
@@ -172,17 +168,16 @@ export default {
 		};
 		};
 	},
 	},
 	computed: {
 	computed: {
-		...mapState(['loginInterceptor','storeInfo']),
+		...mapState(['loginInterceptor', 'storeInfo']),
 		...mapState('user', ['hasLogin', 'userInfo'])
 		...mapState('user', ['hasLogin', 'userInfo'])
 	},
 	},
 	onLoad(option) {
 	onLoad(option) {
-		
 		let agree = uni.getStorageSync('agree') || false;
 		let agree = uni.getStorageSync('agree') || false;
 		// 判断是否已经同意协议
 		// 判断是否已经同意协议
 		if (!agree) {
 		if (!agree) {
 			uni.redirectTo({ url: '/pages/contract/start' });
 			uni.redirectTo({ url: '/pages/contract/start' });
 		}
 		}
-		
+
 		if (option.spread) {
 		if (option.spread) {
 			// 存储邀请人
 			// 存储邀请人
 			uni.setStorage({
 			uni.setStorage({
@@ -231,22 +226,22 @@ export default {
 	},
 	},
 	// #endif
 	// #endif
 	methods: {
 	methods: {
-		...mapMutations(['setLat', 'setLon','setStoreInfo']),
+		...mapMutations(['setLat', 'setLon', 'setStoreInfo']),
 		//获取定位信息
 		//获取定位信息
 		getaddress() {
 		getaddress() {
-			console.log('dizhi+++++++++++')
+			console.log('dizhi+++++++++++');
 			let obj = this;
 			let obj = this;
 			uni.getLocation({
 			uni.getLocation({
-				type:'gcj02',
+				type: 'gcj02',
 				success: res => {
 				success: res => {
-					console.log(res)
-					console.log('66666666666666666666')
+					console.log(res);
+					console.log('66666666666666666666');
 					obj.setLat(res.latitude);
 					obj.setLat(res.latitude);
 					obj.setLon(res.longitude);
 					obj.setLon(res.longitude);
 					obj.getStore(res.latitude, res.longitude);
 					obj.getStore(res.latitude, res.longitude);
 				},
 				},
 				fail: err => {
 				fail: err => {
-					console.log(err,'shi+++++++++++++++')
+					console.log(err, 'shi+++++++++++++++');
 					openMap().then(e => {
 					openMap().then(e => {
 						this.getaddress();
 						this.getaddress();
 					});
 					});
@@ -263,25 +258,23 @@ export default {
 		onImageError(key, index) {
 		onImageError(key, index) {
 			this[key][index].image = '/static/error/errorImage.jpg';
 			this[key][index].image = '/static/error/errorImage.jpg';
 		},
 		},
-		getStore(latitude,longitude) {
-			let obj = this
+		getStore(latitude, longitude) {
+			let obj = this;
 			store_list({
 			store_list({
-				latitude:latitude,
-				longitude:longitude,
+				// latitude: latitude,
+				// longitude: longitude,
+				latitude: obj.latitude,
+				longitude: obj.longitude,
 				page: 1,
 				page: 1,
-				limit: 1,
-			}).then(({data})=> {
-				console.log(data,'storeInfo++++')
-				obj.setStoreInfo(data.list[0])
-			})
+				limit: 1
+			}).then(({ data }) => {
+				console.log(data, 'storeInfo++++');
+				obj.setStoreInfo(data.list[0]);
+			});
 		},
 		},
 		// 请求载入数据
 		// 请求载入数据
 		async loadData() {
 		async loadData() {
 			const obj = this;
 			const obj = this;
-			// store_list({latitude:obj.latitude,longitude:obj.longitude}).then(({data}) =>{
-			// 	console.log(data)
-			// 	obj.store_name = data.list[0].detailed_address
-			// })
 			loadIndexs({}).then(({ data }) => {
 			loadIndexs({}).then(({ data }) => {
 				let goods = data.info;
 				let goods = data.info;
 				this.carouselList = data.banner;
 				this.carouselList = data.banner;
@@ -290,9 +283,9 @@ export default {
 				this.goodsList = goods.bastList; //最新商品
 				this.goodsList = goods.bastList; //最新商品
 			});
 			});
 			getProducts({
 			getProducts({
-				page:1,
+				page: 1,
 				limit: 2,
 				limit: 2,
-				is_consumer: 1,
+				is_consumer: 1
 			})
 			})
 				.then(({ data }) => {
 				.then(({ data }) => {
 					obj.bastList = data.map(e => {
 					obj.bastList = data.map(e => {
@@ -300,7 +293,7 @@ export default {
 						e.ot_price = Number(e.ot_price);
 						e.ot_price = Number(e.ot_price);
 						return e;
 						return e;
 					});
 					});
-					console.log(obj.bastList,'123456')
+					console.log(obj.bastList, '123456');
 				})
 				})
 				.catch(e => {
 				.catch(e => {
 					console.log(e);
 					console.log(e);
@@ -318,6 +311,12 @@ export default {
 				url: '/pages/product/product?id=' + item.id
 				url: '/pages/product/product?id=' + item.id
 			});
 			});
 		},
 		},
+		//消费券详情页
+		navToDetailvoucher(item) {
+			uni.navigateTo({
+				url: '/pages/prefecture/detail?id=' + item.id
+			});
+		},
 		// 轮播图跳转
 		// 轮播图跳转
 		bannerNavToUrl(item) {
 		bannerNavToUrl(item) {
 			// #ifdef H5
 			// #ifdef H5
@@ -330,11 +329,11 @@ export default {
 				url: item.wap_url
 				url: item.wap_url
 			});
 			});
 		},
 		},
-		nav(url){
-			console.log(url,'111111111')
+		nav(url) {
+			console.log(url, '111111111');
 			uni.navigateTo({
 			uni.navigateTo({
 				url
 				url
-			})
+			});
 		}
 		}
 	}
 	}
 };
 };
@@ -559,7 +558,7 @@ page {
 		margin: 20rpx auto 0;
 		margin: 20rpx auto 0;
 		padding-bottom: 10rpx;
 		padding-bottom: 10rpx;
 		.xfq {
 		.xfq {
-			background: linear-gradient(43deg, #ffc063, #ffa163) !important; 
+			background: linear-gradient(43deg, #ffc063, #ffa163) !important;
 		}
 		}
 		.content-top {
 		.content-top {
 			width: 690rpx;
 			width: 690rpx;
@@ -642,13 +641,13 @@ page {
 }
 }
 .bastgood-box {
 .bastgood-box {
 	margin-top: 20rpx;
 	margin-top: 20rpx;
-	background-color: #FFFFFF;
+	background-color: #ffffff;
 	padding: 40rpx 0;
 	padding: 40rpx 0;
 	.bast-bg {
 	.bast-bg {
 		width: 376rpx;
 		width: 376rpx;
 		height: 34rpx;
 		height: 34rpx;
 		margin: 0 auto;
 		margin: 0 auto;
-		image{
+		image {
 			width: 100%;
 			width: 100%;
 			height: 100%;
 			height: 100%;
 		}
 		}
@@ -711,12 +710,12 @@ page {
 			.btn {
 			.btn {
 				width: 138rpx;
 				width: 138rpx;
 				height: 52rpx;
 				height: 52rpx;
-				background: #52C696;
+				background: #52c696;
 				border-radius: 26rpx;
 				border-radius: 26rpx;
 				font-size: 26rpx;
 				font-size: 26rpx;
 				font-family: PingFang SC;
 				font-family: PingFang SC;
 				font-weight: 500;
 				font-weight: 500;
-				color: #FFFFFF;
+				color: #ffffff;
 				line-height: 52rpx;
 				line-height: 52rpx;
 				text-align: center;
 				text-align: center;
 				position: absolute;
 				position: absolute;
@@ -726,5 +725,4 @@ page {
 		}
 		}
 	}
 	}
 }
 }
-
 </style>
 </style>

+ 15 - 4
pages/merchant/finance.vue

@@ -2,7 +2,7 @@
 	<view class="center">
 	<view class="center">
 		<view class="top">
 		<view class="top">
 			<image src="../../static/img/sybg.png" mode="" class="sybg"></image>
 			<image src="../../static/img/sybg.png" mode="" class="sybg"></image>
-			<picker mode="date" :value="now_date" @change="bindDateChange" :fields="'month'" :end="now_date">
+			<picker mode="date" :value="now_date" @change="bindDateChange" :fields="'date'" :end="now_date">
 				<view class="uni-input choose-time">{{now_date}} ></view>
 				<view class="uni-input choose-time">{{now_date}} ></view>
 			</picker>
 			</picker>
 			<view class="top-card">
 			<view class="top-card">
@@ -105,9 +105,19 @@
 		data() {
 		data() {
 			let start = new Date(new Date().toLocaleDateString()).getTime()
 			let start = new Date(new Date().toLocaleDateString()).getTime()
 			let a = new Date()
 			let a = new Date()
-			let month = a.getMonth() + 1 + ''
+			let month = a.getMonth() + 1
+			let date = a.getDate()
 			let year = a.getFullYear() + ''
 			let year = a.getFullYear() + ''
-			
+			if(month < 10) {
+				month = '0' +month
+			}else {
+				month = month + ''
+			}
+			if(date < 10) {
+				date = '0' +date 
+			}else {
+				date = date + ''
+			}
 			return {
 			return {
 				height: '',
 				height: '',
 				list: [],
 				list: [],
@@ -120,7 +130,7 @@
 				today_momey: '',//日营业额
 				today_momey: '',//日营业额
 				tiday_start: start/1000,//今日零点时间戳
 				tiday_start: start/1000,//今日零点时间戳
 				today_count: '',//今日订单数
 				today_count: '',//今日订单数
-				now_date: year+ '-' + month  
+				now_date: year+ '-' + month + '-' +date
 			}
 			}
 		},
 		},
 		computed: {
 		computed: {
@@ -162,6 +172,7 @@
 		},
 		},
 		onLoad() {
 		onLoad() {
 			 console.log(this.tiday_start,'start')
 			 console.log(this.tiday_start,'start')
+			 console.log(this.now_date)
 			this.getOrderMonth()
 			this.getOrderMonth()
 			this.getMonth()
 			this.getMonth()
 			this.getTaday()
 			this.getTaday()

+ 89 - 42
pages/merchant/order.vue

@@ -6,65 +6,111 @@
 				<view class="input"><input type="text" disabled placeholder="输入关键字" /></view>
 				<view class="input"><input type="text" disabled placeholder="输入关键字" /></view>
 			</view>
 			</view>
 		</view>
 		</view>
-		<view class="main" v-for="(item, index) in list" :key="index">
-			<view class="top flex">
-				<view class="userinfo clamp">用户ID:{{ item.userID }}</view>
-				<view class="type">{{ item.type == 1 ? '待收货' : item.type == 2 ? '待发货' : item.type == 3 ? '待付款' : '已完成' }}</view>
-			</view>
-			<view class="mainbox">
-				<view class="bg"><image src="" mode=""></image></view>
-				<view class="main-info flex">
-					<view class="main-left">
-						<view class="name clamp">{{ item.name }}</view>
-						<view class="order">订单编号:{{ item.orderID }}</view>
-						<view class="ordertype">{{ item.store_type == 1 ? '别店订单' : '本店订单' }}</view>
-					</view>
-					<view class="main-right">
-						<view class="price">¥{{ item.price }}</view>
-						<view class="num">x{{ item.num }}</view>
+		<scroll-view class="list-scroll-content" scroll-y @scrolltolower="loadData" :style="{ height: maxheight + 'px' }">
+			<view class="main" v-for="(item, index) in list" :key="index" @click="goToOrderDetail(item)">
+				<view class="top flex">
+					<view class="userinfo clamp">订单编号ID:{{ item.order_id }}</view>
+					<view class="type">{{ item.status_name }}</view>
+				</view>
+				<view class="mainbox" v-for="(ls, ind) in item._info">
+					<view class="bg"><image :src="ls.cart_info.productInfo.image" mode=""></image></view>
+					<view class="main-info flex">
+						<view class="main-left">
+							<view class="name clamp2">{{ ls.cart_info.productInfo.store_name }}</view>
+						</view>
+						<view class="main-right">
+							<view class="price">¥{{ ls.cart_info.productInfo.ot_price }}</view>
+							<view class="num">x{{ ls.cart_info.cart_num}}</view>
+						</view>
 					</view>
 					</view>
 				</view>
 				</view>
+				<view class="item-btm">共{{ item.total_num }}件商品 合计:¥{{ item.total_price }}</view>
 			</view>
 			</view>
-			<view class="item-btm">共一件商品 合计:¥{{ item.sum }}</view>
-		</view>
+			<uni-load-more :status="loadType"></uni-load-more>
+		</scroll-view>
 	</view>
 	</view>
 </template>
 </template>
 
 
 <script>
 <script>
+import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+import empty from '@/components/empty';
+import { merchantList } from '@/api/merchant.js';
 export default {
 export default {
-	data() {
-		return {
-			list: [
+	components: {
+		empty,
+		uniLoadMore
+	},
+	onReady() {
+		let obj = this;
+		// 初始化获取页面高度
+		uni.createSelectorQuery()
+			.select('.center')
+			.fields(
 				{
 				{
-					name: '满园春防脱发保湿滋养护法素',
-					price: '24.9',
-					num: '1',
-					orderID: '55648785545',
-					userID: '李丹丹',
-					sum: '24.9',
-					type: 1,
-					store_type: 1
+					size: true
 				},
 				},
-				{
-					name: '满园春防脱发保湿滋养护法素',
-					price: '24.9',
-					num: '1',
-					orderID: '55648785545',
-					userID: '李丹丹',
-					sum: '24.9',
-					type: 1,
-					store_type: 1
+				data => {
+					// 初始化获取头部高度
+					uni.createSelectorQuery()
+						.select('.input-box')
+						.fields(
+							{
+								size: true
+							},
+							es => {
+								console.log(data,es)
+								// 保存头部高度
+								obj.maxheight = data.height - es.height;
+							}
+						)
+						.exec();
 				}
 				}
-			]
+			)
+			.exec();
+	},
+	data() {
+		return {
+			page: 1,
+			limit: 10,
+			loadType: 'more',
+			list: [],
+			maxheight:''
 		};
 		};
 	},
 	},
-	onLoad() {},
-	methods: {}
+	onPullDownRefresh() {
+		this.loadData();
+	},
+	onLoad() {
+		this.loadData();
+	},
+	methods: {
+		loadData() {
+			const obj = this;
+			if (obj.loadType == 'loading' || obj.loadType == 'nomore') {
+				return;
+			}
+			obj.loadType = 'loading';
+			merchantList({ page: obj.page, limit: obj.limit }).then(({ data }) => {
+				obj.list = obj.list.concat(data);
+				obj.page ++
+				if (data.length == obj.limit) {
+					obj.loadType = 'more';
+				} else {
+					obj.loadType = 'nomore';
+				}
+			});
+		},
+		goToOrderDetail(e) {
+			uni.navigateTo({
+				url: '/pages/merchant/orderDetail?id=' + e.order_id
+			});
+		},
+	}
 };
 };
 </script>
 </script>
 
 
 <style lang="scss">
 <style lang="scss">
-page {
+page,.center {
 	height: 100%;
 	height: 100%;
 	background: #f6f4f4;
 	background: #f6f4f4;
 }
 }
@@ -195,4 +241,5 @@ page {
 		color: #333333;
 		color: #333333;
 	}
 	}
 }
 }
+
 </style>
 </style>

File diff suppressed because it is too large
+ 179 - 0
pages/merchant/orderDetail.vue


+ 1 - 1
pages/merchant/storeData.vue

@@ -1,7 +1,7 @@
 <template>
 <template>
 	<view class="content">
 	<view class="content">
 		<view class="headr">
 		<view class="headr">
-			<picker mode="date" :value="now_date" @change="bindDateChange" :fields="'month'" :end="now_date">
+			<picker mode="date" :value="now_date" @change="bindDateChange" :fields="'date'" :end="now_date">
 				<view class="uni-input choose-time">{{now_date}} ></view>
 				<view class="uni-input choose-time">{{now_date}} ></view>
 			</picker>
 			</picker>
 			<view class="month">
 			<view class="month">

+ 59 - 24
pages/wallet/openMember.vue

@@ -42,6 +42,9 @@
 					<view class="item-tip">{{ item.tip }}</view>
 					<view class="item-tip">{{ item.tip }}</view>
 				</view>
 				</view>
 			</view>
 			</view>
+		</view>
+		<view class="store" @click="chooseStore" v-if="choose == 0">
+			选择门店: {{storeInfo.name|| '请选择门店'}}
 		</view>
 		</view>
 		<view class="vip">
 		<view class="vip">
 			<view class="system-title">
 			<view class="system-title">
@@ -64,8 +67,8 @@
 				</view>
 				</view>
 			</view>
 			</view>
 		</view>
 		</view>
-		<view class="" @click="chooseStore">
-			选择门店: {{storeInfo.name|| '请选择门店'}}
+		<view class="zw">
+			
 		</view>
 		</view>
 		<view class="box-buttom">
 		<view class="box-buttom">
 			<view class="price-left">
 			<view class="price-left">
@@ -296,13 +299,13 @@ export default {
 			getUserInfo({})
 			getUserInfo({})
 				.then(({ data }) => {
 				.then(({ data }) => {
 					this.setUserInfo(data);
 					this.setUserInfo(data);
-					if (this.state == 1) {
-						uni.navigateTo({
-							url: '/pages/vip/success'
-						});
-					} else {
-						uni.navigateBack();
-					}
+					// if (this.state == 1) {
+					// 	uni.switchTa({
+					// 		url: '/pages/user/user'
+					// 	});
+					// } else {
+					// 	uni.navigateBack();
+					// }
 				})
 				})
 				.catch(e => {
 				.catch(e => {
 					console.log(e);
 					console.log(e);
@@ -327,21 +330,43 @@ export default {
 				uni.showLoading({
 				uni.showLoading({
 					title: '支付中',
 					title: '支付中',
 					mask: true
 					mask: true
-				});
-				let data = {
-					store_id: obj.storeInfo.id,
-					pay_type: this.payName,
-					level_id: obj.level_id,
-					// #ifdef H5
-					from: obj.froms ? 'weixin' : 'H5', //来源
-					// #endif
-					// #ifdef MP-WEIXIN
-					from: 'routine', //来源
-					// #endif
-					// #ifdef APP-PLUS
-					from: 'app' //来源
-					// #endif
-				};
+				});
+				console.log(obj.storeInfo,'654321')
+				if(obj.choose == 0 && obj.storeInfo.name == ''){
+					this.$api.msg('请选择门店')
+					return
+				}
+				let data
+				if(obj.choose == 0){
+					data = {
+						store_id: obj.storeInfo.id,
+						pay_type: this.payName,
+						level_id: obj.level_id,
+						// #ifdef H5
+						from: obj.froms ? 'weixin' : 'H5', //来源
+						// #endif
+						// #ifdef MP-WEIXIN
+						from: 'routine', //来源
+						// #endif
+						// #ifdef APP-PLUS
+						from: 'app' //来源
+						// #endif
+					};
+				} else{
+					data = {
+						pay_type: this.payName,
+						level_id: obj.level_id,
+						// #ifdef H5
+						from: obj.froms ? 'weixin' : 'H5', //来源
+						// #endif
+						// #ifdef MP-WEIXIN
+						from: 'routine', //来源
+						// #endif
+						// #ifdef APP-PLUS
+						from: 'app' //来源
+						// #endif
+					}
+				}
 				console.log(data, '传值');
 				console.log(data, '传值');
 				becomeVip(data).then(({ data }) => {
 				becomeVip(data).then(({ data }) => {
 					console.log('fufei', data);
 					console.log('fufei', data);
@@ -768,6 +793,10 @@ export default {
 			}
 			}
 		}
 		}
 	}
 	}
+}
+.zw {
+	height: 98rpx;
+	width: 750rpx;
 }
 }
 .box-buttom {
 .box-buttom {
 	width: 750rpx;
 	width: 750rpx;
@@ -937,6 +966,12 @@ export default {
 		line-height: 24px;
 		line-height: 24px;
 		opacity: 0.67;
 		opacity: 0.67;
 	}
 	}
+}
+.store {
+	width: 750rpx;
+	margin-top: 20rpx;
+	padding: 20rpx;
+	background: #FFFFFF;
 }
 }
 </style>
 </style>
 
 

Some files were not shown because too many files changed in this diff