Commit cd8c7626 authored by 黄奎's avatar 黄奎

页面修改

parent 5ed2eafc
......@@ -90,15 +90,14 @@
background: #F0F2F5 !important;
border: 0;
}
</style>
<template>
<div class="schedulVisit">
<div class="page-content">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat
class="stickycreatInsertStr-column-table schedul_Vtable" separator="none" :data="data" :columns="columns"
row-key="name" :visible-columns="visibleColumns">
<template v-slot:top="props">
row-key="name">
<template>
<div class="fangkeTitle" ref="fkdj">访客登记</div>
<span class="fangkeNumb">{{data.length}}</span>
<div class="visit_Date">
......@@ -157,28 +156,9 @@
</el-popover>
</div>
</template>
<template v-slot:body-cell-VisitTimes="props">
<q-td :props="props">
<span>{{props.row.VisitTimes==0?'首次':props.row.VisitTimes}}</span>
</q-td>
</template>
<template v-slot:body-cell-VisitorStatus="props">
<q-td :props="props">
<img v-if="props.row.VisitorStatus==1" src="../../assets/images/normal.png" />
<img v-if="props.row.VisitorStatus==2" src="../../assets/images/vip.png" />
<img v-if="props.row.VisitorStatus==3" src="../../assets/images/blackList.png" />
</q-td>
</template>
<template v-slot:body-cell-Evaluate="props">
<q-td :props="props">
{{getRemarks(props.row.Evaluate)}}
</q-td>
</template>
<template v-slot:body-cell-Remark="props">
<q-td :props="props">
{{getRemarks(props.row.Remark)}}
</q-td>
</template>
<template v-slot:bottom>
<q-pagination class="full-width justify-end" v-model="msg.pageIndex" color="primary" :max="pageCount"
:input="true" @input="changePage" />
......@@ -230,7 +210,8 @@
<q-btn flat size="xs" icon="edit" slot="reference" @click="EditVisitor(props.row.Id)" color="accent"
style="font-weight:400" label="编辑" v-if="DutyAuthObj.isShowEdit" />
</el-popover>
<q-btn flat size="xs" @click="getDetail(props.row)" icon="iconfont icon-View" color="accent" style="font-weight:400" label="详情" />
<q-btn flat size="xs" @click="getDetail(props.row)" icon="iconfont icon-View" color="accent"
style="font-weight:400" label="详情" />
</q-td>
</template>
</q-table>
......@@ -240,11 +221,8 @@
</template>
<script>
import {
queryVisitorPage,
queryVisitor,
updateVisitor,
setVisitor,
} from '../../api/scheduling/schedu'
getStudentPage
} from "../../api/school";
import {
getGuestBasicsEnumList
} from '../../api/sale/sale'
......@@ -267,41 +245,35 @@
data() {
return {
columns: [{
name: 'Name',
name: 'StuName',
label: '姓名',
required: true,
field: 'Name',
field: 'StuName',
align: 'left'
},
{
name: 'Tel',
field: 'Tel',
label: '电话',
name: 'StuSexStr',
field: 'StuSexStr',
label: '性别',
align: 'left',
},
{
name: 'WeChatNum',
field: 'WeChatNum',
label: '微信',
align: 'left'
},
{
name: 'CourseName',
label: '兴趣课程',
field: 'CourseName',
align: 'left'
name: 'StuTel',
field: 'StuTel',
label: '电话',
align: 'left',
},
{
name: 'StudyTime',
label: '学习时间',
field: 'StudyTime',
align: 'left'
name: 'StuStageName',
field: 'StuStageName',
label: '客户阶段',
align: 'left',
},
{
name: 'LevelType',
label: '当前水平',
field: 'LevelType',
align: 'left'
name: 'CreateTimeStr',
field: 'CreateTimeStr',
label: '创建时间',
align: 'left',
},
{
name: 'CreateByName',
......@@ -309,30 +281,12 @@
field: 'CreateByName',
align: 'left'
},
{
name: 'VisitorStatus',
label: '状态',
field: 'VisitorStatus',
align: 'left'
},
{
name: 'Evaluate',
label: '意向评估',
field: 'Evaluate',
align: 'left'
},
{
name: 'VisitTimes',
label: '到访次数',
field: 'VisitTimes',
align: 'left'
},
{
name: 'Remark',
label: '备注',
field: 'Remark',
align: 'left'
},
{
name: 'optioned',
label: '操作',
......@@ -346,7 +300,7 @@
pageIndex: 1,
pageSize: 5,
rowsPerPage: 5,
PlanId: 0,
IsQueryMyStu: 1,
KeyWords: "",
},
addMsg: {
......@@ -380,11 +334,7 @@
isShowAdd: true, //是否显示新增按钮【默认显示】
isShowEdit: true, //是否显示编辑按钮【默认显示】
},
//表格可见列
visibleColumns: [
'Name', 'Tel', 'WeChatNum', 'CourseName', 'StudyTime', "LevelType",
"CreateByName", "VisitorStatus", "Evaluate", 'VisitTimes', 'Remark', 'optioned'
], //可见列
rules: { //表单必填验证
Name: [{
......@@ -423,8 +373,8 @@
trigger: 'blur'
}]
},
sendObj:{},
isShowDetail:false
sendObj: {},
isShowDetail: false
}
},
......@@ -456,7 +406,7 @@
}
});
},
submitForm2(addMsg2){
submitForm2(addMsg2) {
this.$refs[addMsg2].validate((valid) => {
if (valid) {
this.SaveVisitor();
......@@ -501,7 +451,8 @@
//获取访客列表
getVisitoryPage() {
this.loading = true;
queryVisitorPage(this.msg).then(res => {
getStudentPage(this.msg).then(res => {
console.log("res", res)
this.loading = false
this.data = res.Data.PageData;
this.pageCount = res.Data.PageCount;
......@@ -548,7 +499,7 @@
this.addMsg.VisitorStatus = '';
this.addMsg.Evaluate = "";
this.addMsg.Remark = "";
this.$refs.addMsg1.resetFields();
this.$refs.addMsg1.resetFields();
},
//保存
SaveVisitor() {
......@@ -558,32 +509,30 @@
this.isShowVform = false;
this.getVisitoryPage();
this.clearAddMsg();
this.$refs.addMsg1.resetFields();
this.$refs.addMsg2.resetFields();
this.$refs.addMsg1.resetFields();
this.$refs.addMsg2.resetFields();
})
},
//过滤备注显示
getRemarks(remark){
if(remark.length>10){
return remark.substring(0,10)+'...';
}else{
getRemarks(remark) {
if (remark.length > 10) {
return remark.substring(0, 10) + '...';
} else {
return remark;
}
},
//获取详情
getDetail(obj){
getDetail(obj) {
this.sendObj = obj;
this.isShowDetail=true;
this.isShowDetail = true;
},
//关闭
closeDetail(){
this.isShowDetail=false;
closeDetail() {
this.isShowDetail = false;
}
}
}
</script>
<style lang="sass">
@import url('~assets/css/table.sass')
</style>
</style>
\ No newline at end of file
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