shish 1 год назад
Родитель
Сommit
8c5b490ea3
3 измененных файлов с 39 добавлено и 38 удалено
  1. 37 36
      ghs/src/views/in/refund-list.vue
  2. 1 1
      ghs/src/views/order/list.vue
  3. 1 1
      ghs/src/views/order/refund-list.vue

+ 37 - 36
ghs/src/views/in/refund-list.vue

@@ -13,7 +13,7 @@
 			</template>
 			</template>
 
 
             <template #table-column-status="{scope}">
             <template #table-column-status="{scope}">
-				{{ scope.row.status==0?'待审核': scope.row.status==1 ? '已通过' : scope.row.status==2 ? '已驳回' : scope.row.status==3?'已取消':'其他' }}
+				{{ scope.row.status==0?'审核中': scope.row.status==1? '已完成' : '其它' }}
 			</template>
 			</template>
 
 
 			<template #slot-export-order>
 			<template #slot-export-order>
@@ -39,27 +39,28 @@
 			</template>
 			</template>
 
 
 			<template #slot-search-option="{scope}">
 			<template #slot-search-option="{scope}">
-        		<el-input v-model="customName" placeholder="客户名称" size="mini" style="width:110px;" :clearable="true" ref="customSearchRef" @input="changeSearch()" @focus="name=''"></el-input>
+
+				<el-select @change="getCurrentGhs" v-model="currentGhsName" filterable remote reserve-keyword placeholder="搜索供货商" clearable 
+				:remote-method="searchGhs" :loading="loading" style="width:130px;margin-right:10px;" size="mini">
+    				<el-option v-for="item in ghsList" :key="item.id" :label="`${item.name}`" :value="item.id"></el-option>
+  				</el-select>
+
 				<el-select size="mini" v-model="currentStaffName" placeholder="操作人" style="width:110px;margin-left:8px;" @change="getKdStaff" :clearable="true">
 				<el-select size="mini" v-model="currentStaffName" placeholder="操作人" style="width:110px;margin-left:8px;" @change="getKdStaff" :clearable="true">
 					<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item.id"></el-option>
 					<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item.id"></el-option>
 				</el-select>
 				</el-select>
-				<span style="margin-left:9px;font-size:18px;">订单日期:</span>
+				<span style="margin-left:9px;font-size:16px;">采购日期:</span>
 				<el-date-picker v-model="currentDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchDate" value-format="yyyy-MM-dd"
 				<el-date-picker v-model="currentDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchDate" value-format="yyyy-MM-dd"
 					class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
 					class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
 				</el-date-picker>
 				</el-date-picker>
-				<span style="margin-left:9px;font-size:18px;">售后申请日期:</span>
+				<span style="margin-left:9px;font-size:16px;">售后申请日:</span>
 				<el-date-picker v-model="currentRefundDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchRefundDate" value-format="yyyy-MM-dd"
 				<el-date-picker v-model="currentRefundDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchRefundDate" value-format="yyyy-MM-dd"
 					class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
 					class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
 				</el-date-picker>
 				</el-date-picker>
 
 
-				<el-radio-group v-model="status" @change="changeStatus" style="margin-right:20px;padding-top:6px;margin-left:4px;">
-					<el-radio label="-1">全部</el-radio>
-					<el-radio label="0">待审</el-radio>
-					<el-radio label="1">通过</el-radio>
-					<el-radio label="2">驳回</el-radio>
-					<el-radio label="3">取消</el-radio>
-				</el-radio-group>
+			</template>
 
 
+			<template #slot-total-amount>
+				<span style="font-size:15px;font-weight:bold;margin-left:15px;">总金额:{{ totalRefundPrice }}</span>
 			</template>
 			</template>
 
 
 		</x-crud>
 		</x-crud>
@@ -83,18 +84,13 @@ export default {
 					val: 0
 					val: 0
 				},
 				},
 				{
 				{
-					text: '已通过',
-					key: '1',
+					text: '审核中',
+					key: '0',
 					val: 0
 					val: 0
 				},
 				},
 				{
 				{
-					text: '已驳回',
-					key: '2',
-					val: 0
-				},
-				{
-					text: '已取消',
-					key: '3',
+					text: '已完成',
+					key: '1',
 					val: 0
 					val: 0
 				}
 				}
 			],
 			],
