🎉 表格加载添加loading

pull/59/head
smallchill 6 years ago
parent 59c85bee15
commit 1fd754d0aa
  1. 4
      src/views/authority/apiscope.vue
  2. 4
      src/views/authority/datascope.vue
  3. 4
      src/views/authority/role.vue
  4. 4
      src/views/desk/notice.vue
  5. 4
      src/views/flow/follow.vue
  6. 4
      src/views/flow/manager.vue
  7. 4
      src/views/flow/model.vue
  8. 4
      src/views/monitor/log/api.vue
  9. 4
      src/views/monitor/log/error.vue
  10. 4
      src/views/monitor/log/usual.vue
  11. 4
      src/views/resource/oss.vue
  12. 8
      src/views/system/client.vue
  13. 4
      src/views/system/dept.vue
  14. 4
      src/views/system/dict.vue
  15. 4
      src/views/system/menu.vue
  16. 4
      src/views/system/param.vue
  17. 4
      src/views/system/tenant.vue
  18. 4
      src/views/system/topmenu.vue
  19. 4
      src/views/system/user.vue
  20. 8
      src/views/tool/code.vue
  21. 4
      src/views/work/claim.vue
  22. 4
      src/views/work/done.vue
  23. 4
      src/views/work/send.vue
  24. 4
      src/views/work/start.vue
  25. 4
      src/views/work/todo.vue
  26. 2
      vue.config.js

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -89,6 +90,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -474,8 +476,10 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getMenuList(page.currentPage, page.pageSize, params).then(res => {
this.data = res.data.data;
this.loading = false;
});
},
//

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -89,6 +90,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -504,8 +506,10 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getMenuList(page.currentPage, page.pageSize, params).then(res => {
this.data = res.data.data;
this.loading = false;
});
},
//

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -95,6 +96,7 @@
apiScopeTreeObj: [],
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -330,6 +332,7 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
this.data = res.data.data;
getRoleTree().then(res => {
@ -337,6 +340,7 @@
const index = this.$refs.crud.findColumnIndex("parentId");
this.option.column[index].dicData = data;
});
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
:page="page"
@row-del="rowDel"
@ -41,6 +42,7 @@
return {
form: {},
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -247,10 +249,12 @@
}
values.releaseTimeRange = null;
}
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -51,6 +52,7 @@
processInstanceId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -165,10 +167,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
followList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -116,6 +117,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -313,10 +315,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
managerList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -125,6 +126,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -297,10 +299,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
modelList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
getDictionary({code: 'flow'}).then(res => {
this.category = res.data.data;

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -26,6 +27,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -127,10 +129,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getApiList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
:before-open="beforeOpen"
@ -26,6 +27,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -134,10 +136,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getErrorList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -26,6 +27,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -126,10 +128,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getUsualList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
:page="page"
@row-del="rowDel"
@ -55,6 +56,7 @@
return {
form: {},
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -281,10 +283,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
:page="page"
@row-del="rowDel"
@ -37,6 +38,7 @@
return {
form: {},
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -268,17 +270,19 @@
}
done();
},
currentChange(currentPage){
currentChange(currentPage) {
this.page.currentPage = currentPage;
},
sizeChange(pageSize){
sizeChange(pageSize) {
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -50,6 +51,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -272,6 +274,7 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
this.data = res.data.data;
getDeptTree().then(res => {
@ -279,6 +282,7 @@
const index = this.$refs.crud.findColumnIndex("parentId");
this.option.column[index].dicData = data;
});
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -45,6 +46,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -236,6 +238,7 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
this.data = res.data.data;
getDictTree().then(res => {
@ -243,6 +246,7 @@
const index = this.$refs.crud.findColumnIndex("parentId");
this.option.column[index].dicData = data;
});
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -44,6 +45,7 @@
return {
form: {},
query: {},
loading: true,
selectionList: [],
page: {
pageSize: 10,
@ -295,8 +297,10 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
this.data = res.data.data;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -38,6 +39,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -186,10 +188,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -38,6 +39,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -206,10 +208,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
:page="page"
:permission="permissionList"
@ -70,6 +71,7 @@
form: {},
box: false,
query: {},
loading: true,
props: {
label: "title",
value: "key"
@ -276,10 +278,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -80,6 +81,7 @@
form: {},
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -406,10 +408,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
getDeptTree(this.form.tenantId).then(res => {
const index = this.$refs.crud.findColumnIndex("deptId");

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -44,6 +45,8 @@
return {
form: {},
selectionList: [],
loading: true,
query: {},
page: {
pageSize: 10,
currentPage: 1,
@ -209,6 +212,7 @@
this.onLoad(this.page);
},
searchChange(params) {
this.query = params;
this.onLoad(this.page, params);
},
selectionChange(list) {
@ -274,10 +278,12 @@
this.page.pageSize = pageSize;
},
onLoad(page, params = {}) {
getList(page.currentPage, page.pageSize, params).then(res => {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -74,6 +75,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -191,10 +193,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
claimList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -67,6 +68,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -167,10 +169,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
doneList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -71,6 +72,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -177,10 +179,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
sendList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -75,6 +76,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -180,10 +182,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
startList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -1,6 +1,7 @@
<template>
<basic-container>
<avue-crud :option="option"
:table-loading="loading"
:data="data"
ref="crud"
v-model="form"
@ -74,6 +75,7 @@
selectionId: '',
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
@ -177,10 +179,12 @@
...params,
category: (params.category) ? flowCategory(params.category) : null
}
this.loading = true;
todoList(page.currentPage, page.pageSize, Object.assign(values, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.data = data.records;
this.loading = false;
});
}
}

@ -25,7 +25,7 @@ module.exports = {
port: 1888,
proxy: {
'/api': {
target: 'http://localhost',
target: 'https://saber.bladex.vip/api',
ws: true,
pathRewrite: {
'^/api': '/'

Loading…
Cancel
Save