ソースを参照

修改会员价显示方式

gcz 2 年 前
コミット
1e4b2c7fc8

+ 7 - 7
common/config.js

@@ -12,15 +12,15 @@
 // }
 
 //64
-// let baseUrl='https://xusfoodapi.hw.hongweisoft.com/appapi/app';
-// let upFileUrl='http://fileupload.hw.hongweisoft.com/upload/single/minio';
-// // let staticUrl='http://res.hw.hongweisoft.com/xushuo/';
-// let staticUrl='https://xusapi.gzxsjt.cn/miniores/imgs/app';
+let baseUrl='https://xusfoodapi.hw.hongweisoft.com/appapi/app';
+let upFileUrl='http://fileupload.hw.hongweisoft.com/upload/single/minio';
+// let staticUrl='http://res.hw.hongweisoft.com/xushuo/';
+let staticUrl='https://xusapi.gzxsjt.cn/miniores/imgs/app';
 
 //正式
-let baseUrl='https://xusapi.gzxsjt.cn/appapi/app';
-let upFileUrl='https://xusapi.gzxsjt.cn/thirdapi/upload/single/minio';
-let staticUrl='https://xusapi.gzxsjt.cn/miniores/imgs/app';
+// let baseUrl='https://xusapi.gzxsjt.cn/appapi/app';
+// let upFileUrl='https://xusapi.gzxsjt.cn/thirdapi/upload/single/minio';
+// let staticUrl='https://xusapi.gzxsjt.cn/miniores/imgs/app';
 
 const commonConfig = {
 	wxAppid: '', // 测试wxAppid

+ 5 - 5
pages/index/index.vue

@@ -98,13 +98,13 @@
 					<view class="product-v2" @click="$u.route('/shopping/productdetails',{id:item.id})" v-for="item in hotGoods" :key="item.id">
 						<u--image :showLoading="true" :src="item.mainImg" width="100%" height="280rpx"></u--image>
 						<view class="name ellipsis-2">{{item.goodsName}}</view>
-						<view class="price u-flex">
-							<view class="myprice" v-if="vuex_member_info.priceType>1">
+						<view class="price">
+							<view class="myprice u-flex">
 								¥ <text class="price-num">{{item.vipPrice}}</text>
-								<text class="gray line-through">{{item.salePrice}}</text>
+								<text class="price-type">会员价</text>
 							</view>
-							<view class="myprice" v-else>
-								¥ <text class="price-num">{{item.salePrice}}</text>
+							<view class="salePrice">
+								<text class="gray line-through">{{item.salePrice}}</text>
 							</view>
 						</view>
 					</view>

+ 7 - 6
shopping/producTypetList.vue

@@ -67,18 +67,19 @@
 									<view class="u-flex u-row-between">
 										<view class="left">
 											<view class="up">
-												<view class="" v-if="vuex_member_info.priceType>1">
+												<view class="u-flex">
 													<text class="price">¥ <text class="price-num">{{item.vipPrice}}</text></text>
-													<text class="vip-icon">VIP</text>
+													<!-- <text class="vip-icon">VIP</text> -->
+													<text class="price-type">会员价</text>
 												</view>
-												<view class="" v-else>
+												<!-- <view class="" v-else>
 													<text class="price">¥ <text class="price-num">{{item.salePrice}}</text></text>
-												</view>
+												</view> -->
 											</view>
 											<view class="down">
 												<!-- <text class="discount">8.8折</text> -->
-												<text v-if="vuex_member_info.priceType>1" class="original-price gray line-through">¥ {{item.salePrice}}</text>
-												<text class="sales gray">销量 {{item.saleCount}}</text>
+												<text class="original-price gray line-through">¥ {{item.salePrice}}</text>
+												<!-- <text class="sales gray">销量 {{item.saleCount}}</text> -->
 											</view>
 										</view>
 										<u--image :showLoading="false" @click.native.stop="addCart(item.id)" :src="staticUrl+'/img/add.png'" width="48rpx" height="48rpx"></u--image>

+ 6 - 5
shopping/productList.vue

@@ -27,17 +27,18 @@
 							<view class="u-flex u-row-between">
 								<view class="left">
 									<view class="up">
-										<view class="" v-if="vuex_member_info.priceType>1">
+										<view class="u-flex" >
 											<text class="price">¥ <text class="price-num">{{item.vipPrice}}</text></text>
-											<text class="vip-icon">VIP</text>
+											<!-- <text class="vip-icon">VIP</text> -->
+											<text class="price-type">会员价</text>
 										</view>
-										<view class="" v-else>
+										<!-- <view class="" v-else>
 											<text class="price">¥ <text class="price-num">{{item.salePrice}}</text></text>
-										</view>
+										</view> -->
 									</view>
 									<view class="down">
 										<!-- <text class="discount">8.8折</text> -->
-										<text v-if="vuex_member_info.priceType>1" class="original-price gray line-through">¥ {{item.salePrice}}</text>
+										<text class="original-price gray line-through">¥ {{item.salePrice}}</text>
 										<text class="sales gray">
 											<text v-if="typeName=='特价专区'">抢购量</text>
 											<text v-else>销量</text>

+ 11 - 6
shopping/productdetails.vue

@@ -26,19 +26,23 @@
 		</u-swiper>
 		<view class="product-info view-wrap">
 			<view class="red">
-				<view class="" v-if="vuex_member_info.priceType>1">
+				<view class="u-flex">
 					<text class="price">¥ <text class="price-num">{{details.vipPrice}}</text></text>
-					<text class="vip-icon">VIP</text>
-					<text class="exchangeCredit" v-if="details.isCredit==1">+{{details.exchangeCredit}}积分</text>
+					<text class="price-type" style="margin-left: 20rpx;">会员价</text>
+					<!-- <text class="vip-icon">VIP</text> -->
+					<view class="exchangeCredit u-flex" v-if="details.isCredit==1">
+						+{{details.exchangeCredit}} 
+						<text style="font-size: 30rpx;">积分</text>
+					</view>
 				</view>
-				<view class="" v-else>
+				<!-- <view class="" v-else>
 					<text v-if="details.isCredit==1&&details.exchangeType==0" class="price">¥ <text class="price-num">0</text></text>
 					<text v-else class="price">¥ <text class="price-num">{{details.salePrice}}</text></text>
 					<text class="exchangeCredit" v-if="details.isCredit==1">+{{details.exchangeCredit}}积分</text>
-				</view>
+				</view> -->
 			</view>
 			<view class="u-flex u-row-between gray">
-				<text v-if="vuex_member_info.priceType>1" class="line-through">¥ <text class="">{{details.salePrice}}</text></text>
+				<text class="line-through">¥ <text class="">{{details.salePrice}}</text></text>
 				<text class="">库存 {{details.stock}}</text>
 			</view>
 			<view class="name">{{details.goodsName}}</view>
@@ -496,6 +500,7 @@
 .product-info{
 	.price-num{
 		font-size: 60rpx;
+		font-family: PingFangSC-Semibold, PingFang SC;
 	}
 	.exchangeCredit{
 		font-size: 60rpx;

+ 18 - 1
uni.scss

@@ -195,12 +195,18 @@ page{
 		}
 		.price{
 			color: $uni-text-color-red;
+			font-family: PingFangSC-Regular, PingFang SC;
 		}
 		.price-num{
 			font-size: 40rpx;
 			font-weight: bold;
 			margin-left: 2px;
 		}
+		.price-type{
+			color: #FF3C3F;
+			font-size: 22rpx;
+			margin-left: 20rpx;
+		}
 		.original-price{
 			
 		}
@@ -292,17 +298,28 @@ page{
 			font-size: 20rpx;
 			font-weight: 600;
 			color: #00A447;
+			font-family: PingFangSC-Regular, PingFang SC;
 			.price-num{
 				font-size: 30rpx;
 				font-weight: 600;
 				margin-left: 5rpx;
 			}
 			.gray{
-				margin-left: 21rpx;
 				font-size: 22rpx;
 				font-weight: 400;
 				color: #999999;
 			}
+			.price-type{
+				font-size: 20rpx;
+				font-family: PingFangSC-Regular, PingFang SC;
+				font-weight: 400;
+				color: #FFFFFF;
+				line-height: 28rpx;
+				padding: 0 9rpx;
+				background: #D6996C;
+				border-radius: 6rpx;
+				margin-left: 20rpx;
+			}
 		}
 	}
 }