Kaynağa Gözat

代客下单、销售端我的订单列表

huangzhe 3 yıl önce
ebeveyn
işleme
a618fdecad

+ 11 - 1
src/components/basic-component/app-tab-bar/app-tab-bar.vue

xqd
@@ -67,12 +67,22 @@
 							"text": "订单",
 							"url": "/pages/sale/mySaleOrder"
 						},
+						{
+							"active_color": "#A18353",
+							"active_icon": "https://t17.9026.com/web/statics/image/sale/sale_order_select.png",
+							"color": "#989898",
+							"icon": "https://t17.9026.com/web/statics/image/sale/sale_order.png",
+							"id": 3,
+							"open_type": "redirect",
+							"text": "购物车",
+							"url": "/pages/cart/cart"
+						},
 						{
 							"active_color": "#A18353",
 							"active_icon": "https://t17.9026.com/web/statics/image/sale/sale_my_select.png",
 							"color": "#989898",
 							"icon": "https://t17.9026.com/web/statics/image/sale/sale_my.png",
-							"id": 3,
+							"id": 4,
 							"key": "",
 							// "link": {
 							// 	"icon": "https://t1.9026.com/web/statics/img/mall/pick-link/icon-user-center.png",

+ 2 - 2
src/components/page-component/app-user-center-top/app-user-center-top.vue

xqd
@@ -232,9 +232,9 @@
 					</app-form-id>
 				</template>
 			</view>
-			<view class="box-grow-0 address-container">
+			<!-- <view class="box-grow-0 address-container">
 				<image style="width: 32rpx;height: 34rpx;" src="https://t17.9026.com/web/statics/image/index/arrow_right.png" mode=""></image>
-			</view>
+			</view> -->
 		</view>
 		<!-- style 4 end -->
 		

+ 8 - 4
src/components/page-component/index/app-nav-bar.vue

xqd
@@ -340,14 +340,18 @@ $app-bg-color: #FFFFFF;
             padding-left: #{26rpx};
 
             .icon-back {
-                // background-image: url("https://shop.9026.com/web/statics/image/mall/static/icon/h5-back-2.png");
-				background-image: url("https://t17.9026.com/web/statics/image/index/back.png");
+                background-image: url("https://shop.9026.com/web/statics/image/mall/static/icon/h5-back-2.png");
+				// background-image: url("https://t17.9026.com/web/statics/image/index/back.png");
                 background-repeat: no-repeat;
                 background-size: 100% 100%;
+				height: #{30rpx};
+				width: #{20rpx};
+				
                 // height: #{27rpx};
                 // width: #{16rpx};
-				height: #{33rpx};
-				width: #{33rpx};
+				
+				// height: #{33rpx};
+				// width: #{33rpx};
                 display: block;
             }
         }

+ 9 - 4
src/core/request.js

xqd
@@ -17,10 +17,15 @@ const request = async function (args) {
         // #endif
     };
 
-    await Vue.prototype.$store.dispatch('user/loadAccessTokenFormCache');
-    if (Vue.prototype.$store.state.user && Vue.prototype.$store.state.user.accessToken) {
-        header['X-Access-Token'] = Vue.prototype.$store.state.user.accessToken;
-    }
+	if(Vue.prototype.$store.state.user && Vue.prototype.$store.state.user.isEnterSales && Vue.prototype.$store.state.user.customerAccessToken && Vue.prototype.$store.state.user.isOrderBehalfBustomers){
+		header['X-Access-Token'] = Vue.prototype.$store.state.user.customerAccessToken;
+	}else{
+		await Vue.prototype.$store.dispatch('user/loadAccessTokenFormCache');
+		if (Vue.prototype.$store.state.user && Vue.prototype.$store.state.user.accessToken) {
+		    header['X-Access-Token'] = Vue.prototype.$store.state.user.accessToken;
+		}
+	}
+	
     if (Vue.prototype.$store.state.user && Vue.prototype.$store.state.user.tempParentId !== 0) {
         header['X-User-Id'] = Vue.prototype.$store.state.user.tempParentId + '';
     }

+ 14 - 9
src/pages/coupon/index/index.vue

xqd xqd xqd
@@ -5,10 +5,15 @@
         <view v-else class="list">
 	        <view @click="toDetail(item.id)" v-for="item in list" :key="item.id">
 	            <view class="list-item">
