فهرست منبع

commit -m 采美豆改版

zhengjinyi 4 سال پیش
والد
کامیت
cd802a2d33
5فایلهای تغییر یافته به همراه27 افزوده شده و 16 حذف شده
  1. 18 7
      components/cm-module/creatOrder/freight.vue
  2. 2 2
      pages/tabBar/home/index.vue
  3. 3 3
      pages/user/order/create-order.vue
  4. 2 2
      services/ajax.env.js
  5. 2 2
      services/config.env.js

+ 18 - 7
components/cm-module/creatOrder/freight.vue

@@ -13,8 +13,8 @@
 				</view>
 			</view>
 			<view class="freight-bean" v-if="isBeansShow">
-				<view class="bean-le" v-if="freightData.freePostFlag == 1">可用{{ freightBeansMoney*100 }}采美豆抵用{{ freightBeansMoney }}元运费</view>
-				<view class="bean-le" v-if="freightData.freePostFlag == -1">可用{{ freightBeansMoney*100 }}采美豆抵用{{ freightMoney }}运费</view>
+				<view class="bean-le" v-if="freightData.freePostFlag == 1">可用{{ deductionBeans }}采美豆抵用{{ freightBeansMoney }}元运费</view>
+				<view class="bean-le" v-if="freightData.freePostFlag == -1">可用{{ deductionBeans }}采美豆抵用{{ freightBeansMoney }}运费</view>
 				<view class="bean-ri">
 					<view class="checkbox-box">
 						<button class="checkbox iconfont"
@@ -49,6 +49,7 @@
 				ischecked:false,
 				isBeansShow:false,
 				userBeans:0,
+				deductionBeans:0,
 				freightBeansMoney:0,
 				
 			}
@@ -75,23 +76,33 @@
 						this.userBeans = res.userBeans
 						this.freePostFlag = res.freePostFlag
 						this.optionList.unshift(this.orderPriceToFixed(this.freightMoney))
-						if( res.userBeans >= this.freightMoney*100 ){
+						if( res.userBeans > 0 ){
 							this.isBeansShow = true
 						}else{
 							this.isBeansShow = false
 						}
+						if(res.userBeans >= this.freightBeansMoney*100){
+							this.deductionBeans = this.freightBeansMoney*100
+						}else{
+							this.deductionBeans = res.userBeans
+						}
 						break
 					case -1:
 						this.freightText = '到付'
 						this.userBeans = res.userBeans
 						this.freePostFlag = res.freePostFlag
 						this.freightData.freight  = 0
-						if( res.userBeans >= 3000 ){
-							this.freightBeansMoney = 30
+						this.freightBeansMoney = 30
+						if( res.userBeans >0 ){
 							this.isBeansShow = true
 						}else{
 							this.isBeansShow = false
 						}
+						if(res.userBeans >= this.freightBeansMoney*100){
+							this.deductionBeans = this.freightBeansMoney*100
+						}else{
+							this.deductionBeans = res.userBeans
+						}
 						break
 				}
 			},
@@ -104,7 +115,7 @@
 							case 0:
 								self.freightMoney = self.infoData.freight
 								self.freePostFlag = 1
-								if( self.userBeans >= self.freightMoney*100 ){
+								if( self.userBeans > 0 ){
 									self.isBeansShow = true
 									self.freightBeansMoney = self.freightMoney
 								}else{
@@ -115,7 +126,7 @@
 							case 1:
 								self.freePostFlag = -1
 								self.freightMoney = '到付'
-								if( self.userBeans >= 3000 ){
+								if( self.userBeans > 0 ){
 									self.freightBeansMoney = 30
 									self.isBeansShow = true
 								}else{

+ 2 - 2
pages/tabBar/home/index.vue

@@ -78,8 +78,8 @@
 				isRequest:false,
 				isNavRequest:false,
 				isLiveRequest:false,
-				isActivityBean:true,
-				beansType:12,
+				isActivityBean:false,
+				beansType:1,
 				beanNumber:50,
 			}
 		},

+ 3 - 3
pages/user/order/create-order.vue

@@ -180,7 +180,7 @@
 					this.hanldFreePostFlag = response.data.freePostFlag
 					this.hanldFreight = response.data.freight
 					if(this.hanldFreePostFlag == 1){
-						if( this.freightData.userBeans >= this.hanldFreight*100 ){
+						if( this.freightData.userBeans > 0 ){
 							this.freightBeansMoney = this.hanldFreight
 						}else{
 							this.freightBeansMoney = 0
@@ -189,7 +189,7 @@
 						this.attributePallPrice()
 						this.hanldFreightBeans(this.isCheckedBeans)
 					}else{
-						if( this.freightData.userBeans >= 3000 ){
+						if( this.freightData.userBeans > 0 ){
 							this.freightBeansMoney = 30
 						}else{
 							this.freightBeansMoney = 0
@@ -247,7 +247,7 @@
 				this.isCheckedBeans = data;
 				if(this.isCheckedBeans){
 					// 判断如果采美豆大于等于运费*100
-					if( this.freightData.userBeans >= this.hanldFreight*100 ){
+					if( this.freightData.userBeans > 0 ){
 						this.hanldUserBeans = this.freightBeansMoney*100
 					}else{
 						this.hanldUserBeans = 0

+ 2 - 2
services/ajax.env.js

@@ -2,10 +2,10 @@ let URL_CONFIG = ''
 if(process.env.NODE_ENV === 'development'){
     // 开发环境
 	// URL_CONFIG = 'http://192.168.2.68:8008'	 //涛涛联调地址
-	// URL_CONFIG = 'http://192.168.2.67:8008'	 //裴裴联调地址
+	URL_CONFIG = 'http://192.168.2.67:8008'	 //裴裴联调地址
 	// URL_CONFIG = 'http://192.168.2.81:8008'
 	// URL_CONFIG = 'http://192.168.2.75:8008'	 //超超联调地址
-    URL_CONFIG = 'https://spi-b.caimei365.com'	 //采美测试地址
+    // URL_CONFIG = 'https://spi-b.caimei365.com'	 //采美测试地址
 	// URL_CONFIG = 'https://spi.caimei365.com'
 }else{
     // 生产环境

+ 2 - 2
services/config.env.js

@@ -2,8 +2,8 @@ let URL_CONFIG = ''
 if(process.env.NODE_ENV === 'development'){
     // 开发环境
     // URL_CONFIG = 'http://192.168.2.75:18002'	 //超超联调地址
-	// URL_CONFIG = 'http://192.168.2.67:18002'	 //裴裴联调地址
-	URL_CONFIG = 'https://core-b.caimei365.com'
+	URL_CONFIG = 'http://192.168.2.67:18002'	 //裴裴联调地址
+	// URL_CONFIG = 'https://core-b.caimei365.com'
 	// URL_CONFIG = 'https://core.caimei365.com'
 }else{
     // 生产环境