|
|
@@ -161,6 +161,18 @@
|
|
|
placeholder="最多"
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="归属组别" prop="deptId">
|
|
|
+ <el-cascader
|
|
|
+ v-model="queryParams.deptId"
|
|
|
+ :options="deptOptions"
|
|
|
+ :props="cascaderProps"
|
|
|
+ placeholder="请选择组别"
|
|
|
+ clearable
|
|
|
+ size="small"
|
|
|
+ style="width: 200px"
|
|
|
+ @change="handleDeptChange"
|
|
|
+ />
|
|
|
+ </el-form-item>
|
|
|
<el-form-item>
|
|
|
<el-button
|
|
|
type="primary"
|
|
|
@@ -1499,6 +1511,7 @@ import {
|
|
|
getScrmPrescribeInfo,
|
|
|
importCustomer
|
|
|
} from "@/api/qw/companyCustomer";
|
|
|
+import{treeselect} from "@/api/company/companyDept";
|
|
|
import { parseTime } from "@/utils/common";
|
|
|
import { getCitys } from "@/api/hisStore/city";
|
|
|
import CollectionInfoDialog from "./CollectionInfoDialog.vue";
|
|
|
@@ -1585,6 +1598,14 @@ export default {
|
|
|
}
|
|
|
};
|
|
|
return {
|
|
|
+ deptOptions: [], // 树形部门数据
|
|
|
+ cascaderProps: { // el-cascader 配置
|
|
|
+ value: 'id',
|
|
|
+ label: 'label',
|
|
|
+ children: 'children',
|
|
|
+ checkStrictly: true, // 允许选择任意层级
|
|
|
+ emitPath: false // 只返回选中节点的 value(即 id)
|
|
|
+ },
|
|
|
importLoading: false,
|
|
|
templateForm: {
|
|
|
id: null,
|
|
|
@@ -1613,6 +1634,7 @@ export default {
|
|
|
dateRange: [],
|
|
|
createTimeRange: [],
|
|
|
queryParams: {
|
|
|
+ deptId: null, // 归属组别ID
|
|
|
pageNum: 1,
|
|
|
pageSize: 10,
|
|
|
customerName: null,
|
|
|
@@ -1826,8 +1848,18 @@ export default {
|
|
|
questionOptions(3).then((response) => {
|
|
|
this.questionOptions = response.rows;
|
|
|
});
|
|
|
+ //获取部门树
|
|
|
+ treeselect().then(response => {
|
|
|
+ this.deptOptions = response.data || [];
|
|
|
+ }).catch(() => {
|
|
|
+ this.deptOptions = [];
|
|
|
+ });
|
|
|
},
|
|
|
methods: {
|
|
|
+ /** 归属组别变化时自动搜索 */
|
|
|
+ handleDeptChange(value) {
|
|
|
+ this.handleQuery();
|
|
|
+ },
|
|
|
/** 下载导入模板 */
|
|
|
downloadTemplate() {
|
|
|
// 模板文件路径(放在 public/template/ 目录下)
|
|
|
@@ -2552,6 +2584,8 @@ export default {
|
|
|
this.queryParams.myCustomerFlag = true; // 保持默认选中
|
|
|
this.queryParams.processStatus = null;
|
|
|
this.handleQuery();
|
|
|
+ // 清空归属组别
|
|
|
+ this.queryParams.deptId = null;
|
|
|
},
|
|
|
handleClaim(row) {
|
|
|
this.currentClaimRow = row;
|