-					<image src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-bg-0.png" v-if="activeTab == 1"></image>
+					<!-- <image src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-bg-0.png" v-if="activeTab == 1"></image>
 					<image src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-bg-1.png" v-else></image>
 	                <image class="status" src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-status-icon-1.png" v-if="activeTab == 2"></image>
-	                <image class="status" src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-status-icon-2.png" v-if="activeTab == 3"></image>
+	                <image class="status" src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-status-icon-2.png" v-if="activeTab == 3"></image> -->
+					
+					<image src="../../../static/image/index/img-coupon-bg-0.png" v-if="activeTab == 1"></image>
+					<image src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-bg-1.png" v-else></image>
+					<image class="status" src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-status-icon-1.png" v-if="activeTab == 2"></image>
+					<image class="status" src="https://shop.9026.com/web/statics/img/mall/coupon/img-coupon-status-icon-2.png" v-if="activeTab == 3"></image>
 	                <view class="item-left dir-top-nowrap main-center">
 	                    <view class="coupon-price t-omit" v-if="item.coupon.type == 2">¥{{item.coupon.sub_price | reservedNum}}</view>
 	                    <view class="coupon-price t-omit" v-else>{{item.coupon.discount | reservedNum}}折</view>
@@ -17,12 +22,12 @@
 	                    <view style="font-size: 10px" v-if="item.discount_limit">优惠上限:¥{{item.discount_limit | reservedNum}}</view>
 	                </view>
 	                <view class="item-right">
-	                    <view class="item-name t-omit t-large t-large-color">{{item.coupon.name}}</view>
-	                    <view class="t-small-color time-area">{{item.start_time}} - {{item.end_time}}</view>
-	                    <view v-if="item.coupon.appoint_type == 3">全场通用</view>
-                        <view v-else-if="item.coupon.appoint_type == 4">仅限当面付活动使用</view>
-	                    <view v-else-if="item.coupon.appoint_type == 5">仅限礼品卡使用</view>
-	                    <view v-else>限品类</view>
+	                    <view class="item-name t-omit t-large t-large-color hjx-tc-222 hjx-tw-600">{{item.coupon.name}}</view>
+						<view v-if="item.coupon.appoint_type == 3">全场通用</view>
+						<view v-else-if="item.coupon.appoint_type == 4">仅限当面付活动使用</view>
+						<view v-else-if="item.coupon.appoint_type == 5">仅限礼品卡使用</view>
+						<view v-else>限品类</view>
+	                    <view class="t-small-color time-area hjx-tc-B19D60">{{item.start_time}} - {{item.end_time}}</view>
 	                </view>
 	            </view>
 	        </view>
@@ -209,7 +214,7 @@
 	    width: #{190rpx};
 	    text-align: center;
 	    font-size: #{24rpx};
-	    color: #fff;
+	    color: #B19D60;
 	    padding-top: #{8rpx};
 	}
 

+ 4 - 2
src/pages/favorite/favorite.vue

xqd xqd
@@ -347,11 +347,13 @@ export default {
 				this.statusTop = 85;
 				setTimeout(() => {
 					this.getCurrent = index;
+					this.getFavorite();
 				});
-				this.getFavorite();
+				
 			} else if (index === 1) {
 				setTimeout(() => {
 					this.is_goods = false;
+					this.getTopicList();
 				}, 500);
 				this.getCurrent = index;
 				this.left = 375;
@@ -368,7 +370,7 @@ export default {
 					this.touch = false;
 					this.allTouch = false;
 				}
-				this.getTopicList();
+				
 			}
 		},
 

+ 57 - 33
src/pages/index/binding/binding.vue

xqd xqd xqd xqd xqd xqd xqd
@@ -12,6 +12,7 @@
 				</view>
 				<image class="bg" src="https://t17.9026.com/web/statics/image/sale/properties_gradual.png" mode="">
 				</image>
+				<view class="is-mainbuilding" v-if="item.is_master_estate">主楼盘</view>
 			</view>
 			<AppNoData v-if="dataList.length===0" title="您还未绑定任何楼盘"></AppNoData>
 		</view>
@@ -42,18 +43,18 @@
 				</view>
 			</view>
 			
-			<!-- <view class="line"></view>
-			<picker mode="selector" @change="bindPickerNature" :range="natureList">
-				<view class="main-between cross-center item">
+			<view class="line" v-show="name!=''"></view>
+			<!-- <picker mode="selector" @change="bindPickerProperty" :range="propertyList" v-show="name!=''" disabled> -->
+				<view class="main-between cross-center item" v-show="name!=''">
 					<view class="title_1">楼盘性质</view>
 					<view class="main-right cross-center">