@@ -142,8 +138,12 @@ export default {
 			refundEndTime:'',
 			refundEndTime:'',
 			refundSearchTime:'',
 			refundSearchTime:'',
 			currentRefundDateList:[],
 			currentRefundDateList:[],
-			customName:'',
-			status:'-1'
+			status:'-1',
+			totalRefundPrice:0,
+			currentGhsName:'',
+			currentGhsId:0,
+			ghsList:[],
+			loading:false
 		};
 		};
 	},
 	},
 	computed: {
 	computed: {
@@ -156,23 +156,23 @@ export default {
 		that.$service.shopAdmin.getAllStaff().then(res => {
 		that.$service.shopAdmin.getAllStaff().then(res => {
 			that.staffList = res.list
 			that.staffList = res.list
 		})
 		})
-		this.$nextTick(() => {
-      		this.$refs.customSearchRef.focus()
-    	})
 	},
 	},
 	methods: {
 	methods: {
-		changeStatus(e){
-			this.status = e
+		getCurrentGhs(e){
+			this.currentGhsId = e
 			this.refreshData()
 			this.refreshData()
 		},
 		},
-		changeSearch(){
+		searchGhs(query) {
 			let that = this
 			let that = this
-			if(this.T != null){
-				clearTimeout(this.T)
+			if (query !== '') {
+				this.loading = true;
+				this.$service.ghs.list({name:query}).then(res=>{
+					that.loading = false
+					that.ghsList = res.list	
+				})
+			} else {
+				this.ghsList = []
 			}
 			}
-			this.T = setTimeout(function(){
-				that.refreshData()
-			},650)
 		},
 		},
 		getKdStaff(e){
 		getKdStaff(e){
 			this.currentStaffId = e
 			this.currentStaffId = e
@@ -204,17 +204,18 @@ export default {
 		},
 		},
 		refreshData(){
 		refreshData(){
       		this.app.refresh({status:this.tabIndex,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,refundSearchTime:this.refundSearchTime,refundStartTime:this.refundStartTime,
       		this.app.refresh({status:this.tabIndex,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,refundSearchTime:this.refundSearchTime,refundStartTime:this.refundStartTime,
-				refundEndTime:this.refundEndTime,customName:this.customName,shopAdminId:this.currentStaffId,status:this.status})
+				refundEndTime:this.refundEndTime,shopAdminId:this.currentStaffId,status:this.status,ghsId:this.currentGhsId})
     	},
     	},
 		exportData(){
 		exportData(){
 			this.$service.cgRefund.getList({status:this.tabIndex,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,refundSearchTime:this.refundSearchTime,refundStartTime:this.refundStartTime,
 			this.$service.cgRefund.getList({status:this.tabIndex,searchTime:this.searchTime,startTime:this.startTime,endTime:this.endTime,refundSearchTime:this.refundSearchTime,refundStartTime:this.refundStartTime,
-				refundEndTime:this.refundEndTime,customName:this.customName,shopAdminId:this.currentStaffId,status:this.status,pageSize:9999999,export:1}).then(res => {
+				refundEndTime:this.refundEndTime,shopAdminId:this.currentStaffId,status:this.status,pageSize:9999999,export:1,ghsId:this.currentGhsId}).then(res => {
 				if(res.file){
 				if(res.file){
 					window.location.href = res.file
 					window.location.href = res.file
 				}
 				}
 			})
 			})
 		},
 		},
 		handleClick() {
 		handleClick() {
+			this.status = this.tabIndex
 			this.refreshData()
 			this.refreshData()
 		},
 		},
 		onLoad({ ctx, app }) {
 		onLoad({ ctx, app }) {
@@ -310,7 +311,7 @@ export default {
 					['slot-tabs'],
 					['slot-tabs'],
 					['slot-search-option','flex1','slot-export-order'],
 					['slot-search-option','flex1','slot-export-order'],
 					['data-table'],
 					['data-table'],
-					['flex1', 'pagination']
+					['slot-total-amount','flex1', 'pagination']
 				])
 				])
 				.on('refresh', async (params, { next }) => {
 				.on('refresh', async (params, { next }) => {
 					let result = await next(params)
 					let result = await next(params)

+ 1 - 1
ghs/src/views/order/list.vue

@@ -150,7 +150,7 @@
 				<el-select size="mini" v-model="currentKdStaffName" placeholder="开单人" style="width:110px;margin-left:8px;" @change="getKdStaff" :clearable="true">
 				<el-select size="mini" v-model="currentKdStaffName" placeholder="开单人" style="width:110px;margin-left:8px;" @change="getKdStaff" :clearable="true">
 					<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item.id"></el-option>
 					<el-option v-for="item in staffList" :key="item.id" :label="item.name" :value="item.id"></el-option>
 				</el-select>
 				</el-select>
-        <span style="margin-left:9px;font-size:17px;">账单时间:</span>
+        <span style="margin-left:9px;font-size:16px;">账单时间:</span>
         <el-date-picker v-model="currentDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchDate" value-format="yyyy-MM-dd"
         <el-date-picker v-model="currentDateList" type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="开始日期" @change="getSearchDate" value-format="yyyy-MM-dd"
           class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
           class="custom-date-picker" end-placeholder="结束日期" :picker-options="pickerOptions" size="mini" style="margin-right:8px;">
         </el-date-picker>
         </el-date-picker>

+ 1 - 1
ghs/src/views/order/refund-list.vue

@@ -49,7 +49,7 @@
 			<template #slot-search-option="{scope}">
 			<template #slot-search-option="{scope}">
 
 
 				<el-select @change="getCurrentCustom" v-model="currentCustomName" filterable remote reserve-keyword placeholder="搜索客户" clearable 
 				<el-select @change="getCurrentCustom" v-model="currentCustomName" filterable remote reserve-keyword placeholder="搜索客户" clearable 
-				:remote-method="searchCustom" :loading="loading" style="width:160px;margin-right:10px;" size="mini">
+				:remote-method="searchCustom" :loading="loading" style="width:130px;margin-right:10px;" size="mini">
     				<el-option v-for="item in customList" :key="item.id" :label="`${item.name}`" :value="item.id"></el-option>
     				<el-option v-for="item in customList" :key="item.id" :label="`${item.name}`" :value="item.id"></el-option>
   				</el-select>
   				</el-select>