Commit 863259c4 authored by 毛线's avatar 毛线

loading优化

parent e4d991b3
......@@ -13,7 +13,11 @@
<div class="end">结束金额</div>
<div class="remark">备注</div>
</div>
<div class="table">
<div
v-loading="loading"
element-loading-background="#00293785"
element-loading-spinner="el-icon-loading"
class="table">
<ScoreRow v-for="(item, index) in list" :key="index" :data="item" :index="index"/>
</div>
</div>
......@@ -31,6 +35,7 @@ export default {
return {
index: 0,
list: [], // 消息列表
loading: false,
}
},
watch: {
......@@ -50,13 +55,16 @@ export default {
params.filterType = type
}
this.list = []
this.loading = true
this.$request({
url: '/api/player/user/creditTransferLog',
method: 'get',
params,
}).then(({ rows }) => {
console.log('creditTransferLog data', { ...rows[0] })
this.list = rows
this.loading = false
}).catch(() => {
this.loading = false
})
},
}
......
......@@ -8,9 +8,13 @@ Vue.use(VueClipboard) // 复制组件
import {
Message,
Loading,
} from 'element-ui'
Vue.use(Loading.directive)
Vue.prototype.$message = Message
Vue.prototype.$loading = Loading.service
Vue.filter('img', function(value) {
return `${process.env.img_domain}${value}`
......
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