Commit 713e2985 authored by zhengke's avatar zhengke

1

parent cc081d27
...@@ -33,17 +33,22 @@ ...@@ -33,17 +33,22 @@
</style> </style>
<template> <template>
<div> <div>
<div class="row wrap"> <q-btn label="新增" color="accent q-mb-lg" size="sm" @click="isShowAdd=true" />
<q-select filled stack-label option-label="Name" v-model="AssitMsg.AssistType" option-value="Id" <q-btn label="取消" style="margin-left:20px;" v-if="isShowAdd" flat color="grey-10 q-mb-lg" size="sm"
:options="AssistDropList" label="角色" dense class="col-6 q-pb-lg q-pr-lg" emit-value map-options /> @click="isShowAdd=false" />
<q-select filled dense v-model="AssitMsg.AssistId" @filter="filterEmployee" use-input :options="myEmployeeList" <template v-if="isShowAdd">
option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value map-options /> <div class="row wrap">
<i class="iconfont icon-close delAssist"></i> <q-select filled stack-label option-label="Name" v-model="AssitMsg.AssistType" option-value="Id"
</div> :options="AssistDropList" label="角色" dense class="col-6 q-pb-lg q-pr-lg" emit-value map-options />
<div class="row wrap" style="margin-bottom:10px;float:right;"> <q-select filled dense v-model="AssitMsg.AssistId" @filter="filterEmployee" use-input :options="myEmployeeList"
<q-btn label="保存" color="accent q-mb-lg" size="md" @click="saveAssit()" /> option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value map-options />
</div> <i class="iconfont icon-close delAssist"></i>
<div> </div>
<div class="row wrap" style="margin-bottom:10px;float:right;">
<q-btn label="保存" color="accent q-mb-lg" size="md" @click="saveAssit()" />
</div>
</template>
<div v-if="dataList.length>0">
<table class="studentAssitTable" style="border:1px solid #f2f2f2;border-collapse:collapse;" cellspacing="0" <table class="studentAssitTable" style="border:1px solid #f2f2f2;border-collapse:collapse;" cellspacing="0"
cellpadding="0"> cellpadding="0">
<tr> <tr>
...@@ -158,13 +163,17 @@ ...@@ -158,13 +163,17 @@
position: 'top' position: 'top'
}) })
this.getList(); this.getList();
this.isShowAdd = false;
this.clearMsg();
} }
}).catch(() => { }).catch(() => {
}) })
}, },
clearMsg(){ clearMsg() {
this.AssitMsg.Id = 0;
this.AssitMsg.AssistId = 1;
this.AssitMsg.AssistType = 1;
}, },
//获取数据 //获取数据
getList() { getList() {
...@@ -198,13 +207,14 @@ ...@@ -198,13 +207,14 @@
}) })
that.getList() that.getList()
}) })
}).onCancel(() => {}); }).onCancel(() => {});
}, },
//获取修改数据 //获取修改数据
getEditInfo(obj) { getEditInfo(obj) {
this.AssitMsg.Id = obj.Id; this.AssitMsg.Id = obj.Id;
this.AssitMsg.AssistId = obj.AssistId; this.AssitMsg.AssistId = obj.AssistId;
this.AssitMsg.AssistType = obj.AssistType; this.AssitMsg.AssistType = obj.AssistType;
this.isShowAdd=true;
} }
} }
} }
......
...@@ -91,6 +91,15 @@ ...@@ -91,6 +91,15 @@
methods: { methods: {
//保存跟进 //保存跟进
saveFlow() { saveFlow() {
if(this.flowMsg.Remark==''){
this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请输入内容!',
})
return;
}
saveStudentFollow(this.flowMsg).then(res => { saveStudentFollow(this.flowMsg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
......
...@@ -66,9 +66,9 @@ ...@@ -66,9 +66,9 @@
<div class="info_content" style="margin-bottom:0;"> <div class="info_content" style="margin-bottom:0;">
<div class="customer_info_component"> <div class="customer_info_component">
<div class="customer_info_Stage"> <div class="customer_info_Stage">
<div class="stage_label">客户名称</div> <div class="stage_label" style="margin-top:-16px;">客户名称</div>
<div class="stage_value"> <div class="stage_value">
<q-input filled v-model="customObj.StuName" dense></q-input> <q-input filled v-model="customObj.StuName" style="width:182px;" :rules="[val => !!val || '请输入客户名称']" ref="StuName" dense></q-input>
</div> </div>
</div> </div>
</div> </div>
...@@ -83,32 +83,27 @@ ...@@ -83,32 +83,27 @@
</div> </div>
<div class="customer_info_component"> <div class="customer_info_component">
<div class="customer_info_Stage"> <div class="customer_info_Stage">
<div class="stage_label">电话</div> <div class="stage_label" style="margin-top:-16px;">电话</div>
<div class="stage_value"> <div class="stage_value">
<q-input filled v-model="customObj.StuTel" dense></q-input> <q-input filled v-model="customObj.StuTel" style="width:182px;" :rules="[val => !!val || '请输入电话号码']" ref="StuTel" dense></q-input>
</div> </div>
</div> </div>
</div> </div>
<div class="customer_info_component"> <div class="custom_Line"></div>
<div class="customer_info_Stage"> <div class="info_title">基本资料</div>
<div class="stage_label">出生日期</div> <div class="info_content">
<div class="stage_value"> <div class="info_item studentDate">
<q-input filled v-model="customObj.StuBirth" dense style="width:182px;" mask="date" label="出生日期"> <div class="item_label">出生日期</div>
<template v-slot:append> <div class="item_value">
<q-icon name="event" class="cursor-pointer"> <q-field filled dense>
<q-popup-proxy ref="qDateProxy1" transition-show="scale" transition-hide="scale">  <template v-slot:control>
<q-date v-model="customObj.StuBirth" @input="() => $refs.qDateProxy1.hide()" /> <el-date-picker v-model="customObj.StuBirth" style="height:28px;width:150px" type="date" placeholder="选择日期">
</q-popup-proxy> </el-date-picker>
</q-icon>
</template> </template>
</q-input> </q-field>
</div> </div>
</div> </div>
</div>
<div class="custom_Line"></div>
<div class="info_title">基本资料</div>
<div class="info_content">
<div class="info_item"> <div class="info_item">
<div class="item_label">客户来源</div> <div class="item_label">客户来源</div>
<div class="item_value"> <div class="item_value">
...@@ -230,14 +225,7 @@ ...@@ -230,14 +225,7 @@
StuId: 0, StuId: 0,
}, },
//客户对象 //客户对象
customObj: { customObj: {},
AssistList:[{
Id:0,//编号
AssistId:1,//员工编号
AssistType:1,//类型
StuId:1,//学员编号
}]
},
//日语基础列表 //日语基础列表
basicList: [], basicList: [],
//学历列表 //学历列表
...@@ -268,21 +256,34 @@ ...@@ -268,21 +256,34 @@
methods: { methods: {
//保存学员信息 //保存学员信息
saveStu() { saveStu() {
saveStudent(this.customObj).then(res => { this.$refs.StuName.validate();
if (res.Code == 1) { this.$refs.StuTel.validate();
this.$q.notify({ if (!this.$refs.StuName.hasError&&!this.$refs.StuTel.hasError){
icon: 'iconfont icon-chenggong', var myreg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1}))+\d{8})$/;
color: 'accent', if(!myreg.test(this.customObj.StuTel)){
timeout: 2000, this.$q.notify({
message: '数据保存成功!', type: 'negative',
position: 'top' position: "top",
}) message: `请输入正确的电话号码`
this.$emit('success'); })
if(this.AddType == 1){ return
this.$emit('close');
}
} }
}) saveStudent(this.customObj).then(res => {
if (res.Code == 1) {
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: '数据保存成功!',
position: 'top'
})
this.$emit('success');
if(this.AddType == 1){
this.$emit('close');
}
}
})
}
}, },
//获取员工列表 //获取员工列表
getEmployeeList() { getEmployeeList() {
......
...@@ -15,18 +15,15 @@ ...@@ -15,18 +15,15 @@
<q-btn label="选择试听课" style="margin-left:50px;" color="accent q-mb-lg" size="sm" @click="isShowTeacher=true" /> <q-btn label="选择试听课" style="margin-left:50px;" color="accent q-mb-lg" size="sm" @click="isShowTeacher=true" />
</div> </div>
<template v-if="isShowAdd"> <template v-if="isShowAdd">
<div class="row wrap"> <div class="row wrap studentDate">
<q-input filled v-model="addMsg.ClassDate" dense ref="ClassDate" class="col-6 q-pb-lg q-pr-lg" mask="date" <q-field filled class="q-pb-lg q-pr-lg" dense>
label="预约日期">  <template v-slot:control>
<template v-slot:append> <el-date-picker v-model="addMsg.ClassDate" ref="ClassDate" :rules="[val => !!val || '请选择预约日期']"
<q-icon name="event" class="cursor-pointer"> style="height:28px;width:228px" type="date" placeholder="预约日期">
<q-popup-proxy ref="qDateProxy1" transition-show="scale" transition-hide="scale"> </el-date-picker>
<q-date v-model="addMsg.ClassDate" @input="() => $refs.qDateProxy1.hide()" />
</q-popup-proxy>
</q-icon>
</template> </template>
</q-input> </q-field>
<div class="Student_Date col-6"> <div class="Student_Date col-6 q-pr-lg">
<q-field filled class="q-pb-lg" dense> <q-field filled class="q-pb-lg" dense>
 <template v-slot:control>  <template v-slot:control>
<el-time-select v-model="addMsg.ClassTime" size="small" ref="ClassTime" style="width:50%" :picker-options="{ <el-time-select v-model="addMsg.ClassTime" size="small" ref="ClassTime" style="width:50%" :picker-options="{
...@@ -53,7 +50,7 @@ ...@@ -53,7 +50,7 @@
:options="ContentList" :rules="[val => !!val || '请选择主讲内容']" label="主讲内容" :options="ContentList" :rules="[val => !!val || '请选择主讲内容']" label="主讲内容"
class="col-6 q-pb-lg q-pr-lg" emit-value map-options /> class="col-6 q-pb-lg q-pr-lg" emit-value map-options />
<q-select filled stack-label option-value="TId" option-label="TeacherName" v-model="addMsg.TeacherId" <q-select filled stack-label option-value="TId" option-label="TeacherName" v-model="addMsg.TeacherId"
ref="TeacherId" :options="TeacherList" label="选择教师" dense class="col-6 q-pb-lg" emit-value ref="TeacherId" :options="TeacherList" label="选择教师" dense class="col-6 q-pb-lg q-pr-lg" emit-value
map-options /> map-options />
</div> </div>
<div class="row wrap"> <div class="row wrap">
...@@ -182,8 +179,15 @@ ...@@ -182,8 +179,15 @@
methods: { methods: {
//保存 //保存
saveAppointForm() { saveAppointForm() {
this.$refs.ClassDate.validate(); if(this.addMsg.ClassDate==''){
this.$refs.ClassContent.validate(); this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请选择预约日期!',
})
return;
}
if (this.addMsg.ClassTime == '') { if (this.addMsg.ClassTime == '') {
this.$q.notify({ this.$q.notify({
type: 'negative', type: 'negative',
...@@ -202,7 +206,7 @@ ...@@ -202,7 +206,7 @@
}) })
return; return;
} }
if (!this.$refs.ClassDate.hasError && !this.$refs.ClassContent.hasError) { if (!this.$refs.ClassContent.hasError) {
SetVisitorReserve(this.addMsg).then(res => { SetVisitorReserve(this.addMsg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
v-model="VisitMsg.School_Id" :options="schoolList" emit-value map-options label="到访校区" /> v-model="VisitMsg.School_Id" :options="schoolList" emit-value map-options label="到访校区" />
<q-field filled class="q-pb-lg" dense> <q-field filled class="q-pb-lg" dense>
 <template v-slot:control>  <template v-slot:control>
<el-date-picker v-model="VisitMsg.Date" style="height:28px;width:232px" type="date" placeholder="选择日期"> <el-date-picker v-model="VisitMsg.Date" style="height:28px;width:228px" type="date" placeholder="到访日期">
</el-date-picker> </el-date-picker>
</template> </template>
</q-field> </q-field>
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<div class="row warp studentDate"> <div class="row warp studentDate">
<q-field filled class="q-pb-lg q-pr-lg" dense> <q-field filled class="q-pb-lg q-pr-lg" dense>
 <template v-slot:control>  <template v-slot:control>
<el-time-select v-model="VisitMsg.VisitTime" size="small" ref="ClassTime" style="width:210px" :picker-options="{ <el-time-select v-model="VisitMsg.VisitTime" size="small" ref="ClassTime" style="width:230px" :picker-options="{
start: '09:00', start: '09:00',
step: '00:15', step: '00:15',
end: '21:00', end: '21:00',
...@@ -38,12 +38,12 @@ ...@@ -38,12 +38,12 @@
</el-time-select> </el-time-select>
</template> </template>
</q-field> </q-field>
<q-select filled v-model="VisitMsg.ReceptionPersion" dense @filter="filterEmployee" class="col-6 q-pb-lg" <q-select filled v-model="VisitMsg.ReceptionPersion" style="width:250px;" dense @filter="filterEmployee" class="col-6 q-pb-lg"
:options="myEmployeeList" option-label="EmployeeName" use-input option-value="Id" emit-value map-options :options="myEmployeeList" option-label="EmployeeName" use-input option-value="Id" emit-value map-options
label="接待人" /> label="接待人" />
</div> </div>
<div class="row wrap"> <div class="row wrap">
<q-input filled v-model="VisitMsg.Remark" dense :rows="3" type="textarea" class="col-12 q-pb-lg" label="备注"> <q-input filled v-model="VisitMsg.Remark" dense :rows="3" type="textarea" class="col-12 q-pb-lg q-pr-lg" label="备注">
</q-input> </q-input>
</div> </div>
...@@ -187,12 +187,18 @@ ...@@ -187,12 +187,18 @@
this.getSchool(); this.getSchool();
this.getEmployeeList(); this.getEmployeeList();
this.getList(); this.getList();
let userInfo = this.getLocalStorage();
if(userInfo){
this.VisitMsg.ReceptionPersion = parseInt(userInfo.AccountId);
}
}, },
methods: { methods: {
//点击到访 //点击到访
clickItem(item) { clickItem(item) {
this.feedBackMsg.Id = item.Id; this.feedBackMsg.Id = item.Id;
this.feedBackMsg.Feedback = item.Feedback; this.feedBackMsg.Feedback = item.Feedback;
this.feedBackMsg.IsVisit = item.IsVisit;
this.isShowEdit = true; this.isShowEdit = true;
}, },
SetFeedBack() { SetFeedBack() {
...@@ -256,6 +262,24 @@ ...@@ -256,6 +262,24 @@
//保存数据 //保存数据
saveVisit() { saveVisit() {
this.VisitMsg.StuId = this.saveObj.StuId; this.VisitMsg.StuId = this.saveObj.StuId;
if(this.VisitMsg.Date==''){
this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请选择到访日期!',
})
return;
}
if(this.VisitMsg.VisitTime==''){
this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请选择到访时间!',
})
return;
}
saveStudentVisit(this.VisitMsg).then(res => { saveStudentVisit(this.VisitMsg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
......
...@@ -9,35 +9,21 @@ ...@@ -9,35 +9,21 @@
@click="isShowAdd=false" /> @click="isShowAdd=false" />
</div> </div>
<template v-if="isShowAdd"> <template v-if="isShowAdd">
<div class="row wrap"> <div class="row wrap studentDate">
<q-input filled class="col-6 q-pb-lg q-pr-lg" dense v-model="yueMsg.AppointmentPoint" label="约访地点"></q-input> <q-input filled class="col-6 q-pb-lg q-pr-lg" dense v-model="yueMsg.AppointmentPoint" label="约访地点"></q-input>
<q-input filled v-model="yueMsg.AppointmentTime" dense> <q-field filled class="q-pb-lg" dense>
<template v-slot:prepend>  <template v-slot:control>
<q-icon name="event" class="cursor-pointer"> <el-date-picker
<q-popup-proxy transition-show="scale" transition-hide="scale"> v-model="yueMsg.AppointmentTime"
<q-date v-model="yueMsg.AppointmentTime" mask="YYYY-MM-DD HH:mm"> type="datetime"
<div class="row items-center justify-end"> style="width:228px"
<q-btn v-close-popup label="Close" color="primary" flat /> placeholder="选择约访日期时间!">
</div> </el-date-picker>
</q-date>
</q-popup-proxy>
</q-icon>
</template>
<template v-slot:append>
<q-icon name="access_time" class="cursor-pointer">
<q-popup-proxy transition-show="scale" transition-hide="scale">
<q-time v-model="yueMsg.AppointmentTime" mask="YYYY-MM-DD HH:mm" format24h>
<div class="row items-center justify-end">
<q-btn v-close-popup label="Close" color="primary" flat />
</div>
</q-time>
</q-popup-proxy>
</q-icon>
</template> </template>
</q-input> </q-field>
</div> </div>
<div class="row wrap"> <div class="row wrap">
<q-input filled v-model="yueMsg.Remark" dense :rows="3" type="textarea" class="col-12 q-pb-lg" label="备注"> <q-input filled v-model="yueMsg.Remark" dense :rows="3" type="textarea" class="col-12 q-pb-lg q-pr-lg" label="备注">
</q-input> </q-input>
</div> </div>
<div class="row wrap" style="margin-bottom:10px;"> <div class="row wrap" style="margin-bottom:10px;">
...@@ -180,6 +166,24 @@ ...@@ -180,6 +166,24 @@
//保存约访 //保存约访
savePoint() { savePoint() {
this.yueMsg.StuId = this.saveObj.StuId; this.yueMsg.StuId = this.saveObj.StuId;
if(this.yueMsg.AppointmentPoint==''){
this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请输入约访地点!',
})
return;
}
if(this.yueMsg.AppointmentTime==''){
this.$q.notify({
type: 'negative',
position: "top",
timeout: 2000,
message: '请选择约访日期时间!',
})
return;
}
saveStudentAppointment(this.yueMsg).then(res => { saveStudentAppointment(this.yueMsg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
......
...@@ -424,7 +424,7 @@ ...@@ -424,7 +424,7 @@
.operate_Content { .operate_Content {
overflow: auto; overflow: auto;
padding-right: 20px; /* padding-right: 20px; */
} }
.operate_Content::-webkit-scrollbar { .operate_Content::-webkit-scrollbar {
......
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