|
@@ -1,23 +1,38 @@
|
|
<template>
|
|
<template>
|
|
<div class="school-manage pg-main">
|
|
<div class="school-manage pg-main">
|
|
<div class="pg-title">
|
|
<div class="pg-title">
|
|
- <span>用学校管理</span>
|
|
|
|
|
|
+ <span>学校管理</span>
|
|
</div>
|
|
</div>
|
|
- <div class="pg-select-infos" style="padding: 20px">
|
|
|
|
- <Button
|
|
|
|
- style="min-left: 10px"
|
|
|
|
- type="primary"
|
|
|
|
- icon="md-search"
|
|
|
|
- @click="load"
|
|
|
|
- >查询</Button
|
|
|
|
- >
|
|
|
|
- <Button
|
|
|
|
- type="primary"
|
|
|
|
- icon="md-refresh"
|
|
|
|
- :loading="loading"
|
|
|
|
- @click="toSyncSchool"
|
|
|
|
- >机构同步</Button
|
|
|
|
- >
|
|
|
|
|
|
+ <div class="pg-select-infos">
|
|
|
|
+ <Form ref="user_query_form" :label-width="80" inline>
|
|
|
|
+ <Row :gutter="20">
|
|
|
|
+ <Col span="8">
|
|
|
|
+ <FormItem label="学校" style="width: 100%">
|
|
|
|
+ <Select v-model="query.schoolId" filterable clearable>
|
|
|
|
+ <Option v-for="item in schools" :value="item.id" :key="item.id"
|
|
|
|
+ >{{ item.name }}
|
|
|
|
+ </Option>
|
|
|
|
+ </Select>
|
|
|
|
+ </FormItem>
|
|
|
|
+ </Col>
|
|
|
|
+ <Col span="8">
|
|
|
|
+ <Button
|
|
|
|
+ style="min-left: 10px"
|
|
|
|
+ type="primary"
|
|
|
|
+ icon="md-search"
|
|
|
|
+ @click="filterSchool"
|
|
|
|
+ >查询</Button
|
|
|
|
+ >
|
|
|
|
+ <Button
|
|
|
|
+ type="primary"
|
|
|
|
+ icon="md-refresh"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ @click="toSyncSchool"
|
|
|
|
+ >机构同步</Button
|
|
|
|
+ >
|
|
|
|
+ </Col>
|
|
|
|
+ </Row>
|
|
|
|
+ </Form>
|
|
</div>
|
|
</div>
|
|
<div class="pg-body">
|
|
<div class="pg-body">
|
|
<Table
|
|
<Table
|
|
@@ -47,10 +62,7 @@ export default {
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
query: {
|
|
query: {
|
|
- pageNo: 1,
|
|
|
|
- pageSize: 10,
|
|
|
|
- totalElements: 0,
|
|
|
|
- totalPages: 0,
|
|
|
|
|
|
+ schoolId: 1,
|
|
},
|
|
},
|
|
columns: [
|
|
columns: [
|
|
{
|
|
{
|
|
@@ -126,6 +138,7 @@ export default {
|
|
},
|
|
},
|
|
},
|
|
},
|
|
],
|
|
],
|
|
|
|
+ schools: [],
|
|
list: [],
|
|
list: [],
|
|
curRow: {},
|
|
curRow: {},
|
|
loading: false,
|
|
loading: false,
|
|
@@ -138,9 +151,15 @@ export default {
|
|
load() {
|
|
load() {
|
|
axios.post("/system/common/school/list", {}).then((response) => {
|
|
axios.post("/system/common/school/list", {}).then((response) => {
|
|
let data = response.data.data;
|
|
let data = response.data.data;
|
|
- this.list = data || [];
|
|
|
|
|
|
+ this.schools = data || [];
|
|
|
|
+ this.list = this.schools;
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ filterSchool() {
|
|
|
|
+ this.list = this.schools.filter(
|
|
|
|
+ (item) => item.id === this.query.schoolId
|
|
|
|
+ );
|
|
|
|
+ },
|
|
toSet(row) {
|
|
toSet(row) {
|
|
this.curRow = row;
|
|
this.curRow = row;
|
|
this.$refs.SchoolSetDialog.open();
|
|
this.$refs.SchoolSetDialog.open();
|