17755135699 1 سال پیش
والد
کامیت
724e1e894b

+ 2 - 2
pages.json

@@ -45,7 +45,7 @@
 				"navigationStyle": "custom"
 			}
 		},
-		
+
 		//房态
 		{
 			"path": "pages/house/index",
@@ -242,7 +242,7 @@
 				{
 					"path": "Mine/Businesses/Businesses",
 					"style": {
-						"navigationBarTitleText": "商户",
+						"navigationBarTitleText": "商户信息",
 						"enablePullDownRefresh": false
 					}
 				}

+ 18 - 15
pages/home/index.vue

@@ -105,8 +105,8 @@
 			</view>
 		</block>
 		<Tabbar :tabbarIndex="0"></Tabbar>
-		<u-picker :show="shShow" :columns="nameList" @close="shShow=false" @cancel="shShow=false"
-			@confirm="confirm" :immediateChange="true" itemHeight="88"></u-picker>
+		<u-picker :show="shShow" :columns="nameList" @close="shShow=false" @cancel="shShow=false" @confirm="confirm"
+			:immediateChange="true" itemHeight="88"></u-picker>
 		<!-- 取消订单 -->
 		<u-modal :show="show" @confirm="confirmCheck" :show-cancel-button="true" @cancel="show=false">
 			<view class="slot-content">
@@ -179,17 +179,19 @@
 						this.shList.forEach(d => shs.push(d.merchantName));
 						this.nameList = [shs];
 						let id = uni.getStorageSync('homestayId');
-						if(!uni.getStorageSync('homestayId')) id = uni.getStorageSync('merchantId');
+						if (!uni.getStorageSync('homestayId')) id = uni.getStorageSync('merchantId');
 						let t = this.shList.find(d => d.merchantId == id);
 						this.name = t ? t.merchantName : ''
 					} else this.$showToast(res.data.msg);
 				})
 			},
 			confirm(e) {
+				console.log(e);
 				this.name = e.value[0];
 				this.shShow = false;
-				
+
 				let t = this.shList.find(d => d.merchantName == this.name);
+				console.log('000', t);
 				if (t) {
 					if (t.merchantType == 2) { //酒店民宿
 						uni.setStorageSync('homestayId', t.merchantId);
@@ -204,27 +206,28 @@
 						this.list = [];
 						uni.setStorageSync('homestayId', '');
 						uni.setStorageSync('merchantId', t.merchantId);
-						uni.setStorageSync('merchantName', t.merchantName);
-						uni.reLaunch({
+						uni.navigateTo({
 							url: '/pagesHouse/home/index'
 						})
 					}
 				}
+
 			},
 			getDetails() {
-				this.$api.get('/merchant/hotel/home/getHotelHomeInfo/' + (uni.getStorageSync('homestayId')||0)).then(res => {
-					if (res.data.code === 0) {
-						this.item = res.data.data;
-					} else this.$showToast(res.data.msg);
-				})
+				this.$api.get('/merchant/hotel/home/getHotelHomeInfo/' + (uni.getStorageSync('homestayId') || 0)).then(
+					res => {
+						if (res.data.code === 0) {
+							this.item = res.data.data;
+						} else this.$showToast(res.data.msg);
+					})
 			},
 			getList() {
 				this.$api.get('/merchant/hotel/order/getMerchantOrderPageList', {
-					homestayId: (uni.getStorageSync('homestayId')||0),
+					homestayId: (uni.getStorageSync('homestayId') || 0),
 					limit: this.limit,
 					page: this.page,
 					orderStatus: '',
-					orderTime:new Date().Format('yyyy-MM-dd')
+					orderTime: new Date().Format('yyyy-MM-dd')
 				}).then(res => {
 					if (res.data.code === 0) {
 						this.list = [...this.list, ...res.data.data.list];
@@ -254,9 +257,9 @@
 					url: '/pages/home/condition'
 				})
 			},
-			toConfirm(){
+			toConfirm() {
 				uni.navigateTo({
-					url:'/pagesMy/orderList/orderList?Type=0'
+					url: '/pagesMy/orderList/orderList?Type=0'
 				})
 			},
 			cancle(item) {

+ 225 - 37
pagesHouse/Mine/Businesses/Businesses.vue

@@ -21,8 +21,10 @@
 				</view>
 				<view class="">
 					渔家乐
-					<!-- <u-icon name="arrow-right"></u-icon> -->
 				</view>
+				<!-- 	<view class="right">
+					<input type="text" v-model="list.phone" border="none" placeholder="请输入" style="height: 48rpx;" />
+				</view> -->
 			</view>
 			<view class="one-mobile">
 				<view class="mobile">
@@ -33,13 +35,13 @@
 				</view>
 			</view>
 
-			<view class="one" @click="nav">
+			<view class="one">
 				<view class="">
 					企业类型
 				</view>
-				<view class="">
-					<!-- <u-icon name="arrow-right"></u-icon> -->
-					渔家乐
+				<view class="right">
+					<input type="text" v-model="companyType" border="none" placeholder="请输入"
+						style="height: 48rpx; text-align: right;" />
 				</view>
 			</view>
 
@@ -47,8 +49,10 @@
 				<view class="mobile">
 					企业法人
 				</view>
+
 				<view class="right">
-					{{list.legalPerson}}
+					<input type="text" v-model="list.legalPerson" border="none" placeholder="请输入"
+						style="height: 48rpx;" />
 				</view>
 			</view>
 
@@ -56,8 +60,9 @@
 				<view class="mobile">
 					法人身份证号码
 				</view>
+
 				<view class="right">
-					{{list.idCard}}
+					<input type="text" v-model="list.idCard" border="none" placeholder="请输入" style="height: 48rpx;" />
 				</view>
 			</view>
 
@@ -65,8 +70,10 @@
 				<view class="mobile" style="width: 350rpx;">
 					统一社区信用代码
 				</view>
+
 				<view class="right">
-					{{list.creditCode}}
+					<input type="text" v-model="list.creditCode" border="none" placeholder="请输入"
+						style="height: 48rpx;" />
 				</view>
 			</view>
 
@@ -75,7 +82,8 @@
 					企业地址
 				</view>
 				<view class="right">
-					{{list.areaDetail}}
+					<input type="text" v-model="list.areaDetail" border="none" placeholder="请输入"
+						style="height: 48rpx;" />
 				</view>
 			</view>
 
@@ -89,8 +97,9 @@
 				<view class="mobile">
 					联系人姓名
 				</view>
+
 				<view class="right">
-					{{list.linkName}}
+					<input type="text" v-model="list.linkName" border="none" placeholder="请输入" style="height: 48rpx;" />
 				</view>
 			</view>
 
@@ -98,8 +107,9 @@
 				<view class="mobile">
 					联系人号码
 				</view>
+
 				<view class="right">
-					{{list.phone}}
+					<input type="text" v-model="list.phone" border="none" placeholder="请输入" style="height: 48rpx;" />
 				</view>
 			</view>
 		</view>
@@ -109,27 +119,27 @@
 		</view>
 		<view class="from-content" style="padding: 30rpx;">
 			<view class="tenant-image">
-				<view>
+				<view @click="idCardFront">
 					<image :src="list.idCardFront" mode=""></image>
 					<view>法人身份证国徽面</view>
 				</view>
-				<view>
+				<view @click="idCardReverse">
 					<image :src="list.idCardReverse" mode=""></image>
 					<view>法人身份证人像面</view>
 				</view>
-				<view>
+				<view @click="licensePic">
 					<image :src="list.licensePic" mode=""></image>
 					<view>营业执照</view>
 				</view>
-				<view>
+				<view @click="usccl">
 					<image :src="list.usccl" mode=""></image>
 					<view>统一社会信息代码证</view>
 				</view>
-				<view>
+				<view @click="shopSign">
 					<image :src="list.shopSign" mode=""></image>
 					<view>门头照</view>
 				</view>
-				<view>
+				<view @click="shopImgs">
 					<image :src="list.shopImgs" mode=""></image>
 					<view>店铺照片</view>
 				</view>
@@ -161,7 +171,7 @@
 		</u-popup>
 
 		<view class="from-content">
-			<button class="tenant-button">
+			<button class="tenant-button" @click="merchant">
 				立即保存
 			</button>
 		</view>
@@ -194,24 +204,82 @@
 						name: '硕士',
 					}
 				],
+				fishermanId: uni.getStorageSync('merchantId'),
+				list: {},
 				dto: {
-					realName: '黄沙村渔家乐', //昵称
-					modifyPhone: '18755113256', //手机号
-					headUrl: '', // 头像
-					idCode: '', // 证件号
+					name: '', //商户名称
+					busName: '', //企业名称
+					merchantType: 10, //商户类型
+					companyType: '', //企业类型
+					legalPerson: '', //企业法人
+					idCard: '', //法人身份证号码
+					creditCode: '', //统一社区信用代码
+					areaDetail: '', //企业地址
+					linkName: '', //联系人姓名
+					phone: '', //联系人号码
+					idCardFront: '', //法人身份证国徽面
+					idCardReverse: '', //法人身份证人像面
+					licensePic: '', //营业执照
+					usccl: '', //统一社会信息代码证
+					shopSign: '', //门头照
+					shopImgs: '', //店铺照片
 					id: ''
 				},
-				fishermanId: uni.getStorageSync('merchantId'),
-				list: {}
+				typeList: {},
+				companyType: ''
 			}
 		},
 		onLoad() {
 			this.getList()
+			this.getDict()
 		},
 
 		methods: {
-			// 上传头像
-			upImage() {
+			// 获取数据 
+			getList() {
+				// this.$api.get('/merchant/merchantFisherman/home?id=' + this.homestayId).then(res => {
+				// 	console.log(res.data);
+				// })
+				let id = this.fishermanId
+				this.$api.get(`/merchant/merchantFisherman/home/${id}`).then(res => {
+					console.log(res.data);
+					this.list = res.data.data
+				})
+			},
+			// 获取企业类型字典
+			getDict() {
+				this.$api.get('/sys/dict/type/all').then(res => {
+					console.log(res.data)
+					//this.$store.state.Dict = Object.assign(res.data);
+					// this.dictValue
+					this.typeList = res.data.data.find((p) => p.dictType == 'CompanyType').dataList;
+					console.log(this.typeList);
+					this.companyType = this.typeList.find((p) => p.dictValue == this.list.companyType).dictLabel
+					console.log(this.companyType);
+				})
+			},
+			// 立即保存
+			merchant() {
+				this.dto.name = this.list.name
+				this.dto.busName = this.list.busName
+				this.dto.merchantType = this.list.merchantType
+				this.dto.companyType = this.list.companyType
+				this.dto.legalPerson = this.list.legalPerson
+				this.dto.idCard = this.list.idCard
+				this.dto.creditCode = this.list.creditCode
+				this.dto.idCardReverse = this.list.idCardReverse
+				this.dto.licensePic = this.list.licensePic
+				this.dto.usccl = this.list.usccl
+				this.dto.shopSign = this.list.shopSign
+				this.dto.shopImgs = this.list.shopImgs
+				this.dto.id = uni.getStorageSync('merchantId')
+
+				this.$api.put('/merchant/merchantFisherman/home', this.dto).then(res => {
+					console.log(res);
+				})
+			},
+			// 上传头像法人身份证国徽面
+			idCardFront() {
 				uni.chooseImage({
 					sourceType: ['album'], //从相册选择
 					success: chooseImageRes => {
@@ -226,7 +294,8 @@
 							success: res => {
 								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
 								let data = JSON.parse(res.data);
-								this.dto.headUrl = data.data.url
+								this.dto.idCardFront = data.data.url
+								this.list.idCardFront = data.data.url
 							}
 						});
 					},
@@ -236,18 +305,137 @@
 				});
 
 			},
+			// 上传法人身份证人像面
+			idCardReverse() {
+				uni.chooseImage({
+					sourceType: ['album'], //从相册选择
+					success: chooseImageRes => {
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'file',
+							header: {
+								token: wx.getStorageSync('access_token')
+							},
+							success: res => {
+								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
+								let data = JSON.parse(res.data);
+								this.dto.idCardReverse = data.data.url
+								this.list.idCardReverse = data.data.url
+							}
+						});
+					},
+					fail: err => {
+						this.myToast('图片上传失败', 'none');
+					}
+				});
 