-						<text :class="{'val':nature!=='','pla':nature===''}">{{nature?nature:'请选择'}}</text>
+						<text :class="{'val':property!=='','pla':property===''}">{{property?property:'请选择'}}</text>
 						<image class="arrow-right"
-							src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode="">
+							src="" mode="">
 						</image>
 					</view>
 				</view>
-			</picker> -->
+			<!-- </picker> -->
 			<view class="line" v-show="name!=''"></view>
 			<view class="main-between cross-center item" @click="selectSale" v-show="name!=''">
 				<view class="title_1">绑定销售</view>
@@ -84,28 +85,36 @@
 				region: '',
 				regionId:{},
 				multiIndex:[],
-				nature: '',
+				property: '',
 				sale: '',
 				
 				estate_id:'',
 				sale_id:'',
 
-				natureList: ['住宅用房', '非住宅用房'],
+				propertyList: ['住宅用房', '非住宅用房'],
 
-				dataList: [{}]
+				dataList: [{}],
+				
+				isSwitchMainBuilding:0
 			};
 		},
 		onShow() {
 			var pages = getCurrentPages();
 			var currPage = pages[pages.length - 1]; //当前页面
-
-			'estateInfo' in currPage.$vm ? this.name = currPage.$vm.estateInfo.name : ''
-			'estateInfo' in currPage.$vm ? this.estate_id = currPage.$vm.estateInfo.id : ''
-			'estateInfo' in currPage.$vm ? this.multiIndex = currPage.$vm.estateInfo.multiIndex : ''
-			'saleInfo' in currPage.$vm ? this.sale = currPage.$vm.saleInfo.name : ''
-			'saleInfo' in currPage.$vm ? this.sale_id = currPage.$vm.saleInfo.id : ''
+			
+			if('estateInfo' in currPage.$vm){
+				this.name = currPage.$vm.estateInfo.name
+				this.estate_id = currPage.$vm.estateInfo.id
+				this.multiIndex = currPage.$vm.estateInfo.multiIndex
+				this.property = currPage.$vm.estateInfo.property=='1'?'住宅用房':'非住宅用房'
+			}
+			if('saleInfo' in currPage.$vm){
+				this.sale = currPage.$vm.saleInfo.name
+				this.sale_id = currPage.$vm.saleInfo.id
+			}
 		},
-		onLoad() {
+		onLoad(option) {
+			this.isSwitchMainBuilding=option.isSwitchMainBuilding
 			this.getDate(1,'')
 		},
 		methods: {
@@ -170,22 +179,24 @@
 				'selectedProperties':'selectedProperties'
 			}),
 			selectMasterEstate(index,estate_id){
-				this.$request({
-					url:this.$api.index.select_master_estate,
-					data:{
-						estate_id:estate_id
-					},
-					method:'post'
-				}).then(res=>{
-					uni.showToast({
-						icon:res.code===0?'success':'none',
-						title:res.msg
+				if(this.isSwitchMainBuilding){
+					this.$request({
+						url:this.$api.index.select_master_estate,
+						data:{
+							estate_id:estate_id
+						},
+						method:'post'
+					}).then(res=>{
+						uni.showToast({
+							icon:res.code===0?'success':'none',
+							title:res.msg
+						})
+						if(res.code===0){
+							this.selectedProperties(this.dataList[index])
+							uni.navigateBack()
+						}
 					})
-					if(res.code===0){
-						this.selectedProperties(this.dataList[index])
-						uni.navigateBack()
-					}
-				})
+				}
 			},
 			selectBuild() {
 				uni.navigateTo({
@@ -197,8 +208,8 @@
 					url: `/pages/index/binding/bindingSale?estate_id=${this.estate_id}&name=${this.name}`
 				})
 			},
-			bindPickerNature(e) {
-				this.nature = this.natureList[e.target.value]
+			bindPickerProperty(e) {
+				this.property = this.propertyList[e.target.value]
 			}
 		}
 	}
@@ -317,6 +328,7 @@
 			// background-image: url(https://t17.9026.com/web/statics/image/sale/properties_gradual.png);
 			padding: 25rpx;
 			position: relative;
+			overflow: hidden;
 
 			.bg {
 				position: absolute;
@@ -359,6 +371,18 @@
 					line-height: 34rpx;
 				}
 			}
