first commit
This commit is contained in:
@@ -0,0 +1,142 @@
|
||||
<!--#
|
||||
layout("/layouts/platform.html"){
|
||||
#-->
|
||||
<style>
|
||||
.el-table-container {
|
||||
padding-left: 0px;
|
||||
margin-top: 5px;
|
||||
padding-right: 0px;
|
||||
}
|
||||
</style>
|
||||
<div id="app" v-cloak>
|
||||
|
||||
<guava>
|
||||
<div style="padding-right: 10px">
|
||||
<el-card shadow="never">
|
||||
<div class="btn-group tool-button mt5">
|
||||
<el-input placeholder="请输入内容" clearable v-model="pageForm.searchKeyword"
|
||||
@keyup.enter.native="doSearch">
|
||||
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||
style="width: 120px;">
|
||||
<el-option label="协会名称" value="club.name"></el-option>
|
||||
</el-select>
|
||||
</el-input>
|
||||
</div>
|
||||
<div class="btn-group tool-button mt5">
|
||||
<el-button type="primary" icon="el-icon-search" @click="doSearch"></el-button>
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
<el-row class="el-table-container" style="padding-top: 0">
|
||||
<el-table :data="tableData" style="width: 100%" row-key="id" v-loading="tabLoading">
|
||||
<el-table-column align="center" header-align="center" label="序号" type="index">
|
||||
<template scope="scope">
|
||||
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" header-align="center" label="协会名称" width="250px"
|
||||
prop="name"></el-table-column>
|
||||
|
||||
<el-table-column align="center" sortable header-align="center" label="协会总人数"
|
||||
prop="total"></el-table-column>
|
||||
|
||||
<el-table-column align="center" sortable header-align="center" label="在职人数"
|
||||
prop="work"></el-table-column>
|
||||
|
||||
<el-table-column align="center" header-align="center" label="退休人数"
|
||||
prop="retire"></el-table-column>
|
||||
|
||||
<el-table-column align="center" sortable header-align="center" label="男"
|
||||
prop="man"></el-table-column>
|
||||
|
||||
<el-table-column align="center" sortable header-align="center" label="女"
|
||||
prop="woman"></el-table-column>
|
||||
|
||||
<el-table-column align="center" sortable header-align="center" label="理事机构人数"
|
||||
prop="governing_body"></el-table-column>
|
||||
|
||||
<el-table-column align="center" header-align="center" label="协会确认" sortable
|
||||
prop="club_has_confirm"></el-table-column>
|
||||
|
||||
<el-table-column align="center" header-align="center" label="协会待确认" sortable
|
||||
prop="club_no_confirm"></el-table-column>
|
||||
|
||||
<el-table-column align="center" header-align="center" label="校工会确认" sortable
|
||||
prop="school_has_confirm"></el-table-column>
|
||||
|
||||
<el-table-column align="center" header-align="center" label="校工会待确认" sortable width="160"
|
||||
prop="school_no_confirm"></el-table-column>
|
||||
|
||||
</el-table>
|
||||
</el-row>
|
||||
|
||||
<el-row class="el-pagination-container">
|
||||
<el-pagination
|
||||
@size-change="pageSizeChange"
|
||||
@current-change="pageNumberChange"
|
||||
:current-page="pageForm.pageNumber"
|
||||
:page-sizes="[10, 20, 30, 50]"
|
||||
:page-size="pageForm.pageSize"
|
||||
layout="total, sizes, prev, pager, next"
|
||||
:total="pageForm.totalCount">
|
||||
</el-pagination>
|
||||
</el-row>
|
||||
</div>
|
||||
</guava>
|
||||
|
||||
</div>
|
||||
<script>
|
||||
const vue = new Vue({
|
||||
el: '#app',
|
||||
data() {
|
||||
return {
|
||||
tableData: [],
|
||||
pageForm: {
|
||||
searchKeyword: "",
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
totalCount: 0,
|
||||
searchName: 'club.name',
|
||||
},
|
||||
tabLoading: false,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
doSearch() {
|
||||
this.pageForm.pageNumber = 1
|
||||
this.pageData()
|
||||
},
|
||||
pageNumberChange(val) {//页码更新操作
|
||||
this.pageForm.pageNumber = val;
|
||||
this.pageData();
|
||||
},
|
||||
pageSizeChange(val) {//分页大小更新操作
|
||||
this.pageForm.pageSize = val;
|
||||
this.pageData();
|
||||
},
|
||||
pageData() {//加载分页数据
|
||||
sublime.showLoadingbar();//显示loading
|
||||
this.tabLoading = true
|
||||
$.post(base + "/platform/sys/club/clubUserCount/pageData", this.pageForm, (data) => {
|
||||
sublime.closeLoadingbar();//关闭loading
|
||||
this.tabLoading = false
|
||||
if (data.code === 0) {
|
||||
this.tableData = data.data.list;
|
||||
this.pageForm.totalCount = data.data.totalCount;
|
||||
} else {
|
||||
this.$message({
|
||||
message: data.msg,
|
||||
type: 'error'
|
||||
});
|
||||
}
|
||||
}, "json");
|
||||
},
|
||||
},
|
||||
async created() {
|
||||
this.pageData();
|
||||
}
|
||||
})
|
||||
</script>
|
||||
<!--#
|
||||
}
|
||||
#-->
|
||||
Reference in New Issue
Block a user