shish il y a 1 an
Parent
commit
c655f08cdf
1 fichiers modifiés avec 23 ajouts et 9 suppressions
  1. 23 9
      ghs/src/views/order/list.vue

+ 23 - 9
ghs/src/views/order/list.vue

@@ -146,6 +146,9 @@
 
       <template #slot-search-option="{scope}">
         <el-input v-model="name" placeholder="客户名称 / 订单号" size="mini" style="width:150px;" :clearable="true" ref="orderSearchRef" @input="changeSearch()" @focus="name=''"></el-input>
+				<el-select size="mini" v-model="currentKdStaffName" placeholder="开单人" style="width:110px;margin-left:10px;" @change="getKdStaff" :clearable="true">
+					<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item.id"></el-option>
+				</el-select>
         <span style="margin-left:9px;font-size:19px;">付款时间:</span>
         <el-date-picker v-model="currentDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchDate" value-format="yyyy-MM-dd"
                 end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:10px;">
@@ -322,7 +325,10 @@ export default {
       searchTime:'',
       name:'',
       currentRefundData:{},
-      refundRecordData:{}
+      refundRecordData:{},
+      currentKdStaffName:'',
+      currentKdStaffId:0,
+      staffList:[]
     };
   },
   created() {
@@ -344,9 +350,17 @@ export default {
     this.$nextTick(() => {
       this.$refs.orderSearchRef.focus()
     })
-  
+
+    that.$service.shopAdmin.getAllStaff().then(res => {
+      that.staffList = res.list
+    })
+
 	},
   methods: {
+		getKdStaff(e){
+			this.currentKdStaffId = e
+      this.refreshData()
+		},
     doMore(cmd,data){
       if(cmd == 'cancel'){
         this.$message.error('开发中')
@@ -387,7 +401,7 @@ export default {
         clearTimeout(this.T)
       }
       this.T = setTimeout(function(){
-        that.app.refresh({ status: that.tabIndex,book:that.book,clearSign:that.clearSign,searchTime:that.searchTime,startTime:that.startTime,endTime:that.endTime,name:that.name })
+        that.app.refresh({ status: that.tabIndex,book:that.book,clearSign:that.clearSign,searchTime:that.searchTime,startTime:that.startTime,endTime:that.endTime,name:that.name,shopAdminId:this.currentKdStaffId })
       },650)			
 		},
     confirmReach(info){
@@ -423,11 +437,11 @@ export default {
     },
     changeClearSign(e){
       this.clearSign = e
-      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,name:this.name });
+      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,name:this.name,shopAdminId:this.currentKdStaffId });
     },
     changeBook(e){
       this.book = e
-      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,name:this.name });
+      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,name:this.name,shopAdminId:this.currentKdStaffId });
     },
     getSearchDate(){
       if (this.$util.isEmpty(this.currentDateList)) {
@@ -439,10 +453,10 @@ export default {
         this.startTime = this.currentDateList[0]
         this.endTime = this.currentDateList[1]
       }
-      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name})
+      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name,shopAdminId:this.currentKdStaffId})
     },
     refreshData(){
-      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name})
+      this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name,shopAdminId:this.currentKdStaffId})
     },
     todays(type) {
       var myDate = new Date();
@@ -537,7 +551,7 @@ export default {
       this.app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,name:this.name });
     },
 		exportData(){
-			this.$service.order.getOrderList({status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,pageSize:9999999,export:1,name:this.name}).then(res => {
+			this.$service.order.getOrderList({status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,pageSize:9999999,export:1,name:this.name,shopAdminId:this.currentKdStaffId}).then(res => {
 				if(res.file){
 					window.location.href = res.file
 				}
@@ -713,7 +727,7 @@ export default {
             this.tabsData[4].val = asset.shop.finishOrder||0;
           })
           .done();
-          app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name })
+          app.refresh({ status: this.tabIndex,book:this.book,clearSign:this.clearSign,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,name:this.name,shopAdminId:this.currentKdStaffId })
     },
     onSongSuccess() {