浏览代码

机构用户类型优化

zhengjinyi 5 年之前
父节点
当前提交
c9811b7f26

+ 3 - 3
pages/tabBar/cart/cart.vue

@@ -427,14 +427,14 @@
 			},
 			processActivityPrice(pros){//单独处理活动价格和阶梯价格
 				let ladderPriceList = pros.ladderPriceList;
-				if(pros.ladderPriceFlag == '0' || pros.actStatus == 1){
-					pros.retailPrice = pros.retailPrice
-				}else{
+				if(pros.ladderPriceFlag == '1'){
 					ladderPriceList.forEach((item,index)=>{
 						if(pros.productCount>=item.buyNum){
 							pros.retailPrice = item.buyPrice
 						}
 					})
+				}else{
+					pros.retailPrice = pros.retailPrice
 				}
 			},
 			updateShoppogNum(pros){//加减购物车商品更新到后台

+ 14 - 14
pages/user/regularPurchase/regularPurchase.vue

@@ -82,13 +82,7 @@
 			},
 			changeCountAdd(){//popup弹窗数量增加按钮
 				this.number++
-				if(this.handleData.ladderPriceFlag == '1'){
-					this.handleData.ladderPriceList.forEach((item,index)=>{
-						if(this.number>=item.buyNum){
-							this.buyRetailPrice = item.buyPrice
-						}
-					})
-				}
+				this.calculatPerice()
 			},
 			changeCountSub(){//popup弹窗数量减按钮
 				if(this.number<=this.minBuyNumber){
@@ -98,13 +92,7 @@
 					return
 				}else{
 					this.number--
-					if(this.handleData.ladderPriceFlag == '1'){
-						this.handleData.ladderPriceList.forEach((item,index)=>{
-							if(this.number>=item.buyNum){
-								this.buyRetailPrice = item.buyPrice
-							}
-						})
-					}
+					this.calculatPerice()
 					this.isQuantity =false
 				}
 			 },
@@ -117,6 +105,18 @@
 					this.number = this.minBuyNumber
 				}else{
 					this.number = e.detail.value
+					this.calculatPerice()
+				}
+			},
+			calculatPerice(){//判断是否为阶梯价然后做计算价格处理
+				if(this.handleData.ladderPriceFlag == '1'){
+					this.handleData.ladderPriceList.forEach((item,index)=>{
+						if(this.number>=item.buyNum){
+							this.buyRetailPrice = item.buyPrice
+						}
+					})
+				}else{
+					this.buyRetailPrice = this.handleData.retailPrice;
 				}
 			},
 			toConfirmation(){//跳转确认订单页面

+ 2 - 0
seller/pages/cart/buyagain.vue

@@ -124,6 +124,8 @@
 							this.buyRetailPrice = item.buyPrice
 						}
 					})
+				}else{
+					this.buyRetailPrice = this.handleData.retailPrice;
 				}
 			},
 			getAddProductCart(){//增加购物车成功和toast弹窗提示成功

+ 4 - 4
seller/pages/cart/cart.vue

@@ -381,14 +381,14 @@
 			},
 			processActivityPrice(pros){//单独处理活动价格和阶梯价格
 				let ladderPriceList = pros.ladderPriceList;
-				if(pros.ladderPriceFlag == '0' || pros.actStatus == 1){
-					pros.retailPrice = pros.retailPrice
-				}else{
+				if(pros.ladderPriceFlag == '1'){
 					ladderPriceList.forEach((item,index)=>{
 						if(pros.productCount>=item.buyNum){
 							pros.retailPrice = item.buyPrice
 						}
-					})
+					});
+				}else{
+					pros.retailPrice = pros.retailPrice
 				}
 			},
 			updateShoppogNum(pros){//加减购物车商品更新到后台

+ 2 - 0
seller/pages/cart/immediately.vue

@@ -120,6 +120,8 @@
 							this.buyRetailPrice = item.buyPrice
 						}
 					})
