|
@@ -2,7 +2,10 @@
|
|
<div id="index">
|
|
<div id="index">
|
|
<list-frame title="班主任管理" @query="search" :filter="filFields" @add="$router.push({ path: '/director/detail' })">
|
|
<list-frame title="班主任管理" @query="search" :filter="filFields" @add="$router.push({ path: '/director/detail' })">
|
|
<template #options="{item}">
|
|
<template #options="{item}">
|
|
- <template v-if="item.model"></template>
|
|
|
|
|
|
+ <template v-if="item.model === 'dept'">
|
|
|
|
+ <el-option label="信息部" value="1"></el-option>
|
|
|
|
+ <el-option label="办公室" value="0"></el-option>
|
|
|
|
+ </template>
|
|
</template>
|
|
</template>
|
|
<data-table :fields="fields" :data="list" :opera="opera" @edit="toEdit"></data-table>
|
|
<data-table :fields="fields" :data="list" :opera="opera" @edit="toEdit"></data-table>
|
|
</list-frame>
|
|
</list-frame>
|
|
@@ -13,7 +16,7 @@
|
|
import listFrame from '@frame/layout/admin/list-frame';
|
|
import listFrame from '@frame/layout/admin/list-frame';
|
|
import dataTable from '@frame/layout/admin/data-table';
|
|
import dataTable from '@frame/layout/admin/data-table';
|
|
export default {
|
|
export default {
|
|
- metaInfo: { title: '班主任表' },
|
|
|
|
|
|
+ metaInfo: { title: '班主任管理' },
|
|
name: 'index',
|
|
name: 'index',
|
|
props: {},
|
|
props: {},
|
|
components: {
|
|
components: {
|
|
@@ -62,8 +65,8 @@ export default {
|
|
},
|
|
},
|
|
],
|
|
],
|
|
list: [
|
|
list: [
|
|
- { name: '班主任1', deptname: '信息部', gender: '1', tel: '13089419810', age: 20, birthday: `2020-01-01`, is_ly: 0 },
|
|
|
|
- { name: '班主任2', deptname: '信息部', gender: '0', tel: '13089419810', age: 20, birthday: `2020-01-01`, is_ly: 1 },
|
|
|
|
|
|
+ { id: 1, name: '班主任1', deptname: '信息部', gender: '1', tel: '13089419810', age: 20, birthday: `2020-01-01`, is_ly: 0 },
|
|
|
|
+ { id: 2, name: '班主任2', deptname: '信息部', gender: '0', tel: '13089419810', age: 20, birthday: `2020-01-01`, is_ly: 1 },
|
|
],
|
|
],
|
|
}),
|
|
}),
|
|
created() {},
|
|
created() {},
|
|
@@ -75,6 +78,7 @@ export default {
|
|
toEdit(data) {
|
|
toEdit(data) {
|
|
console.log(`in toEdit`);
|
|
console.log(`in toEdit`);
|
|
console.log(data);
|
|
console.log(data);
|
|
|
|
+ this.$router.push({ path: '/director/detail', query: { id: data.id } });
|
|
},
|
|
},
|
|
},
|
|
},
|
|
};
|
|
};
|