-			getList() {
-				// this.$api.get('/merchant/merchantFisherman/home?id=' + this.homestayId).then(res => {
-				// 	console.log(res.data);
-				// })
-				let id = this.fishermanId
-				this.$api.get(`/merchant/merchantFisherman/home/${id}`).then(res => {
-					console.log(res.data);
-					this.list = res.data.data
-				})
-			}
+			}, // 上传营业执照
+			licensePic() {
+				uni.chooseImage({
+					sourceType: ['album'], //从相册选择
+					success: chooseImageRes => {
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'file',
+							header: {
+								token: wx.getStorageSync('access_token')
+							},
+							success: res => {
+								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
+								let data = JSON.parse(res.data);
+								this.dto.licensePic = data.data.url
+								this.list.licensePic = data.data.url
+							}
+						});
+					},
+					fail: err => {
+						this.myToast('图片上传失败', 'none');
+					}
+				});
+
+			}, // 上传统一社会信息代码证
+			usccl() {
+				uni.chooseImage({
+					sourceType: ['album'], //从相册选择
+					success: chooseImageRes => {
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'file',
+							header: {
+								token: wx.getStorageSync('access_token')
+							},
+							success: res => {
+								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
+								let data = JSON.parse(res.data);
+								this.dto.usccl = data.data.url
+								this.list.usccl = data.data.url
+							}
+						});
+					},
+					fail: err => {
+						this.myToast('图片上传失败', 'none');
+					}
+				});
+
+			}, // 上传门头照
+			shopSign() {
+				uni.chooseImage({
+					sourceType: ['album'], //从相册选择
+					success: chooseImageRes => {
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'file',
+							header: {
+								token: wx.getStorageSync('access_token')
+							},
+							success: res => {
+								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
+								let data = JSON.parse(res.data);
+								this.dto.shopSign = data.data.url
+								this.list.shopSign = data.data.url
+							}
+						});
+					},
+					fail: err => {
+						this.myToast('图片上传失败', 'none');
+					}
+				});
+
+			}, // 上传店铺照片
+			shopImgs() {
+				uni.chooseImage({
+					sourceType: ['album'], //从相册选择
+					success: chooseImageRes => {
+						const tempFilePaths = chooseImageRes.tempFilePaths;
+						uni.uploadFile({
+							url: 'https://i.ringzle.com/island-cloud-server/oss/file/upload', // 仅为示例,非真实的接口地址
+							filePath: tempFilePaths[0],
+							name: 'file',
+							header: {
+								token: wx.getStorageSync('access_token')
+							},
+							success: res => {
+								// uploadFile上传成功后,根据和后台的约定msgCode判断接口调用状态
+								let data = JSON.parse(res.data);
+								this.dto.shopImgs = data.data.url
+								this.list.shopImgs = data.data.url
+							}
+						});
+					},
+					fail: err => {
+						this.myToast('图片上传失败', 'none');
+					}
+				});
 
+			},
 		}
 
 

