添加loading

dev_review
yujialong 10 months ago
parent 09d3eaa5d8
commit effa4606b7
  1. 5
      src/views/customer/customer.vue
  2. 4
      src/views/match/list/index.vue
  3. 4
      src/views/match/manage/matchArchList.vue
  4. 19
      src/views/match/manage/matchRank.vue
  5. 32
      src/views/match/manage/matchSignup.vue
  6. 10
      src/views/serve/projectAdd.vue
  7. 4
      src/views/user/User.vue

@ -1,5 +1,5 @@
<template>
<div>
<div v-loading="loading">
<el-card shadow="hover"
class="mgb20">
<div>
@ -85,8 +85,7 @@
v-auth>批量删除</el-button>
</div>
</div>
<el-table v-loading="loading"
:data="listData"
<el-table :data="listData"
class="table"
ref="table"
stripe

@ -1,5 +1,6 @@
<template>
<div class="page">
<div class="page"
v-loading="loading">
<h6 class="p-title">筛选</h6>
<div class="tool mul">
<ul class="filter">
@ -82,7 +83,6 @@
stripe
header-align="center"
@selection-change="handleSelectionChange"
v-loading="loading"
row-key="id">
<el-table-column type="selection"
width="55"

@ -387,12 +387,12 @@ export default {
stageId: this.stageId,
isNakadai: 1
})
this.loading = false
this.total = page.total
this.list = page.records
this.statData = data
this.avgScore = (+data.avgScore).toFixed(2)
this.getChart()
this.loading = false
this.method != 2 && this.getChart()
}
},
initData () {

@ -11,6 +11,7 @@
</el-card>
<el-card shadow="hover"
v-loading="loading"
class="m-b-20">
<div class="tabs">
<template v-for="(item, i) in grades">
@ -60,7 +61,6 @@
ref="table"
stripe
row-key="scoreId"
v-loading="loading"
@selection-change="handleSelectionChange"
header-align="center">
<el-table-column type="selection"
@ -372,6 +372,7 @@ export default {
},
//
getRank () {
this.loading = true
//
if (this.type) {
this.$post(this.api.manuallyUploadedRankings, {
@ -389,7 +390,9 @@ export default {
this.total = message.total
this.getPublishTime()
this.loading = false
}).catch(res => { })
}).catch(res => {
this.loading = false
})
} else { //
if (!this.active) {
//
@ -408,7 +411,9 @@ export default {
this.total = total
this.getPublishTime()
this.loading = false
}).catch(res => { })
}).catch(res => {
this.loading = false
})
} else {
//
this.$post(`${this.api.stageRaceRanking}?competitionId=${this.id}&stageId=${this.active}&pageNum=${this.page}&pageSize=${this.pageSize}&publicationType=${this.type}&keyword=${this.keyword}`).then(({ page, total, publishStatus }) => {
@ -417,7 +422,9 @@ export default {
this.total = total
this.getPublishTime()
this.loading = false
}).catch(res => { })
}).catch(res => {
this.loading = false
})
}
}
},
@ -443,8 +450,8 @@ export default {
}
},
//
typeChange (val) {
this.$post(`${this.api.toggleTheSortingMode}?competitionId=${this.id}&stageId=${this.active || this.stageId}&isOverallRanking=${this.active ? 0 : 1}&whetherToManuallyPublish=${this.type}`).then(res => { }).catch(res => { })
async typeChange (val) {
await this.$post(`${this.api.toggleTheSortingMode}?competitionId=${this.id}&stageId=${this.active || this.stageId}&isOverallRanking=${this.active ? 0 : 1}&whetherToManuallyPublish=${this.type}`)
this.getRank()
},
initData () {

@ -54,6 +54,7 @@
header-align="center"
@selection-change="handleSelectionChange"
row-key="id"
v-loading="loading"
@sort-change="sortChange">
<el-table-column type="selection"
width="80"
@ -437,7 +438,8 @@ export default {
},
uploading: false,
isBackstage: 0,
exporting: false
exporting: false,
loading: false,
};
},
watch: {
@ -459,8 +461,9 @@ export default {
this.getTeam()
this.getClient()
},
getData () {
this.$post(this.api.queryRegistrationByCondition, {
async getData () {
this.loading = true
const { data } = await this.$post(this.api.queryRegistrationByCondition, {
pageNum: this.page,
pageSize: this.pageSize,
competitionId: this.id,
@ -468,18 +471,17 @@ export default {
isDisable: this.isDisable,
schoolOrder: this.schoolOrder,
teamOrder: this.teamOrder,
}).then(({ data }) => {
const list = data.records;
list.map(e => {
if (e.teacherDetails) {
e.teachers = JSON.parse(e.teacherDetails)
}
})
this.listData = list
this.total = data.total;
this.$refs.table.clearSelection();
}).catch(res => {
});
})
const list = data.records;
list.map(e => {
if (e.teacherDetails) {
e.teachers = JSON.parse(e.teacherDetails)
}
})
this.listData = list
this.total = data.total;
this.$refs.table.clearSelection();
this.loading = false
},
//
getInfo () {

@ -1,6 +1,7 @@
<template>
<div ref="main"
class="main">
class="main"
v-loading="loading">
<el-row :gutter="20">
<el-col :span="24">
<el-card shadow="hover"
@ -389,7 +390,8 @@ export default {
listLoading: false,//
submiting: false, //
updateTime: 0,
savingJud: false
savingJud: false,
loading: false,
};
},
computed: {
@ -463,6 +465,7 @@ export default {
},
getInfoData () { //
if (!this.isToPoint) {
this.loading = true
this.$get(`${this.api.getProjectDetail}?projectId=${this.projectId}`).then(res => {
let { projectManage, projectJudgmentVos } = res;
if (!projectManage.remark) projectManage.remark = projectManage.projectName //
@ -475,12 +478,13 @@ export default {
this.projectJudgmentData.forEach((e, i) => {
e.sort = i + 1;
});
this.loading = false
this.$nextTick(() => {
this.updateTime = 0
this.$refs.main.scrollTop = 0;
});
}).catch(err => {
console.log(err);
this.loading = false
});
}
},

@ -1,5 +1,6 @@
<template>
<div class="wrap">
<div class="wrap"
v-loading="loading">
<el-card shadow="hover"
class="mgb20">
<div>
@ -141,7 +142,6 @@
stripe
header-align="center"
@selection-change="handleSelectionChange"
v-loading="loading"
row-key="userId">
<el-table-column type="selection"
width="55"

Loading…
Cancel
Save