zhengjinyi 4 роки тому
батько
коміт
7653bb2c57

+ 1 - 1
components/cm-module/creatOrder/invoiceTent.vue

@@ -34,7 +34,7 @@
 						</view>
 						<view class="invoice-from">
 							<view class="label">注册地址:</view>
-							<input class="form-input" type="text" v-model="invoiceData.registeredAddress" placeholder="请填写单位注册地址(必填)" maxlength="30">
+							<input class="form-input" type="text" v-model="invoiceData.registeredAddress" placeholder="请填写单位注册地址(必填)" maxlength="100">
 						</view>
 						<view class="invoice-from">
 							<view class="label">注册电话:</view>

+ 1 - 1
components/cm-module/creatOrder/sellerInvoice.vue

@@ -37,7 +37,7 @@
 						</view>
 						<view class="invoice-from">
 							<view class="label">注册地址:</view>
-							<input class="form-input" type="text" v-model="invoiceData.registeredAddress" placeholder="请填写单位注册地址(必填)" placeholder-class="placeholder" maxlength="30">
+							<input class="form-input" type="text" v-model="invoiceData.registeredAddress" placeholder="请填写单位注册地址(必填)" placeholder-class="placeholder" maxlength="100">
 						</view>
 						<view class="invoice-from">
 							<view class="label">注册电话:</view>

+ 1 - 7
components/cm-module/listTemplate/commodityList.vue

@@ -150,7 +150,6 @@
 				totalPage: 1,
 				pullFlag: true,
 				cartNum: 0,
-				identity:2,
 			}
 		},
 		created() {		
@@ -161,11 +160,6 @@
 				this.userID = resolve.userID ? resolve.userID : 0;
 				this.shopId = resolve.shopID ? resolve.shopID : 0;
 				this.userIdentity = resolve.userIdentity
-				if(this.userIdentity == 1){
-					this.identity = 1
-				}else{
-					this.identity = 2
-				}
 				this.getListFromServer();
 			}).catch(error =>{
 				this.getListFromServer();
@@ -177,7 +171,7 @@
 			},
 		},
 		computed: {
-			...mapState(['hasLogin','userInfo'])
+			...mapState(['hasLogin','userInfo','identity'])
 		},
 		methods:{
 			toLower() {

+ 2 - 2
components/cm-module/listTemplate/productList.vue

@@ -119,7 +119,7 @@
 			},
 		},
 		computed: {
-			...mapState(['hasLogin','userInfo'])
+			...mapState(['hasLogin','userInfo','identity'])
 		},
 		methods:{
 			scrolltolower() {
@@ -138,7 +138,7 @@
 				this.loadingText = '加载中';
 				this.isShowEmpty = false;				
 				if(loadMore) {this.pageNum += 1;}
-				let params = {userId:this.userID,pageNum:this.pageNum,pageSize:this.pageSize}
+				let params = {userId:this.userID,identity:this.identity,pageNum:this.pageNum,pageSize:this.pageSize}
 				this.ProductService.GetRepeatBuyAgainProductList(params).then(response =>{
 					this.isShowWrapper = true
 					this.cartQuantity = response.data.cartQuantity

+ 5 - 1
components/cm-module/productDetails/recommend.vue

@@ -12,6 +12,7 @@
 </template>
 
 <script>
+	import { mapState,mapMutations} from 'vuex';
 	import authorize from '@/common/config/authorize.js'
 	import tuiLoadmore from "@/components/tui-components/loadmore/loadmore"
 	import tuiNomore from "@/components/tui-components/nomore/nomore"
@@ -45,9 +46,12 @@
 			this.productID = this.queryProductid
 			this.infoRecommend(this.queryProductid,this.queryType)
 		},
+		computed: {
+			...mapState(['identity'])
+		},
 		methods:{
 			infoRecommend(id,type){
-				this.ProductService.queryProductDetilsRelevant({ productId:id,recommendType:type ? type : 0 }).then(response =>{
+				this.ProductService.queryProductDetilsRelevant({ productId:id,recommendType:type ? type : 0,identity:this.identity }).then(response =>{
 					if( response.data && response.data.length > 0){
 						this.isEmpty = false
 						this.recommendList = response.data

+ 2 - 2
pages/goods/product.vue

@@ -366,11 +366,11 @@
 			this.getWinHeight()
 		},
 		computed: {
-			...mapState(['hasLogin','isWxAuthorize'])
+			...mapState(['hasLogin','isWxAuthorize','identity'])
 		},
 		methods:{
 			initData(){// 初始化商品详情查询
-				this.ProductService.queryProductDetils({userId:this.userID,productID:this.productID}).then(response =>{	
+				this.ProductService.queryProductDetils({userId:this.userID,productID:this.productID,identity:this.identity}).then(response =>{	
 					this.skeletonShow = false
 					this.productImage=[];
 					this.shop = response.data.shop

+ 5 - 8
pages/search/search.vue

@@ -152,7 +152,6 @@
 				themeClass: 'block',
 				show:false,
 				userIdentity:'',	
-				identity:2,
 				searchKeyType:1,
 				isShowClose:false,	//是否显示清空输入框图标
 				isSearchHistory:false,//是都显示搜索历史
@@ -183,15 +182,12 @@
 		},
 		onLoad(option) {
 			console.log(option)
+			
 			this.$api.getStorage().then((resolve) =>{
 				this.userID = resolve.userID ? resolve.userID : 0;
 				this.shopId = resolve.shopID ? resolve.shopID : 0;
-				this.userIdentity = resolve.userIdentity ? resolve.userIdentity : '';
-				if(this.userIdentity == 1){
-					this.listQuery.identity = 1
-				}else{
-					this.listQuery.identity = 2
-				}
+				this.userIdentity = resolve.userIdentity;
+				this.listQuery.identity = this.identity;
 				if(option.keyWord){
 					this.listQuery.keyword = option.keyWord
 					this.setSearchHistoryAdd()
@@ -209,7 +205,7 @@
 			},
 		},
 		computed: {
-			...mapState(['hasLogin','userInfo'])
+			...mapState(['hasLogin','userInfo','identity'])
 		},
 		methods:{
 			initGetSerachRecord(){//查询搜索历史记录
@@ -708,6 +704,7 @@
 				padding:0 16rpx;
 				font-size: $font-size-20;
 				margin-left: 15rpx;
+				margin-top:15px;
 				border: 1px solid #E15616;
 				float: right;
 			}

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

@@ -127,7 +127,7 @@
 			
 		},
 		computed: {
-			...mapState(['hasLogin','userInfo','isActivity'])
+			...mapState(['hasLogin','userInfo','identity'])
 		},
 		methods: {
 			...mapMutations(['login','logout']),
@@ -213,7 +213,7 @@
 				})
 			},
 			GetHomeRecommendInfo(){//首页热门推荐
-				this.CommonService.GetHomeRecommendInfo().then(response =>{
+				this.CommonService.GetHomeRecommendInfo({identity:this.identity}).then(response =>{
 					this.RecommendList = response.data
 					this.GetProductPrice()
 				})

+ 22 - 19
seller/pages/order/order-historylist.vue

@@ -284,25 +284,28 @@
 				}, 600);	
 			}, 
 			getOnReachBottomData(index){//上拉加载
-				let params = {listType:index,orderSubmitType:this.screenTab,serviceProviderId:this.serviceProviderId,pageNum:this.pageNum+=1,pageSize:this.pageSize};
-				this.SellerService.GetSellerOrderList(params).then(response =>{
-					let orderItem = this.orderTabBar[index];
-					let resData = response.data.results
-					this.hasNextPage = response.data.hasNextPage;
-					orderItem.orderList = orderItem.orderList.concat(resData)
-					this.pullFlag = false;// 防上拉暴滑
-					setTimeout(()=>{this.pullFlag = true;},500)
-					if(this.hasNextPage){
-						this.pullUpOn = false
-						this.nomoreText = '上拉显示更多'
-					}else{
-						this.loadding = false
-						this.pullUpOn = false
-						this.nomoreText = '已至底部'
-					}
-				}).catch(error =>{
-					this.$util.msg(error.msg,2000)
-				})
+				this.pageNum += 1
+				this.$api.getComStorage('orderUserInfo').then((resolve) =>{
+					let params = {listType:index,clubID:resolve.clubID,orderSubmitType:this.screenTab,serviceProviderId:this.serviceProviderId,pageNum:this.pageNum,pageSize:this.pageSize};
+					this.SellerService.GetSellerClubOrderList(params).then(response =>{
+						let orderItem = this.orderTabBar[index];
+						let resData = response.data.results
+						this.hasNextPage = response.data.hasNextPage;
+						orderItem.orderList = orderItem.orderList.concat(resData)
+						this.pullFlag = false;// 防上拉暴滑
+						setTimeout(()=>{this.pullFlag = true;},500)
+						if(this.hasNextPage){
+							this.pullUpOn = false
+							this.nomoreText = '上拉显示更多'
+						}else{
+							this.loadding = false
+							this.pullUpOn = false
+							this.nomoreText = '已至底部'
+						}
+					}).catch(error =>{
+						this.$util.msg(error.msg,2000)
+					})
+				})	
 			},
 			scrolltolower() {
 				if(this.hasNextPage){

+ 2 - 2
services/ajax.env.js

@@ -4,8 +4,8 @@ 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.75:8008'	 //超超联调地址
-    // URL_CONFIG = 'https://spi-b.caimei365.com'	 //采美测试地址
-	URL_CONFIG = 'https://spi.caimei365.com'
+    URL_CONFIG = 'https://spi-b.caimei365.com'	 //采美测试地址
+	// URL_CONFIG = 'https://spi.caimei365.com'
 }else{
     // 生产环境
 	// URL_CONFIG = 'https://spi-b.caimei365.com'

+ 9 - 0
store/index.js

@@ -9,6 +9,7 @@ const store = new Vuex.Store({
 		isWxAuthorize:false,
 		hasLogin: false,
 		userInfo: {},
+		identity:0,
 		wechatUserInfo:{},
 		cartNumber:0,
 		isIphoneX:false,
@@ -48,6 +49,14 @@ const store = new Vuex.Store({
 			let TIME = api.formatDate()
 			console.log(`${TIME}`,provider)
 			state.userInfo = provider;
+			if(provider.userIdentity){
+				state.identity = provider.userIdentity
+			}else if(provider.userID == 5261 || provider.userID == 10947 || provider.userID == 11579){
+				state.identity = 1;
+			}else{
+				state.identity = 0;
+			}
+			console.log('用户类型',state.identity)
 			uni.setStorage({//缓存用户登陆状态
 			    key: 'userInfo',
 			    data: provider