+ 24 - 19
pagesHouse/Mine/index.vue

@@ -4,11 +4,11 @@
 			mode="widthFix"></image>
 		<view class="account" :style="{'margin-top':(mt-44)+'px'}">
 			<view class="a_left">
-				<view class="al_avatar" @tap="toLogin">
-					<image :src="avatar"></image>
+				<view class="al_avatar">
+					<image :src="dto.shopSign"></image>
 				</view>
 				<view class="al_name_edit">
-					<text>{{name}}</text>
+					<text>{{dto.linkName==''?'临时商户':dto.linkName}}</text>
 					<view class="ane_edit" @tap="toTurn('/pagesHouse/Mine/PersonalEditing/PersonalEditing',true)">
 						<text>编辑</text>
 						<image src="https://i.ringzle.com/file/20240129/e824a765b6c24ac6aafbb49b12c23aa9.png"></image>
@@ -62,11 +62,10 @@
 						<view class="demo-layout bg-purple-light">
 							<view class="one2">
 								<!-- {{myList.islandName}} -->
-								{{merchantName}}
+								{{dto.name}}
 							</view>
 							<view class="two2">
-								<!-- {{myList.areaDetail}} -->
-								<!-- 舟山市嵊泗县嵊山镇前卫村后岗 -->
+								{{dto.address}}
 							</view>
 						</view>
 					</u-col>
