Commit 942a5e06 authored by zhengke's avatar zhengke

1

parents 89de6cb8 18a23dab
......@@ -20,7 +20,7 @@ export default {
</script>
<style>
@import url("//at.alicdn.com/t/font_2077629_bgk17xi4zj.css");
@import url("//at.alicdn.com/t/font_2077629_w1o8daso6r9.css");
@font-face{
font-family: 'din';
src: url('./assets/font/DIN-Bold.otf') format('opentype');
......
......@@ -80,3 +80,11 @@ export function getEventLogPageList(data) {
data
})
}
// 设置学生跳课
export function setGuestStartChapter(data) {
return request({
url: '/Scroll/SetGuestStartChapter',
method: 'post',
data
})
}
\ No newline at end of file
<style>
.delAssist {
.delAssist {
position: absolute;
right: -16px;
top: -12px;
......@@ -12,148 +12,51 @@
text-align: center;
line-height: 20px;
cursor: pointer;
}
}
.studentAssitTable {
.studentAssitTable {
width: 100%;
text-align: center;
}
}
.studentAssitTable td {
.studentAssitTable td {
height: 40px;
line-height: 40px;
border: 1px solid #f2f2f2;
}
}
.studentAssitTable th {
.studentAssitTable th {
height: 40px;
background-color: #f2f2f2;
}
}
</style>
<template>
<div>
<q-btn
label="新增"
color="accent q-mb-lg"
size="sm"
v-if="userInfo.IsCourseConsultant == 1"
@click="isShowAdd = true"
/>
<q-btn label="新增" color="accent q-mb-lg" size="sm" v-if="userInfo.IsCourseConsultant == 1"
@click="isShowAdd = true" />
<span class="text-grey-4" v-else>抱歉,你没有权限邀请其他服务人员</span>
<q-btn
label="取消"
style="margin-left:20px;"
v-if="isShowAdd"
flat
color="grey-10 q-mb-lg"
size="sm"
@click="isShowAdd = false"
/>
<q-btn label="取消" style="margin-left:20px;" v-if="isShowAdd" flat color="grey-10 q-mb-lg" size="sm"
@click="isShowAdd = false" />
<template v-if="isShowAdd">
<div class="row wrap" v-if="isHaveTeacher">
<q-select
filled
stack-label
option-label="Name"
@input="getRole"
v-model="AssitMsg.AssistType"
option-value="Id"
:options="AssistTeacherDropList"
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-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
/>
<i class="iconfont icon-close delAssist"></i>
</div>
<div class="row wrap" v-else>
<q-select
filled
stack-label
option-label="Name"
@input="getRole"
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-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
/>
<div class="row wrap">
<q-select filled stack-label option-label="Name" @input="getRole" 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-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 />
<i class="iconfont icon-close delAssist"></i>
</div>
<div class="row wrap" style="margin-bottom:10px;float:right;">
<q-btn
label="保存"
color="accent q-mb-lg"
size="md"
@click="saveAssit()"
/>
<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"
cellpadding="0"
>
<table class="studentAssitTable" style="border:1px solid #f2f2f2;border-collapse:collapse;" cellspacing="0"
cellpadding="0">
<tr>
<th style="width:180px;">角色</th>
<th style="width:180px;">人员</th>
......@@ -164,35 +67,14 @@
<td>{{ item.AssistName }}</td>
<td v-if="userInfo.IsCourseConsultant == 1">
<div v-if="item.AssistType != 2 && item.AssistType != 4">
<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="删除"
@click="deleteAssits(item.Id)"
/>
<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="删除"
@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>
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="修改"
@click="getGuwenEditInfo(item)"></q-btn>
</div>
</td>
</tr>
......@@ -201,16 +83,17 @@
</div>
</template>
<script>
import {
import {
GetAssistTypeList,
SetStudentAssist,
GetStudentAssistList,
RemoveStudentAssist
} from "../../../api/sale/sale";
import { queryEmployee } from "../../../api/users/user";
import { mapState } from "vuex";
} from "../../../api/sale/sale";
import {
queryEmployee
} from "../../../api/users/user";
export default {
export default {
meta: {
title: ""
},
......@@ -241,7 +124,6 @@ export default {
dataList: [],
page_Count: 0,
AssistDropList: [], //下拉数据
AssistTeacherDropList:[],
RoleListData: [], //课程顾问下拉数据
employeeList: [],
myEmployeeList: [],
......@@ -255,26 +137,6 @@ export default {
this.msg.StuId = this.saveObj.StuId;
}
},
computed: mapState({
isHaveTeacher(state) {
if (
state.user.userInfo &&
state.user.userInfo.ActionMenuList &&
state.user.userInfo.ActionMenuList.length > 0
) {
let action = state.user.userInfo.ActionMenuList.find(x => {
if (x.FunctionCode == "Query_TeacherAssist") {
return x;
}
});
if (action) {
return true;
}
}
return false;
}
}),
mounted() {
this.getList();
this.GetAssistTypeList();
......@@ -288,12 +150,9 @@ export default {
if (res.Code == 1) {
let template = res.Data;
template.forEach(x => {
if (x.Id != 1 && x.Id != 4) {
if (x.Id != 1) {
this.AssistDropList.push(x);
}
if (x.Id==4){
this.AssistTeacherDropList.push(x);
}
});
}
});
......@@ -317,7 +176,6 @@ export default {
this.RoleListData = res.Data;
});
},
//筛选员工
filterEmployee(val, update, abort) {
update(() => {
......@@ -361,11 +219,11 @@ export default {
.catch(() => {});
},
//课程顾问是本人 显示编辑按钮
isShowBian(item){
let isShow=false;
if(item.AssistTypeName=='课程顾问'){
if(this.userInfo.AccountName==item.AssistName){
isShow=true
isShowBian(item) {
let isShow = false;
if (item.AssistTypeName == '课程顾问') {
if (this.userInfo.AccountName == item.AssistName) {
isShow = true
}
}
return isShow;
......@@ -404,7 +262,7 @@ export default {
this.AssitMsg.AssistType = obj.AssistType;
this.isShowAdd = true;
},
getGuwenEditInfo(obj){
getGuwenEditInfo(obj) {
this.getRole();
this.AssitMsg.Id = obj.Id;
this.AssitMsg.AssistId = obj.AssistId;
......@@ -412,5 +270,5 @@ export default {
this.isShowAdd = true;
}
}
};
};
</script>
\ No newline at end of file
......@@ -28,6 +28,7 @@
height: 40px;
background-color: rgb(238, 238, 239);
}
.stulistNumber {
display: inline-block;
width: 25px;
......@@ -39,6 +40,7 @@
cursor: pointer;
color: #2961FE;
}
.OCourseTable {
width: 400px;
text-align: center;
......@@ -52,7 +54,6 @@
height: 40px;
background-color: rgb(238, 238, 239);
}
</style>
<template>
<div class="stuList">
......@@ -71,8 +72,8 @@
<q-btn color="accent" class="q-mr-md" size="sm" icon="swap_horiz" label="转留学"
:disable="selection.length === 0" @click="transferAbroad" />
<q-btn color="accent" class="q-mr-md" size="sm" icon="add" label="新增学员" @click="EditStudent(null)" />
<q-btn v-if="authObj&&authObj.isShowDownload" color="accent" class="q-mr-md" size="sm" icon="download" label="下载"
@click="downloadStudent" />
<q-btn v-if="authObj&&authObj.isShowDownload" color="accent" class="q-mr-md" size="sm" icon="download"
label="下载" @click="downloadStudent" />
</div>
<div class="page-option" v-if="pushMode">
<q-btn color="accent" unelevated class="q-mr-md" size="sm" icon="swap_horiz" label="立即推送" :loading="pushing"
......@@ -106,10 +107,13 @@
</template>
<template v-slot:body-cell-StuSourceIdName="props">
<q-td :props="props">
<div>
<div v-if="IsShowStuSourceIdName(props.row)">
<span v-if="props.row.CreateType == 2 && props.row.EnterpriseName">{{props.row.EnterpriseName}}:</span>
{{ props.row.StuSourceIdName }}
</div>
<div v-else>
-
</div>
</q-td>
</template>
<template v-slot:body-cell-AdvisorWinRate="props">
......@@ -131,7 +135,8 @@
<th>跟进比例</th>
<th>跟进备注</th>
</tr>
<tr v-for="(sItem,sIndex) in props.row.AdvisorList" style="border-bottom:1px dashed #d1d1d1;" :key="sIndex">
<tr v-for="(sItem,sIndex) in props.row.AdvisorList" style="border-bottom:1px dashed #d1d1d1;"
:key="sIndex">
<td>{{sItem.AdvisorStatusName}}</td>
<td>{{sItem.AdvisorDate}}</td>
<td>{{sItem.AdvisorRate}}</td>
......@@ -154,7 +159,8 @@
<template v-slot:body-cell-OrderCount="props">
<q-td :props="props" v-if="props.row.OrderCount == 0" class="text-grey-4">未报名</q-td>
<q-td :props="props" v-if="props.row.OrderCount > 0" class="bg-negative text-white" style="cursor:pointer;text-decoration:underline;" @click="getStuRight(props.row,3)">
<q-td :props="props" v-if="props.row.OrderCount > 0" class="bg-negative text-white"
style="cursor:pointer;text-decoration:underline;" @click="getStuRight(props.row,3)">
已报名{{ props.row.OrderCount }}</q-td>
</template>
<template v-slot:body-cell-TeacherManager="props">
......@@ -199,8 +205,9 @@
</q-table>
<student-form v-if="isShowStuForm" :save-obj="stuOption" @close="closeStuForm" @success="refreshStuList">
</student-form>
<studentRight-form v-if="isShowStuRight" :isJudgeTrans="isJudgeTrans" :BelongType="BelongType" :checkType="checkType" :save-obj="stuOption"
@close="closeStuForm" @success="refreshStuList" @reload="referDataHandler">
<studentRight-form v-if="isShowStuRight" :isJudgeTrans="isJudgeTrans" :BelongType="BelongType"
:checkType="checkType" :save-obj="stuOption" @close="closeStuForm" @success="refreshStuList"
@reload="referDataHandler">
</studentRight-form>
<studentAdd-form v-if="isShowAdd" :save-obj="stuOption" @close="closeStuForm" @success="refreshStuList">
</studentAdd-form>
......@@ -286,6 +293,18 @@
label: "是否报名",
align: "left"
},
{
name: "VisitCount",
label: "到访次数",
field: "VisitCount",
align: "left"
},
{
name: "TrialLessonCount",
label: "试听次数",
field: "TrialLessonCount",
align: "left"
},
{
name: "StuSex",
label: "性别",
......@@ -394,18 +413,7 @@
field: "StuChannelName",
align: "left"
},
{
name: "VisitCount",
label: "到访次数",
field: "VisitCount",
align: "left"
},
{
name: "TrialLessonCount",
label: "试听次数",
field: "TrialLessonCount",
align: "left"
},
{
name: "CreateTimeStr",
label: "创建时间",
......@@ -433,8 +441,9 @@
pushMode: false,
pushing: false,
assistListFormat: [],
checkType:1,
isShowAbroad: false
checkType: 1,
isShowAbroad: false,
userInfo: {}, //当前登录人员
};
},
watch: {
......@@ -447,14 +456,31 @@
}
},
created() {
this.userInfo = this.getLocalStorage();
this.formatAssistList();
this.initAuth();
},
mounted() {},
computed: {
...mapGetters(["userInfo", "logo", "name"])
...mapGetters(["logo", "name"])
},
methods: {
IsShowStuSourceIdName(item) {
var isHaveAuth = false;
if (this.userInfo && this.userInfo.ActionMenuList && this.userInfo.ActionMenuList.length >
0) {
this.userInfo.ActionMenuList.forEach((x) => {
if (x.FunctionCode == "Look_StuSourceId") {
isHaveAuth = true;
}
});
}
if (item.CreateBy == this.userInfo.Id || isHaveAuth) {
return true;
} else {
return false;
}
},
//下载文件
downloadStudent() {
var msg = JSON.parse(JSON.stringify(this.queryMsg));
......@@ -605,11 +631,11 @@
this.isShowAbroad = false;
},
//点击学生姓名弹出
getStuRight(obj,type) {
getStuRight(obj, type) {
if (obj) {
this.stuOption = obj;
this.BelongType = obj.BelongType;
this.checkType=type;
this.checkType = type;
} else {
this.stuOption = null;
}
......@@ -632,7 +658,7 @@
this.isShowTransfer = true;
},
//转留学
transferAbroad(){
transferAbroad() {
this.isShowAbroad = true;
},
getCurseManager(row) {
......@@ -677,7 +703,7 @@
});
if (msg == "") {
SetStudentAssistBatch(parameter).then(r => {
this.$emit("reload");
this.refreshStuList();
this.selection = [];
this.pushMode = false;
});
......
<template>
<!-- 跳课 -->
<q-dialog
v-model="show"
content-class="bg-grey-1"
persistent
transition-show="scale"
transition-hide="scale"
>
<q-card style="width: 900px; max-width: 900px">
<q-card-section class="row items-center q-pb-none">
<div class="text-h6">跳课</div>
<q-space />
<q-btn icon="close" flat round dense @click="changeDig(false)" />
</q-card-section>
<q-card-section class="q-pt-none">
<div class="row col flex q-col-gutter-md">
<q-field filled label="姓名" readonly stack-label class="col-4">
<template v-slot:control>
<div>{{ saveObj.GuestName }}</div>
</template>
</q-field>
<!-- <q-field filled label="课程" readonly stack-label class="col-4">
<template v-slot:control>
<div>{{ saveObj.CourseName }}</div>
</template>
</q-field>
<q-field filled label="班级" readonly stack-label class="col-4">
<template v-slot:control>
<div>{{ saveObj.ClassName }}</div>
</template>
</q-field> -->
<q-field filled label="已上课次数" readonly stack-label class="col-4">
<template v-slot:control>
<div>{{ saveObj.CourseChapterNo }}</div>
</template>
</q-field>
<q-field filled label="预约次数" readonly stack-label class="col-4">
<template v-slot:control>
<div>{{ saveObj.AppointNum }}</div>
</template>
</q-field>
</div>
<div class="q-my-xs">
类型:
<q-radio
v-model="type"
val="a"
label="第一次课开始"
color="teal"
@input="changeType"
/>
<q-radio
v-model="type"
val="b"
label="中途已上课"
color="teal"
@input="changeType"
/>
<q-radio
v-model="type"
val="c"
label="后续未上课"
color="teal"
@input="changeType"
/>
</div>
<div class="row col q-col-gutter-md">
<q-input
filled
v-model.number="msg.SChapterNo"
label="跳课开始章节"
type="number"
class="col-4"
stack-label
:min="0"
v-if="type == 'b'"
@change="changeStartChapter"
/>
<q-input
filled
v-model.number="endSChapterNo"
label="跳课结束章节"
type="number"
class="col-4"
stack-label
:min="0"
:max="999"
@change="changeEndChapter"
/>
</div>
<div class="q-my-xs" style="word-wrap:break-word">
<span style="white-space:nowrap">跳课章节列表:</span>{{ msg.ChapterNos }}</div>
</q-card-section>
<q-separator />
<q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" @click="changeDig(false)" />
<q-btn
label="保存"
color="accent q-px-md"
:loading="loading"
@click="save"
/>
</q-card-actions>
</q-card>
</q-dialog>
</template>
<script>
import { setGuestStartChapter } from "../../api/stuMan/index.js";
export default {
model: {
prop: "show",
event: "changeshow"
},
props: {
show: {
type: Boolean,
default: false
},
saveObj: {
type: Object
}
},
watch: {
show(){
this.loading = false
},
},
data() {
return {
type: "c",
saveLoading: false,
msg: {
StuId: 0,
GuestId: 0,
CourseId: 0,
ChapterNos: "",
SChapterNo: 0
},
endSChapterNo: 0,
loading: false
};
},
mounted() {},
methods: {
//开关弹窗
changeDig(val) {
this.$emit("changeshow", val);
},
changeType() {
this.msg.SChapterNo = 0;
this.msg.ChapterNos = "";
this.endSChapterNo = 0;
},
changeStartChapter() {
if (!this.msg.SChapterNo) {
this.msg.SChapterNo = 0;
}
this.changeEndChapter();
},
changeEndChapter() {
if (!this.endSChapterNo) {
this.endSChapterNo = 0;
}
if (this.endSChapterNo>=999) {
this.endSChapterNo = 999;
}
const end = parseInt(this.endSChapterNo);
let arr = [];
if (this.type == "a") {
for (let i = 1; i <= end; i++) {
arr.push(i);
}
} else if (this.type == "b") {
for (let i = this.msg.SChapterNo; i <= end; i++) {
arr.push(i);
}
} else if (this.type == "c") {
let start = this.saveObj.CourseChapterNo + this.saveObj.AppointNum;
for (let i = start + 1; i <= end; i++) {
arr.push(i);
}
}
this.msg.ChapterNos = arr.toString();
},
save() {
if (this.endSChapterNo == 0) {
this.$q.notify({
message: "请输入跳课的章节",
position: "top"
});
return;
}
this.msg.StuId = this.saveObj.Student_Id;
this.msg.GuestId = this.saveObj.Id;
this.msg.CourseId = this.saveObj.CourseId;
this.loading = true;
setGuestStartChapter(this.msg)
.then(res => {
this.loading = false;
if (res.Code == 1) {
this.$q.notify({
message: "操作成功",
position: "top"
});
this.changeDig(false);
this.$emit("success");
}
})
.catch(err => {
this.loading = false;
});
}
}
};
</script>
......@@ -39,6 +39,7 @@
:key="_index"
:val="_item"
@input="courseCheck(item.TeacherId, _item)"
v-if="_item.ClassType==3"
>
{{ item.TeacherName }} {{ _item.CourseName }}
{{ _item.RoomName }} {{ _item.StartTime }}-{{
......
......@@ -73,7 +73,7 @@
color="accent"
size="xs"
label="确认"
v-if="saveObj.AppointState == 1&&saveObj.GuestList.length>=saveObj.ScrollMinNum"
v-if="saveObj.AppointState == 1&&saveObj.GuestList.length>=saveObj.ScrollMinNum&&auth.IsEdit"
@click="confirmSub"
class="q-ml-md"
/>
......@@ -110,7 +110,7 @@
v-if="saveObj.ClassType == 3"
>
<template v-slot:control>
<div v-if="saveObj.AppointState == 1">
<div v-if="saveObj.AppointState == 1&&auth.IsEdit">
<div class="q-mt-sm flex justify-start">
<q-btn
color="accent"
......@@ -179,6 +179,14 @@ export default {
saveObj: {
type: Object,
default: null
},
auth:{
type:Object,
default:()=>{
return {
IsEdit:false
}
}
}
},
data() {
......@@ -202,6 +210,14 @@ export default {
message: "操作成功",
position: "top"
});
this.checkStuType2.map((e)=>{
this.saveObj.GuestList.map((_e,_i)=>{
if(e==_e.AppointmentId){
this.saveObj.GuestList.splice(_i,1)
}
})
})
this.checkStuType2=[]
this.$emit("success");
}
});
......@@ -229,7 +245,8 @@ export default {
position: "top",
type: "positive"
});
this.$emit("success");
// this.saveObj.AppointState = 2
this.$emit("close");
}
});
},
......@@ -243,7 +260,7 @@ export default {
},
ChangeCourseSuccessHandle(){
this.$emit("success");
this.$emit("close");
}
}
};
......
......@@ -21,8 +21,14 @@
</template>
</q-field>
<!-- 详情显示内容 start-->
<div class="col-12" v-if="editType==2">
<Detail :dateObj="dateObj" :saveObj="saveObj" @success="detailSuccessHandle"/>
<div class="col-12" v-if="editType == 2">
<Detail
:dateObj="dateObj"
:saveObj="saveObj"
:auth="auth"
@success="detailSuccessHandle"
@close="detailCloseHandle"
/>
</div>
<!-- 详情显示内容 end -->
<q-select
......@@ -75,7 +81,7 @@
map-options
label="老师"
class="col-12"
@input="getCanTeacherTimeList()"
@input="getCanTeacherTimeList"
/>
<q-field
filled
......@@ -129,7 +135,7 @@
</q-field>
<div
class="row col"
v-show="(editType == 1 || saveObj.ClassType == 3) && showAddStu()"
v-show="(editType == 1 || saveObj.ClassType == 3)&&auth.IsEdit"
>
<div class="col-10">
<q-select
......@@ -145,7 +151,6 @@
:dense="false"
class="col-6"
@filter="filterStu"
@input="addStu"
>
<template v-slot:no-option>
<q-item>
......@@ -189,14 +194,14 @@
import {
GetCanTeacherClassTimeList,
GetCanAppointmentStuList,
SetAdminScrollAppointment,
SetAdminScrollAppointment
} from "../../../api/studyabroad/subscribe.js";
import {
queryCourseDropdownList,
queryChapterTree
} from "../../../api/course/index";
import selectTree from "../../../components/common/select-tree";
import Detail from "./detail.vue"
import Detail from "./detail.vue";
import QCalendar from "@quasar/quasar-ui-qcalendar";
export default {
components: {
......@@ -227,22 +232,32 @@ export default {
teacherList: {
type: Array,
default: () => []
},
auth:{
type:Object,
default:()=>{
return {
IsEdit:false
}
}
}
},
watch: {
show(val){
show(val) {
console.log(1111111)
this.addLoading = false
if (val) {
this.stuInfo = "";
this.teaClassMsg.CourseId=0
this.teaClassMsg.TeacherId=0
this.chapterList=[]
this.teacherTimeList=[]
this.courseCheckList=[]
this.stuList=[]
this.teaClassMsg.CourseId = 0;
this.teaClassMsg.TeacherId = 0;
this.chapterList = [];
this.teacherTimeList = [];
this.courseCheckList = [];
this.stuList = [];
this.allStuList = [];
if (this.editType == 2) {
this.getStu();
}
}
}
},
......@@ -280,11 +295,10 @@ export default {
stuInfo: "",
checkStuList: [],
courseCheckList: [],
addLoading:false,
addLoading: false,
chapterList: [], //章节列表,
checkChapter: {}, //选择的章节
returnString: [], //章节默认值
};
},
mounted() {
......@@ -294,13 +308,17 @@ export default {
//开关弹窗
changeDig(val) {
this.$emit("changeshow", val);
if (!val) {
this.stuList = [];
this.allStuList = [];
}
},
//获取课程
getCourseList() {
queryCourseDropdownList({
IsQPrice: 1,
IsQuerySalePlat: 1,
IsScrollClass :1
IsScrollClass: 1
}).then(res => {
if (res.Code == 1) {
this.CourseList = res.Data;
......@@ -337,11 +355,13 @@ export default {
//获取老师的空闲上课时段
getCanTeacherTimeList() {
this.teaClassMsg.Date = this.dateObj.date;
this.stuInfo = "";
if (this.teaClassMsg.TeacherId == 0) return;
GetCanTeacherClassTimeList(this.teaClassMsg).then(res => {
this.teacherTimeList = res.Data;
});
},
//获取学生列表
getStu() {
this.stuMsg.CourseId = this.teaClassMsg.CourseId || 0;
this.stuMsg.CourseGradeId =
......@@ -353,7 +373,7 @@ export default {
this.allStuList = JSON.parse(JSON.stringify(res.Data));
});
},
//筛选学
//筛选学
filterStu(val, update) {
update(() => {
if (val === "") {
......@@ -366,7 +386,6 @@ export default {
}
});
},
addStu() {},
//获取章节
getChapterTree() {
if (this.teaClassMsg.CourseId == 0) return;
......@@ -400,8 +419,8 @@ export default {
if (this.checkChapter.CourseRate && this.checkChapter.ChapterNo) {
this.getStu();
}
this.teaClassMsg.TeacherId=0
this.teacherTimeList=[]
this.teaClassMsg.TeacherId = 0;
this.teacherTimeList = [];
},
subscribeCourse() {
if (
......@@ -441,6 +460,7 @@ export default {
const totalTime = this.courseCheckList.reduce((pre, cur) => {
return (pre += cur.Minutes);
}, 0);
console.log(452, this.courseCheckList, totalTime);
if (this.checkChapter.StudyMinutes !== totalTime) {
this.$q.notify({
message: "课时不匹配,请重新上课时段",
......@@ -486,51 +506,35 @@ export default {
this.saveMsg.CourseGradeId = this.saveObj.CourseGradeId;
this.saveMsg.ShiftSort = this.saveObj.ShiftSort;
}
this.addLoading=true
SetAdminScrollAppointment(this.saveMsg).then(res => {
this.addLoading=false
this.addLoading = true;
SetAdminScrollAppointment(this.saveMsg)
.then(res => {
this.addLoading = false;
if (res.Code == 1) {
this.getStu();
this.stuInfo = "";
if(this.editType==1){
this.$q
.dialog({
title: "预约成功",
message: "是否继续预约?",
cancel: "否",
ok: "是",
persistent: true
})
.onOk(() => {})
.onCancel(() => {
this.changeDig(false);
});
}else if(this.editType==2){
this.changeDig(false);
this.$q.notify({
message: "操作成功",
position: "top",
position: "top"
});
if (this.editType == 2) {
this.saveObj.GuestList.push({
GuestName: this.stuInfo.StuName,
AppointmentId: res.Data
});
}
this.stuInfo = "";
this.getStu();
this.$emit("success");
}
}).catch(()=>{
this.addLoading=false
})
.catch(() => {
this.addLoading = false;
});
},
showAddStu() {
if (
new Date(this.dateObj.date).getTime() <
new Date(QCalendar.today()).getTime()
) {
return false;
} else {
return true;
}
detailSuccessHandle() {
this.getStu();
this.$emit("success");
},
detailSuccessHandle(){
detailCloseHandle() {
this.changeDig(false);
this.$emit("success");
}
......
......@@ -229,7 +229,13 @@
this.msg.TeacherId = Number(this.$route.query.TeacherId);
}
if(this.$route.query.TeacherIds){
this.msg.TeacherIds = this.$route.query.TeacherIds;
let arr=this.$route.query.TeacherIds.split(',')
let idsArr=[]
arr.map(e=>{
let _arr=e.split('-')
idsArr.push(_arr[1])
})
this.msg.TeacherIds = idsArr.toString();
}
}
this.getList();
......
......@@ -771,19 +771,14 @@
cursor: pointer;
text-decoration: underline;
}
</style>
<template>
<div class="page_fdd FinancialDocumentsDetail" v-if="GetDetail">
<div class="_none_print">
<p class="_tit">
{{GetDetail.FinanceName}}
<span
:class="{color_shz:(GetDetail.StatusStr!=='通过' && GetDetail.StatusStr!=='驳回' && GetDetail.StatusStr!=='作废'),color_tg:GetDetail.StatusStr==='通过',color_bh:GetDetail.StatusStr==='驳回'}">{{GetDetail.StatusStr}}</span>
<span :class="{color_shz:(GetDetail.StatusStr!=='通过' && GetDetail.StatusStr!=='驳回' && GetDetail.StatusStr!=='作废'),color_tg:GetDetail.StatusStr==='通过',color_bh:GetDetail.StatusStr==='驳回'}">{{GetDetail.StatusStr}}</span>
</p>
<div style="width: 890px;position: relative;text-align: right;">
<span
......@@ -796,10 +791,8 @@
</span>
<span v-show="huijiShow" class="_Printing"
@click="goPrintPageNew(GetDetail.Type,GetDetail.FrID,GetDetail.Is_Merge,OrderSource)">凭证打印</span>
<!-- <span v-show="GetDetail.AccountantMergeDetailList && GetDetail.AccountantMergeDetailList.length>0" class="_Printing" @click="goPrintPage2(GetDetail.Type,GetDetail.FrID,GetDetail.Is_Merge,OrderSource)">会计合并打印</span>-->
<span class="_Printing" style="margin-left:10px;"
@click="goPrintPage(GetDetail.Type,GetDetail.FrID,GetDetail.Is_Merge,OrderSource)">打印单据</span>
</div>
<div class="_conten">
<my-Bill v-if="GetDetail.Type===2 && GetDetail.Type!==5" :isPrintPage="false" :ID="GetDetail.FrID"
......@@ -830,7 +823,8 @@
@click="goassets2(GetDetail.ReFinanceId,GetDetail.OtherType)"> 销售提成:{{GetDetail.ReFinanceId}}</span>
<span class="fr" style="text-decoration: underline;cursor: pointer;" v-if="GetDetail.OtherType==26"
@click="goassets2(GetDetail.ReFinanceId,GetDetail.OtherType)"> 教师课时:{{GetDetail.ReFinanceId}}</span>
<span class="fr" style="text-decoration: underline;cursor: pointer;" v-if="GetDetail.OtherType==40 || GetDetail.OtherType==41"
<span class="fr" style="text-decoration: underline;cursor: pointer;"
v-if="GetDetail.OtherType==40 || GetDetail.OtherType==41"
@click="goassets2(GetDetail.ReFinanceId,GetDetail.OtherType)"> 教育活动:{{GetDetail.ReFinanceId}}</span>
<span class="fr" style="text-decoration: underline;cursor: pointer;" v-if="GetDetail.OtherType==42 "
@click="goassets2(GetDetail.ReFinanceId,GetDetail.OtherType)"> 活动提成:{{GetDetail.ReFinanceId}}</span>
......@@ -847,15 +841,20 @@
<template v-if="GetDetail.RelevanceFrId">
<span class="fr" style="margin-right:10px;">
相关单据:<span @click="goFinancal(sItem)" v-for="(sItem,sIndex) in getRelevanArr(GetDetail.RelevanceFrId)" style="text-decoration:underline;cursor:pointer;margin-right:5px;">
相关单据:<span @click="goFinancal(sItem)" v-for="(sItem,sIndex) in getRelevanArr(GetDetail.RelevanceFrId)"
style="text-decoration:underline;cursor:pointer;margin-right:5px;">
{{sItem}}</span>
</span>
</template>
<template v-if="GetDetail.OtherType==28">
<span class="fr" v-if="GetDetail&&GetDetail.ReFinanceId" style="text-decoration: underline;cursor: pointer;color:red;"
@click="goTuikuanDetail('/user/billquery',GetDetail.ReFinanceId)" title="点击查看退款申请单"> 退款申请单:{{GetDetail.ReFinanceId}}</span>
<span class="fr" v-if="GetDetail&&GetDetail.ReFinanceId2" style="text-decoration: underline;cursor: pointer;margin-right:20px;color:red;"
@click="goTuikuanDetail('/courseRefund',GetDetail.ReFinanceId2)" title="点击查看退款协议"> 退款协议:{{GetDetail.ReFinanceId2}}</span>
<span class="fr" v-if="GetDetail&&GetDetail.ReFinanceId"
style="text-decoration: underline;cursor: pointer;color:red;"
@click="goTuikuanDetail('/user/billquery',GetDetail.ReFinanceId)" title="点击查看退款申请单">
退款申请单:{{GetDetail.ReFinanceId}}</span>
<span class="fr" v-if="GetDetail&&GetDetail.ReFinanceId2"
style="text-decoration: underline;cursor: pointer;margin-right:20px;color:red;"
@click="goTuikuanDetail('/courseRefund',GetDetail.ReFinanceId2)" title="点击查看退款协议">
退款协议:{{GetDetail.ReFinanceId2}}</span>
</template>
<span class="fr" style="text-decoration: underline;cursor: pointer;" v-if="GetDetail.OtherType==17"
@click="lookbreakage(GetDetail.ReFinanceId)"> 报损/报溢单:{{GetDetail.ReFinanceId}}</span>
......@@ -971,7 +970,8 @@
<div>
<p v-if="GetDetail.Type!==7">费用归属部门:<span class="_font_bold">{{GetDetail.DepartName}}</span></p>
<div style="display:flex;">
<div style="margin-right:20px;text-decoration:underline;cursor:pointer;" v-if="GetDetail.OtherType==53" @click="goFinDetail(GetDetail)">
<div style="margin-right:20px;text-decoration:underline;cursor:pointer;" v-if="GetDetail.OtherType==53"
@click="goFinDetail(GetDetail)">
单据详情
</div>
<el-popover popper-class="detailsIT_Journal" width="250" trigger="click">
......@@ -996,11 +996,15 @@
</el-popover>
</div>
</div>
<div lass="_explain" v-if="GetDetail.Type==2 && GetDetail.InvoiceType>0" style="flex-direction: column;align-items: flex-start;">
<div lass="_explain" v-if="GetDetail.Type==2 && GetDetail.InvoiceType>0"
style="flex-direction: column;align-items: flex-start;">
<div style="color: #1273BC;">发票说明:</div>
<div style="display:flex">
<p >发票类型:<p style='font-weight: bold;'>{{GetDetail.InvoiceTypeName}}</p> </p>
<p v-if="GetDetail.InvoiceType == 3" style="margin-left:30px">发票金额: <p style='font-weight: bold;' v-if="GetDetail.InvoiceType == 3">{{GetDetail.InvoiceMoney}}元</p></p>
<p>发票类型:<p style='font-weight: bold;'>{{GetDetail.InvoiceTypeName}}</p>
</p>
<p v-if="GetDetail.InvoiceType == 3" style="margin-left:30px">发票金额: <p style='font-weight: bold;'
v-if="GetDetail.InvoiceType == 3">{{GetDetail.InvoiceMoney}}元</p>
</p>
</div>
<div>
发票备注:{{GetDetail.InvoiceRemark == null || GetDetail.InvoiceRemark==''?'无':GetDetail.InvoiceRemark}}
......@@ -1090,7 +1094,7 @@
</div>
</div>
<div v-if="ConfigInfo && ConfigInfo.Enable==1 && getreceipt() && ishowSJ ">
<p class="_splic" >
<p class="_splic">
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
</p>
<div class="_tit _tit2 w890px ConfigInfoStyle">
......@@ -1503,8 +1507,8 @@
isShowviewQuo: false, //是否显示预览报价单
rId: 0,
showbohui: false, //5-10新加
ConfigInfo:null,//收据配置数据
ishowSJ:true,//收据是否显示
ConfigInfo: null, //收据配置数据
ishowSJ: true, //收据是否显示
}
},
components: {
......@@ -2195,32 +2199,35 @@
},
})
},
goassets2(ID,OtherType){
goassets2(ID, OtherType) {
var tempStr = ''
if(OtherType==31){
tempStr = '/financial/financalDocument/PropertyProcurementDetails?id='+ID;
}else if(OtherType==32){
tempStr = '/financial/financalDocument/SuppliesProcurementDetail?id='+ID;
}else if(OtherType==33){
tempStr = '/financial/financalDocument/InAndOutDdetails?id='+ID;
}else if(OtherType==39){
tempStr = '/financial/userCommissionDetails?UserIds='+this.GetDetail.EduCommissionEmp+'&preriodId='+ID;
}else if(OtherType==26){
tempStr = '/course/rewardDetailed?TeacherIds='+this.GetDetail.EduCommissionEmp+'&Id='+ID;
}else if(OtherType==40 || OtherType== 41){
tempStr = '/sale/activityList?Id='+ID;
}else if(OtherType==42){
tempStr = '/financial/reportform/activityCommissionDetails?id='+ID +'&UserIds='+this.GetDetail.EduCommissionEmp;
}else if(OtherType==44){
tempStr = '/financial/studyabroad/sBuserCommissionDetails?preriodId='+ID;
}else if(OtherType==47){
tempStr = '/financial/contribution/CommissionUserDetailList?TeacherIds='+this.GetDetail.EduCommissionEmp+'&preriodId='+ID;
}else if(OtherType==50){
tempStr = '/financial/market/AchievementsUserDetailList?UserIds='+this.GetDetail.EduCommissionEmp+'&preriodId='+ID;
}else if(OtherType==51){
tempStr = '/financial/market/empBonusDetail?Id='+ID;
}else if(OtherType==49){
tempStr = '/financial/returnPassbook/returnpassbookStatistics?UnionCashOutId='+ID;
if (OtherType == 31) {
tempStr = '/financial/financalDocument/PropertyProcurementDetails?id=' + ID;
} else if (OtherType == 32) {
tempStr = '/financial/financalDocument/SuppliesProcurementDetail?id=' + ID;
} else if (OtherType == 33) {
tempStr = '/financial/financalDocument/InAndOutDdetails?id=' + ID;
} else if (OtherType == 39) {
tempStr = '/financial/userCommissionDetails?UserIds=' + this.GetDetail.EduCommissionEmp + '&preriodId=' + ID;
} else if (OtherType == 26) {
tempStr = '/course/rewardDetailed?TeacherIds=' + this.GetDetail.EduCommissionEmp + '&Id=' + ID;
} else if (OtherType == 40 || OtherType == 41) {
tempStr = '/sale/activityList?Id=' + ID;
} else if (OtherType == 42) {
tempStr = '/financial/reportform/activityCommissionDetails?id=' + ID + '&UserIds=' + this.GetDetail
.EduCommissionEmp;
} else if (OtherType == 44) {
tempStr = '/financial/studyabroad/sBuserCommissionDetails?preriodId=' + ID;
} else if (OtherType == 47) {
tempStr = '/financial/contribution/CommissionUserDetailList?TeacherIds=' + this.GetDetail.EduCommissionEmp +
'&preriodId=' + ID;
} else if (OtherType == 50) {
tempStr = '/financial/market/AchievementsUserDetailList?UserIds=' + this.GetDetail.EduCommissionEmp +
'&preriodId=' + ID;
} else if (OtherType == 51) {
tempStr = '/financial/market/empBonusDetail?Id=' + ID;
} else if (OtherType == 49) {
tempStr = '/financial/returnPassbook/returnpassbookStatistics?UnionCashOutId=' + ID;
}
this.$router.push({
......@@ -2228,9 +2235,9 @@
});
},
//跳转到退款协议
goTuikuanDetail(path,Id){
this.OpenNewUrl(path,{
Id:Id
goTuikuanDetail(path, Id) {
this.OpenNewUrl(path, {
Id: Id
})
},
lookbreakage(ID) {
......@@ -2275,7 +2282,7 @@
query: {
'ClassId': item.ClassId,
'School_Id': item.School_Id,
'ClassName': encodeURI(item.ClassName) ,
'ClassName': encodeURI(item.ClassName),
}
})
......@@ -2314,38 +2321,38 @@
}
},
//数组字符串转数组
getRelevanArr(Relevance){
getRelevanArr(Relevance) {
var Arr = [];
if(Relevance){
if (Relevance) {
Arr = Relevance.split(',');
}
return Arr;
},
//跳转
goFinancal(item){
goFinancal(item) {
this.OpenNewUrl('/financial/financalDocument/FinancialDocumentsDetail', {
"id": item
});
},
getReceiptif(){
getReceiptif() {
getReceiptConfigInfo({}).then(res => {
if (res.Code == 1) {
this.ConfigInfo = res.Data;
}
})
},
getreceipt(){
if(this.ConfigInfo.TempleteIds.indexOf(this.GetDetail.TemplateId)!=-1){
getreceipt() {
if (this.ConfigInfo.TempleteIds.indexOf(this.GetDetail.TemplateId) != -1) {
return true
}else{
} else {
return false
}
},
getSJstate(){
getSJstate() {
this.ishowSJ = false
},
//跳转至详情
goFinDetail(obj){
goFinDetail(obj) {
this.$router.push({
path: '/financial/returnPassbook/ReturnUserList',
query: {
......@@ -2355,15 +2362,13 @@
}
})
}
},
mounted() {
this.GetAuth();
this.userInfo = this.getLocalStorage();
this.qjGroupId = this.QjGroupId();
this.Financial_post_GetDetail(this.ID)
this.getReceiptif()//获取收据配置
this.getReceiptif() //获取收据配置
this.queryMsg.FinanceId = this.$route.query.id;
if (this.$route.query.Conditon) {
this.returnCode = this.$route.query.Conditon;
......@@ -2371,5 +2376,4 @@
this.getTuikuan();
}
}
</script>
\ No newline at end of file
......@@ -4,20 +4,26 @@
padding: 18px 0 0 16px;
text-align: right;
}
.ReturnperiodsList .border-bottom {
/* border-bottom: 1px dashed #EEE; */
padding-bottom: 5px;
margin-bottom: 5px;
}
.ReturnperiodsList .text-bottom{
height: 32px;line-height: 32px; margin-bottom: 10px;
.ReturnperiodsList .text-bottom {
height: 32px;
line-height: 32px;
margin-bottom: 10px;
}
.ReturnperiodsList ._icon_btn i.icon-sousuo {
background-color: #47BF8C;
}
.ReturnperiodsList ._icon_btn .icon-add{
.ReturnperiodsList ._icon_btn .icon-add {
background-color: #47BF8C;
}
.ReturnperiodsList ._icon_btn i {
width: 26px;
height: 26px;
......@@ -30,90 +36,62 @@
cursor: pointer;
outline: none;
}
.ReturnperiodsList .el-table td,.el-table th{
.ReturnperiodsList .el-table td,
.el-table th {
padding: 5px 0;
}
</style>
<template>
</style>
<template>
<div class="page-body ReturnperiodsList">
<div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md">
<!-- <div style="margin-right: 20px;" v-if='iscMaker==true'>
<div class="block">
<span style="margin-right: 5px;">校区</span>
<el-select v-model="msg.SchoolId" filterable @change="handleCurrentChanges(1)">
<el-option value="-1" label="不限"></el-option>
<el-option v-for='item in CompanyList' :label='item.SName' :value='item.SId' :key='item.SId'></el-option>
</el-select>
</div>
</div> -->
<div style="display:flex;justify-content: space-between;width: 100%;align-items: center;" >
<div style="display:flex;justify-content: space-between;width: 100%;align-items: center;">
<div class="block" style="display:flex;">
<span style="margin-right: 5px;">月份筛选</span>
<el-date-picker
v-model="msg.Month"
value-format="yyyy-MM"
type="month"
placeholder="选择月"
@change="handleCurrentChanges(1)"
>
<el-date-picker v-model="msg.Month" value-format="yyyy-MM" type="month" placeholder="选择月"
@change="handleCurrentChanges(1)">
</el-date-picker>
</div>
<div v-if='isgenerate==true'>
<q-btn :loading="loading1" color="primary" size="11px" label="生成幸福存折" @click="scCommission" style="height:28px"/>
<q-btn :loading="loading1"  color="primary"  size="11px"  label="生成幸福存折"  @click="scCommission"
 style="height:28px" />
<div style="font-size: 10px;color: #666;">*默认生成上月幸福存折</div>
</div>
</div>
</div>
</div>
<template >
<el-table
ref="filterTable"
:data="tableData"
v-loading = 'loading'
:header-cell-style="{backgroundColor:'#f5f6f7', color: '#a8a8b3'}"
border
style="width: 100%">
<!-- <el-table-column prop="Id" label="ID" ></el-table-column> -->
<el-table-column prop="BatchName" label="周期" ></el-table-column>
<el-table-column prop="TotalMoney" label="累计金额" > </el-table-column>
<el-table-column prop="CreateByName" label="创建人" > </el-table-column>
<el-table-column prop="CreateDate" label="创建时间" > </el-table-column>
<el-table-column label="操作" >
<template>
<el-table ref="filterTable" :data="tableData" v-loading='loading'
:header-cell-style="{backgroundColor:'#f5f6f7', color: '#a8a8b3'}" border style="width: 100%">
<el-table-column prop="BatchName" label="周期"></el-table-column>
<el-table-column prop="TotalMoney" label="累计金额"> </el-table-column>
<el-table-column prop="CreateByName" label="创建人"> </el-table-column>
<el-table-column prop="CreateDate" label="创建时间"> </el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<div class="_icon_btn">
<el-tooltip class="item" effect="dark" content="查看" placement="top">
<i class="iconfont icon-sousuo"
@click="goUrl(scope.row.Id)"></i>
<i class="iconfont icon-sousuo" @click="goUrl(scope.row.Id)"></i>
</el-tooltip>
</div>
</template>
</el-table-column>
</el-table>
<div style="margin-top: 10px;text-align: center;">
<el-pagination background @current-change="handleCurrentChanges" layout="total,prev, pager, next, jumper" :current-page.sync="msg.PageIndex"
:page-size="msg.PageSize" :total='total'>
<el-pagination background @current-change="handleCurrentChanges" layout="total,prev, pager, next, jumper"
:current-page.sync="msg.PageIndex" :page-size="msg.PageSize" :total='total'>
</el-pagination>
</div>
</template>
</div>
</template>
<script>
</template>
<script>
import {
getSchoolDropdown
} from '../../../api/school/index'
import{
import {
getCommissionPeriodsPageList,
setSellCommissionRule,
setUserReturnCommission,
......@@ -130,52 +108,49 @@
return {
loading: false,
loading1: false,
value2:'',
value2: '',
//列表数据参数
msg: {
PageIndex: 1,
PageSize: 15,
SchoolId:'-1',
Month:'',
CommissionType:2,
SchoolId: '-1',
Month: '',
CommissionType: 2,
},
pageCount: 0,
persistent: false,
listData:{},
tableData:[],
total:0,
CompanyList:[],
isgenerate:false,//是否有生成的权限
iscMaker:false,//是否有制单的权限
SendEmployeeList:[],//可发放提成的用户列表
costmode:false,
multipleSelection:[],
totalAmount:0,//选中的金额总额
CheckID:0,
listData: {},
tableData: [],
total: 0,
CompanyList: [],
isgenerate: false, //是否有生成的权限
iscMaker: false, //是否有制单的权限
SendEmployeeList: [], //可发放提成的用户列表
costmode: false,
multipleSelection: [],
totalAmount: 0, //选中的金额总额
CheckID: 0,
}
},
created() {
let userinfo = this.getLocalStorage();
userinfo.ActionMenuList.map(x=>{//判断权限
if(x.FunctionCode == "SAGenerate_Commission"){//判断是否有生成的权限
userinfo.ActionMenuList.map(x => { //判断权限
if (x.FunctionCode == "SAGenerate_Commission") { //判断是否有生成的权限
this.isgenerate = true;
}
if(x.FunctionCode == "SACommission_maker"){//判断是否有制单的权限
if (x.FunctionCode == "SACommission_maker") { //判断是否有制单的权限
this.iscMaker = true;
}
})
var myDate=new Date();
myDate.setMonth(myDate.getMonth()-1);
// this.msg.Month = myDate.getFullYear() + "-" + (myDate.getMonth()+1)
var myDate = new Date();
myDate.setMonth(myDate.getMonth() - 1);
},
mounted() {
this.getList();//获取提成周期列表
// this.getBranchList()
this.getList(); //获取提成周期列表
},
methods: {
getList(){
getList() {
this.loading = true;
getCommissionPeriodsPageList(this.msg).then(res => {
if (res.Code == 1) {
......@@ -185,10 +160,12 @@
}
})
},
scCommission(){//生成提成
if(this.loading1 == false){
this.loading1= true;
setUserReturnCommission({type:2}).then(res => {
scCommission() { //生成提成
if (this.loading1 == false) {
this.loading1 = true;
setUserReturnCommission({
type: 2
}).then(res => {
if (res.Code == 1) {
this.$q.notify({
icon: 'iconfont icon-chenggong',
......@@ -199,20 +176,20 @@
})
this.getList()
}
this.loading1= false;
}).catch(err=>{
this.loading1= false;
this.loading1 = false;
}).catch(err => {
this.loading1 = false;
})
}
},
getBranchList(){//获取校区
getBranchList() { //获取校区
getSchoolDropdown({}).then(res => {
this.CompanyList = res.Data;
}).catch(() => {
})
},
goUrl(id ) {
goUrl(id) {
this.$router.push({
path: '/financial/returnPassbook/ReturnUserList',
query: {
......@@ -222,16 +199,13 @@
}
})
},
handleCurrentChanges(val){
this.msg.PageIndex= val;
handleCurrentChanges(val) {
this.msg.PageIndex = val;
this.getList()
},
},
}
</script>
<style lang="sass">
</script>
<style lang="sass">
@import url('~assets/css/table.sass')
</style>
\ No newline at end of file
</style>
\ No newline at end of file
<style>
.baseSet_Title {
.baseSet_Title {
width: 120px !important;
padding: 18px 0 0 16px;
text-align: right;
}
}
.CommissionDetail .border-bottom {
/* border-bottom: 1px dashed #EEE; */
.CommissionDetail .border-bottom {
padding-bottom: 5px;
margin-bottom: 5px;
}
}
.CommissionDetail .text-bottom {
.CommissionDetail .text-bottom {
height: 32px;
line-height: 32px;
margin-bottom: 10px;
}
}
.CommissionDetail ._icon_btn i.icon-sousuo {
.CommissionDetail ._icon_btn i.icon-sousuo {
background-color: #47bf8c;
}
}
.CommissionDetail ._icon_btn i {
.CommissionDetail ._icon_btn i {
width: 26px;
height: 26px;
display: inline-block;
......@@ -32,93 +31,30 @@
margin-right: 10px;
cursor: pointer;
outline: none;
}
}
.CommissionDetail .el-table td,
.el-table th {
.CommissionDetail .el-table td,
.el-table th {
padding: 5px 0;
}
}
</style>
<template>
<template>
<div class="page-body CommissionDetail">
<div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md">
<div style="margin-right: 10px;">
<q-btn
color="primary"
size="11px"
label="返回"
@click="goreturn"
style="margin-left:10px"
/>
<q-btn color="primary" size="11px" label="返回" @click="goreturn" style="margin-left:10px" />
</div>
<div class="col row wrap q-mr-lg q-col-gutter-md">
<!-- <div class="col-3">
<q-select
filled
stack-label
use-input
input-debounce="0"
option-value="SId"
@input="getList"
option-label="SName"
v-model="msg.SchoolId"
:options="CompanyList"
label="校区"
:dense="false"
emit-value
map-options
></q-select>
</div> -->
<!-- <div class="col-3">
<q-select
filled
stack-label
input-debounce="0"
option-value="Id"
@input="getList"
option-label="Name"
v-model="msg.Status"
:options="StatusList"
label="状态"
:dense="false"
emit-value
map-options
></q-select>
</div> -->
<div class="col-3">
<q-select
filled
stack-label
input-debounce="0"
option-value="Id"
@input="getlaiyuan"
option-label="Name"
v-model="msg.OrderSourceType"
:options="customFromList"
label="来源"
dense
emit-value
map-options
></q-select>
<q-select filled stack-label input-debounce="0" option-value="Id" @input="getlaiyuan" option-label="Name"
v-model="msg.OrderSourceType" :options="customFromList" label="来源" dense emit-value map-options>
</q-select>
</div>
<div class="col-3" v-if="msg.OrderSourceType == 1 || msg.OrderSourceType == 3">
<q-select
filled
stack-label
clearable
v-model="msg.OrderSourceId"
:dense="false"
:options="myEmployeeList"
use-input
@input="getList"
label="人员"
@filter="filterEmployee"
option-label="EmployeeName"
option-value="Id"
emit-value
map-options
>
<q-select filled stack-label clearable v-model="msg.OrderSourceId" :dense="false" :options="myEmployeeList"
use-input @input="getList" label="人员" @filter="filterEmployee" option-label="EmployeeName"
option-value="Id" emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">未找到相关数据</q-item-section>
......@@ -127,22 +63,9 @@
</q-select>
</div>
<div class="col-3" v-if="msg.OrderSourceType == 2">
<q-select
filled
stack-label
v-model="msg.OrderSourceId"
clearable
:dense="false"
:options="customList"
use-input
@input="getList"
label="关联同行"
@filter="filterFn"
option-label="CustomerName"
option-value="CustomerId"
emit-value
map-options
>
<q-select filled stack-label v-model="msg.OrderSourceId" clearable :dense="false" :options="customList"
use-input @input="getList" label="关联同行" @filter="filterFn" option-label="CustomerName"
option-value="CustomerId" emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">未找到相关数据</q-item-section>
......@@ -151,22 +74,9 @@
</q-select>
</div>
<div class="col-3" v-if="msg.OrderSourceType == 4">
<q-select
filled
clearable
stack-label
v-model="msg.OrderSourceId"
:dense="false"
:options="InvitationList"
use-input
@input="getList"
label="转介人"
@filter="filterFnStudent"
option-label="StuName"
option-value="StuId"
emit-value
map-options
>
<q-select filled clearable stack-label v-model="msg.OrderSourceId" :dense="false" :options="InvitationList"
use-input @input="getList" label="转介人" @filter="filterFnStudent" option-label="StuName"
option-value="StuId" emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">未找到相关数据</q-item-section>
......@@ -178,46 +88,24 @@
</div>
</div>
<template>
<el-table
ref="filterTable"
:data="tableData"
v-loading="loading"
:header-cell-style="{ backgroundColor: '#f5f6f7', color: '#a8a8b3' }"
border
style="width: 100%"
>
<el-table ref="filterTable" :data="tableData" v-loading="loading"
:header-cell-style="{ backgroundColor: '#f5f6f7', color: '#a8a8b3' }" border style="width: 100%">
<el-table-column prop="SchoolName" label="校区"></el-table-column>
<el-table-column
prop="UserName"
label="人员"
:filters="UserNamelist"
:filter-method="filterHandler"
></el-table-column>
<el-table-column prop="UserName" label="人员" :filters="UserNamelist" :filter-method="filterHandler">
</el-table-column>
<el-table-column prop="OrderSourceType" label="类型">
<template slot-scope="scope">
{{getOrderSourceType(scope.row.OrderSourceType)}}
</template>
</el-table-column>
<el-table-column
prop="StudentCount"
label="学生数量"
sortable
:sort-method="StudentCount"
></el-table-column>
<el-table-column
prop="CommissionMoeny"
label="提成金额"
sortable
:sort-method="CommissionMoeny"
></el-table-column>
<el-table-column prop="StudentCount" label="学生数量" sortable :sort-method="StudentCount"></el-table-column>
<el-table-column prop="CommissionMoeny" label="提成金额" sortable :sort-method="CommissionMoeny"></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<div class="_icon_btn">
<el-tooltip class="item" effect="dark" content="查看" placement="top">
<i
class="iconfont icon-sousuo"
@click="goUrl('returnPassbook/returnpassbookStatistics', scope.row)"
></i>
<i class="iconfont icon-sousuo"
@click="goUrl('returnPassbook/returnpassbookStatistics', scope.row)"></i>
</el-tooltip>
</div>
</template>
......@@ -226,29 +114,29 @@
</template>
</div>
</template>
<script>
import {
<script>
import {
GetClassTypePageList,
} from '../../../api/system/index';
import {
} from '../../../api/system/index';
import {
GetStudentList,
} from '../../../api/course/class';
import {
} from '../../../api/course/class';
import {
getCommissionUserList,
} from '../../../api/finance/index'
import {
} from '../../../api/finance/index'
import {
getSchoolDropdown,
getStudentDorpDownList
} from "../../../api/school/index";
import {
} from "../../../api/school/index";
import {
queryEmployee
} from '../../../api/users/user'
import {
} from '../../../api/users/user'
import {
CreateTypeList,
GetCustomerList
} from '../../../api/sale/sale'
export default {
} from '../../../api/sale/sale'
export default {
meta: {
title: "销售提成详情"
},
......@@ -265,15 +153,28 @@ export default {
OrderSourceType: '-1',
OrderSourceId: 0,
Q_SelectNormal: '2',
UserDept:0
UserDept: 0
},
pageCount: 0,
persistent: false,
tableData: [],
CompanyList: [],
StatusList: [
{ Id: '-2', Name: '不限' }, { Id: '-1', Name: '不返佣' }, { Id: '0', Name: '待返佣' }, { Id: '1', Name: '已返佣到账户' }, { Id: '2', Name: '佣金已提现' },
],
StatusList: [{
Id: '-2',
Name: '不限'
}, {
Id: '-1',
Name: '不返佣'
}, {
Id: '0',
Name: '待返佣'
}, {
Id: '1',
Name: '已返佣到账户'
}, {
Id: '2',
Name: '佣金已提现'
}, ],
see_tcdetailed: false,
customFromList: [],
UserNamelist: [],
......@@ -288,13 +189,12 @@ export default {
AllInvitationList: [],
}
},
created() {
},
created() {},
mounted() {
if (this.$route.query && this.$route.query.id) {
this.msg.BatchId = this.$route.query.id
}
if (this.$route.query.ReFinanceId2){
if (this.$route.query.ReFinanceId2) {
this.msg.UserDept = this.$route.query.ReFinanceId2;
}
this.getList()
......@@ -303,21 +203,20 @@ export default {
this.getEmployeeList()
this.getStudentDorpDown()
this.GetCustomerList()
this.getStudentList();//学员下拉
this.getStudentList(); //学员下拉
},
methods: {
getList() {
this.loading = true;
let msg = JSON.parse(JSON.stringify(this.msg))
if (msg.OrderSourceId == ''|| msg.OrderSourceId==null) {
if (msg.OrderSourceId == '' || msg.OrderSourceId == null) {
msg.OrderSourceId = 0
}
getCommissionUserList(msg).then(res => {
if (res.Code == 1) {
this.loading = false;
this.tableData = res.Data;
this.UserNamelist = [];
this.tableData.forEach(x => {
let obj3 = {
......@@ -333,13 +232,12 @@ export default {
getlaiyuan() {
if (this.msg.OrderSourceType == -1) {
this.msg.OrderSourceId = 0
} else {
this.msg.OrderSourceId = ''
}
this.getList()
},
getBranchList() {//获取校区
getBranchList() { //获取校区
getSchoolDropdown({}).then(res => {
let obj = {
SName: '不限',
......@@ -361,14 +259,13 @@ export default {
}
this.customFromList = res.Data;
this.customFromList.unshift(obj);
}
})
},
getOrderSourceType(Id){
getOrderSourceType(Id) {
let Name = ''
this.customFromList.forEach(x=>{
if(x.Id == Id){
this.customFromList.forEach(x => {
if (x.Id == Id) {
Name = x.Name
}
})
......@@ -464,17 +361,14 @@ export default {
}
})
},
goUrl(path, row) {
this.$router.push({
path: '/financial/' + path,
query: {
preriodId: this.$route.query.id,
CommissionType: this.$route.query.CommissionType,
OrderSourceType:row.OrderSourceType,
OrderSourceId:row.OrderSourceId,
OrderSourceType: row.OrderSourceType,
OrderSourceId: row.OrderSourceId,
blank: 'y',
}
})
......@@ -492,13 +386,9 @@ export default {
goreturn() {
this.$router.go(-1);
}
},
}
}
</script>
<style lang="sass">
@import url('~assets/css/table.sass')
<style lang="sass">
@import url('~assets/css/table.sass')
</style>
\ No newline at end of file
\ No newline at end of file
......@@ -206,7 +206,14 @@
this.msgFinance.BatchId = id;
SetCommissionPeriodsFinanace(this.msgFinance).then(res => {
if (res.Code == 1) {
this.getList()
this.getList();
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: res.Message,
position: 'top'
})
}
this.loading1 = false;
}).catch(err => {
......
......@@ -152,6 +152,11 @@
</template>
<template v-if="item.label=='合计回单'||item.label=='合计到访'||item.label=='合计转化率'">
<el-table-column :prop="item.prop" :label="item.label" fixed="right" sortable width="115" :key="index">
<template slot-scope="scope">
<a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;">
{{scope.row[item.prop]}}
</a>
</template>
</el-table-column>
</template>
<template v-if="item.SubList&&item.SubList.length>0">
......@@ -213,6 +218,7 @@
};
},
created() {
this.getEmployeeList();
this.CurrentUserInfo = this.getLocalStorage();
if (this.CurrentUserInfo && this.CurrentUserInfo.ActionMenuList && this.CurrentUserInfo.ActionMenuList.length >
0) {
......@@ -248,13 +254,33 @@
this.msg.endTime = year + strLink + month + strLink + day;
this.dateList.push(year + strLink + month + strLink + '01');
this.dateList.push(year + strLink + month + strLink + day);
this.getEmployeeList();
this.getData();
setTimeout(() => {
this.tableHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 60;
}, 200)
},
methods: {
//跳转到客户列表
showDetail(row) {
if (this.CurrentUserInfo && (this.CurrentUserInfo.IsMarket == 1 || this.CurrentUserInfo.IsCourseConsultant ==
1)) {
var url = "/sale/mystu";
this.OpenNewUrl(url, {
startTime: this.msg.startTime,
endTime: this.msg.endTime,
createBy: row.Id,
})
} else {
var url = '/school/student';
this.OpenNewUrl(url, {
startTime: this.msg.startTime,
endTime: this.msg.endTime,
createBy: row.Id,
})
}
},
//下载渠道总表
downloadMarketChannelStudentStatic() {
var msg = JSON.parse(JSON.stringify(this.msg));
this.loading = true;
......
......@@ -195,10 +195,12 @@
customFromList: [], //客户来源
StuChannelList: [], //收客渠道
allStuChannelList: [], //所有收客渠道
consultList: []
consultList: [],
CurrentUserInfo: {},
};
},
created() {
this.CurrentUserInfo = this.getLocalStorage();
this.getSchool();
this.getStuStageList();
this.getCustomTypeList();
......@@ -217,6 +219,12 @@
if (this.$route.query.ChannelId) {
this.msg.StuChannel = this.$route.query.ChannelId;
}
if (this.$route.query.createBy) {
if (this.CurrentUserInfo.IsManager == 1 && this.CurrentUserInfo.IsMarket == 1) {
this.msg.BelongType = 4;
this.msg.CreateIds.push(Number(this.$route.query.createBy));
}
}
this.getCustomerList();
this.getCustomFrom();
this.GetStuChannelList();
......
......@@ -17,8 +17,8 @@
<div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md">
<div class="col-4 Sysuser_Date">
<q-field filled>
 <template v-slot:control>
<q-field filled>
<template v-slot:control>
<el-date-picker v-model="dateList" type="daterange" style="width:100%" :picker-options="pickerOptions0"
align="right" value-format="yyyy-MM-dd" @change="getData" unlink-panels range-separator="至"
start-placeholder="开始日期" end-placeholder="结束日期">
......@@ -27,8 +27,8 @@
</q-field>
</div>
<div class="col-3 Sysuser_Date">
<q-field filled>
 <template v-slot:control>
<q-field filled>
<template v-slot:control>
<el-select class="topselect" v-model="msg.empList" @change="getData" style="width:100%;" collapse-tags
multiple filterable placeholder="请选择">
<el-option v-for="item in EmployeeList" :key="item.Id" :label="item.EmployeeName" :value="item.Id">
......@@ -56,10 +56,25 @@
<el-table-column prop="ChannelName" label="渠道名">
</el-table-column>
<el-table-column prop="ClueCount" label="回单" sortable>
<template slot-scope="scope">
<a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;">
{{scope.row.ClueCount}}
</a>
</template>
</el-table-column>
<el-table-column prop="VisitCount" label="到访" sortable>
<template slot-scope="scope">
<a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;">
{{scope.row.VisitCount}}
</a>
</template>
</el-table-column>
<el-table-column prop="OrderCount" label="合同数" sortable>
<template slot-scope="scope">
<a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;">
{{scope.row.VisitCount}}
</a>
</template>
</el-table-column>
<el-table-column prop="OrderIncome" label="新业绩金额" sortable>
</el-table-column>
......@@ -112,6 +127,7 @@
};
},
created() {
this.getEmployeeList();
this.CurrentUserInfo = this.getLocalStorage();
if (this.CurrentUserInfo && this.CurrentUserInfo.ActionMenuList && this.CurrentUserInfo.ActionMenuList.length >
0) {
......@@ -138,13 +154,46 @@
this.msg.endTime = year + strLink + month + strLink + day;
this.dateList.push(year + strLink + month + strLink + '01');
this.dateList.push(year + strLink + month + strLink + day);
this.getEmployeeList();
this.getData();
setTimeout(() => {
this.tableHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 90;
}, 100)
},
methods: {
//跳转到列表
showDetail(row) {
var url = "/sale/mystu";
if (this.CurrentUserInfo && (this.CurrentUserInfo.IsMarket == 1 || this.CurrentUserInfo.IsCourseConsultant ==
1)) {
url = "/sale/mystu";
} else {
url = '/school/student';
}
var CreateType = 2;
//同行渠道
if (this.msg.top_Check == 1) {
CreateType = 2;
}
//内部渠道
if (this.msg.top_Check == 2) {
CreateType = 3;
}
//学校渠道
if (this.msg.top_Check == 3) {
CreateType = 2;
}
//转介绍渠道
if (this.msg.top_Check == 4) {
CreateType = 4;
}
this.OpenNewUrl(url, {
CreateType: CreateType,
StuSourceId: row.ChannelId,
startTime: this.msg.startTime,
endTime: this.msg.endTime,
})
},
//下载同行渠道
downloadMarketCreateType() {
var msg = JSON.parse(JSON.stringify(this.msg));
var fileName = "同行渠道.xls";
......
......@@ -61,6 +61,11 @@
v-model="msg.AdvisorStatus" ref="AdvisorStatus" :options="consultList" clearable label="当前状态"
class="col-6 q-pb-lg" emit-value map-options />
</div>
<div class="col-3">
<q-select filled stack-label option-value="Id" @input="resetSearch" dense option-label="Name"
v-model="msg.StuChannel" ref="AdvisorStatus" :options="channelList" clearable label="渠道"
class="col-6 q-pb-lg" emit-value map-options />
</div>
</div>
</div>
<div class="page-content">
......@@ -94,6 +99,9 @@
import {
GetStudentAdvisorConfigList
} from "../../api/customerstudent/customerstudent";
import {
GetStuChannelList
} from "../../api/sale/sale";
import stulist from '../../components/school/student/stulist'
import {
mapGetters
......@@ -126,7 +134,10 @@
StuType: '',
QStudentStatus: 1, //客户状态 1有效 2无效
AdvisorStatus: '', //当前状态
StuChannel:"",
StuChannel: "",
CreateIds: [],
CreateType: "", //来源类型
StuSourceId: "", //来源人编号
},
dateArray: [], //日期数组
pageCount: 0,
......@@ -138,7 +149,9 @@
AuthObj: {
isShowDownload: true,
},
consultList: []
consultList: [],
//渠道列表
channelList: [],
}
},
computed: {
......@@ -148,6 +161,7 @@
this.getEmployeeList();
this.getStuStageList();
this.getCustomTypeList();
this.queryChannelList();
},
mounted() {
this.currentUrl = this.$route.path;
......@@ -162,10 +176,27 @@
if (this.$route.query.ChannelId) {
this.msg.StuChannel = this.$route.query.ChannelId;
}
if (this.$route.query.createBy) {
this.msg.CreateBy = Number(this.$route.query.createBy);
}
if (this.$route.query.CreateType) {
this.msg.CreateType = Number(this.$route.query.CreateType);
}
if (this.$route.query.StuSourceId) {
this.msg.StuSourceId = Number(this.$route.query.StuSourceId);
}
this.getStatusList();
this.getStudent()
},
methods: {
//获取渠道列表
queryChannelList() {
GetStuChannelList({}).then(res => {
if (res.Code == 1) {
this.channelList = res.Data;
}
})
},
//获取跟进状态下拉
getStatusList() {
let msg = {
......
......@@ -384,9 +384,14 @@
@click="transferClass(props.row, 1)" />
<q-btn-dropdown flat size="xs" color="dark" label="更多" style="margin-left: 10px">
<q-list>
<q-item clickable v-close-popup @click="showAddEvent(props.row)">
<q-item dense clickable v-close-popup @click="showAddEvent(props.row)">
<q-item-section>
<q-item-label>添加事件</q-item-label>
<q-item-label overline>添加事件</q-item-label>
</q-item-section>
</q-item>
<q-item dense clickable v-close-popup @click="showChangeCourse(props.row)">
<q-item-section>
<q-item-label overline >跳课</q-item-label>
</q-item-section>
</q-item>
</q-list>
......@@ -422,6 +427,8 @@
<studentRight-form v-if="isShowStuRight" :isJudgeTrans="isJudgeTrans" :BelongType="BelongType" :save-obj="stuOption"
@close="closeStuForm" @success="refreshStuList" @reload="refreshStuList">
</studentRight-form>
<!-- 跳课 -->
<JumpCourse v-model="isShowChangeCourse" :saveObj="ChangeCourseObj" @success="refreshPage" ></JumpCourse>
</div>
</template>
<script>
......@@ -453,6 +460,7 @@
import list from "../../components/stuMan/makeUpHours.vue"; //可补课课时,缺勤次数,请假次数
import eventLog from "../../components/stuMan/eventRecord.vue"; //事件记录
import studentRightForm from "../../components/school/student/studentRight-form";
import JumpCourse from "../../components/stuMan/jumpCourse"
import {
queryEmployee
} from "../../api/users/user";
......@@ -469,7 +477,8 @@
myOrderForm,
list,
eventLog,
studentRightForm
studentRightForm,
JumpCourse
},
data() {
......@@ -644,6 +653,18 @@
field: "MakeUpHours",
align: "left"
},
{
name: "CourseChapterNo",
label: "已上课次数",
field: "CourseChapterNo",
align: "left"
},
{
name: "AppointNum",
label: "预约次数",
field: "AppointNum",
align: "left"
},
{
name: "AbsenceNum",
label: "缺勤次数",
......@@ -742,7 +763,9 @@
TransListData: [], //转介人数据
MyTransListData: [],
source: 0, //1:从课程列表进入
courseName: ""
courseName: "",
isShowChangeCourse:false,
ChangeCourseObj:{}
};
},
created() {
......@@ -1145,6 +1168,10 @@
},
refreshStuList() {
this.getList();
},
showChangeCourse(item){
this.isShowChangeCourse=true
this.ChangeCourseObj=item
}
}
};
......
<template>
<div class="page-body" style="width: 100%;">
<div class="page-body">
<div class="col row wrap q-mr-lg q-col-gutter-md searchBox">
<div class="col-2">
<q-select
......@@ -86,6 +86,7 @@
emit-value
map-options
label="显示模式"
@input="changeDate"
/>
</div>
</div>
......@@ -108,13 +109,13 @@
@click="calendarNext"
/>
</div>
<div class="viewbox">
<q-calendar
v-model="selectedDate"
:view="viewType"
ref="calendar"
locale="zh-CN"
class="calendar-container"
style="height:calc(100% - 32px)"
class="calendar-container "
bordered
hour24-format
:interval-start="8"
......@@ -123,6 +124,7 @@
animated
transition-prev="slide-right"
transition-next="slide-left"
:weekdays="[1, 2, 3, 4, 5, 6, 0]"
@input="onModelChanged"
@click:date2="onClickDate2"
@click:day:header2="onClickDayHeader2"
......@@ -131,7 +133,7 @@
@click:interval:header2="onClickIntervalHeader2"
>
<template #day-header="{ timestamp }">
<div class="justify-center items-center " v-if="viewType == 'week'">
<div v-if="viewType == 'week'">
<q-badge
:color="item.bg"
:label="item.TeacherName"
......@@ -140,7 +142,7 @@
class="q-mr-xs"
/>
</div>
<div class="justify-center items-center " v-if="viewType == 'day'">
<div class="flex no-wrap" v-if="viewType == 'day'">
<q-badge
:color="item.bg"
:label="item.TeacherName"
......@@ -192,8 +194,8 @@
"
/>
<q-icon
name="lock"
color="res"
name="lock_open"
color="dark"
style="position:absolute;top:0;right:0"
v-if="
viewType == 'week' &&
......@@ -240,7 +242,9 @@
类型:<span></span
><span v-if="__item.ClassType == 1">跟班</span
><span v-if="__item.ClassType == 2">试听课</span
><span v-if="__item.ClassType == 3">约课</span></span
><span v-if="__item.ClassType == 3"
>约课</span
></span
>
</div>
......@@ -275,7 +279,12 @@
color="accent"
size="xs"
label="确认"
v-if="__item.AppointState == 1"
v-if="
__item.AppointState == 1 &&
__item.GuestList.length >=
__item.ScrollMinNum &&
auth.IsEdit
"
@click="
confirmSub(
item.ClassDate,
......@@ -303,7 +312,10 @@
label="未成班"
style="position:absolute;top:0;right:0"
v-if="
isShowTag(__item.GuestList.length, __item.ScrollMinNum)
isShowTag(
__item.GuestList.length,
__item.ScrollMinNum
)
"
/>
<div class="flex">
......@@ -324,12 +336,18 @@
</div>
<div class="flex no-wrap">
<span class="detailLabel">时间:</span
><span>{{ __item.StartTime }}-{{ __item.EndTime }}</span>
><span
>{{ __item.StartTime }}-{{ __item.EndTime }}</span
>
</div>
<div class="flex no-wrap" v-if="__item.ClassType !== 2">
<span class="detailLabel">进度:</span
><span>{{ __item.Ranks }}/{{ __item.TotalPlanNum }}</span>
<span class="q-ml-sm">{{ __item.CourseGradeName }}</span>
><span
>{{ __item.Ranks }}/{{ __item.TotalPlanNum }}</span
>
<span class="q-ml-sm">{{
__item.CourseGradeName
}}</span>
</div>
<div class="flex no-wrap">
<span class="detailLabel"> 类型:</span
......@@ -360,9 +378,18 @@
color="accent"
size="xs"
label="确认"
v-if="__item.AppointState == 1"
v-if="
__item.AppointState == 1 &&
__item.GuestList.length >=
__item.ScrollMinNum &&
auth.IsEdit
"
@click="
confirmSub(item.ClassDate, _item.TeacherId, __item)
confirmSub(
item.ClassDate,
_item.TeacherId,
__item
)
"
/>
</span>
......@@ -383,11 +410,14 @@
</div>
</template>
</q-calendar>
</div>
<SubscribeForm
v-model="showForm"
:editType="editType"
:dateObj="dateObj"
:saveObj="saveObj"
:auth="auth"
:teacherList="TeacherList2"
@success="successHandle"
/>
......@@ -417,12 +447,11 @@ export default {
},
pickerOptions: {
disabledDate: time => {
//time跟页面没有关系 相当于日期数组
let timeRange = this.config.AppointDay * 24 * 60 * 60 * 1000; // 7天
let _maxTime = Date.now() - 8.64e7 + timeRange; // 最大时间
return (
time.getTime() < Date.now() - 8.64e7 || time.getTime() > _maxTime
); //设置选择今天以及今天之后的日期
// let timeRange = this.config.AppointDay * 24 * 60 * 60 * 1000;
// let _maxTime = Date.now() - 8.64e7 + timeRange; // 最大时间
// return (
// time.getTime() < Date.now() - 8.64e7 || time.getTime() > _maxTime
// );
}
},
viewType: "week",
......@@ -502,7 +531,10 @@ export default {
TeacherList2: [],
events: [],
dateObj: {},
saveObj: {}
saveObj: {},
auth: {
IsEdit: false
}
};
},
components: {
......@@ -516,6 +548,15 @@ export default {
this.msg.EndDate = this.$refs.calendar.lastEnd;
this.getData();
this.getAppointmentConfig();
const ActionMenuList = JSON.parse(localStorage.getItem("loginUserInfo")).data.ActionMenuList
const res = ActionMenuList.find(e => {
return e.FunctionCode == "subscribe_edit";
});
if (res) {
this.auth.IsEdit = true;
} else {
this.auth.IsEdit = false;
}
},
methods: {
badgeClasses(event, type, TeacherId) {
......@@ -567,7 +608,7 @@ export default {
}, 100);
},
getTeacherList() {
getTeacherDropDownList({ LeaveStatus: 1,IsShow :1 }).then(res => {
getTeacherDropDownList({ LeaveStatus: 1, IsShow: 1 }).then(res => {
if (res.Code == 1) {
this.TeacherList = JSON.parse(JSON.stringify(res.Data));
var obj = {
......@@ -602,7 +643,19 @@ export default {
},
getData() {
GetAppointmentPlanStat(this.msg).then(res => {
this.events = res.Data;
// this.events = res.Data;
let data = JSON.parse(JSON.stringify(res.Data));
res.Data.map((e, i) => {
data[i].RList = [];
e.RList.map(x => {
this.legendList.map(y => {
if (y.TId == x.TeacherId) {
data[i].RList.push(x);
}
});
});
});
this.events = data;
});
},
changeDate() {
......@@ -634,10 +687,13 @@ export default {
onClickDayHeader2(data) {},
onClickInterval2(data) {},
onClickTime2(data) {
//小于今天,不显示弹窗
if (this.showAddStu(data.scope.timestamp.date) && this.auth.IsEdit) {
this.showForm = true;
this.editType = 1;
this.saveObj = {};
this.dateObj = data.scope.timestamp;
}
},
onClickIntervalHeader2(data) {},
showDetail(data, date, tid) {
......@@ -686,29 +742,34 @@ export default {
GetAppointmentConfig({}).then(res => {
this.config = res.Data;
});
},
showAddStu(date) {
if (new Date(date).getTime() < new Date(QCalendar.today()).getTime()) {
return false;
} else {
return true;
}
}
}
};
</script>
<style lang="sass">
.calendar-container
position: relative
.my-event
// width: 100%
position: absolute
font-size: 12px
// .full-width
// left: 0
// width: 100%
// .left-side
// left: 0
// width: 49.75%
// .right-side
// left: 50.25%
// width: 49.75%
</style>
<style lang="scss">
.viewbox {
// width:1500px;
overflow-x: auto;
box-sizing: border-box;
}
.calendar-container {
position: relative;
// height: calc(100% - 32px);
// width: 200%;
overflow: auto;
}
.my-event {
position: absolute;
font-size: 12px;
}
.searchBox .el-input__inner {
border: none;
background-color: transparent;
......@@ -724,25 +785,6 @@ export default {
// padding: 3px;
height: 100%;
}
.courseItem::-webkit-scrollbar {
/*滚动条整体样式*/
width: 4px; /*高宽分别对应横竖滚动条的尺寸*/
height: 4px;
scrollbar-arrow-color: #999;
}
.courseItem::-webkit-scrollbar-thumb {
/*滚动条里面小方块*/
border-radius: 5px;
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: rgba(0, 0, 0, 0.2);
scrollbar-arrow-color: #999;
}
.courseItem::-webkit-scrollbar-track {
/*滚动条里面轨道*/
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
border-radius: 0;
background: rgba(0, 0, 0, 0.1);
}
.detailLabel {
width: 35px;
white-space: nowrap;
......
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