Commit 35f7d5da authored by 罗超's avatar 罗超

Merge branch 'master' of http://gitlab.oytour.com/luochao/confucius into master

parents 53ff514a 03c4b3c7
......@@ -33,7 +33,7 @@
<template>
<div>
<!--课程顾问 或有教师权限-->
<template v-if="userInfo.IsCourseConsultant == 1||isHaveTeacherEdit">
<template v-if="userInfo.IsCourseConsultant == 1||isHaveTeacherEdit||isHaveXueManager">
<q-btn label="新增" color="accent q-mb-lg" size="sm" @click="isShowAdd = true" />
</template>
<template v-else>
......@@ -43,11 +43,14 @@
@click="isShowAdd = false" />
<template v-if="isShowAdd">
<div class="row wrap">
<q-select filled stack-label option-label="Name" @input="getRole" v-model="AssitMsg.AssistType"
<q-select filled stack-label option-label="Name" @input="changeData" v-model="AssitMsg.AssistType"
option-value="Id" :options="AssistDropList" label="角色" dense class="col-6 q-pb-lg q-pr-lg" emit-value
map-options />
<q-select filled dense v-if="AssitMsg.AssistType == 2" v-model="AssitMsg.AssistId" :options="RoleListData"
option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value map-options />
<q-select filled dense v-if="AssitMsg.AssistType == 4" v-model="AssitMsg.AssistId"
:options="TeacherList" option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value
map-options />
<q-select filled dense v-else v-model="AssitMsg.AssistId" @filter="filterEmployee" use-input
:options="myEmployeeList" option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value
map-options />
......@@ -70,8 +73,8 @@
<td>{{ item.AssistTypeName }}</td>
<td>{{ item.AssistName }}</td>
<td>
<template v-if="userInfo.IsCourseConsultant == 1||isHaveTeacherEdit">
<div v-if="userInfo.IsCourseConsultant == 1&&item.AssistType != 2 && item.AssistType != 4">
<template v-if="userInfo.IsCourseConsultant == 1||isHaveTeacherEdit||isHaveXueManager">
<div v-if="userInfo.IsCourseConsultant == 1&&(item.AssistType == 2 ||item.AssistType == 3)">
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="修改"
@click="getEditInfo(item)"></q-btn>
<q-btn flat size="xs" icon="delete" color="negative" style="font-weight:400" label="删除"
......@@ -83,12 +86,7 @@
<q-btn flat size="xs" icon="delete" color="negative" style="font-weight:400" label="删除"
@click="deleteAssits(item.Id)" />
</div>
<div v-if="isShowBian(item)">
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="修改"
@click="getGuwenEditInfo(item)"></q-btn>
</div>
</template>
</td>
</tr>
</table>
......@@ -141,6 +139,7 @@
page_Count: 0,
AssistDropList: [], //下拉数据
RoleListData: [], //课程顾问下拉数据
TeacherList: [], //教师列表
employeeList: [],
myEmployeeList: [],
userInfo: {}
......@@ -170,12 +169,12 @@
}
}
return false;
}
},
}),
mounted() {
this.getList();
this.GetAssistTypeList();
this.getEmployeeList();
},
methods: {
//获取协助人员
......@@ -185,41 +184,48 @@
if (res.Code == 1) {
let template = res.Data;
template.forEach(x => {
if (this.userInfo.IsCourseConsultant == 1 && this.isHaveTeacherEdit) {
if (this.userInfo.IsCourseConsultant == 1) {
if (x.Id != 1) {
this.AssistDropList.push(x);
}
} else if (this.userInfo.IsCourseConsultant == 1 && !this.isHaveTeacherEdit) {
if (x.Id != 1 && x.Id != 4) {
if (x.Id == 4 && this.isHaveTeacherEdit) {
this.AssistDropList.push(x);
}
} else if (this.userInfo.IsCourseConsultant == 0 && this.isHaveTeacherEdit) {
if (x.Id == 4) {
this.AssistDropList.push(x);
} else if (this.userInfo.IsCourseConsultant == 0) {
if (this.isHaveTeacherEdit) {
if (x.Id == 4) {
this.AssistDropList.push(x);
}
}
}
});
}
});
},
//获取员工列表
getEmployeeList() {
queryEmployee({
IsLeave: 1,
UserRole: 0
}).then(res => {
this.employeeList = res.Data;
this.myEmployeeList = res.Data;
});
},
//切换课程顾问
getRole() {
queryEmployee({
changeData() {
var queryObj = {
IsLeave: 1,
UserRole: 2
}).then(res => {
this.RoleListData = res.Data;
});
UserRole: 0,
AccountTypeStr: "",
};
if (this.AssitMsg.AssistType == 2) {
queryObj.UserRole = 2;
queryEmployee(queryObj).then(res => {
this.RoleListData = res.Data;
});
}
if (this.AssitMsg.AssistType == 4) {
queryObj.AccountTypeStr = "2"
queryEmployee(queryObj).then(res => {
this.TeacherList = res.Data;
});
} else {
queryObj.UserRole = 0;
queryEmployee(queryObj).then(res => {
this.employeeList = res.Data;
this.myEmployeeList = res.Data;
});
}
},
//筛选员工
filterEmployee(val, update, abort) {
......@@ -241,6 +247,7 @@
message: "数据保存成功!",
position: "top"
});
this.$emit("success");
this.getList();
this.isShowAdd = false;
this.clearMsg();
......@@ -263,16 +270,6 @@
})
.catch(() => {});
},
//课程顾问是本人 显示编辑按钮
isShowBian(item) {
let isShow = false;
if (item.AssistTypeName == '课程顾问') {
// if (this.userInfo.AccountName == item.AssistName) {
isShow = true
// }
}
return isShow;
},
//删除协同
deleteAssits(Id) {
let that = this;
......
......@@ -214,7 +214,7 @@
stuData: {},
userInfo: {},
isconsult: false, //学生咨询弹窗
IsHaveCurseManager:false,//是否存在课程顾问
IsHaveCurseManager: false, //是否存在课程顾问
};
},
created() {
......@@ -264,7 +264,9 @@
},
//刷新列表
refreshStudentPage() {
console.log("2222");
this.$emit("success");
},
//客户情况信息的修改
consultsuccess(data) {
......
......@@ -436,7 +436,6 @@
WeChatNo: '',
StuType: '', //学生类型
StuGuestState: '', //合同状态
IsQueryMyStu: '1', //是否查询我的学员 1是 0否
SFTime: '',
EFTime: '',
StuStage: '', //客户状态
......
......@@ -147,7 +147,6 @@
分数差距
</q-th>
</template>
<template v-else>
<q-th :key="col.name" :props="props" style="max-width:70px">
{{ col.label }}
......@@ -155,6 +154,7 @@
</template>
</template>
</q-tr>
<template v-slot:bottom>
</template>
</q-table>
......@@ -191,6 +191,7 @@
field: 'StudentCount',
align: 'left'
},
{
name: 'AttendClassHourScore',
label: '上课时数',
......
......@@ -42,7 +42,12 @@
separator="none" :data="dataList" :columns="columns" row-key="">
<q-tr slot="header" slot-scope="props" :props="props">
<template v-for="col in props.cols" :props="props">
<template v-if="col.label=='线上与学生互动数'">
<template v-if="col.label=='班主任学生互动'">
<q-th :key="col.name" :props="props" style="max-width:75px;text-align:center;">
班主任<br />学生互动
</q-th>
</template>
<template v-else-if="col.label=='线上与学生互动数'">
<q-th :key="col.name" :props="props" style="max-width:90px;text-align:center;">
线上与学生<br />互动数
</q-th>
......@@ -168,14 +173,22 @@
<span v-else>{{props.row.DateStr}}</span>
</q-td>
</template>
<template v-slot:body-cell-FinishTimesPlanCount="props">
<q-td :props="props">
{{props.row.FinishTimes}} / {{props.row.FollowCount}}
</q-td>
</template>
<template v-slot:bottom-row>
<q-tr>
<q-tr v-if="lastRow">
<q-td>
{{lastRow.DateStr}}
</q-td>
<q-td>
{{lastRow.StudentCount}}
</q-td>
<q-td>
{{lastRow.FinishTimes}} / {{lastRow.FollowCount}}
</q-td>
<q-td>
{{lastRow.AttendClassHourScore}}
</q-td>
......@@ -241,7 +254,6 @@
</q-td>
</q-tr>
</template>
<template v-slot:bottom>
</template>
</q-table>
......@@ -277,6 +289,11 @@
align: 'left',
sortable: true
},
{
name: 'FinishTimesPlanCount',
label: '班主任学生互动',
align: 'left'
},
{
name: 'AttendClassHourScore',
label: '上课时数',
......
This diff is collapsed.
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