@@ -115,8 +114,12 @@
 				],
 				price: 0, //钱包余额
 				merchantName: uni.getStorageSync('merchantName'),
+				dto: {}
 			}
 		},
+		onLoad() {
+			this.getInfo();
+		},
 		methods: {
 			toTurn(url, login) { //login 是否需要验证登录跳转
 				if (!url) return this.$showToast('正在开发中...')
@@ -125,19 +128,21 @@
 					url
 				});
 
-				// if (login) {
-				// 	this.$login().then(res => {
-				// 		if (res === 0) {
-				// 			uni.navigateTo({
-				// 				url
-				// 			});
-				// 		} else this.$refs['phoneNumber'].show = true;
-				// 	})
-				// } else {
-				// 	uni.navigateTo({
-				// 		url
-				// 	});
-				// }
+
+			},
+			getInfo() {
+				this.$api.get('/merchant/merchantFisherman/home/' + uni.getStorageSync('merchantId')).then(res => {
+					console.log(res)
+					if (res.data.code == 0) {
+						this.dto = res.data.data;
+						if (!res.data.data.shopSign) {
+							this.dto.shopSign =
+								'https://i.ringzle.com/file/20240225/26feb8cc8f744123a980211ebdfb8d40.png';
+						}
+						this.shopImgs = res.data.data.split(',');
+						console.log(this.shopImgs)
+					}
+				})
 			},
 		}
 	}

