Browse Source

【Mod】推分享标题修改,优惠券缺陷修复,轮播图尺寸适配问题修复

liuxiangxin 7 tháng trước cách đây
mục cha
commit
f1da901cdf

+ 2 - 2
pages.json

@@ -163,12 +163,12 @@
 			"pagePath": "pages/score/index",
 			"iconPath": "static/tabbar/score.png",
 			"selectedIconPath": "static/tabbar/score_active.png",
-			"text": "积分"
+			"text": "积分兑换"
 		}, {
 			"pagePath": "pages/score/clockin",
 			"iconPath": "static/tabbar/clockin.png",
 			"selectedIconPath": "static/tabbar/clockin_active.png",
-			"text": "签到"
+			"text": "积分签到"
 		},{
 			"pagePath": "pages/car/index",
 			"iconPath": "static/icon/car.png",

+ 7 - 1
pages/car/index.vue

@@ -71,6 +71,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 登录提示
 			if( !this.$checkAccess.alterLogin() )  return ;
@@ -292,7 +298,7 @@
 				.car_name{
 					max-height: 80rpx;
 					font-size: 30rpx;
-					line-height: 50rpx;
+					line-height: 40rpx;
 					overflow: hidden;
 				}
 				.car_spec{

+ 18 - 4
pages/index/index.vue

@@ -5,7 +5,7 @@
 			<view class="banner_list" v-if="bannerList.length">
 				<swiper class="banner_swiper" :autoplay="true" >
 					<swiper-item v-for="(item,index) in bannerList" :key="index">
-						<image :src="item.thumb" mode="widthFix"  @click="navLottery(item.link_url)"></image>
+						<image :src="item.thumb" class="image" @click="navLottery(item.link_url)"></image>
 					</swiper-item>
 				</swiper>
 			</view>
@@ -74,6 +74,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 是否显示价格
 			this.isShowPrice 		= this.$checkAccess.checkShowPrice();
@@ -278,12 +284,20 @@
 		margin-top: 120rpx;
 		.banner_list{
 			display: block;
-			max-width: 680rpx;
+			width: 680rpx;
+			height: 382rpx;
+			line-height: 382rpx;
 			text-align: center;
 			.banner_swiper{
 				display: block;
-				max-width: 680rpx;
+				width: 680rpx;
+				height: 382rpx;
+				line-height: 382rpx;
 				text-align: center;
+				.image{
+					width: 680rpx;
+					height: 382rpx;
+				}
 			}
 		}
 	}
@@ -303,7 +317,7 @@
 				display: block;
 				overflow: hidden;
 				margin: 20rpx 0rpx;
-				margin-right: 20rpx;
+				margin-right: 40rpx;
 				background-color: #FFFFFF;
 				border-radius: 20rpx;
 				.product_image{

+ 16 - 8
pages/orders/completion.vue

@@ -18,10 +18,10 @@
 		</view>
 		<view class="lotteryinfo" v-if="this.islotteryinfo">
 			<view class="lottery_title">恭喜您预约成功,诚邀您参与以下活动</view>
-			<view class="banner">
-				<swiper class="swiper" :autoplay="true" >
+			<view class="banner_list">
+				<swiper class="banner_swiper" :autoplay="true" >
 					<swiper-item v-for="(item,index) in orderBannerList" :key="index">
-						<image class="swiper_item_img" :src="item.thumb" mode="widthFix"  @click="navLottery(item.link_url)"></image>
+						<image class="image" :src="item.thumb" @click="navLottery(item.link_url)"></image>
 					</swiper-item>
 				</swiper>
 			</view>
@@ -141,7 +141,7 @@
 			}
 		}
 		.lotteryinfo{
-			width: 630rpx;
+			width: 680rpx;
 			overflow: hidden;
 			margin: 50rpx auto;
 			.lottery_title{
@@ -151,14 +151,22 @@
 				line-height: 60rpx;
 				text-align: center;
 			}
-			.banner{
+			.banner_list{
 				display: block;
-				max-width: 630rpx;
+				width: 680rpx;
+				height: 382rpx;
+				line-height: 382rpx;
 				text-align: center;
-				.swiper{
+				.banner_swiper{
 					display: block;
-					max-width: 630rpx;
+					width: 680rpx;
+					height: 382rpx;
+					line-height: 382rpx;
 					text-align: center;
+					.image{
+						width: 680rpx;
+						height: 382rpx;
+					}
 				}
 			}
 		}

+ 1 - 1
pages/orders/index.vue

@@ -38,7 +38,7 @@
 					<uni-icons :type="item.contents_class?'up':'down'" size="20" ></uni-icons>
 				</view>
 				<view class="order_price">
-					<span>¥{{item.price_total}}</span>
+					<span>¥{{item.pay_total}}</span>
 				</view>
 			</view>
 		</view>

+ 41 - 26
pages/product/index.vue

@@ -80,16 +80,16 @@
 					</view>
 				</view>
 				<view class="select_sku" >
-					<view class="product_attr" v-for="(spec,spec_index) in productInfo.product_attr" :key="spec_index">
-						<view class="spec_name">{{ spec.spec_name }}</view>
-						<view class="arrt_list">
-							<scroll-view scroll-y="true" class="scroll_y" >
-								<view class="arrt_option" :class="option.active?'active':''" v-for="(option,attr_index) in spec.attr_list" :key="attr_index" @click="attrChange(spec_index,attr_index)">
-									{{option.name}}
-								</view>
-							</scroll-view>
+					<scroll-view scroll-y="true" class="scroll_y" >
+						<view class="product_attr" v-for="(spec,spec_index) in productInfo.product_attr" :key="spec_index">
+							<view class="spec_name">{{ spec.spec_name }}</view>
+							<view class="arrt_list">
+									<view class="arrt_option" :class="option.active?'active':''" v-for="(option,attr_index) in spec.attr_list" :key="attr_index" @click="attrChange(spec_index,attr_index)">
+										{{option.name}}
+									</view>
+							</view>
 						</view>
-					</view>
+					</scroll-view>
 				</view>
 				<!-- 选择优惠券 -->
 				<view class="to_select_coupon" v-if="specBtnType==1" @click="openCoupon()">
@@ -255,6 +255,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 没有添加客服就不显示
 			this.isShowPrice = this.$checkAccess.checkShowPrice();
@@ -457,14 +463,15 @@
 			checkCoupon(){
 				// 如果存在的话
 				if( this.couponList.length ){
+					let hasIsStd = false;
 					// 循环优惠券
 					for (let i in this.couponList) {
 						/* 商品的总价格,决定是否可用 */
-						var totalPrice	 = 0.00;
+						let totalPrice	 = 0.00;
 						// 如果是商品券
 						if( this.couponList[i].type_id == 1 ){
 							// 判断商品是不是在商品范围
-							var isScope = false;
+							let isScope = false;
 							// 循环商品范围
 							for (let k in this.couponList[i].product_scope) {
 								// 如果存在商品范围
@@ -478,7 +485,9 @@
 							totalPrice				= this.$decimal.add(totalPrice,this.$decimal.mul(this.productInfo.price,this.quantity));
 						}
 						// 判断价格到不到限额
-						this.couponList[i].is_std	= totalPrice.toFixed() >= this.$decimal.mul(this.couponList[i].std_pay,1).toFixed();
+						this.couponList[i].is_std	= parseFloat(totalPrice.toFixed()) >= parseFloat(this.$decimal.mul(this.couponList[i].std_pay,1).toFixed());
+						// 如果不可用的话,该项已选择则不选
+						if( !this.couponList[i].is_std && this.couponList[i].checked )	this.checkedCoupon(i);
 					}
 				}
 			},
@@ -540,7 +549,7 @@
 						totalPrice				= this.$decimal.mul(this.productInfo.price,this.quantity);
 					}
 					// 如果是可以用的话
-					if( totalPrice.toFixed() >= this.$decimal.mul(this.couponList[i].std_pay,1).toFixed() ){
+					if( parseFloat(totalPrice.toFixed())  >= parseFloat(this.$decimal.mul(this.couponList[i].std_pay,1).toFixed()) ){
 						// 扣减金额
 						let rebatePrice = this.$decimal.mul(1,0);
 						// 满减
@@ -677,6 +686,8 @@
 						this.sku_id 		= this.productInfo.product_sku[k].id;
 						// 计算价格
 						this.priceHandler();
+						// 优惠券是否可用
+						this.checkCoupon();
 					}else{
 						var attr_ids = this.productInfo.product_sku[0].attr_ids.split(",");
 						// 循环规格列表
@@ -702,6 +713,8 @@
 						this.sku_id = this.productInfo.product_sku[0].id;
 						// 计算价格
 						this.priceHandler();
+						// 优惠券是否可用
+						this.checkCoupon();
 					}
 				}
 			},
@@ -775,6 +788,8 @@
 						this.sku_id = this.productInfo.product_sku[i].id;
 						// 计算价格
 						this.priceHandler();
+						// 优惠券是否可用
+						this.checkCoupon();
 					}
 					// 如果没有对应的SKU
 					if( !haveSku ){
@@ -1170,21 +1185,21 @@
 				font-size: 28rpx;
 				padding: 30rpx 35rpx;
 				margin-bottom: 20rpx;
-				.product_attr{
-					display: block;
-					overflow: hidden;
-					margin-bottom: 20rpx;
-					.spec_name{
-						display: block;
-						font-size: 28rpx;
-						line-height: 40rpx;
-						margin-bottom: 20rpx;
-					}
-					.arrt_list{
+				.scroll_y{
+					height: 240rpx;
+					.product_attr{
 						display: block;
 						overflow: hidden;
-						.scroll_y{
-							height: 240rpx;
+						margin-bottom: 20rpx;
+						.spec_name{
+							display: block;
+							font-size: 28rpx;
+							line-height: 40rpx;
+							margin-bottom: 20rpx;
+						}
+						.arrt_list{
+							display: block;
+							overflow: hidden;
 							.arrt_option{
 								float: left;
 								height: 40rpx;

+ 6 - 0
pages/score/clockin.vue

@@ -81,6 +81,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 请求打卡列表
 			this.getClockinList();

+ 7 - 1
pages/score/index.vue

@@ -51,6 +51,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 没有数据的话,或者请求中,不允许刷新
 			if( this.isReqing )		return ;
@@ -217,7 +223,7 @@
 				display: block;
 				overflow: hidden;
 				margin: 20rpx 0rpx;
-				margin-right: 20rpx;
+				margin-right: 40rpx;
 				background-color: #FFFFFF;
 				border-radius: 20rpx;
 				.product_image{

+ 6 - 0
pages/score/product.vue

@@ -145,6 +145,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 如果存在产品ID的话
 			if( this.requestParam.id > 0) {

+ 3 - 3
pages/user/follow.vue

@@ -5,11 +5,11 @@
 				<view class="close_area">
 					<!-- <button class="close_btn" @click="closeAddFollow()">关闭</button> -->
 				</view>
-				<view class="info_alter">长按识别二维码添加客服</view>
 				<view class="qr_code_area">
 					<image v-if="followQrcode" :src="followQrcode" class="qr_code" mode="" show-menu-by-longpress></image>
 				</view>
-				<button class="save_btn" @click="saveImage()">保存图片添加客服</button>
+				<view class="info_alter">长按识别二维码添加客服</view>
+				<!-- <button class="save_btn" @click="saveImage()">保存图片添加客服</button> -->
 			</view>
 		</uni-popup>
 	</view>
@@ -69,7 +69,7 @@
 			display: block;
 			color: #FFFFFF;
 			width: 700rpx;
-			height: 1100rpx;
+			height: 800rpx;
 			margin: 0 auto;
 			font-size: 26rpx;
 			border-radius: 40rpx;

+ 7 - 1
pages/user/index.vue

@@ -20,7 +20,7 @@
 		<view class="navigator_list">
 			<navigator class="navigator_item" url="/pages/orders/index" >
 				<image class="navigator_image" src="../../static/icon/orders.png" mode=""></image>
-				<view class="navigator_title">预 约</view>
+				<view class="navigator_title">预约报单</view>
 			</navigator>
 			<navigator class="navigator_item" url="/pages/coupon/index" >
 				<image class="navigator_image" src="../../static/icon/coupon.png" mode=""></image>
@@ -57,6 +57,12 @@
 			})
 			// #endif
 		},
+		onShareAppMessage(obj) {
+			return {
+			  title: '为您提供优秀的数据营销服务和解决方案',
+			  path: '/pages/index/index'
+			}
+		},
 		onShow() {
 			// 登录提示
 			if( !this.$checkAccess.alterLogin() ) return ;

+ 1 - 1
utils/request.js

@@ -2,7 +2,7 @@
 var domain = 'https://kailin.dfwy.tech/'
 // #ifdef MP-WEIXIN
 // 'http://127.0.0.1:8000/';
-domain = 'https://mall.findit.ltd/';//uni.getAccountInfoSync().miniProgram.envVersion == 'release' ? 'https://mall.findit.ltd/' : 'https://kailin.dfwy.tech/';
+domain = uni.getAccountInfoSync().miniProgram.envVersion == 'release' ? 'https://mall.findit.ltd/' : 'https://kailin.dfwy.tech/';
 // #endif
 
 // 发送网络请求的函数