+				}else{
+					this.buyRetailPrice = this.handleData.retailPrice;
 				}
 			},
 			getAddProductCart(){//增加购物车成功和toast弹窗提示成功

+ 3 - 2
seller/pages/club/club-list.vue

@@ -72,6 +72,7 @@
 				searchInputVal:'',
 				isEmpty:false,
 				nomoreText: '上拉显示更多',
+				status:66,
 				pageNum:1,
 				pageSize:10,
 				hasNextPage:false,
@@ -107,7 +108,7 @@
 				this.initclubList()
 			},
 			initclubList(){
-				let params = {userIdentity:'',name:this.searchInputVal,pageNum:1,pageSize:this.pageSize,spId:this.serviceProviderId,status:90}
+				let params = {userIdentity:'',name:this.searchInputVal,pageNum:1,pageSize:this.pageSize,spId:this.serviceProviderId,status:this.status}
 				getSellerClubList(params).then(response =>{
 					let responseData = response.data
 					if(responseData.results&&responseData.results.length > 0){
@@ -133,7 +134,7 @@
 			},	
 			getOnReachBottomData(){
 				this.pageNum+=1
-				let params = {userIdentity:'',name:this.searchInputVal,pageNum:this.pageNum,pageSize:this.pageSize,spId:this.serviceProviderId,status:90}
+				let params = {userIdentity:'',name:this.searchInputVal,pageNum:this.pageNum,pageSize:this.pageSize,spId:this.serviceProviderId,status:this.status}
 				getSellerClubList(params).then(response =>{
 					let responseData = response.data
 					if(responseData.results&&responseData.results.length > 0){

+ 3 - 0
seller/pages/login/apply.vue

@@ -414,6 +414,7 @@ import { mapMutations } from 'vuex';
 							this.medicaCampList = this.setNewMainpro(organizationClub.mainpro)
 							this.mentuzCampList = this.mentuzCampNullList
 						}
+						this.mainpro = organizationClub.mainpro;
 					}
 					//机构类型
 					switch(this.secondClubType){
@@ -464,6 +465,7 @@ import { mapMutations } from 'vuex';
 					}
 					this.mainpro = mainproList.join('/')
 				}
+				console.log(this.mainpro)
 				if( this.registerEmail == ''){
 					this.$util.msg('请输入邮箱地址',2000);
 					return
@@ -667,6 +669,7 @@ import { mapMutations } from 'vuex';
 					let _OBJ = {value:(index+1).toString(),name:item,checked:true}
 					_ARRAY.push(_OBJ)
 				})
+				console.log(_ARRAY)
 				return _ARRAY
 			},
 			addCustomItem(){

+ 7 - 7
seller/pages/login/information.vue

@@ -349,14 +349,14 @@
 						this.addressData.townID = organizationClub.townID
 					}
 					this.addressData.addressDetail = organizationClub.address ? organizationClub.address : ''
-					this.socialCreditCode = organizationClub.socialCreditCode
-					this.firstClubType = organizationClub.firstClubType
-					this.secondClubType = organizationClub.secondClubType
+					this.socialCreditCode = this.$reg.checkData(organizationClub.socialCreditCode)
+					this.firstClubType = this.$reg.checkData(organizationClub.firstClubType)
+					this.secondClubType = this.$reg.checkData(organizationClub.secondClubType)
 					this.addressData.address = organizationClub.provincialAddress ? organizationClub.provincialAddress : ''
-					this.uploadBusinessImage = organizationClub.businessLicenseImage
-					this.uploadMedicalImage = organizationClub.medicalPracticeLicenseImg
-					this.uploadMentuzImage = organizationClub.headpic
-					this.department = organizationClub.department						
+					this.uploadBusinessImage = this.$reg.checkData(organizationClub.businessLicenseImage)
+					this.uploadMedicalImage = this.$reg.checkData(organizationClub.medicalPracticeLicenseImg)
+					this.uploadMentuzImage = this.$reg.checkData(organizationClub.headpic)
+					this.department = this.$reg.checkData(organizationClub.department)						
 					//机构类型&&主营项目
 					switch(this.firstClubType){
 						case '1':