Commit 5839a541 authored by 黄奎's avatar 黄奎

页面修改

parent ad0f605f
<style> <style>
.delAssist { .delAssist {
position: absolute; position: absolute;
right: -16px; right: -16px;
top: -12px; top: -12px;
...@@ -12,104 +12,51 @@ ...@@ -12,104 +12,51 @@
text-align: center; text-align: center;
line-height: 20px; line-height: 20px;
cursor: pointer; cursor: pointer;
} }
.studentAssitTable { .studentAssitTable {
width: 100%; width: 100%;
text-align: center; text-align: center;
} }
.studentAssitTable td { .studentAssitTable td {
height: 40px; height: 40px;
line-height: 40px; line-height: 40px;
border: 1px solid #f2f2f2; border: 1px solid #f2f2f2;
} }
.studentAssitTable th { .studentAssitTable th {
height: 40px; height: 40px;
background-color: #f2f2f2; background-color: #f2f2f2;
} }
</style> </style>
<template> <template>
<div> <div>
<q-btn <q-btn label="新增" color="accent q-mb-lg" size="sm" v-if="userInfo.IsCourseConsultant == 1"
label="新增" @click="isShowAdd = true" />
color="accent q-mb-lg"
size="sm"
v-if="userInfo.IsCourseConsultant == 1"
@click="isShowAdd = true"
/>
<span class="text-grey-4" v-else>抱歉,你没有权限邀请其他服务人员</span> <span class="text-grey-4" v-else>抱歉,你没有权限邀请其他服务人员</span>
<q-btn <q-btn label="取消" style="margin-left:20px;" v-if="isShowAdd" flat color="grey-10 q-mb-lg" size="sm"
label="取消" @click="isShowAdd = false" />
style="margin-left:20px;"
v-if="isShowAdd"
flat
color="grey-10 q-mb-lg"
size="sm"
@click="isShowAdd = false"
/>
<template v-if="isShowAdd"> <template v-if="isShowAdd">
<div class="row wrap"> <div class="row wrap">
<q-select <q-select filled stack-label option-label="Name" @input="getRole" v-model="AssitMsg.AssistType"
filled option-value="Id" :options="AssistDropList" label="角色" dense class="col-6 q-pb-lg q-pr-lg" emit-value
stack-label map-options />
option-label="Name" <q-select filled dense v-if="AssitMsg.AssistType == 2" v-model="AssitMsg.AssistId" :options="RoleListData"
@input="getRole" option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value map-options />
v-model="AssitMsg.AssistType" <q-select filled dense v-else v-model="AssitMsg.AssistId" @filter="filterEmployee" use-input
option-value="Id" :options="myEmployeeList" option-label="EmployeeName" class="col-6 q-pb-lg" option-value="Id" emit-value
:options="AssistDropList" map-options />
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> <i class="iconfont icon-close delAssist"></i>
</div> </div>
<div class="row wrap" style="margin-bottom:10px;float:right;"> <div class="row wrap" style="margin-bottom:10px;float:right;">
<q-btn <q-btn label="保存" color="accent q-mb-lg" size="md" @click="saveAssit()" />
label="保存"
color="accent q-mb-lg"
size="md"
@click="saveAssit()"
/>
</div> </div>
</template> </template>
<div v-if="dataList.length > 0"> <div v-if="dataList.length > 0">
<table <table class="studentAssitTable" style="border:1px solid #f2f2f2;border-collapse:collapse;" cellspacing="0"
class="studentAssitTable" cellpadding="0">
style="border:1px solid #f2f2f2;border-collapse:collapse;"
cellspacing="0"
cellpadding="0"
>
<tr> <tr>
<th style="width:180px;">角色</th> <th style="width:180px;">角色</th>
<th style="width:180px;">人员</th> <th style="width:180px;">人员</th>
...@@ -120,35 +67,14 @@ ...@@ -120,35 +67,14 @@
<td>{{ item.AssistName }}</td> <td>{{ item.AssistName }}</td>
<td v-if="userInfo.IsCourseConsultant == 1"> <td v-if="userInfo.IsCourseConsultant == 1">
<div v-if="item.AssistType != 2 && item.AssistType != 4"> <div v-if="item.AssistType != 2 && item.AssistType != 4">
<q-btn <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="修改"
flat @click="getEditInfo(item)"></q-btn>
size="xs" <q-btn flat size="xs" icon="delete" color="negative" style="font-weight:400" label="删除"
icon="edit" @click="deleteAssits(item.Id)" />
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>
<div v-if="isShowBian(item)"> <div v-if="isShowBian(item)">
<q-btn <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="修改"
flat @click="getGuwenEditInfo(item)"></q-btn>
size="xs"
icon="edit"
color="accent"
style="font-weight:400"
label="修改"
@click="getGuwenEditInfo(item)"
></q-btn>
</div> </div>
</td> </td>
</tr> </tr>
...@@ -157,15 +83,17 @@ ...@@ -157,15 +83,17 @@
</div> </div>
</template> </template>
<script> <script>
import { import {
GetAssistTypeList, GetAssistTypeList,
SetStudentAssist, SetStudentAssist,
GetStudentAssistList, GetStudentAssistList,
RemoveStudentAssist RemoveStudentAssist
} from "../../../api/sale/sale"; } from "../../../api/sale/sale";
import { queryEmployee } from "../../../api/users/user"; import {
queryEmployee
} from "../../../api/users/user";
export default { export default {
meta: { meta: {
title: "" title: ""
}, },
...@@ -222,7 +150,7 @@ export default { ...@@ -222,7 +150,7 @@ export default {
if (res.Code == 1) { if (res.Code == 1) {
let template = res.Data; let template = res.Data;
template.forEach(x => { template.forEach(x => {
if (x.Id != 1 && x.Id != 4) { if (x.Id != 1) {
this.AssistDropList.push(x); this.AssistDropList.push(x);
} }
}); });
...@@ -292,11 +220,11 @@ export default { ...@@ -292,11 +220,11 @@ export default {
.catch(() => {}); .catch(() => {});
}, },
//课程顾问是本人 显示编辑按钮 //课程顾问是本人 显示编辑按钮
isShowBian(item){ isShowBian(item) {
let isShow=false; let isShow = false;
if(item.AssistTypeName=='课程顾问'){ if (item.AssistTypeName == '课程顾问') {
if(this.userInfo.AccountName==item.AssistName){ if (this.userInfo.AccountName == item.AssistName) {
isShow=true isShow = true
} }
} }
return isShow; return isShow;
...@@ -335,7 +263,7 @@ export default { ...@@ -335,7 +263,7 @@ export default {
this.AssitMsg.AssistType = obj.AssistType; this.AssitMsg.AssistType = obj.AssistType;
this.isShowAdd = true; this.isShowAdd = true;
}, },
getGuwenEditInfo(obj){ getGuwenEditInfo(obj) {
this.getRole(); this.getRole();
this.AssitMsg.Id = obj.Id; this.AssitMsg.Id = obj.Id;
this.AssitMsg.AssistId = obj.AssistId; this.AssitMsg.AssistId = obj.AssistId;
...@@ -343,5 +271,5 @@ export default { ...@@ -343,5 +271,5 @@ export default {
this.isShowAdd = true; this.isShowAdd = true;
} }
} }
}; };
</script> </script>
\ No newline at end of file
...@@ -263,19 +263,22 @@ ...@@ -263,19 +263,22 @@
methods: { methods: {
//跳转到客户列表 //跳转到客户列表
showDetail(row) { showDetail(row) {
var url = "/sale/mystu";
if (this.CurrentUserInfo && (this.CurrentUserInfo.IsMarket == 1 || this.CurrentUserInfo.IsCourseConsultant == if (this.CurrentUserInfo && (this.CurrentUserInfo.IsMarket == 1 || this.CurrentUserInfo.IsCourseConsultant ==
1)) { 1)) {
url = "/sale/mystu"; var url = "/sale/mystu";
this.OpenNewUrl(url, {
startTime: this.msg.startTime,
endTime: this.msg.endTime,
createBy: row.Id,
})
} else { } else {
url = '/school/student'; var url = '/school/student';
}
this.OpenNewUrl(url, { this.OpenNewUrl(url, {
ChannelId: 0,
startTime: this.msg.startTime, startTime: this.msg.startTime,
endTime: this.msg.endTime, endTime: this.msg.endTime,
createBy: row.Id, createBy: row.Id,
}) })
}
}, },
//下载渠道总表 //下载渠道总表
downloadMarketChannelStudentStatic() { downloadMarketChannelStudentStatic() {
......
...@@ -195,10 +195,12 @@ ...@@ -195,10 +195,12 @@
customFromList: [], //客户来源 customFromList: [], //客户来源
StuChannelList: [], //收客渠道 StuChannelList: [], //收客渠道
allStuChannelList: [], //所有收客渠道 allStuChannelList: [], //所有收客渠道
consultList: [] consultList: [],
CurrentUserInfo: {},
}; };
}, },
created() { created() {
this.CurrentUserInfo = this.getLocalStorage();
this.getSchool(); this.getSchool();
this.getStuStageList(); this.getStuStageList();
this.getCustomTypeList(); this.getCustomTypeList();
...@@ -217,6 +219,12 @@ ...@@ -217,6 +219,12 @@
if (this.$route.query.ChannelId) { if (this.$route.query.ChannelId) {
this.msg.StuChannel = 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.getCustomerList();
this.getCustomFrom(); this.getCustomFrom();
this.GetStuChannelList(); this.GetStuChannelList();
......
...@@ -69,7 +69,6 @@ ...@@ -69,7 +69,6 @@
</a> </a>
</template> </template>
</el-table-column> </el-table-column>
</el-table-column>
<el-table-column prop="OrderCount" label="合同数" sortable> <el-table-column prop="OrderCount" label="合同数" sortable>
<template slot-scope="scope"> <template slot-scope="scope">
<a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;"> <a @click="showDetail(scope.row)" style="color:#67C23A;cursor:pointer;text-decoration:underline;">
......
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