File tree 6 files changed +12
-10
lines changed
6 files changed +12
-10
lines changed Original file line number Diff line number Diff line change 11
11
</el-radio-group >
12
12
<el-button style =' margin :0 0 20px 20px ;' type =" primary" icon =" document" @click =" handleDownload" :loading =" downloadLoading" >{{$t('excel.export')}} excel</el-button >
13
13
14
- <el-table :data =" list" v-loading.body =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row >
14
+ <el-table :data =" list" v-loading =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row >
15
15
<el-table-column align =" center" label =' Id' width =" 95" >
16
16
<template slot-scope="scope">
17
17
{{scope.$index}}
Original file line number Diff line number Diff line change 3
3
<!-- $t is vue-i18n global function to translate lang -->
4
4
<el-input style =' width :340px ;' :placeholder =" $t('excel.placeholder')" prefix-icon =" el-icon-document" v-model =" filename" ></el-input >
5
5
<el-button style =' margin-bottom :20px ' type =" primary" icon =" document" @click =" handleDownload" :loading =" downloadLoading" >{{$t('excel.selectedExport')}}</el-button >
6
- <el-table :data =" list" v-loading.body =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row @selection-change =" handleSelectionChange"
6
+ <el-table :data =" list" v-loading =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row @selection-change =" handleSelectionChange"
7
7
ref =" multipleTable" >
8
8
<el-table-column type =" selection" align =" center" ></el-table-column >
9
9
<el-table-column align =" center" label =' Id' width =" 95" >
Original file line number Diff line number Diff line change 21
21
<el-checkbox class =" filter-item" style =' margin-left :15px ;' @change =' tableKey=tableKey+1' v-model =" showReviewer" >{{$t('table.reviewer')}}</el-checkbox >
22
22
</div >
23
23
24
- <el-table :key =' tableKey' :data =" list" v-loading =" listLoading" element-loading-text = " 给我一点时间 " border fit highlight-current-row
25
- style =" width : 100% " >
24
+ <el-table :key =' tableKey' :data =" list" v-loading =" listLoading" border fit highlight-current-row
25
+ style =" width : 100% ; min-height : 1000 px ; " >
26
26
<el-table-column align =" center" :label =" $t('table.id')" width =" 65" >
27
27
<template slot-scope="scope">
28
28
<span >{{scope.row.id}}</span >
@@ -221,7 +221,11 @@ export default {
221
221
fetchList (this .listQuery ).then (response => {
222
222
this .list = response .data .items
223
223
this .total = response .data .total
224
- this .listLoading = false
224
+
225
+ // Just to simulate the time of the request
226
+ setTimeout (() => {
227
+ this .listLoading = false
228
+ }, 1.5 * 1000 )
225
229
})
226
230
},
227
231
handleFilter () {
Original file line number Diff line number Diff line change 1
1
<template >
2
2
<div class =" app-container" >
3
3
<!-- Note that row-key is necessary to get a correct row order. -->
4
- <el-table :data =" list" row-key =" id" v-loading.body =" listLoading" border fit highlight-current-row style =" width : 100% " >
4
+ <el-table :data =" list" row-key =" id" v-loading =" listLoading" border fit highlight-current-row style =" width : 100% " >
5
5
6
6
<el-table-column align =" center" label =" ID" width =" 65" >
7
7
<template slot-scope="scope">
Original file line number Diff line number Diff line change 1
1
<template >
2
2
<div class =" app-container" >
3
3
4
- <el-table :data =" list" v-loading.body =" listLoading" border fit highlight-current-row style =" width : 100% " >
4
+ <el-table :data =" list" v-loading =" listLoading" border fit highlight-current-row style =" width : 100% " >
5
5
6
6
<el-table-column align =" center" label =" ID" width =" 80" >
7
7
<template slot-scope="scope">
@@ -89,9 +89,7 @@ export default {
89
89
const items = response .data .items
90
90
this .list = items .map (v => {
91
91
this .$set (v, ' edit' , false ) // https://vuejs.org/v2/guide/reactivity.html
92
-
93
92
v .originalTitle = v .title // will be used when user click the cancel botton
94
-
95
93
return v
96
94
})
97
95
this .listLoading = false
Original file line number Diff line number Diff line change 3
3
<!-- $t is vue-i18n global function to translate lang -->
4
4
<el-input style =' width :300px ;' :placeholder =" $t('zip.placeholder')" prefix-icon =" el-icon-document" v-model =" filename" ></el-input >
5
5
<el-button style =' margin-bottom :20px ;' type =" primary" icon =" document" @click =" handleDownload" :loading =" downloadLoading" >{{$t('zip.export')}} zip</el-button >
6
- <el-table :data =" list" v-loading.body =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row >
6
+ <el-table :data =" list" v-loading =" listLoading" element-loading-text =" 拼命加载中" border fit highlight-current-row >
7
7
<el-table-column align =" center" label =' ID' width =" 95" >
8
8
<template slot-scope="scope">
9
9
{{scope.$index}}
You can’t perform that action at this time.
0 commit comments