瀏覽代碼

reactor:439 综合查询增加数据列;

zhangchong 1 月之前
父節點
當前提交
ff4da43e9d
共有 3 個文件被更改,包括 21 次插入6 次删除
  1. 2 0
      src/views/business/order/tableHeader.tsx
  2. 17 4
      src/views/business/visit/index.vue
  3. 2 2
      src/views/business/visit/todo.vue

+ 2 - 0
src/views/business/order/tableHeader.tsx

@@ -156,6 +156,8 @@ export const ZGTableHeader = [
 		sortable: true,
 		formatter: 'formatDate',
 	},
+	{ field: 'fromPhone', title: '来电号码', width: 140 },
+	{ field: 'contact', title: '联系电话', width: 140 },
 	{ field: 'orgLevelOneName', title: '一级部门', width: 140 },
 	{ field: 'orgLevelTwoName', title: '二级部门', width: 140 },
 	{ field: 'acceptType', title: '受理类型', width: 110 },

+ 17 - 4
src/views/business/visit/index.vue

@@ -1,7 +1,7 @@
 <template>
 	<div class="business-visit-container layout-padding">
 		<div class="layout-padding-auto layout-padding-view pd20">
-			<vxe-grid v-bind="gridOptions" ref="gridRef">
+			<vxe-grid v-bind="gridOptions" ref="gridRef" v-on="gridEvents">
 				<template #form>
 					<el-form :model="state.queryParams" ref="ruleFormRef" @submit.native.prevent inline :disabled="gridOptions.loading">
 						<el-form-item label="数据范围" prop="IsProvince">
@@ -191,7 +191,7 @@
 						<el-option label="否" :value="false" />
 					</el-select>
 				</el-form-item>
-				<el-form-item label="是否有修改记录" prop="IsUpdate" v-if="['ZiGong','LuZhou'].includes(themeConfig.appScope)" label-width="110px">
+				<el-form-item label="是否有修改记录" prop="IsUpdate" v-if="['ZiGong', 'LuZhou'].includes(themeConfig.appScope)" label-width="110px">
 					<el-select v-model="state.queryParams.IsUpdate" placeholder="请选择是否有修改记录" class="w100" clearable @change="handleQuery">
 						<el-option label="是" :value="true" />
 						<el-option label="否" :value="false" />
@@ -273,7 +273,9 @@ const state = reactive<any>({
 		CreationTimeStart: null,
 		CreationTimeEnd: null,
 		OrderTagCode: null,
-		IsUpdate:null, // 是否有修改记录
+		IsUpdate: null, // 是否有修改记录
+		SortField: null, // 排序字段
+		SortRule: null, // 排序方式
 	},
 	tableData: [], //表单
 	loading: false, // 加载
@@ -345,24 +347,28 @@ const gridOptions = reactive<any>({
 			title: '受理时间',
 			width: 160,
 			formatter: 'formatDate',
+			sortable: true,
 		},
 		{
 			field: 'order.filedTime',
 			title: '办结时间',
 			width: 160,
 			formatter: 'formatDate',
+			sortable: true,
 		},
 		{
 			field: 'publishTime',
 			title: '发布时间',
 			width: 160,
 			formatter: 'formatDate',
+			sortable: true,
 		},
 		{
 			field: 'creationTime',
 			title: '回访任务创建时间',
 			width: 160,
 			formatter: 'formatDate',
+			sortable: true,
 		},
 		{ field: 'employeeName', title: '回访人', width: 120 },
 		{
@@ -458,7 +464,14 @@ const queryList = () => {
 			});
 	});
 };
-
+const gridEvents = {
+	sortChange(val: any) {
+		state.queryParams.SortField = val.order ? val.field : null;
+		// 0 升序 1 降序
+		state.queryParams.SortRule = val.order ? (val.order == 'desc' ? 1 : 0) : null;
+		handleQuery();
+	},
+};
 /** 重置按钮操作 */
 const drawerRuleFormRef = ref();
 const ruleFormRef = ref<RefType>(); // 表单ref

+ 2 - 2
src/views/business/visit/todo.vue

@@ -268,8 +268,8 @@ const state = reactive<any>({
 		CreationTimeEnd: null,
 		AiVisitResult: null, //智能回访结果
 		IsAiVisit: null, // IsAiVisit
-		SortField: null,
-		SortRule: null,
+		SortField: null, // 排序字段
+		SortRule: null, // 排序方式
 		OrderTagCode:null, // 工单标签
 	},
 	tableData: [], //表单