+ 14 - 8
pagesHouse/Mine/ordersList/details/details.vue

@@ -31,7 +31,7 @@
 				</view>
 				<view class="ticketInfo-hander">
 					<view class="image">
-						<image :src="list.pic" mode="aspectFill"></image>
+						<image :src="list.picList[0]" mode="aspectFill"></image>
 					</view>
 					<view class="" style="width: 100%; display: flex; flex-wrap: wrap; justify-content: space-between;">
 						<view class="name" style="display: flex; justify-content: space-between;">
@@ -132,6 +132,7 @@
 		},
 		onLoad() {
 			this.list = uni.getStorageSync('list')
+			console.log(this.list);
 			// console.log(JSON.parse(option.list));
 			// this.list = JSON.parse(option.list)
 			// console.log('-----', this.list);
@@ -159,13 +160,17 @@
 			},
 			// 核销
 			handleDetail(item) {
-				console.log(item);
-				this.$api.post('/merchant/merchantFisherman/home/writeOffOrder', {
-					writeOffCode: item.orderCode
-				}).then(
-					res => {
-						console.log(res.data);
-					})
+
+				uni.navigateTo({
+					url: '/pagesHouse/Verification/index'
+				})
+				// console.log(item);
+				// this.$api.post('/merchant/merchantFisherman/home/writeOffOrder', {
+				// 	writeOffCode: item.orderCode
+				// }).then(
+				// 	res => {
+				// 		console.log(res.data);
+				// 	})
 			},
 			// 删除订单
 			toStatus() {
@@ -299,6 +304,7 @@
 				margin-right: 20rpx;
 
 				image {
+					border-radius: 12rpx;
 					width: 100%;
 					height: 100%;
 				}

+ 22 - 14
pagesHouse/Mine/ordersList/index.vue

@@ -20,11 +20,10 @@
 					<text v-else-if='item.state==-3' class="green">已退款</text>
 					<text v-else-if='item.state==4' class="red">待使用</text>
 					<text v-else-if='item.state==5' class="green">已预约</text>
-
 					<text v-else :class="statusClass[item.state]">{{status[item.state]}}</text>
 				</view>
 				<view class="mainContent" @click="navTo(item)">
-					<image class="image" :src="item.pic" mode="aspectFill"></image>
+					<image class="image" :src="item.picList[0]" mode="aspectFill"></image>
 					<view class="middle">
 						<view class="title" style="display: flex; justify-content: space-between;">
 							<span> {{item.thingName}}</span>
@@ -126,7 +125,6 @@
 				} else if (type == -3) {
 					this.changeTab1(4)
 				}
