Commit 22f2ba1e authored by 黄奎's avatar 黄奎

页面修改

parent f5b46909
......@@ -111,6 +111,10 @@
sticky: {
type: String,
default: ""
},
loading: {
type: Boolean,
default: false,
}
},
components: {
......@@ -134,7 +138,7 @@
},
{
name: "CategoryName",
label: "同名称",
label: "同名称",
field: "CategoryName",
align: "left"
},
......@@ -231,9 +235,9 @@
this.getEmployeeList();
},
mounted() {
if(this.dataList&&this.dataList.length>0){
this.dataList.forEach(x=>{
if(x.CustomerType==4){
if (this.dataList && this.dataList.length > 0) {
this.dataList.forEach(x => {
if (x.CustomerType == 4) {
x.CategoryName = x.EnterpriseName
}
})
......
......@@ -10,8 +10,8 @@
</style>
<template>
<div class="b2bcustomlist">
<q-table :pagination="pageMsg" :loading="loading" no-data-label="暂无相关数据" flat
class="sticky-column-table" separator="none" :data="dataList" :columns="columns" row-key="CustomerId">
<q-table :pagination="pageMsg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-column-table"
separator="none" :data="dataList" :columns="columns" row-key="CustomerId">
<template v-slot:top>
<q-space />
<div class="page-option">
......@@ -41,8 +41,10 @@
</template>
<template v-slot:body-cell-optioned="props">
<q-td :props="props">
<q-btn flat size="xs" icon="edit" color="accent" @click="EditCustom(props.row)" style="font-weight:400" label="修改" />
<q-btn flat size="xs" icon="delete" @click="RemoveCustomer(props.row)" color="negative" style="font-weight:400" label="删除" />
<q-btn flat size="xs" icon="edit" color="accent" @click="EditCustom(props.row)" style="font-weight:400"
label="修改" />
<q-btn flat size="xs" icon="delete" @click="RemoveCustomer(props.row)" color="negative"
style="font-weight:400" label="删除" />
</q-td>
</template>
<template v-slot:bottom>
......@@ -52,7 +54,8 @@
<categoryEdit-form v-if="isShowCategoryForm" :customerObj="customerObj" @close="closeCustomForm"
@success="refreshQuestion">
</categoryEdit-form>
<peerRight v-if="isShowDetailForm" :CategoryId="CategoryId" @close="closeCustomForm" :auth="AuthorityObj" @success="refreshQuestion"></peerRight>
<peerRight v-if="isShowDetailForm" :CategoryId="CategoryId" @close="closeCustomForm" :auth="AuthorityObj"
@success="refreshQuestion"></peerRight>
</div>
</template>
<script>
......@@ -66,6 +69,10 @@
dataList: {
type: Array,
default: null
},
loading: {
type: Boolean,
default: false,
}
},
components: {
......@@ -127,7 +134,7 @@
loading: false,
isShowCategoryForm: false,
customerObj: null, //传入参数
tabId:1,
tabId: 1,
//权限设置
AuthorityObj: {
isShowEdit: false, //是否显示新增修改按钮
......@@ -135,15 +142,14 @@
isShowBankBook: false, //是否显示幸福存折
isShowRebate: false //是否显示返佣
},
isShowDetailForm:false,
CategoryId:0
isShowDetailForm: false,
CategoryId: 0
};
},
created() {
},
mounted() {
},
mounted() {},
methods: {
//新增或者修改客户
EditCustom(obj) {
......
......@@ -139,7 +139,7 @@
:options="customList" class="col-6 q-pr-lg q-pb-lg" v-model="objOption.CategoryId" clearable emit-value map-options />
<template v-if="objOption.CustomerType!=4">
<div class="col-6" v-if="!isShowEdit">
<q-btn label="立即添加" @click="isShowEdit=true" size="sm" color="primary" />
<q-btn label="立即添加同行" @click="isShowEdit=true" size="sm" color="primary" />
</div>
<div class="col-6" v-if="isShowEdit" style="position:relative">
<q-input filled stack-label maxlength="20" :dense="false" v-model="objOption.CategoryName" lazy-rules
......
<style lang="scss">
.stuList .q-table__bottom {
.stuList .q-table__bottom {
min-height: 0;
}
.stulistNum {
}
.stulistNum {
display: inline-block;
width: 25px;
height: 25px;
......@@ -12,91 +13,45 @@
border-radius: 50%;
cursor: pointer;
color: #2961fe;
}
.stuListTable {
}
.stuListTable {
width: 200px;
text-align: center;
}
}
.stuListTable tr td {
.stuListTable tr td {
height: 40px;
}
}
.stuListTable tr th {
.stuListTable tr th {
height: 40px;
background-color: rgb(238, 238, 239);
}
}
</style>
<template>
<div class="stuList">
<q-table
:pagination="pageMsg"
:loading="loading"
no-data-label="暂无相关数据"
flat
:selection="pushMode ? 'multiple' : 'single'"
:selected.sync="selection"
class="sticky-right-column-table sticky-tow-column-table"
separator="none"
:data="dataList"
:columns="columns"
row-key="StuId"
hide-bottom
>
<q-table :pagination="pageMsg" :loading="loading" no-data-label="暂无相关数据" flat
:selection="pushMode ? 'multiple' : 'single'" :selected.sync="selection"
class="sticky-right-column-table sticky-tow-column-table" separator="none" :data="dataList" :columns="columns"
row-key="StuId" hide-bottom>
<template v-slot:top>
<div class="col-2 q-table__title">学员信息</div>
<q-space />
<div class="page-option" v-if="!pushMode">
<q-btn
color="accent"
outline
class="q-mr-md"
size="sm"
icon="swap_horiz"
label="推送课程顾问"
v-if="userInfo.IsCourseConsultant == 0"
@click="pushMode = true"
/>
<q-btn
color="accent"
class="q-mr-md"
size="sm"
icon="swap_horiz"
label="转订单"
:disable="selection.length === 0"
@click="transferOrder"
/>
<q-btn
color="accent"
class="q-mr-md"
size="sm"
icon="add"
label="新增学员"
@click="EditStudent(null)"
/>
<q-btn color="accent" outline class="q-mr-md" size="sm" icon="swap_horiz" label="推送课程顾问"
v-if="userInfo.IsCourseConsultant == 0" @click="pushMode = true" />
<q-btn color="accent" class="q-mr-md" size="sm" icon="swap_horiz" label="转订单"
:disable="selection.length === 0" @click="transferOrder" />
<q-btn color="accent" class="q-mr-md" size="sm" icon="add" label="新增学员" @click="EditStudent(null)" />
</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"
@click="assistBatchHandler"
/>
<q-btn
color="accent"
outline
size="sm"
label="退出"
:disable="pushing"
@click="
<q-btn color="accent" unelevated class="q-mr-md" size="sm" icon="swap_horiz" label="立即推送" :loading="pushing"
@click="assistBatchHandler" />
<q-btn color="accent" outline size="sm" label="退出" :disable="pushing" @click="
pushMode = false;
selection = [];
"
/>
" />
</div>
</template>
<template v-slot:body-cell-StuIcon="props">
......@@ -104,14 +59,8 @@
<q-avatar size="md" v-if="props.value">
<img :src="props.value" />
</q-avatar>
<q-avatar
size="md"
color="teal-10"
text-color="white"
v-if="!props.value"
>
{{ props.row.StuName.substring(0, 1) }}</q-avatar
>
<q-avatar size="md" color="teal-10" text-color="white" v-if="!props.value">
{{ props.row.StuName.substring(0, 1) }}</q-avatar>
</q-td>
</template>
<template v-slot:body-cell-StuName="props">
......@@ -123,10 +72,7 @@
</template>
<template v-slot:body-cell-StuSex="props">
<q-td :props="props">
<q-badge
:color="props.value == 1 ? 'negative' : 'primary'"
:label="props.value == 1 ? '女' : '男'"
/>
<q-badge :color="props.value == 1 ? 'negative' : 'primary'" :label="props.value == 1 ? '女' : '男'" />
</q-td>
</template>
<template v-slot:body-cell-StuSourceIdName="props">
......@@ -142,18 +88,9 @@
<q-td :props="props" v-html="getCurseManager(props.row)"></q-td>
</template>
<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"
>已报名{{ props.row.OrderCount }}</q-td
>
<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">
已报名{{ props.row.OrderCount }}</q-td>
</template>
<template v-slot:body-cell-TeacherManager="props">
<q-td :props="props" v-html="getTeacherManager(props.row)"></q-td>
......@@ -171,21 +108,14 @@
<q-popup-proxy>
<q-banner>
<div style="max-height:600px;overflow-y:auto;">
<table
class="stuListTable"
style="border-collapse:collapse;"
>
<table class="stuListTable" style="border-collapse:collapse;">
<tr>
<th>角色</th>
<th>协同人</th>
</tr>
<tr
v-for="(sItem, sIndex) in assistListFormat[
<tr v-for="(sItem, sIndex) in assistListFormat[
props.pageIndex
]"
style="border-bottom:1px dashed #d1d1d1;"
:key="sIndex"
>
]" style="border-bottom:1px dashed #d1d1d1;" :key="sIndex">
<td>{{ sItem.AssistTypeName }}</td>
<td>{{ sItem.AssistName }}</td>
</tr>
......@@ -207,47 +137,29 @@
</q-td>
</template> -->
</q-table>
<student-form
v-if="isShowStuForm"
:save-obj="stuOption"
@close="closeStuForm"
@success="refreshStuList"
>
<student-form v-if="isShowStuForm" :save-obj="stuOption" @close="closeStuForm" @success="refreshStuList">
</student-form>
<studentRight-form
v-if="isShowStuRight"
:isJudgeTrans="isJudgeTrans"
:BelongType="BelongType"
:save-obj="stuOption"
@close="closeStuForm"
@success="refreshStuList"
@reload="referDataHandler"
>
<studentRight-form v-if="isShowStuRight" :isJudgeTrans="isJudgeTrans" :BelongType="BelongType" :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 v-if="isShowAdd" :save-obj="stuOption" @close="closeStuForm" @success="refreshStuList">
</studentAdd-form>
<transfer-order
v-if="isShowTransfer"
:select="selection"
@close="closeStuForm"
@success="refreshStuList"
>
<transfer-order v-if="isShowTransfer" :select="selection" @close="closeStuForm" @success="refreshStuList">
</transfer-order>
</div>
</template>
<script>
import studentForm from "./student-form";
import studentRightForm from "./studentRight-form";
import studentAddForm from "./studentAdd-form";
import transferOrder from "./transfer-order";
import { mapGetters } from "vuex";
import { SetStudentAssistBatch } from "../../../api/sale/sale";
export default {
import studentForm from "./student-form";
import studentRightForm from "./studentRight-form";
import studentAddForm from "./studentAdd-form";
import transferOrder from "./transfer-order";
import {
mapGetters
} from "vuex";
import {
SetStudentAssistBatch
} from "../../../api/sale/sale";
export default {
props: {
dataList: {
type: Array,
......@@ -256,6 +168,10 @@ export default {
isJudgeTrans: {
type: Number,
default: null
},
loading: {
type: Boolean,
default: false,
}
},
components: {
......@@ -266,8 +182,7 @@ export default {
},
data() {
return {
columns: [
{
columns: [{
name: "StuIcon",
label: "",
field: "StuIcon",
......@@ -534,8 +449,7 @@ export default {
this.$q
.dialog({
title: str + "学员",
message:
"你正在进行" + str + "学员行为,一旦执行无法找回,是否确认执行?",
message: "你正在进行" + str + "学员行为,一旦执行无法找回,是否确认执行?",
persistent: true,
cancel: {
label: "取消",
......@@ -676,5 +590,5 @@ export default {
});
}
}
};
};
</script>
\ No newline at end of file
......@@ -28,7 +28,7 @@
<q-input @input="resetSearch" filled clearable v-model="msg.CustomerName" label="联系人" maxlength="20" />
</div>
<div class="col-3">
<q-input @input="resetSearch" filled clearable v-model="msg.CategoryName" label="同名称" maxlength="20" />
<q-input @input="resetSearch" filled clearable v-model="msg.CategoryName" label="同名称" maxlength="20" />
</div>
<div class="col-3">
<q-input @input="resetSearch" filled clearable v-model="msg.ContactNumber" label="电话" maxlength="20" />
......
......@@ -28,7 +28,7 @@
<q-input @input="resetSearch" filled clearable v-model="msg.CustomerName" label="联系人" maxlength="20" />
</div>
<div class="col-3">
<q-input @input="resetSearch" filled clearable v-model="msg.CategoryName" label="同名称" maxlength="20" />
<q-input @input="resetSearch" filled clearable v-model="msg.CategoryName" label="同名称" maxlength="20" />
</div>
<div class="col-3">
<q-input @input="resetSearch" filled clearable v-model="msg.ContactNumber" label="电话" maxlength="20" />
......
This diff is collapsed.
......@@ -48,7 +48,7 @@
</div>
</div>
<div class="page-content">
<stulist :dataList="data" @success="refreshPage" ref="stuList">
<stulist :dataList="data" @success="refreshPage" :loading="loading" ref="stuList">
</stulist>
<div class="row" style="justify-content: flex-end;padding: 5px 20px">
<q-pagination v-model="msg.pageIndex" :max="pageCount" @input="changePage" class="full-width justify-end"
......
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