+			.is-mainbuilding{
+				position: absolute;top: 0;right: 0;
+				width: 100rpx;
+				height: 36rpx;
+				background: #EEEBDF;
+				border-radius: 0px 10rpx 0px 0px;
+				font-size: 20rpx;
+				font-weight: 500;
+				color: #A6824F;
+				line-height: 36rpx;
+				text-align: center;
+			}
 		}
 
 		.addPro {

+ 2 - 1
src/pages/index/hxj_index_component.vue

xqd
@@ -232,7 +232,8 @@
 						image: 'https://t17.9026.com/web/statics/image/index/temporary/jhk-1634284372084.png',
 						title: '主题专区',
 						tag: '主题',
-						link: '/pages/case/themeArea'
+						// link: '/pages/case/themeArea'
+						link:'/pages/topic/list'
 					},
 					{
 						image: 'https://t17.9026.com/web/statics/image/index/temporary/jhk-1634283667210.png',

+ 3 - 3
src/pages/index/index.vue

xqd xqd xqd
@@ -122,7 +122,6 @@
 				updateManager.onCheckForUpdate(function(res) {
 					// 请求完新版本信息的回调
 				})
-
 				updateManager.onUpdateReady(function() {
 					wx.showModal({
 						title: '更新提示',
@@ -148,7 +147,7 @@
 		methods: {
 			navProperties(){
 				uni.navigateTo({
-					url:'/pages/index/binding/binding'
+					url:'/pages/index/binding/binding?isSwitchMainBuilding=1'
 					// url:'/pages/sale/properties/addProperties'
 				})
 			},
@@ -435,7 +434,8 @@
 				userInfo: 'user/info',
 			}),
 			...mapState({
-				systemInfo: state => state.gConfig.systemInfo
+				systemInfo: state => state.gConfig.systemInfo,
+				selectedProperties: state => state.user.selectedProperties
 			}),
 			...mapState('mallConfig', {
 				config: state => state.mall.setting,

+ 6 - 0
src/pages/order-submit/address-pick.vue

xqd xqd
@@ -117,6 +117,9 @@
             ...mapGetters('mallConfig', {
                 getTheme: 'getTheme',
             }),
+			...mapGetters('user', {
+				getIsEnterSales: 'getIsEnterSales'
+			}),
             list() {
                 const allList = this.allList;
                 const newVal = this.keyword;
@@ -131,6 +134,9 @@
             this.sign = options.sign;
         },
         onShow() {
+			if(this.getIsEnterSales){
+				this.$store.commit('user/isOrderBehalfBustomers', true)
+			}
             this.page = 1;
             // #ifdef MP-BAIDU
             setTimeout(() => {

+ 38 - 7
src/pages/order-submit/order-submit.vue

xqd xqd xqd xqd xqd xqd xqd xqd
@@ -584,6 +584,7 @@
 		computed: {
 			...mapState({
 				appImg: state => state.mallConfig.__wxapp_img,
+				info:state=> state.user.info
 			}),
 			theme() {
 				return this.userTheme ? this.userTheme : this.getTheme;
@@ -666,7 +667,11 @@
 			var currPage = pages[pages.length - 1]; //当前页面
 			'customerInfo' in currPage.$vm ? this.customerInfo = currPage.$vm.customerInfo : ''
 		},
+		onHide(){
+			this.$store.commit('user/isOrderBehalfBustomers', false);
+		},
 		onUnload() {
+			this.$store.commit('user/isOrderBehalfBustomers', false);
 			if (this.getPayDataTimer) {
 				clearTimeout(this.getPayDataTimer);
 			}
@@ -682,7 +687,7 @@
 					this.changeZitiAddress();
 				},
 			},
-			customerInfo(nVal,oVal){
+			customerInfo(nVal,oVal){ //获取客户token代客下单用
 				this.$request({
 					url:this.$api.sale.get_token,
 					data:{
@@ -691,7 +696,10 @@
 					method:'post'
 				}).then(res=>{
 					if(res.code===0){
-						this.previewData.address={}
+						this.$store.commit('user/customerAccessToken', res.data.access_token);
+						this.$store.commit('user/isOrderBehalfBustomers', true);
+						
+						delete this.previewData.address
 					}else{
 						uni.showToast({
 							title:res.msg,
@@ -1144,7 +1152,20 @@
 							}, 1000);
 						} else {
 							uni.hideLoading();
-							this.pay(response.data);
+							if(this.getIsEnterSales){
+								uni.showModal({
+									title: '',
+									content: '代客下单成功',
+									showCancel: false,
+									success: function (res) {
+									        if (res.confirm) {
+									           uni.navigateBack()
+									        } 
+									    }
+								});
+							}else{
+								this.pay(response.data)
+							}
 						}
 					} else {
 						this.submitLock = false;
@@ -1287,6 +1308,18 @@
 						this.bookStorage('save', this.$store.state.orderSubmit.formData.list[i].store_id);
 					}
 				}
+				const formData = this.$store.state.orderSubmit.formData;
+				if(this.getIsEnterSales){
+					if(!this.customerInfo || !this.$store.state.user.customerAccessToken){
+						uni.showModal({
+							title: '提示',
+							content: '请选择客户',
+							showCancel: false,
+						});
+						return
+					}
+					formData.place_sale_id=this.info.salesperson_id
+				}
 				if(this.isNeedInvoice){ //判断是否选择发票,并设置发票信息
 					let invoice_info=this.$storage.getStorageSync('invoice_info')
 					if(invoice_info){
@@ -1311,12 +1344,9 @@
 						})
 						return
 					}
-					
-					const formData = this.$store.state.orderSubmit.formData;
 					formData.invoice_info=invoice_info
-					this.$store.commit('orderSubmit/mutSetFormData', formData);
 				}
-				
+				this.$store.commit('orderSubmit/mutSetFormData', formData);
 				if (this.submitLock) return;
 				this.submitLock = true;
 				this.$subscribe(this.previewData.template_message_list).then(res => {
@@ -1368,6 +1398,7 @@
 				}
 			},
 			handleAddressInput(e) {
+				this.previewData.address={}
 				if (typeof e.name !== 'undefined') this.previewData.address.name = e.name;
 				if (typeof e.mobile !== 'undefined') this.previewData.address.mobile = e.mobile;
 			},

+ 1 - 1
src/pages/sale/components/app-my-income.vue

xqd
@@ -1,6 +1,6 @@
 <template>
 	<view class="main-between income">
-		<view class="item" @click="goPage('/pages/share/order/order')">
+		<view class="item" @click="goPage('/pages/sale/mySaleOrder')">
 			<view class="title">订单总额(万)</view>
 			<view class="main-between cross-center">
 				<view class="num">{{userInfo.salesperson_info.order_total_amount}}</view>

+ 67 - 32
src/pages/sale/mySaleOrder.vue

xqd xqd xqd xqd xqd xqd xqd xqd
@@ -1,10 +1,11 @@
 <template>
 	<!-- <app-layout :haveBackground="false"> -->
+	<app-layout >
 	<view class="page">
 		<!-- <view style="background-color: #fff;position: fixed;top: 0;width: 100%;"> -->
 		<view class="main-left cross-center search">
 			<image src="https://t17.9026.com/web/statics/image/index/search.png" mode=""></image>
-			<input style="width: 560rpx;" type="text" value="" placeholder="搜索客户、商品、时间、订单号"
+			<input style="width: 560rpx;" type="text" value="" placeholder="搜索客户、商品、时间、订单号" v-model="keyword"
 				placeholder-style="font-size:28rpx;color:#999;" />
 		</view>
 		<view style="background-color: #fff;position: sticky;top: 0;width: 100%;">
@@ -34,11 +35,11 @@
 		<!-- </view> -->
 
 		<view class="list">
-			<view class="box" v-for="(item,index) in 5" :key="index">
+			<view class="box" v-for="(item,index) in dataList" :key="index">
 				<view class="main-between cross-center header">
 					<view class="cross-center head" :class="{'border_bottom':true}">
-						<image src="https://t17.9026.com/web/statics/image/sale/1.png" mode=""></image>
-						周先生-世龙广场22号楼2202
+						<image :src="item.user.avatar" mode=""></image>
+						{{item.user.nickname}}{{item.user.estate_name?`-${item.user.estate_name}`:''}}
 					</view>
 					<!-- <view class="cross-center head1">
 						<image src="https://t17.9026.com/web/statics/image/sale/1.png" mode=""></image>
@@ -51,30 +52,19 @@
 					</view>
 				</view>
 				<view class="center">
-					<!-- <view class="main-between cross-center">
-						<view class="title">整体评价</view>
-						<view class="isopen cross-center">
-							展开
-							<image src="https://t17.9026.com/web/statics/image/user-center/arrow-bottom.png" mode=""></image>
-						</view>
-					</view> -->
-					<!-- <view class="center-text">客户xxxx向您发起了楼盘xxxx的认证通知,请前往我的-我的客户查看并处理</view> -->
-					<!-- <view class="center-img">
-						<image v-for="(item, index) in 5" :key="index" src="https://t17.9026.com/web/statics/image/user-center/1.png" mode=""></image>
-					</view> -->
-					<view class="main-between goods">
+					<view class="main-between goods" v-for="(goods,index1) in item.detail" :key="index1" @click="$jump({open_type:'navigate',url:'/pages/goods/goods?id='+goods.id})">
 						<view class="main-left desc">
-							<image class="goods-img" src="https://t17.9026.com/web/statics/image/user-center/1.png"
+							<image class="goods-img" :src="goods.goods_info.pic_url"
 								mode=""></image>
 							<view>
-								<view class="title t-omit-two">兴城人居ins居家占位套餐居家占位套餐居家占位套餐居家占位套餐居家占位套餐</view>
+								<view class="title t-omit-two">{{goods.goods_info.name}}</view>
 								<view class="main-between price">
 									<view>
 										<text class="company">¥</text>
-										<text>2466.00</text>
+										<text>{{goods.unit_price}}</text>
 									</view>
 									<view>
-										x1
+										x{{goods.num}}
 									</view>
 								</view>
 							</view>
@@ -85,28 +75,29 @@
 						</view> -->
 					</view>
 					<view class="main-between cross-bottom total_pay">
-						<view class="order_number">订单号:968606069111121</view>
-						<view><text>应付总</text><text>¥</text><text>2388.00</text></view>
+						<view class="order_number">订单号:{{item.order_no}}</view>
+						<view><text>应付总</text><text>¥</text><text>{{item.total_price}}</text></view>
 					</view>
 				</view>
 				<view class="main-between footer cross-center border_top">
 					<template>
-						<view class="date">2021-12-11</view>
+						<view class="date">{{item.updated_at.split(' ')[0]}}</view>
 						<view class="main-around">
 							<!-- <view class="kbtn">上传发票</view> -->
 							<view class="kbtn">再次购买</view>
-							<view class="kbtn">查看物流</view>
+							
+							<view class="kbtn" @click="$jump({open_type:'navigate',url:'/pages/order/express-detail/express-detail'})">查看物流</view>
 						</view>
 					</template>
-					<template v-if="false">
+					<!-- <template v-if="false">
 						<view class="left">查看详情</view>
 						<image style="width: 12rpx;height: 22rpx;"
 							src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode=""></image>
-					</template>
+					</template> -->
 				</view>
 			</view>
-			<view class="no-more">没有更多了...</view>
-			<app-no-goods :title="'暂无数据'" background="#f7f7f7"></app-no-goods>
+			<view class="no-more" v-if="isNoMore">没有更多了...</view>
+			<app-no-goods v-if="dataList.length===0" :title="'暂无数据'" background="#f7f7f7"></app-no-goods>
 		</view>
 		<template>
 			<view class="safe-area-inset-bottom">
@@ -116,12 +107,13 @@
 			<app-tab-bar :page-count="0"></app-tab-bar>
 		</template>
 	</view>
-	<!-- </app-layout> -->
+	</app-layout>
 </template>
 
 <script>
 	import {
-		mapGetters
+		mapGetters,
+		mapState
 	} from 'vuex'
 	import AppTabBar from '@/components/basic-component/app-tab-bar/app-tab-bar.vue';
 	import AppDropdownMenu from '@/components/fui-dropdown-menu/fui-dropdown-menu.vue';
@@ -134,6 +126,7 @@
 		},
 		data() {
 			return {
+				dataList:[{}],
 				options: [
 					[{
 						text: '订单状态',
@@ -162,18 +155,60 @@
 				range1: '全部客户',
 				selectIndex: 0,
 				rangeShow: false,
-				rangeShow1: false
+				rangeShow1: false,
+				
+				
+				keyword:'',
+				page:1,
+				isNoMore:false,
 			};
 		},
 		computed: {
 			...mapGetters('mallConfig', {
 				getTheme: 'getTheme'
+			}),
+			...mapState({
+				info:state=>state.user.info
 			})
 		},
 		onShow() {
 			uni.hideHomeButton()
+			this.getDataList()
+		},
+		onReachBottom() {
+			if(!this.isNoMore){
+				this.page++
+				this.getDataList()
+			}
 		},
 		methods: {
+			getDataList(){
+				this.$showLoading()
+				this.$request({
+					url:this.$api.order.list,
+					data:{
+						status: 0,
+						keyword: this.keyword,
+						dateArr: [],
+						page: this.page,
+						sale_id:this.info.salesperson_id
+					},
+					method:'get'
+				}).then(res=>{
+					this.$hideLoading()
+					if(res.code===0){
+						if(this.page===1){
+							this.dataList=res.data.list
+						}else{
+							this.dataList=this.dataList.concat(res.data.list) 
+						}
+						if(res.data.list.length<20){
+							this.isNoMore=true
+						}
+					}
+				})
+			},
+			
 			filterTap(i) {
 				this.selectIndex = i
 				//显示下拉框
@@ -452,7 +487,7 @@
 		font-size: 24rpx;
 		font-weight: 500;
 		color: #666666;
-		margin-top: 37rpx;
 		text-align: center;
+		line-height: 80rpx;
 	}
 </style>

+ 1 - 1
src/pages/sale/properties/addProperties.vue

xqd
@@ -75,7 +75,7 @@
 					let currPage = pages[pages.length - 1]; //当前页面
 					let prevPage = pages[pages.length - 2]; //上一个页面
 					let multiIndex=[item.province_id,item.city_id,item.district_id]
-					prevPage.$vm.estateInfo={id:id,name:name,multiIndex:multiIndex,address:item.address}
+					prevPage.$vm.estateInfo={id:id,name:name,multiIndex:multiIndex,address:item.address,property:item.property}
 				this.selectIndex=index
 				this.show=true
 			},

+ 11 - 7
src/pages/sale/salePersonInfo.vue

xqd xqd xqd xqd xqd
@@ -3,7 +3,7 @@
 		<view class="main-between cross-center list-item">
 			<view class="title">头像</view>
 			<view class="main-right cross-center">
-				<image class="head" src="../../static/image/index/head_port.png" mode=""></image>
+				<image class="head" :src="info.salesperson_info?info.avatar:'../../static/image/index/head_port.png'" mode=""></image>
 				<image class="arrow-right" src="../../static/image/index/arrow-right-gray.png" mode=""></image>
 			</view>
 		</view>
@@ -11,7 +11,7 @@
 		<view class="main-between cross-center list-item">
 			<view class="title">姓名</view>
 			<view class="main-right cross-center">
-				<input class="input" type="text" v-model="name" />
+				<input class="input" type="text" v-model="info.salesperson_info.name" disabled />
 				<image class="arrow-right" src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode=""></image>
 			</view>
 		</view>
@@ -19,7 +19,7 @@
 		<view class="main-between cross-center list-item">
 			<view class="title">电话号</view>
 			<view class="main-right cross-center">
-				<input class="input" type="text" v-model="mobile" />
+				<input class="input" type="text" v-model="info.salesperson_info.mobile" disabled />
 				<image class="arrow-right" src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode=""></image>
 			</view>
 		</view>
@@ -27,7 +27,7 @@
 		<view class="main-between cross-center list-item">
 			<view class="title">性别</view>
 			<view class="main-right cross-center">
-				<input class="input" type="text" v-model="sex" />
+				<input class="input" type="text" :value="info.salesperson_info.sex=='1'?'男':'女'" disabled />
 				<image class="arrow-right" src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode=""></image>
 			</view>
 		</view>
@@ -35,13 +35,17 @@
 </template>
 
 <script>
+	import {mapState} from "vuex"
 	export default {
 		data() {
 			return {
-				name:'万老三',
-				mobile:'13350561213',
-				sex:'男'
+				
 			};
+		},
+		computed:{
+			...mapState({
+				info:state=>state.user.info
+			})
 		}
 	}
 </script>

+ 13 - 0
src/pages/sale/sale_login/sale_login.vue

xqd xqd
@@ -23,6 +23,7 @@
 </template>
 
 <script>
+	import {mapState} from "vuex"
 	export default {
 		data() {
 			return {
@@ -30,6 +31,18 @@
 				password:'qweqweqwe',
 			};
 		},
+		computed:{
+			...mapState({
+				info:state => state.user.info
+			})
+		},
+		onLoad() {
+			if(this.info.salesperson_info){
+				uni.navigateTo({
+					url:'/pages/sale/sale-user-center'
+				})
+			}
+		},
 		methods:{
 			login(){
 				this.$request({

+ 1 - 1
src/pages/topic/list.vue

xqd
@@ -1,7 +1,7 @@
 <template>
     <app-layout>
         <view class="list">
-            <app-nav-bar v-if="navbarStatus" :fixed="true" :has-height="true"  @headHeight="headHeight" title="专题列表" color="block" background-color="white"></app-nav-bar>
+            <app-nav-bar v-if="navbarStatus" :fixed="true" :has-height="true"  @headHeight="headHeight" title="主题专区" color="block" background-color="white"></app-nav-bar>
             <view class="w-fixed" :style="{top: startHeight + 'px'}">
                 <view class="w-search dir-left-nowrap cross-center">
                     <view class="box-grow-1 w-input">

+ 2 - 2
src/pages/topic/topic.vue

xqd xqd
@@ -57,7 +57,7 @@
             </view>
             <view style="height: 111rpx"></view>
             <view class="detail-navbar dir-left-nowrap cross-center">
-                <view v-if="detail.is_favorite == 1" class="box-grow-1 dir-left-nowrap cross-center main-center"
+               <!-- <view v-if="detail.is_favorite == 1" class="box-grow-1 dir-left-nowrap cross-center main-center"
                       @click="handleLove('no_love',detail)">
                     <view>
                         <image :style="{'background-color': getTheme.background}" src="./image/weitao-love-a.png"></image>
@@ -70,7 +70,7 @@
                     <image src="./image/weitao-love.png"></image>
                     <view>收藏</view>
                 </view>
-                <view class="box-grow-0 line"></view>
+                <view class="box-grow-0 line"></view> -->
                 <view class="box-grow-1 dir-left-nowrap cross-center main-center" @click="isShare = true">
                     <image src="./image/weitao-detail-share.png"></image>
                     <view>分享</view>

BIN
src/static/image/index/img-coupon-bg-0.png


+ 17 - 2
src/store/modules/user.js

xqd xqd xqd xqd xqd xqd xqd
@@ -3,6 +3,7 @@ import user from '../../core/user.js';
 
 const state = {
 	accessToken: null,
+	customerAccessToken: null,
 	info: null,
 	showLoginModal: false,
 	tempParentId: 0,
@@ -20,12 +21,16 @@ const state = {
 	selectedProperties: uni.getStorageSync('selectedProperties')?uni.getStorageSync('selectedProperties'):{name: '绑定楼盘'},
 
 	isEnterSales: false, //是否进入销售端
+	isOrderBehalfBustomers: false, //是否代客下单
 };
 
 const getters = {
 	accessToken(state) {
 		return state.accessToken;
 	},
+	customerAccessToken(state) {
+		return state.customerAccessToken;
+	},
 	info(state) {
 		return state.info;
 	},
@@ -55,6 +60,9 @@ const getters = {
 	},
 	getIsEnterSales(state) {
 		return state.isEnterSales;
+	},
+	getIsOrderBehalfBustomers(state) {
+		return state.isOrderBehalfBustomers;
 	}
 };
 
@@ -62,6 +70,9 @@ const mutations = {
 	accessToken(state, data) {
 		state.accessToken = data;
 	},
+	customerAccessToken(state, data) {
+		state.customerAccessToken = data;
+	},
 	info(state, data) {
 		state.info = data;
 	},
@@ -94,6 +105,9 @@ const mutations = {
 		}
 		state.isEnterSales = data;
 	},
+	isOrderBehalfBustomers(state,data){
+		state.isOrderBehalfBustomers = data;
+	},
 	selectedProperties(state, data) {
 		state.selectedProperties = data
 	}
@@ -128,6 +142,9 @@ const actions = {
 			context.commit('accessToken', accessToken);
 			user.getInfo(options).then(data => {
 				context.commit('info', data);
+				if(context.state.selectedProperties.id==undefined){
+					context.dispatch('selectedProperties', data.estate);
+				}
 			});
 		}).catch((err) => {
 			context.commit('showLoginModal', true);
@@ -173,8 +190,6 @@ const actions = {
 	},
 	selectedProperties(context, data){
 		context.commit('selectedProperties', data);
-		// Vue.prototype.$store.setStorageSync('selectedProperties',data)
-		
 		uni.setStorageSync('selectedProperties',data)
 	}
 };