Commit 2d116d47 authored by Mac's avatar Mac

筛选处理

parent 311dabea
...@@ -270,8 +270,8 @@ export default { ...@@ -270,8 +270,8 @@ export default {
StuType: "", StuType: "",
CreateIds: [], CreateIds: [],
ExistCourseConsultant: "", //是否存在课程顾问(1-存在,2=不存在) ExistCourseConsultant: "", //是否存在课程顾问(1-存在,2=不存在)
CreateType:'', //客户来源 // CreateType:'', //客户来源
StuChannel: "" //收客渠道 // StuChannel: "" //收客渠道
}, },
dateArray: [], //日期数组 dateArray: [], //日期数组
pageCount: 0, pageCount: 0,
......
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
<div class="col-3"> <div class="col-3">
<q-select @input="resetSearch" filled option-value="CourseId" option-label="CourseName" v-model="msg.CourseId" clearable emit-value <q-select @input="resetSearch" filled option-value="CourseId" option-label="CourseName" v-model="msg.CourseId" clearable emit-value
use-input :options="myCourseList" label="课程" dense use-input :options="myCourseList" label="课程" dense
map-options @filter="filterFn" map-options @filter="filterFnkec"
/> />
</div> </div>
<div class="col-3"> <div class="col-3">
...@@ -109,7 +109,7 @@ ...@@ -109,7 +109,7 @@
</div> </div>
<div class="col-3"> <div class="col-3">
<q-select <q-select
@input="resetSearch" @input="msg.StuSourceId='',msg.StuChannel='',resetSearch()"
dense dense
clearable clearable
filled filled
...@@ -122,7 +122,7 @@ ...@@ -122,7 +122,7 @@
label="客户来源" label="客户来源"
/> />
</div> </div>
<div class="col-3"> <div class="col-3" v-if="msg.CreateType==1">
<q-select filled v-model="msg.StuChannel" @input="resetSearch" label="收客渠道" dense :options="StuChannelList" option-label="Name" option-value="Id" emit-value map-options use-input clearable <q-select filled v-model="msg.StuChannel" @input="resetSearch" label="收客渠道" dense :options="StuChannelList" option-label="Name" option-value="Id" emit-value map-options use-input clearable
@filter="filterStuChannel"> @filter="filterStuChannel">
<template v-slot:no-option> <template v-slot:no-option>
...@@ -133,6 +133,29 @@ ...@@ -133,6 +133,29 @@
</q-item> </q-item>
</template> </template>
</q-select> </q-select>
</div>
<div class="col-3" v-if="msg.CreateType==2">
<q-select filled v-model="msg.StuSourceId" dense :options="customList" use-input label="关联同行"
@filter="filterFn" option-label="CustomerName" @input="resetSearch" clearable
option-value="CustomerId" emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
</div>
<div class="col-3" v-if="msg.CreateType==3">
<q-select filled v-model="msg.StuSourceId" dense @filter="filterEmployee" label="介绍人"
use-input :options="myEmployeeList" option-label="EmployeeName" @input="resetSearch" clearable
option-value="Id" emit-value map-options />
</div>
<div class="col-3" v-if="msg.CreateType==4">
<q-select filled v-model="msg.StuSourceId" dense use-input @filter="filterStudent" label="转介人"
:options="MyTransListData" option-label="StuName" @input="resetSearch" clearable
option-value="StuId" emit-value map-options />
</div> </div>
<div class="col-3"> <div class="col-3">
<q-field filled dense> <q-field filled dense>
...@@ -348,17 +371,20 @@ import { ...@@ -348,17 +371,20 @@ import {
queryCourseDropdownList, queryCourseDropdownList,
} from '../../api/course/index' } from '../../api/course/index'
import { queryEmployee } from "../../api/users/user"; import { queryEmployee } from "../../api/users/user";
import { import {
queryGuestStateList, queryGuestStateList,
CreateTypeList, CreateTypeList,
GetStuChannelList GetStuChannelList,
GetCustomerList
} from "../../api/sale/sale.js"; } from "../../api/sale/sale.js";
import { import {
queryStuStageList, queryStuStageList,
GetStudentTypeList, GetStudentTypeList,
GetPersonalDimension, GetPersonalDimension,
getSchoolDropdown getSchoolDropdown,
getStudentDorpDownList
} from "../../api/school/index"; } from "../../api/school/index";
import studentRightForm from "../../components/school/student/studentRight-form"; import studentRightForm from "../../components/school/student/studentRight-form";
import studentFUForm from "../../components/school/student/studentFu-form"; import studentFUForm from "../../components/school/student/studentFu-form";
...@@ -397,7 +423,7 @@ export default { ...@@ -397,7 +423,7 @@ export default {
ConsultantId:'',//课程顾问 ConsultantId:'',//课程顾问
CreateType:'', //客户来源 CreateType:'', //客户来源
StuChannel: "", //收客渠道 StuChannel: "", //收客渠道
StuSourceId:''
}, },
//归属类型列表 //归属类型列表
...@@ -447,7 +473,14 @@ export default { ...@@ -447,7 +473,14 @@ export default {
customFromList: [], //客户来源 customFromList: [], //客户来源
StuChannelList: [], //收客渠道 StuChannelList: [], //收客渠道
allStuChannelList: [], //所有收客渠道 allStuChannelList: [], //所有收客渠道
customList: [], //同行列表
allCustomList: [], //所有同行列表
//员工列表
employeeList: [],
myEmployeeList: [],
TransListData: [], //转介人数据
MyTransListData: [],
} }
...@@ -471,6 +504,9 @@ export default { ...@@ -471,6 +504,9 @@ export default {
this.getRole() this.getRole()
this.getCustomFrom(); this.getCustomFrom();
this.GetStuChannelList(); this.GetStuChannelList();
this.GetCustomerList();
this.getEmployeeList()
this.getStudentDorpDown()
}, },
methods: { methods: {
...@@ -506,6 +542,65 @@ export default { ...@@ -506,6 +542,65 @@ export default {
} }
}); });
}, },
//获取客户下拉数据
GetCustomerList() {
let msg = {
QCreateBy: 0
};
GetCustomerList(msg).then(res => {
if (res.Code == 1) {
this.customList = res.Data;
this.allCustomList = res.Data;
}
});
},
//筛选客户
filterFn(val, update) {
update(() => {
if (val === "") {
this.customList = JSON.parse(JSON.stringify(this.allCustomList));
} else {
const needle = val.toLowerCase();
this.customList = this.allCustomList.filter(
v => v.CustomerName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取员工列表
getEmployeeList() {
queryEmployee({
IsLeave: 1
}).then(res => {
this.employeeList = res.Data;
this.myEmployeeList = res.Data;
});
},
//筛选员工
filterEmployee(val, update, abort) {
update(() => {
this.myEmployeeList = this.employeeList.filter(
v => v.EmployeeName.indexOf(val) > -1
);
});
},
//获取转介人下拉
getStudentDorpDown() {
getStudentDorpDownList().then(res => {
if (res.Code == 1) {
this.TransListData = res.Data;
this.MyTransListData = res.Data;
}
});
},
//筛选转介人
filterStudent(val, update, abort) {
update(() => {
this.MyTransListData = this.TransListData.filter(
v => v.StuName.indexOf(val) > -1
);
});
},
getRole() { getRole() {
queryEmployee({ queryEmployee({
IsLeave: 1, IsLeave: 1,
...@@ -596,6 +691,9 @@ export default { ...@@ -596,6 +691,9 @@ export default {
if(msg.CreateType=='' ||msg.CreateType == null){ if(msg.CreateType=='' ||msg.CreateType == null){
msg.CreateType = 0 msg.CreateType = 0
} }
if(msg.StuSourceId=='' ||msg.StuSourceId == null){
msg.StuSourceId = 0
}
getStudentFollowUpPageList(msg).then(res => { getStudentFollowUpPageList(msg).then(res => {
this.loading = false; this.loading = false;
...@@ -676,7 +774,7 @@ export default { ...@@ -676,7 +774,7 @@ export default {
this.isShowStuFU = true; this.isShowStuFU = true;
}, },
filterFn(val, update) {//课程的栓选 filterFnkec(val, update) {//课程的栓选
update(() => { update(() => {
if (val === '') { if (val === '') {
this.myCourseList = this.allCourseList this.myCourseList = this.allCourseList
......
...@@ -232,7 +232,7 @@ ...@@ -232,7 +232,7 @@
</div> </div>
<div class="col-3"> <div class="col-3">
<q-select <q-select
@input="resetSearch" @input="msg.StuSourceId='',msg.StuChannelId='',resetSearch()"
:dense="false" :dense="false"
clearable clearable
filled filled
...@@ -245,7 +245,7 @@ ...@@ -245,7 +245,7 @@
label="客户来源" label="客户来源"
/> />
</div> </div>
<div class="col-3"> <div class="col-3" v-if="msg.CreateType==1">
<q-select filled v-model="msg.StuChannelId" @input="resetSearch" label="收客渠道" :dense="false" :options="StuChannelList" option-label="Name" option-value="Id" emit-value map-options use-input clearable <q-select filled v-model="msg.StuChannelId" @input="resetSearch" label="收客渠道" :dense="false" :options="StuChannelList" option-label="Name" option-value="Id" emit-value map-options use-input clearable
@filter="filterStuChannel"> @filter="filterStuChannel">
<template v-slot:no-option> <template v-slot:no-option>
...@@ -257,6 +257,30 @@ ...@@ -257,6 +257,30 @@
</template> </template>
</q-select> </q-select>
</div> </div>
<div class="col-3" v-if="msg.CreateType==2">
<q-select filled v-model="msg.StuSourceId" :dense="false" :options="customList" use-input label="关联同行"
@filter="filterFn" option-label="CustomerName" @input="resetSearch" clearable
option-value="CustomerId" emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
</div>
<div class="col-3" v-if="msg.CreateType==3">
<q-select filled v-model="msg.StuSourceId" :dense="false" @filter="filterEmployee" label="介绍人"
use-input :options="myEmployeeList" option-label="EmployeeName" @input="resetSearch" clearable
option-value="Id" emit-value map-options />
</div>
<div class="col-3" v-if="msg.CreateType==4">
<q-select filled v-model="msg.StuSourceId" :dense="false" use-input @filter="filterStudent" label="转介人"
:options="MyTransListData" option-label="StuName" @input="resetSearch" clearable
option-value="StuId" emit-value map-options />
</div>
</div> </div>
</div> </div>
<div class="page-content"> <div class="page-content">
...@@ -409,6 +433,7 @@ ...@@ -409,6 +433,7 @@
import { import {
getSchoolDropdown, getSchoolDropdown,
getClassDropDownList, getClassDropDownList,
getStudentDorpDownList
} from "../../api/school/index"; } from "../../api/school/index";
import { import {
queryCourseDropdownList queryCourseDropdownList
...@@ -422,7 +447,8 @@ ...@@ -422,7 +447,8 @@
queryGuestStateList, queryGuestStateList,
CreateTypeList, CreateTypeList,
GetStuChannelList GetStuChannelList,
GetCustomerList
} from "../../api/sale/sale.js"; } from "../../api/sale/sale.js";
import MoreQuery from "../../components/stuMan/moreQuery.vue"; import MoreQuery from "../../components/stuMan/moreQuery.vue";
import StopLessonForm from "../../components/teacher/stopLessonForm"; import StopLessonForm from "../../components/teacher/stopLessonForm";
...@@ -433,7 +459,9 @@ ...@@ -433,7 +459,9 @@
import list from "../../components/stuMan/makeUpHours.vue"; //可补课课时,缺勤次数,请假次数 import list from "../../components/stuMan/makeUpHours.vue"; //可补课课时,缺勤次数,请假次数
import eventLog from "../../components/stuMan/eventRecord.vue"; //事件记录 import eventLog from "../../components/stuMan/eventRecord.vue"; //事件记录
import studentRightForm from "../../components/school/student/studentRight-form"; import studentRightForm from "../../components/school/student/studentRight-form";
import {
queryEmployee
} from "../../api/users/user";
export default { export default {
meta: { meta: {
title: "学员名单", title: "学员名单",
...@@ -473,7 +501,8 @@ ...@@ -473,7 +501,8 @@
EndOrderTime: "", //下单结束时间 EndOrderTime: "", //下单结束时间
GuestState: "", //学员状态 GuestState: "", //学员状态
CreateType:'', //客户来源 CreateType:'', //客户来源
StuChannelId: "" //收客渠道 StuChannelId: "" ,//收客渠道
StuSourceId:'',
}, },
pageCount: 0, pageCount: 0,
columns: [{ columns: [{
...@@ -500,6 +529,22 @@ ...@@ -500,6 +529,22 @@
name: "TeacherManager", name: "TeacherManager",
label: "协助老师", label: "协助老师",
align: "left" align: "left"
},
{
name: "CreateTypeName",
label: "客户来源",
field: "CreateTypeName",
align: "left",
},{
name: "StuSourceIdName",
label: "来源关联人",
field: "StuSourceIdName",
align: "left",
},{
name: "StuChannelName",
label: "收客渠道",
field: "StuChannelName",
align: "left",
}, },
{ {
name: "Mobile", name: "Mobile",
...@@ -615,22 +660,7 @@ ...@@ -615,22 +660,7 @@
field: "EventlogNum", field: "EventlogNum",
align: "left", align: "left",
}, },
{
name: "CreateTypeName",
label: "客户来源",
field: "CreateTypeName",
align: "left",
},{
name: "StuSourceIdName",
label: "来源关联人",
field: "StuSourceIdName",
align: "left",
},{
name: "StuChannelName",
label: "收客渠道",
field: "StuChannelName",
align: "left",
},
{ {
name: "GuestStateStr", name: "GuestStateStr",
label: "状态", label: "状态",
...@@ -701,9 +731,19 @@ ...@@ -701,9 +731,19 @@
BelongType:1, BelongType:1,
isShowStuRight:false, isShowStuRight:false,
isJudgeTrans:1, isJudgeTrans:1,
customFromList: [], //客户来源
StuChannelList: [], //收客渠道 customFromList: [], //客户来源
allStuChannelList: [], //所有收客渠道 StuChannelList: [], //收客渠道
allStuChannelList: [], //所有收客渠道
customList: [], //同行列表
allCustomList: [], //所有同行列表
//员工列表
employeeList: [],
myEmployeeList: [],
TransListData: [], //转介人数据
MyTransListData: [],
}; };
}, },
...@@ -717,8 +757,12 @@ ...@@ -717,8 +757,12 @@
this.getTypeEnum(); this.getTypeEnum();
this.getEarlyWarningEnum(); this.getEarlyWarningEnum();
this.getList(); this.getList();
this.getCustomFrom(); this.getCustomFrom();
this.GetStuChannelList(); this.GetStuChannelList();
this.GetCustomerList();
this.getEmployeeList()
this.getStudentDorpDown()
}, },
methods: { methods: {
//获取收客渠道 //获取收客渠道
...@@ -753,6 +797,68 @@ ...@@ -753,6 +797,68 @@
} }
}); });
}, },
//获取客户下拉数据
GetCustomerList() {
let msg = {
QCreateBy: 0
};
GetCustomerList(msg).then(res => {
if (res.Code == 1) {
this.customList = res.Data;
this.allCustomList = res.Data;
}
});
},
//筛选客户
filterFn(val, update) {
update(() => {
if (val === "") {
this.customList = JSON.parse(JSON.stringify(this.allCustomList));
} else {
const needle = val.toLowerCase();
this.customList = this.allCustomList.filter(
v => v.CustomerName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取员工列表
getEmployeeList() {
queryEmployee({
IsLeave: 1
}).then(res => {
this.employeeList = res.Data;
this.myEmployeeList = res.Data;
});
},
//筛选员工
filterEmployee(val, update, abort) {
update(() => {
this.myEmployeeList = this.employeeList.filter(
v => v.EmployeeName.indexOf(val) > -1
);
});
},
//获取转介人下拉
getStudentDorpDown() {
getStudentDorpDownList().then(res => {
if (res.Code == 1) {
this.TransListData = res.Data;
this.MyTransListData = res.Data;
}
});
},
//筛选转介人
filterStudent(val, update, abort) {
update(() => {
this.MyTransListData = this.TransListData.filter(
v => v.StuName.indexOf(val) > -1
);
});
},
//获取学员状态列表 //获取学员状态列表
getGuestStateList() { getGuestStateList() {
queryGuestStateList({}).then(res => { queryGuestStateList({}).then(res => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment