|
@@ -101,7 +101,9 @@
|
|
|
class="pagination"
|
|
|
layout="prev, pager, next"
|
|
|
:total="total"
|
|
|
- :page-size="pageSize"
|
|
|
+ :current-page.sync="currentPage"
|
|
|
+ :page-size.sync="limit"
|
|
|
+ @current-change="handleCurrentChange"
|
|
|
></el-pagination>
|
|
|
</div>
|
|
|
<!-- 报名按钮 -->
|
|
@@ -122,7 +124,7 @@ import {
|
|
|
updateUser,
|
|
|
updateClass
|
|
|
} from "@/api/table";
|
|
|
-import { setTimeout } from 'timers';
|
|
|
+import { setTimeout } from "timers";
|
|
|
export default {
|
|
|
name: "Dashboard",
|
|
|
data() {
|
|
@@ -162,9 +164,9 @@ export default {
|
|
|
chioseList: [], // 所有调剂科目的集合
|
|
|
sessionId: "",
|
|
|
brancheList: [], // 所有分部集合
|
|
|
- pageSize: 0,
|
|
|
+ limit : 10,
|
|
|
total: 0,
|
|
|
- page: 0,
|
|
|
+ page: 1,
|
|
|
studentId: "", // 学生id
|
|
|
courseId: "", // 当前选中的课程
|
|
|
subId: "" // 当前选中的项目
|
|
@@ -236,7 +238,9 @@ export default {
|
|
|
qs.stringify({
|
|
|
musicTeamId: this.majorId,
|
|
|
name: this.topForm.team,
|
|
|
- status: this.topForm.status
|
|
|
+ status: this.topForm.status,
|
|
|
+ page:this.page,
|
|
|
+ rows:this.limit
|
|
|
})
|
|
|
).then(res => {
|
|
|
this.tableData = res.data.rows;
|
|
@@ -245,9 +249,10 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
// 重置搜索
|
|
|
- resetStudentList(){
|
|
|
- this.topForm.team = '';
|
|
|
- this.topForm.status = '';
|
|
|
+ resetStudentList() {
|
|
|
+ this.topForm.team = "";
|
|
|
+ this.topForm.status = "";
|
|
|
+ this.page = 1;
|
|
|
this.getstudentList();
|
|
|
},
|
|
|
// 性别分类过滤器
|
|
@@ -294,19 +299,36 @@ export default {
|
|
|
},
|
|
|
// 点击开始缴费 1报名中,2缴费中,3报名截止,4已开团
|
|
|
getMoney() {
|
|
|
- updateClass(qs.stringify({ id: this.majorId, status: 2 })).then(
|
|
|
- res => {
|
|
|
- if(res.code == 200){
|
|
|
- this.$message.success('乐团报名成功请尽快缴费');
|
|
|
- setTimeout(()=>{
|
|
|
- window.location.reload();
|
|
|
- },1000)
|
|
|
-
|
|
|
- }
|
|
|
+ updateClass(qs.stringify({ id: this.majorId, status: 2 })).then(res => {
|
|
|
+ if (res.code == 200) {
|
|
|
+ this.$message.success("乐团报名成功请尽快缴费");
|
|
|
+ setTimeout(() => {
|
|
|
+ // window.location.reload();
|
|
|
+ this.majorStatus = 2;
|
|
|
+ this.getstudentList();
|
|
|
+ }, 1000);
|
|
|
}
|
|
|
- );
|
|
|
+ });
|
|
|
+ },
|
|
|
+ handleCurrentChange(val) {
|
|
|
+ this.page = val;
|
|
|
+ // this.limit = pageSize;
|
|
|
+ this.getstudentList();
|
|
|
+ if (this.autoScroll) {
|
|
|
+ scrollTo(0, 800);
|
|
|
+ }
|
|
|
}
|
|
|
},
|
|
|
+ computed: {
|
|
|
+ currentPage: {
|
|
|
+ get() {
|
|
|
+ return this.page
|
|
|
+ },
|
|
|
+ set(val) {
|
|
|
+ this.$emit('update:page', val)
|
|
|
+ }
|
|
|
+ },
|
|
|
+ },
|
|
|
mounted() {
|
|
|
// 获取所有分部
|
|
|
this.getBranches();
|
|
@@ -341,7 +363,7 @@ export default {
|
|
|
}
|
|
|
.dashboard-container .right {
|
|
|
padding: 15px 0;
|
|
|
- width: 100%;
|
|
|
+ width: calc(100% - 300px);
|
|
|
}
|
|
|
.topWrap {
|
|
|
margin-left: 40px;
|