-				this.getOrderList()
 			} else {
 				console.log('2222');
 				this.getOrderList()
@@ -141,27 +139,37 @@
 				})
 			},
 			// 核销
-			handleDetail(item) {
-				let dto = {
-					writeOffCode: item.orderCode
-				}
-				this.$api.post('/merchant/merchantFisherman/home/writeOffOrder?dto=', dto).then(res => {})
+			handleDetail() {
+				// let dto = {
+				// 	writeOffCode: item.orderCode
+				// }
+				// this.$api.post('/merchant/merchantFisherman/home/writeOffOrder?dto=', dto).then(res => {
+
+				// })
+				uni.navigateTo({
+					url: '/pagesHouse/Verification/index'
+				})
 			},
 			// 删除
 			Detail(item) {
+				console.log(this.current);
 				this.$api.del('/merchant/merchantFisherman/home', [
 					item.id
 				]).then(res => {
 					if (res.data.code == 0) {
 						this.$showToast('删除成功');
-						this.getOrderList()
+						// this.getOrderList()
+						setTimeout(() => {
+							this.changeTab1(this.current)
+						}, 1000)
 					} else {
 						this.$showToast('删除失败');
-						this.getOrderList()
+						setTimeout(() => {
+							this.changeTab1(this.current)
+						}, 1000)
+						// this.getOrderList()
 					}
-
 				})
-
 			},
 			changeTab1(index) {
 				this.current = index;
@@ -194,7 +202,7 @@
 			},
 			getOrderByStatusList(state) {
 				this.$api.get('/merchant/merchantFisherman/home/queryMyOrderPage', {
-					// fishermanId:this.homestayId,
+					fishermanId: this.fishermanId,
 					limit: this.limit,
 					page: this.page,
 					state: state
@@ -346,7 +354,7 @@
 				}
 
 				.mainContent {
-					border-bottom: 1px #f3f3f3 solid;
+					// border-bottom: 1px #f3f3f3 solid;
 					display: flex;
 					padding: 20rpx 0;
 

+ 1 - 1
pagesHouse/Verification/details.vue

@@ -31,7 +31,7 @@
 				</view>
 				<view class="ticketInfo-hander">
 					<view class="image">
-						<image :src="list.pic" mode="aspectFill"></image>
+						<image :src="list.picList[0]" mode="aspectFill"></image>
 					</view>
 					<view class="" style="width: 100%; display: flex; flex-wrap: wrap; justify-content: space-between;">
 						<view class="name" style="display: flex; justify-content: space-between;">

+ 1 - 2
pagesHouse/Verification/handiwork.vue

@@ -12,8 +12,7 @@
 					</view>
 				</view>
 				<view class="two">
-					<u--input type='number' placeholder="请输入核销码" border="none" v-model="value" color='#FFFFFF'
-						size='36'></u--input>
+					<u--input placeholder="请输入核销码" border="none" v-model="value" color='#FFFFFF' size='36'></u--input>
 				</view>
 			</view>
 		</view>

+ 42 - 30
pagesHouse/home/index.vue

@@ -1,8 +1,10 @@
 <template>
+
 	<view class="page" :style="{'min-height':(h-th)+'px'}">
 		<u-navbar bgColor="transparent">
-			<view class="u-nav-slot" slot="left" @tap="shShow=true">
+			<view class="u-nav-slot" slot="left" style="display: flex;" @tap="shShow=true">
 				<text>{{name}}</text>
+				<u-icon name="arrow-down" size="28" :bold="true" color="#fff"></u-icon>
 			</view>
 		</u-navbar>
 		<u-picker :show="shShow" :columns="nameList" @close="shShow=false" @cancel="shShow=false"
@@ -93,6 +95,8 @@
 				<text>¥{{item.price}}</text>
 			</view>
 		</view>
+		<u-picker :show="shShow" :columns="nameList" @close="shShow=false" @cancel="shShow=false" @confirm="confirm"
+			:immediateChange="true" itemHeight="88"></u-picker>
 		<Tabbares :tabbarid="0"></Tabbares>
 	</view>
 </template>
@@ -101,23 +105,27 @@
 	export default {
 		data() {
 			return {
-				name:uni.getStorageSync('merchantName'),
+				merchantName: uni.getStorageSync('merchantName'),
 				emg: 'https://i.ringzle.com/file/20240224/91173dde1cb44b139129e12ad4971f1d.png',
 				icons: ['https://i.ringzle.com/file/20240224/70ab9f9d1a144c95927dedc6e84bcce7.png',
 					'https://i.ringzle.com/file/20240224/3f990c250f444ac9a5d9f334f322c98e.png',
 					'https://i.ringzle.com/file/20240224/7ca1bfa6e348438e83edc5af0589f847.png'
 				],
-				info:{},
-				shShow:false,
-				list:[],
-				shList:[],
-				nameList:[],
+				info: {},
+				list: [],
+				nameList: [],
+				shShow: false,
+				shList: [],
+				name: ''
 			}
 		},
-		onLoad(opt){
+		onLoad(opt) {
+			// if(opt.merchantName ){
+			// 	this.merchantName =opt.merchantName ;
+			// }
 			this.getData();
 			this.getList();
-			this.getType();
+			this.getType()
 		},
 		methods: {
 			getType() {
@@ -127,51 +135,55 @@
 						let shs = [];
 						this.shList.forEach(d => shs.push(d.merchantName));
 						this.nameList = [shs];
-						let id = uni.getStorageSync('merchantId');
-						if(!uni.getStorageSync('merchantId')) id = uni.getStorageSync('merchantId');
+						let id = uni.getStorageSync('homestayId');
+						if (!uni.getStorageSync('homestayId')) id = uni.getStorageSync('merchantId');
 						let t = this.shList.find(d => d.merchantId == id);
 						this.name = t ? t.merchantName : ''
-						console.log(this.nameList)
 					} else this.$showToast(res.data.msg);
 				})
 			},
 			confirm(e) {
+				console.log(e);
 				this.name = e.value[0];
 				this.shShow = false;
+
 				let t = this.shList.find(d => d.merchantName == this.name);
+				console.log('000', t);
 				if (t) {
-					if (t.merchantType == 2) { //酒店民宿
+					if (t.merchantType != 2) { //酒店民宿
 						uni.setStorageSync('homestayId', t.merchantId);
 						uni.setStorageSync('merchantId', '');
-						uni.reLaunch({
-							url: '/pages/home/index'
-						})
+						this.list = [];
 					} else {
+						this.item = null;
+						this.list = [];
 						uni.setStorageSync('homestayId', '');
 						uni.setStorageSync('merchantId', t.merchantId);
-						uni.setStorageSync('merchantName', t.merchantName);
-						this.getData();
-						this.getList();
+						uni.navigateTo({
+							url: '/pages/home/index'
+						})
 					}
 				}
+
 			},
 			getData() {
-				this.$api.get('/merchant/merchantFisherman/home/getMerchantFishermanAppHome/'+ uni.getStorageSync('merchantId')).then(res => {
+				this.$api.get('/merchant/merchantFisherman/home/getMerchantFishermanAppHome/' + uni.getStorageSync(
+					'merchantId')).then(res => {
 					if (res.data.code === 0) {
 						this.info = res.data.data;
-					} 
+					}
 				})
 			},
-			getList(){
-				this.$api.post('/merchant/merchantFisherman/home/getMerchantFishermanOrderList',{
-					dateTime:new Date().Format('yyyy-MM-dd'),
-					dateType:'1',
-					fishermanId:uni.getStorageSync('merchantId')
-					
+			getList() {
+				this.$api.post('/merchant/merchantFisherman/home/getMerchantFishermanOrderList', {
+					dateTime: new Date().Format('yyyy-MM-dd'),
+					dateType: '1',
+					fishermanId: uni.getStorageSync('merchantId')
+
 				}).then(res => {
 					if (res.data.code === 0) {
 						this.list = res.data.data;
-					} 
+					}
 				})
 			},
 			toHref(url) {
@@ -193,8 +205,8 @@
 		background: #F3F4F4;
 		padding-bottom: 40rpx;
 		box-sizing: border-box;
-		width:100%;
-		overflow-x:hidden;
+		width: 100%;
+		overflow-x: hidden;
 
 		.list {
 			width: calc(100% - 36rpx);