Selaa lähdekoodia

refactor:用户信息修改页面

zhanghui 2 vuotta sitten
vanhempi
sitoutus
01fa0362f1

+ 1 - 0
myPages/realNameAuth/index.vue

@@ -243,6 +243,7 @@ page{
     color: #333333;
     line-height: 42px;
     margin-top: 12px;
+    width: 680rpx;
   }
 
   .uploadItem {

+ 63 - 0
myPages/userInfo/index.rpx.css

@@ -0,0 +1,63 @@
+.page{
+    height: 100vh;
+    background: #F9F9F9;
+    padding: 32rpx;
+}
+.outView{
+    background: #FFFFFF;
+    border-radius: 15rpx;
+    padding: 0 24rpx;
+}
+.photoView{
+    width: 100rpx;
+    height: 100rpx;
+    border-radius: 50rpx;
+    padding: 0;
+    margin: 20rpx 0;
+    border: none;
+}
+.photoView:after{
+    border: none;
+}
+
+.photoImage{
+    width: 100rpx;
+    height: 100rpx;
+}
+.key{
+    font-size: 28rpx;
+    font-family: PingFangSC-Regular, PingFang SC;
+    font-weight: 400;
+    color: #333333;
+    line-height: 44rpx;
+}
+.bordBot{
+    border-bottom: 1px solid #F7F7F7;
+}
+.nikeName{
+    font-size: 28rpx;
+    font-family: PingFangSC-Regular, PingFang SC;
+    font-weight: 400;
+    color: #999999;
+    margin: 28rpx 28rpx 28rpx 0;
+    text-align: right;
+}
+.groupItemContent{
+    font-size: 24rpx;
+    font-family: PingFangSC-Regular, PingFang SC;
+    font-weight: 400;
+    color: #999999;
+    margin: 30rpx 0;
+}
+.updateButton{
+    margin-top: 60rpx;
+    border-radius: 40rpx;
+    background: #FFE05C;
+    font-size: 30rpx;
+}
+.updateButton:after{
+    border: none;
+}
+.picker{
+    width: 300rpx;
+}

+ 116 - 258
myPages/userInfo/index.vue

@@ -1,107 +1,73 @@
 <template>
-	<view class="user-info-wrap">
-		<view class="nav-bar">
-			<view class="nav-content">
-				<view class="nav-info">
-					<view class="nav-desc">
-						<view class="nav-name">
-							<view class="">头像</view>
-						</view>
-					</view>
-					<view @click="uploadImg1(1)" class="arrow-right">
-						<view class="head-img">
-							<image v-if="userInfo.selfPhotoUrl" :src="userInfo.selfPhotoUrl" mode=""></image>
-							<image v-else src="../../static/me/u1796.png" mode=""></image>
-						</view>
-						<!-- <u-icon name="arrow-right" color="#666" size="26"></u-icon> -->
-					</view>
+	<view class="page">
+
+		<view class="outView">
+
+			<form @submit="inputValue">
+
+			<view class="flex-row justify-between bordBot" >
+				<view class="key flex-col justify-center ">
+					<text>头像</text>
 				</view>
+					<button class="photoView" open-type="chooseAvatar" @chooseavatar="chooseavatar">
+						<image class="photoImage" :src="userInfo.selfPhotoUrl || '/static/me/u4.png'"></image>
+					</button>
 			</view>
-			<view class="custom-line"></view>
-			<view class="nav-content">
-				<view class="nav-info">
-					<view class="nav-desc">
-						<view class="nav-name">
-							<view class="">昵称</view>
-						</view>
-						<input class="custom-input" v-model="userInfo.ncikName" type="text" placeholder="请输入昵称">
-					</view>
-					<view class="arrow-right">
-						<!-- <u-icon name="arrow-right" color="#666" size="16"></u-icon> -->
-					</view>
+
+			<view class="flex-row justify-between bordBot" >
+				<view class="key flex-col justify-center ">
+					<text>昵称</text>
 				</view>
-			</view>
-			<view class="custom-line"></view>
-			<view class="nav-content">
-				<view class="nav-info">
-					<view class="nav-desc">
-						<view class="nav-name">
-							<view class="">性别</view>
-						</view>
-					</view>
-					<view @click="chooseGender()" class="arrow-right">
-						<view class="change-store">
-							<text v-if="userInfo.sex == 0">男</text>
-							<text v-else-if="userInfo.sex == 1">女</text>
-							<text v-else-if="userInfo.sex == 2">未知</text>
-							<text v-else>请选择性别</text>
-						</view>
-						<u-icon name="arrow-right" color="#666" size="16"></u-icon>
-					</view>
+				<view class="nikeName flex-col justify-center">
+					<input type="nickname" name="nickname" v-model="userInfo.ncikName"   placeholder="请输入昵称"/>
 				</view>
 			</view>
-			<view class="custom-line"></view>
-			<view class="nav-content">
-				<view class="nav-info">
-					<view class="nav-desc">
-						<view class="nav-name">
-							<view class="">生日</view>
-						</view>
-					</view>
-					<view @click="chooseServiceDate()" class="arrow-right">
-						<view class="change-store">
-							<text v-if="userInfo.birthday">{{userInfo.birthday}}</text>
-							<text v-else>请选择生日</text>
-						</view>
-						<u-icon name="arrow-right" color="#666" size="16"></u-icon>
-					</view>
+
+			<view class="flex-row justify-between bordBot" >
+				<view class="key flex-col justify-center ">
+					<text>性别</text>
 				</view>
-			</view>
-			<view class="custom-line"></view>
-			<view class="nav-content">
-				<view class="nav-info">
-					<view class="nav-desc">
-						<view class="nav-name">
-							<view class="">实名认证</view>
-						</view>
-					</view>
-					<view @click="gotoRealNameAuth()" class="arrow-right">
-						<view class="change-store">
-							<text v-if="userInfo.isAttestation">已认证</text>
-							<text v-else>未实名认证,去认证</text>
-						</view>
-						<u-icon name="arrow-right" color="#666" size="16"></u-icon>
+				<picker class="picker"  @change="genderChange" mode='selector'  range-key="gender" :value="genderIndex" :range="genderList">
+					<view class="flex-row justify-end groupItemContent">
+						<text v-if="userInfo.sex == 0">男</text>
+						<text v-else-if="userInfo.sex == 1">女</text>
+						<text v-else-if="userInfo.sex == 2">未知</text>
+						<text v-else>请选择性别</text>
+						<u-icon name="arrow-right" color="#666" size="18"></u-icon>
 					</view>
+				</picker>
+			</view>
+
+			<view class="flex-row justify-between bordBot" >
+				<view class="key flex-col justify-center ">
+					<text>生日</text>
 				</view>
+				<picker class="picker" @change="birthdayChange" mode='date'  range-key="label" >
+					<view class="flex-row justify-end groupItemContent">
+						<text>{{userInfo.birthday || '请选择出生日期' }}</text>
+						<u-icon name="arrow-right" color="#666" size="18"></u-icon>
+					</view>
+				</picker>
 			</view>
-		</view>
 
-		<view @click="saveUserInfo()" class="sure-btn">
-			<view class="btn">确认</view>
-		</view>
+			<view class="flex-row justify-between bordBot" >
+				<view class="key flex-col justify-center ">
+					<text>实名认证</text>
+				</view>
+				<view class="flex-row justify-end groupItemContent" @click="gotoRealNameAuth">
+					<text>{{userInfo.isAttestation? '已认证' : '未实名认证,去认证' }}</text>
+					<u-icon name="arrow-right" color="#666" size="18"></u-icon>
+				</view>
+			</view>
 
+			<button class="updateButton"  formType="submit">
+				<text>保存</text>
+			</button>
 
-		<!-- 日期时间选择 -->
-		<u-datetime-picker
-			:show="dateShow"
-			v-model="value1"
-			mode="date"
-			@confirm="sureChooseDate()"
-		></u-datetime-picker>
+			</form>
 
-		<!-- 性别选择 -->
-		<u-picker :show="genderShow" keyName="gender"  @confirm="sureChooseGender" :columns="genderList"></u-picker>
 
+		</view>
 	</view>
 </template>
 
@@ -109,27 +75,12 @@
 export default {
 	data() {
 		return {
-			userInfo: {
-				auth: true,
-				ncikName: '',
-				sex: '',
-				birthday: '',
-				selfPhoto: '',
-				selfPhotoUrl: '',
-				memberType: '',
-				isAttestation: ''
-			},
-			genderShow: false,
-			dateShow: false,
-			value1: '2023-12-12',
-			// 服务时间
-			genderList: [
-			  [{gender:'男',id:'0'},
-				{gender:'女',id:'1'},
-				{gender:'未知',id:'2'}
-			  ],
-			],
-			imgUrl1: ''
+			photoUrl:'',
+			userInfo: {},
+			genderIndex:0,
+			genderList: [{gender:'男',id:'0'},
+				  		 {gender:'女',id:'1'},
+						 {gender:'未知',id:'2'}],
 		};
 	},
 	mounted() {
@@ -137,57 +88,47 @@ export default {
 	onLoad() {
 
 		// 用户信息
-		let user = uni.getStorageSync('userInfo')
-		this.userInfo.birthday = user.birthday;
-		this.userInfo.sex = user.sex;
-		this.userInfo.ncikName = user.ncikName;
-		this.userInfo.selfPhoto = user.selfPhoto;
-		this.getImgUrlByOssId(user.selfPhoto)
-		this.userInfo.memberType = user.memberType;
-		this.userInfo.isAttestation = user.isAttestation;
+		this.userInfo = uni.getStorageSync('userInfo')
+
+		if (this.userInfo.selfPhoto){
+			this.getImgUrlByOssId(this.userInfo.selfPhoto)
+		}
+
 
 	},
 	methods: {
 
-		// 选择性别
-		chooseGender(){
-			this.genderShow = true;
-		},
-		// 选择值
-		sureChooseGender(e){
-			this.genderShow = false;
-			this.userInfo.sex = e.value[0].id;
+		inputValue(e){
+			console.log('+++++++++++++inputValue+++++++++++',e)
+			this.userInfo.ncikName = e.detail.value.nickname
+			this.saveUserInfo()
 		},
-		// 确定选择的服务日期
-		sureChooseDate(){
-			this.dateShow = false;
-			this.userInfo.birthday = this.$formatDate(this.value1)
-		},
-		// 选择服务日期
-		chooseServiceDate(){
-			this.value1 = Date.now();
-			this.dateShow = true;
+
+		// 选择性别
+		genderChange(e){
+			console.log(e.detail.value)
+			this.userInfo.sex = e.detail.value
 		},
-		// 去会员信息页
-		gotoMemberInfo(){
 
-			uni.navigateTo({
-				url: '/pages/member/member-info',
-			})
+		//选择的日期
+		birthdayChange(e){
+			console.log(e.detail.value)
+			this.userInfo.birthday = e.detail.value
 		},
+
 		// 去实名认证
 		gotoRealNameAuth(){
 			uni.navigateTo({
-				url: '/pages/me/real-name-auth',
+				url: '/myPages/realNameAuth/index',
 			})
 		},
 		// 保存用户信息
 		saveUserInfo(){
 			// 保存数据
-			this.$api.saveUserInfo(null,{data:this.userInfo}).then((res)=>{
+			this.$api.saveUserInfo(this.userInfo).then((res)=>{
 				console.log(res)
 				// 刷新用户信息
-				this.$refreshUserLoginInfo();
+				this.getUserInfo();
 				uni.showToast({
 					title: "操作成功"
 				})
@@ -200,133 +141,50 @@ export default {
 				})
 			});
 		},
+
+		getUserInfo(){
+			this.$api.getUserInfo().then(res=>{
+				console.log('++++++++++++获取用户信息++++++++++++++++++',res)
+				uni.setStorageSync('userInfo',res.data.data)
+				this.userInfo = res.data.data
+			})
+
+		},
+
 		getImgUrlByOssId(Id){
 			this.$api.getImgUrlByOssId(Id).then(res=>{
 				this.userInfo.selfPhotoUrl = res.data.data[0].url.replace(/^http:/, "https:")
 			});
 		},
 		//头像上传
-		uploadImg1(imgIndex) {
-			let that = this;
-			uni.chooseImage({
-				count: 1,
-				success: (chooseImageRes) => {
-					const tempFilePaths = chooseImageRes.tempFilePaths;
 
-					uni.uploadFile({
-						url: that.$baseUrl + '/resource/oss/upload', //仅为示例,非真实的接口地址
-						filePath: tempFilePaths[0],
-						name: 'file',
-						header: {
-							// "Content-Type": "multipart/form-data",
-							// 'X-Access-Token': uni.getStorageSync('token'),
-							'Authorization': 'Bearer ' + uni.getStorageSync('accessToken'),
-						},
-						success: (uploadFileRes) => {
-							let res = JSON.parse(uploadFileRes.data)
-							console.log(res.data)
-							that.userInfo.selfPhoto = res.data.ossId
-							that.getImgUrlByOssId(res.data.ossId);
-						}
-					});
+		chooseavatar(e){
+			let that = this
+			let avatarUrl =e.detail.avatarUrl
+			console.log(e.detail.avatarUrl)
+			uni.uploadFile({
+				url: that.$baseUrl + '/resource/oss/upload', //仅为示例,非真实的接口地址
+				filePath:avatarUrl,
+				name: 'file',
+				header: {
+					// "Content-Type": "multipart/form-data",
+					// 'X-Access-Token': uni.getStorageSync('token'),
+					'Authorization': 'Bearer ' + uni.getStorageSync('accessToken'),
+				},
+				success: (uploadFileRes) => {
+					let res = JSON.parse(uploadFileRes.data)
+					console.log('+++++++++++++++++chooseavatar+++++++++++++++++++++++',uploadFileRes.data)
+					that.userInfo.selfPhoto=res.data.ossId
+					that.userInfo.selfPhotoUrl = res.data.url.replace(/^http:/, "https:")
 				}
 			});
-		}
+
+		},
 	}
 };
 </script>
 
 <style lang="scss">
-.user-info-wrap{
-	margin-left: 12px;
-	margin-right: 12px;
-	/* 导航菜单 */
-	.nav-bar{
-		background: #fff;
-		border-radius: 10px;
-		margin-top: 12px;
-		/* 商店信息 */
-		.nav-content{
-			padding-top: 10px;
-			padding-bottom: 6px;
-			.nav-info{
-				display: flex;
-				padding-left: 10px;
-				align-items: center;
-				.logo {
-					width: 12%;
-					text-align: center;
-					image{
-						width: 24px;
-						height: 24px;
-					}
-				}
-				.nav-desc{
-					width: 32%;
-					display: flex;
-					line-height: 30px;
-					font-family: PingFangSC-Regular, PingFang SC;
-					font-weight: 400;
-					align-items: center;
-					.custom-input{
-						font-size: 12px;
-					}
-					.nav-name{
-						width: 60%;
-						font-size: 14px;
-
-						color: #333333;
-						line-height: 22px;
-					}
-					.change-store{
-						text-align: right;
-						width: 40%;
-						font-size: 12px;
-						color: #333333;
-						line-height: 22px;
-					}
-				}
-
-				.arrow-right{
-					width:68%;
-					text-align: right;
-					margin: 0 auto;
-					cursor: pointer;
-					padding-top: 3px;
-					display: flex;
-					justify-content: flex-end;
-					align-items: center;
-					image{
-						width: 18px;
-						height: 18px;
-					}
-					.head-img {
-						text-align: center;
-						padding-right: 20px;
-						image{
-							width: 24px;
-							height: 24px;
-						}
-					}
-				}
-			}
-		}
-	}
-
-	.sure-btn{
-		margin-top: 20px;
-		width: 100%;
-		.btn{
-			text-align: center;
-			height: 42px;
-			background: #FFE05C;
-			border-radius: 27px;
-			color: #333333;
-			line-height: 42px;
-			margin-top: 12px;
-			font-size: 14px;
-		}
-	}
-}
-
+	@import '/common/css/common.css';
+	@import './index.rpx.css';
 </style>

+ 247 - 234
orderPages/receiveCoupons/index.vue

@@ -1,271 +1,284 @@
 <template>
-  <view class="order-content-wrap">
+	<view class="order-content-wrap">
 
 
-		  <view class="custom-line"></view>
-		  <!-- 当前订单-->
-		  <view class="service-order">
+<!--		<view class="custom-line"></view>-->
+		<!-- 当前订单-->
+<!--		<view class="service-order">-->
 
 
-			  <!-- 门店列表 -->
-			  <view v-for="(item,index) in countsList" :class="computedStyle(item)" class="store-wrap  bg-img">
-				 <view  class="row-list" >
-					<view  class="store-content">
-						<view class="h-left-content">
-							<view class="h-text">
-								<view class="money">¥{{item.discountsPrice}}</view>
-								<view class="desc">{{item.name}}</view>
-							</view>
-						</view>
-						<view class="h-center-content">
-							<view class="title">
-								<text class="h-value">门店通用</text>
-							</view>
-							<view class="title">
-								使用平台:<text v-if="item.strategyType == '0'">全平台</text>
-								<text v-else-if="item.strategyType == '1'">个人优惠卷</text>
-							</view>
-							<view class="title">
-								有效时间:{{this.dateFormat(item.startTime)}}~{{this.dateFormat(item.endTime)}}
-							</view>
-						</view>
-						<view class="h-right-content">
-							<view class="h-btn">
-								<view @click="gotoReceiveCoupon(item)"  class="h-btn-value-receive">立即领取</view>
-							</view>
-						</view>
-					</view>
-				 </view>
-			  </view>
+<!--			&lt;!&ndash; 门店列表 &ndash;&gt;-->
+<!--			<view v-for="(item,index) in countsList" :class="computedStyle(item)" class="store-wrap  bg-img">-->
+<!--				<view class="row-list">-->
+<!--					<view class="store-content">-->
+<!--						<view class="h-left-content">-->
+<!--							<view class="h-text">-->
+<!--								<view class="money">¥{{item.discountsPrice}}</view>-->
+<!--								<view class="desc">{{item.name}}</view>-->
+<!--							</view>-->
+<!--						</view>-->
+<!--						<view class="h-center-content">-->
+<!--							<view class="title">-->
+<!--								<text class="h-value">门店通用</text>-->
+<!--							</view>-->
+<!--							<view class="title">-->
+<!--								使用平台:<text v-if="item.strategyType == '0'">全平台</text>-->
+<!--								<text v-else-if="item.strategyType == '1'">个人优惠卷</text>-->
+<!--							</view>-->
+<!--							<view class="title">-->
+<!--								有效时间:{{this.dateFormat(item.startTime)}}~{{this.dateFormat(item.endTime)}}-->
+<!--							</view>-->
+<!--						</view>-->
+<!--						<view class="h-right-content">-->
+<!--							<view class="h-btn">-->
+<!--								<view @click="gotoReceiveCoupon(item)" class="h-btn-value-receive">立即领取</view>-->
+<!--							</view>-->
+<!--						</view>-->
+<!--					</view>-->
+<!--				</view>-->
+<!--			</view>-->
 
 
-		  <view v-if="countsList.length == 0"  class="footer">
-			<view class="">---暂无数据---</view>
-		  </view>
-		  <view v-if="countsList.length > 0"  class="footer">
-		  	<view class="">---到底了---</view>
-		  </view>
-    </view>
+<!--			<view v-if="countsList.length == 0" class="footer">-->
+<!--				<view class="">-&#45;&#45;暂无数据-&#45;&#45;</view>-->
+<!--			</view>-->
+<!--			<view v-if="countsList.length > 0" class="footer">-->
+<!--				<view class="">-&#45;&#45;到底了-&#45;&#45;</view>-->
+<!--			</view>-->
+<!--		</view>-->
 
-  </view>
+	</view>
 </template>
- <script>
-export default {
-  data() {
-    return {
-	  currentServiceTab: 'orderTab1', // 当前选中的 Tab
-	  list: [1, 2, 3, 4],
-	  reqParm: {
-		  auth: true,
-		  id: null
-	  },
-	  countsList: []
-    };
-  },
-  onLoad() {
-	// 查询可领取的优惠劵
-	this.getUserDiscountsList();
-  },
-  computed: {
+<script>
+	export default {
+		data() {
+			return {
+				currentServiceTab: 'orderTab1', // 当前选中的 Tab
+				list: [1, 2, 3, 4],
+				reqParm: {
+					auth: true,
+					id: null
+				},
+				countsList: []
+			};
+		},
+		onLoad() {
+			// 查询可领取的优惠劵
+			this.getUserDiscountsList();
+		},
+		computed: {
 
-  },
-  methods: {
-	// 日期格式化
-	dateFormat(date){
-	  let time = Date.parse(date);
-	  return uni.$u.date(time, 'yyyy-mm-dd');
-	},
-	// 查询可领取的优惠劵
-	getUserDiscountsList(){
-		let that = this;
-		// 用户绑定门店
-		this.$api.getUserDiscountsList(this.reqParm).then((res)=>{
-			console.log(res.data.data)
-			this.countsList = res.data.data;
-		}).catch(() =>{
-			uni.showToast({
-				title: "操作失败"
-			})
-		})
-	},
-	computedStyle(item) {
-	   return 'bg-img';
-	},
-	// 切换菜单
-	changeServiceTab(tab){
-	  this.currentServiceTab = tab;
-	},
-	// 领取优惠劵
-	gotoReceiveCoupon(item){
-		let that = this;
-		that.reqParm.id = item.id;
-		// 用户绑定门店
-		this.$api.claimCoupon(this.reqParm).then((res)=>{
-			uni.showToast({
-				title: "领取成功"
-			})
+		},
+		methods: {
+			// 日期格式化
+			dateFormat(date) {
+				let time = Date.parse(date);
+				return uni.$u.date(time, 'yyyy-mm-dd');
+			},
 			// 查询可领取的优惠劵
-			that.getUserDiscountsList();
-			// uni.$u.route({
-			// 	url: '/pages/coupon/coupon',
-			// 	params: {}
-			// })
-		}).catch(() =>{
-			uni.showToast({
-				title: "操作失败"
-			})
-		})
-	},
-	// 去使用优惠劵
-	gotoUseCoupon(){
-		uni.$u.route({
-			url: '/pages/index/tabbar',
-			params: {
-				PageCur: 'goods'
-			}
-		})
-	},
-  },
-};
+			getUserDiscountsList() {
+				let that = this;
+				// 用户绑定门店
+				this.$api.getUserDiscountsList(this.reqParm).then((res) => {
+					console.log(res.data.data)
+					this.countsList = res.data.data;
+				}).catch(() => {
+					uni.showToast({
+						title: "操作失败"
+					})
+				})
+			},
+			computedStyle(item) {
+				return 'bg-img';
+			},
+			// 切换菜单
+			changeServiceTab(tab) {
+				this.currentServiceTab = tab;
+			},
+			// 领取优惠劵
+			gotoReceiveCoupon(item) {
+				let that = this;
+				that.reqParm.id = item.id;
+				// 用户绑定门店
+				this.$api.claimCoupon(this.reqParm).then((res) => {
+					uni.showToast({
+						title: "领取成功"
+					})
+					// 查询可领取的优惠劵
+					that.getUserDiscountsList();
+					// uni.$u.route({
+					// 	url: '/pages/coupon/coupon',
+					// 	params: {}
+					// })
+				}).catch(() => {
+					uni.showToast({
+						title: "操作失败"
+					})
+				})
+			},
+			// 去使用优惠劵
+			gotoUseCoupon() {
+				uni.$u.route({
+					url: '/pages/index/tabbar',
+					params: {
+						PageCur: 'goods'
+					}
+				})
+			},
+		},
+	};
 </script>
- <style lang="scss" scoped>
-
- /* 服务订单内容*/
-.service-order-tab-bar{
-	background: #fff;
-	display: flex;
-	justify-content: space-around;
-	height: 50px;
-	background-color: #f5f5f5;
-	.service-order-tab-item{
-		flex: 1;
+<style lang="scss" scoped>
+	/* 服务订单内容*/
+	.service-order-tab-bar {
+		background: #fff;
 		display: flex;
-		align-items: center;
-		justify-content: center;
-		font-size: 16px;
-		color: #333;
-		line-height: 26px;
+		justify-content: space-around;
+		height: 50px;
+		background-color: #f5f5f5;
+
+		.service-order-tab-item {
+			flex: 1;
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			font-size: 16px;
+			color: #333;
+			line-height: 26px;
+		}
+
+		.service-order-tab-item.active {
+			// color: #ff0000;
+		}
+
+		.underline {
+			border-bottom: 2px solid #FFE05C;
+		}
 	}
-	.service-order-tab-item.active {
-	  // color: #ff0000;
+
+	.bg-img {
+		background-image: url('/static/coupon/u210.png');
+		background-repeat: repeat;
+		height: 94px;
+		margin: 12px;
 	}
 
-	.underline {
-	  border-bottom: 2px solid #FFE05C ;
+	.bg-img1 {
+		background-image: url('/static/coupon/u211.png');
+		background-repeat: repeat;
+		height: 94px;
+		margin: 12px;
 	}
-}
 
-.bg-img{
-	background-image: url('/static/coupon/u210.png');
-	background-repeat: repeat;
-	height: 94px;
-	margin: 12px;
-}
-.bg-img1{
-	background-image: url('/static/coupon/u211.png');
-	background-repeat: repeat;
-	height: 94px;
-	margin: 12px;
-}
+	.service-order {
+		// background: #fff;
+	}
 
-.service-order{
-	// background: #fff;
-}
+	/* 门店列表 */
+	.store-wrap {
+		border-radius: 2px;
+		padding-bottom: 12px;
+		padding-left: 12px;
+		padding-right: 12px;
 
-/* 门店列表 */
-.store-wrap{
-	border-radius: 2px;
-	padding-bottom: 12px;
-	padding-left: 12px;
-	padding-right: 12px;
-	.row-list{
-		.store-content{
-			display: flex;
-			align-items: center;
-			height: 94px;
-			color: #333333;
-			.h-left-content{
-				width: 26%;
-				text-align: center;
-				.h-text{
-					width: 100%;
-					font-weight: 400;
-					line-height: 18px;
-					font-size: 12px;
-					.money{
-						font-size: 18px;
-						font-weight: bold;
-						line-height: 26px;
-					}
-				}
-			}
-			.h-center-content{
-				width: 50%;
-				padding-left: 12px;
-				.title{
-					width: 100%;
-					color: #999999;
-					font-size: 12px;
-					.h-value{
-						font-size: 14px;
-						line-height: 42px;
-						color: #333333;
-					}
-				}
-			}
-			.h-right-content{
-				width: 24%;
+		.row-list {
+			.store-content {
 				display: flex;
-				justify-content: center;
 				align-items: center;
-				background-image: url('/static/coupon/u2102.png');
 				height: 94px;
-				font-size: 12px;
-				.h-btn-value-use{
-					background: #FFE05C;
-					color: #333333;
-					height: 30px;
-					width: 80px;
+				color: #333333;
+
+				.h-left-content {
+					width: 26%;
 					text-align: center;
-					line-height: 30px;
-					border-radius: 15px;
+
+					.h-text {
+						width: 100%;
+						font-weight: 400;
+						line-height: 18px;
+						font-size: 12px;
+
+						.money {
+							font-size: 18px;
+							font-weight: bold;
+							line-height: 26px;
+						}
+					}
 				}
-				.h-btn-value-receive{
-					background: #93D21A;
-					color: #fff;
-					height: 30px;
-					width: 80px;
-					text-align: center;
-					line-height: 30px;
-					border-radius: 15px;
+
+				.h-center-content {
+					width: 50%;
+					padding-left: 12px;
+
+					.title {
+						width: 100%;
+						color: #999999;
+						font-size: 12px;
+
+						.h-value {
+							font-size: 14px;
+							line-height: 42px;
+							color: #333333;
+						}
+					}
 				}
-				.h-btn-img{
+
+				.h-right-content {
+					width: 24%;
 					display: flex;
+					justify-content: center;
 					align-items: center;
-					image{
-						height: 68px;
-						width: 68px;
+					background-image: url('/static/coupon/u2102.png');
+					height: 94px;
+					font-size: 12px;
+
+					.h-btn-value-use {
+						background: #FFE05C;
+						color: #333333;
+						height: 30px;
+						width: 80px;
+						text-align: center;
+						line-height: 30px;
+						border-radius: 15px;
+					}
+
+					.h-btn-value-receive {
+						background: #93D21A;
+						color: #fff;
+						height: 30px;
+						width: 80px;
+						text-align: center;
+						line-height: 30px;
+						border-radius: 15px;
+					}
+
+					.h-btn-img {
+						display: flex;
+						align-items: center;
+
+						image {
+							height: 68px;
+							width: 68px;
+						}
 					}
 				}
 			}
+
 		}
 
 	}
 
-}
-
-/* 产品订单 */
-.product-order{
-	margin-top: 12px;
-}
-
-/* 底部 */
-.footer{
-	margin-top: 30px;
-	height: 120px;
-	font-size: 12px;
-	text-align: center;
-	color: #666;
-}
+	/* 产品订单 */
+	.product-order {
+		margin-top: 12px;
+	}
 
+	/* 底部 */
+	.footer {
+		margin-top: 30px;
+		height: 120px;
+		font-size: 12px;
+		text-align: center;
+		color: #666;
+	}
 </style>

+ 45 - 45
orderPages/useCoupons/index.vue

@@ -1,55 +1,55 @@
 <template>
   <view class="order-content-wrap">
 
-		  <!-- 当前订单-->
-		  <view class="service-order">
+<!--		  &lt;!&ndash; 当前订单&ndash;&gt;-->
+<!--		  <view class="service-order">-->
 
-			  <view @click="noUseCoupon()" class="h-no-use-coupons">
-				  <u-icon name="share-square" color="#333" size="25"></u-icon>
-				  <view class="">
-					  <text>不使用优惠券</text>
-				  </view>
-			  </view>
+<!--			  <view @click="noUseCoupon()" class="h-no-use-coupons">-->
+<!--				  <u-icon name="share-square" color="#333" size="25"></u-icon>-->
+<!--				  <view class="">-->
+<!--					  <text>不使用优惠券</text>-->
+<!--				  </view>-->
+<!--			  </view>-->
 
-			  <view v-for="(item,index) in countsList" :class="computedStyle(item)" class="store-wrap  bg-img">
-				 <view  class="row-list" >
-					<view @click="useCoupon(item)"  class="store-content">
-						<view class="h-left-content">
-							<view class="h-text">
-								<view class="money">¥{{item.discountsPrice}}</view>
-								<view class="desc">{{item.name}}</view>
-							</view>
-						</view>
-						<view class="h-center-content">
-							<view class="title">
-								<text class="h-value">门店通用</text>
-							</view>
-							<view class="title">
-								使用平台:全平台
-							</view>
-							<view class="title">
-								有效时间:{{this.dateFormat(item.startTime)}}~{{this.dateFormat(item.endTime)}}
-							</view>
-						</view>
-						<view class="h-right-content">
-							<u-icon v-if="item.id == couponIds" name="checkmark-circle" color="#333" size="25"></u-icon>
-							<view v-else class="no-checked"></view>
-							<view class="h-btn">
-								<!-- <view @click="useCoupon(item)"  class="h-btn-value-receive">选择使用</view> -->
-							</view>
-						</view>
-					</view>
-				 </view>
-			  </view>
+<!--			  <view v-for="(item,index) in countsList" :class="computedStyle(item)" class="store-wrap  bg-img">-->
+<!--				 <view  class="row-list" >-->
+<!--					<view @click="useCoupon(item)"  class="store-content">-->
+<!--						<view class="h-left-content">-->
+<!--							<view class="h-text">-->
+<!--								<view class="money">¥{{item.discountsPrice}}</view>-->
+<!--								<view class="desc">{{item.name}}</view>-->
+<!--							</view>-->
+<!--						</view>-->
+<!--						<view class="h-center-content">-->
+<!--							<view class="title">-->
+<!--								<text class="h-value">门店通用</text>-->
+<!--							</view>-->
+<!--							<view class="title">-->
+<!--								使用平台:全平台-->
+<!--							</view>-->
+<!--							<view class="title">-->
+<!--								有效时间:{{this.dateFormat(item.startTime)}}~{{this.dateFormat(item.endTime)}}-->
+<!--							</view>-->
+<!--						</view>-->
+<!--						<view class="h-right-content">-->
+<!--							<u-icon v-if="item.id == couponIds" name="checkmark-circle" color="#333" size="25"></u-icon>-->
+<!--							<view v-else class="no-checked"></view>-->
+<!--							<view class="h-btn">-->
+<!--								&lt;!&ndash; <view @click="useCoupon(item)"  class="h-btn-value-receive">选择使用</view> &ndash;&gt;-->
+<!--							</view>-->
+<!--						</view>-->
+<!--					</view>-->
+<!--				 </view>-->
+<!--			  </view>-->
 
-		  <view v-if="countsList.length == 0"  class="footer">
-		  	 <view class="">---暂无数据---</view>
-		  </view>
+<!--		  <view v-if="countsList.length == 0"  class="footer">-->
+<!--		  	 <view class="">-&#45;&#45;暂无数据-&#45;&#45;</view>-->
+<!--		  </view>-->
 
-		  <view v-if="countsList.length > 0"  class="footer">
-		  	<view class="">---到底了---</view>
-		  </view>
-    </view>
+<!--		  <view v-if="countsList.length > 0"  class="footer">-->
+<!--		  	<view class="">-&#45;&#45;到底了-&#45;&#45;</view>-->
+<!--		  </view>-->
+<!--    </view>-->
 
   </view>
 </template>

+ 1 - 1
pages/index/index.vue

@@ -187,7 +187,7 @@
 						<view class="custom-line"></view>
 						<!-- 门店列表 -->
 						<view class="store-wrap ">
-							<view class="store-list" v-for="item in 1">
+							<view class="store-list">
 								<view class="store-content">
 									<view class="store-img">
 										<image src="../../static/logo.png" mode=""></image>

+ 1 - 1
pages/order/module/mescrollUni-item.vue

@@ -8,7 +8,7 @@
 	<mescroll-uni :ref="'mescrollRef' + i" @init="mescrollInit" :height="height" :down="downOption" @down="downCallback"
 		:up="upOption" @up="upCallback" @emptyclick="emptyClick">
 		<view>
-			<view class="service-order " v-for="(item,index) in list" >
+			<view class="service-order " v-for="(item,index) in list" :key="index">
 				<!-- 门店列表 -->
 				<view class="store-wrap" >
 					<view :class="{ 'grayscale': item.forstStatus === '1' }">

BIN
static/me/u4.png