Commit 3bbc9815 authored by zhengke's avatar zhengke

修改

parent 51973f5b
...@@ -115,14 +115,15 @@ ...@@ -115,14 +115,15 @@
.sticky-header-column-table .sticky-header-column-table
td:first-child td:first-child
/* bg color is important for td; just specify one */ /* bg color is important for td; just specify one */
background-color: #c1f4cd !important /* background-color: #c1f4cd !important */
tr th tr th
position: sticky position: sticky
/* higher than z-index for td below */ /* higher than z-index for td below */
z-index: 2 z-index: 3
/* bg color is important; just specify one */ /* bg color is important; just specify one */
background: #fff /* background: #fff */
background-color:#f5f6f7
/* this will be the loading indicator */ /* this will be the loading indicator */
thead tr:last-child th thead tr:last-child th
......
<style> <style>
.Sysuser_Date .el-input__inner {
background: transparent !important;
border: 0 !important;
}
</style> </style>
<template> <template>
<div class="page-body"> <div class="page-body">
<div class="col row wrap q-mb-lg">
<div class="col-3 Sysuser_Date q-mr-lg">
<q-field filled dense>
<template v-slot:control>
<el-date-picker v-model="myDate" style="width:100%" value-format="yyyy-MM" @change="getCheckDate()" size="small" type="month" placeholder="选择年月">
</el-date-picker>
</template>
</q-field>
</div>
</div>
<div class="page-content"> <div class="page-content">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-column-table no-bottom-table" <q-table :pagination="msg" ref="table" :loading="loading" :style="{'height':tableHeight+'px'}" no-data-label="暂无相关数据" flat
separator="none" :data="dataList" :columns="columns" row-key=""> class="sticky-column-table sticky-header-column-table no-bottom-table zk_Table" separator="none" :data="dataList" :columns="columns" row-key="">
<template v-slot:bottom> <template v-slot:bottom>
</template> </template>
</q-table> </q-table>
...@@ -220,31 +233,47 @@ ...@@ -220,31 +233,47 @@
], ],
dataList: [], dataList: [],
loading: false, loading: false,
myDate:'',
tableHeight:500,
msg: { msg: {
YearStr: 2022, YearStr: '',
MonthStr: 2, MonthStr: '',
rowsPerPage: 1000, rowsPerPage: 1000,
}, },
} }
}, },
created() {}, created() {
setTimeout(() => {
this.tableHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 90;
}, 100)
},
mounted() { mounted() {
this.getList(); let d = new Date();
this.msg.YearStr = d.getFullYear().toString();
this.msg.MonthStr = (d.getMonth()+1).toString();
this.myDate = this.msg.YearStr+'-'+this.msg.MonthStr
this.getList();
}, },
methods: { methods: {
getCheckDate(){
if(this.myDate){
this.msg.YearStr = this.myDate.split('-')[0];
this.msg.MonthStr = this.myDate.split('-')[1];
this.getList();
}
},
//获取数据 //获取数据
getList() { getList() {
GetStudentStatic(this.msg).then(res => { GetStudentStatic(this.msg).then(res => {
if(res.Code==1){ if (res.Code == 1) {
this.dataList = res.Data; this.dataList = res.Data;
} }
}) })
} }
} }
} }
</script> </script>
<style lang="sass"> <style lang="sass">
@import url('~assets/css/table.sass') @import url('~assets/css/table.sass')
</style> </style>
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