Sfoglia il codice sorgente

删除不必要页面

l1069030731 2 anni fa
parent
commit
1baae750a1
46 ha cambiato i file con 19 aggiunte e 7842 eliminazioni
  1. 0 53
      src/api/base/region.js
  2. 0 50
      src/api/desk/notice.js
  3. 0 99
      src/api/flow/flow.js
  4. 0 22
      src/api/report/report.js
  5. 0 50
      src/api/resource/attach.js
  6. 0 59
      src/api/resource/oss.js
  7. 0 72
      src/api/resource/sms.js
  8. 0 50
      src/api/system/client.js
  9. 0 81
      src/api/system/dept.js
  10. 0 89
      src/api/system/dictbiz.js
  11. 0 39
      src/api/system/param.js
  12. 0 60
      src/api/system/post.js
  13. 0 89
      src/api/system/role.js
  14. 0 97
      src/api/system/scope.js
  15. 0 77
      src/api/system/topmenu.js
  16. 0 120
      src/api/system/user.js
  17. 0 69
      src/api/tool/code.js
  18. 0 50
      src/api/tool/datasource.js
  19. 0 34
      src/api/work/process.js
  20. 0 81
      src/api/work/work.js
  21. 19 105
      src/router/views/index.js
  22. 0 333
      src/views/system/client.vue
  23. 0 363
      src/views/system/dept.vue
  24. 0 443
      src/views/system/dict.vue
  25. 0 442
      src/views/system/dictbiz.vue
  26. 0 423
      src/views/system/menu.vue
  27. 0 45
      src/views/system/param.vue
  28. 0 281
      src/views/system/post.vue
  29. 0 994
      src/views/system/user.vue
  30. 0 94
      src/views/system/userinfo.vue
  31. 0 46
      src/views/util/affix.vue
  32. 0 22
      src/views/util/cache.vue
  33. 0 59
      src/views/util/crud-form.vue
  34. 0 199
      src/views/util/data.vue
  35. 0 359
      src/views/util/demo/dict-classic.vue
  36. 0 469
      src/views/util/demo/dict-horizontal.vue
  37. 0 474
      src/views/util/demo/dict-vertical.vue
  38. 0 454
      src/views/util/demo/dict.vue
  39. 0 447
      src/views/util/demo/dictbiz.vue
  40. 0 40
      src/views/util/form-detail.vue
  41. 0 82
      src/views/util/permission.vue
  42. 0 122
      src/views/util/store.vue
  43. 0 129
      src/views/util/table.vue
  44. 0 27
      src/views/util/tags.vue
  45. 0 21
      src/views/util/test.vue
  46. 0 28
      src/views/util/top.vue

+ 0 - 53
src/api/base/region.js

@@ -1,53 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/region/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getLazyTree = (parentCode, params) => {
-  return request({
-    url: '/api/blade-system/region/lazy-tree',
-    method: 'get',
-    params: {
-      ...params,
-      parentCode
-    }
-  })
-}
-
-export const getDetail = (code) => {
-  return request({
-    url: '/api/blade-system/region/detail',
-    method: 'get',
-    params: {
-      code
-    }
-  })
-}
-
-export const remove = (id) => {
-  return request({
-    url: '/api/blade-system/region/remove',
-    method: 'post',
-    params: {
-      id,
-    }
-  })
-}
-
-export const submit = (row) => {
-  return request({
-    url: '/api/blade-system/region/submit',
-    method: 'post',
-    data: row
-  })
-}
-

+ 0 - 50
src/api/desk/notice.js

@@ -1,50 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-desk/notice/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-desk/notice/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-desk/notice/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-desk/notice/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const getNotice = (id) => {
-  return request({
-    url: '/api/blade-desk/notice/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-

+ 0 - 99
src/api/flow/flow.js

@@ -1,99 +0,0 @@
-import request from '@/router/axios';
-
-export const modelList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/model/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const managerList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/manager/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const followList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/follow/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-
-export const removeModel = (ids) => {
-  return request({
-    url: '/api/blade-flow/model/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const deployModel = (params) => {
-  return request({
-    url: '/api/blade-flow/model/deploy',
-    method: 'post',
-    params
-  })
-}
-
-export const changeState = (params) => {
-  return request({
-    url: '/api/blade-flow/manager/change-state',
-    method: 'post',
-    params
-  })
-}
-
-export const deployUpload = (category, tenantIds, files) => {
-  const formData = new FormData();
-  formData.append('category', category);
-  formData.append('tenantIds', tenantIds);
-  files.forEach(file => {
-    formData.append('files', file);
-  });
-  return request({
-    headers: {
-      "Content-Type": "multipart/form-data"
-    },
-    url: '/api/blade-flow/manager/deploy-upload',
-    method: 'post',
-    data: formData
-  })
-}
-
-export const deleteDeployment = (deploymentIds) => {
-  return request({
-    url: '/api/blade-flow/manager/delete-deployment',
-    method: 'post',
-    params: {
-      deploymentIds,
-    }
-  })
-}
-
-export const deleteProcessInstance = (params) => {
-  return request({
-    url: '/api/blade-flow/follow/delete-process-instance',
-    method: 'post',
-    params
-  })
-}

+ 0 - 22
src/api/report/report.js

@@ -1,22 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-report/report/rest/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-report/report/rest/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}

+ 0 - 50
src/api/resource/attach.js

@@ -1,50 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-resource/attach/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-resource/attach/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-resource/attach/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-resource/attach/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-resource/attach/submit',
-    method: 'post',
-    data: row
-  })
-}
-

+ 0 - 59
src/api/resource/oss.js

@@ -1,59 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-resource/oss/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-resource/oss/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-resource/oss/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-resource/oss/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-resource/oss/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const enable = (id) => {
-  return request({
-    url: '/api/blade-resource/oss/enable',
-    method: 'post',
-    params: {
-      id
-    }
-  })
-}

+ 0 - 72
src/api/resource/sms.js

@@ -1,72 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-resource/sms/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-resource/sms/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-resource/sms/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-resource/sms/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-resource/sms/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const enable = (id) => {
-  return request({
-    url: '/api/blade-resource/sms/enable',
-    method: 'post',
-    params: {
-      id
-    }
-  })
-}
-
-export const send = (code, phones, params) => {
-  return request({
-    url: '/api/blade-resource/sms/endpoint/send-message',
-    method: 'post',
-    params: {
-      code,
-      phones,
-      params,
-    }
-  })
-}
-

+ 0 - 50
src/api/system/client.js

@@ -1,50 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/client/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-system/client/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/client/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/client/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/client/submit',
-    method: 'post',
-    data: row
-  })
-}
-

+ 0 - 81
src/api/system/dept.js

@@ -1,81 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/dept/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getLazyList = (parentId, params) => {
-  return request({
-    url: '/api/blade-system/dept/lazy-list',
-    method: 'get',
-    params: {
-      ...params,
-      parentId
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/dept/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/dept/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/dept/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const getDept = (id) => {
-  return request({
-    url: '/api/blade-system/dept/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}
-
-export const getDeptTree = (tenantId) => {
-  return request({
-    url: '/api/blade-system/dept/tree',
-    method: 'get',
-    params: {
-      tenantId,
-    }
-  })
-}
-
-export const getDeptLazyTree = (parentId) => {
-  return request({
-    url: '/api/blade-system/dept/lazy-tree',
-    method: 'get',
-    params: {
-      parentId
-    }
-  })
-}
-

+ 0 - 89
src/api/system/dictbiz.js

@@ -1,89 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/dict-biz/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getParentList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/dict-biz/parent-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getChildList = (current, size, parentId, params) => {
-  return request({
-    url: '/api/blade-system/dict-biz/child-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-      parentId: parentId,
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/dict-biz/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/dict-biz/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/dict-biz/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-
-export const getDict = (id) => {
-  return request({
-    url: '/api/blade-system/dict-biz/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}
-export const getDictTree = () => {
-  return request({
-    url: '/api/blade-system/dict-biz/tree?code=DICT',
-    method: 'get'
-  })
-}
-
-export const getDictionary = (params) => {
-  return request({
-    url: '/api/blade-system/dict-biz/dictionary',
-    method: 'get',
-    params,
-  })
-}

+ 0 - 39
src/api/system/param.js

@@ -1,39 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/param/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/param/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/param/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/param/submit',
-    method: 'post',
-    data: row
-  })
-}

+ 0 - 60
src/api/system/post.js

@@ -1,60 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/post/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getPostList = (tenantId) => {
-  return request({
-    url: '/api/blade-system/post/select',
-    method: 'get',
-    params: {
-      tenantId
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-system/post/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/post/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/post/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/post/submit',
-    method: 'post',
-    data: row
-  })
-}
-

+ 0 - 89
src/api/system/role.js

@@ -1,89 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/role/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-export const grantTree = () => {
-  return request({
-    url: '/api/blade-system/menu/grant-tree',
-    method: 'get',
-  })
-}
-
-export const grant = (roleIds, menuIds, dataScopeIds, apiScopeIds) => {
-  return request({
-    url: '/api/blade-system/role/grant',
-    method: 'post',
-    data: {
-      roleIds,
-      menuIds,
-      dataScopeIds,
-      apiScopeIds
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/role/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/role/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/role/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-
-export const getRole = (roleIds) => {
-  return request({
-    url: '/api/blade-system/menu/role-tree-keys',
-    method: 'get',
-    params: {
-      roleIds,
-    }
-  })
-}
-
-export const getRoleTree = (tenantId) => {
-  return request({
-    url: '/api/blade-system/role/tree',
-    method: 'get',
-    params: {
-      tenantId,
-    }
-  })
-}
-
-export const getRoleTreeById = (roleId) => {
-  return request({
-    url: '/api/blade-system/role/tree-by-id',
-    method: 'get',
-    params: {
-      roleId,
-    }
-  })
-}

+ 0 - 97
src/api/system/scope.js

@@ -1,97 +0,0 @@
-import request from '@/router/axios';
-
-export const getListDataScope = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/data-scope/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const removeDataScope = (ids) => {
-  return request({
-    url: '/api/blade-system/data-scope/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const addDataScope = (row) => {
-  return request({
-    url: '/api/blade-system/data-scope/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const updateDataScope = (row) => {
-  return request({
-    url: '/api/blade-system/data-scope/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const getMenuDataScope = (id) => {
-  return request({
-    url: '/api/blade-system/data-scope/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}
-
-export const getListApiScope = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/api-scope/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const removeApiScope = (ids) => {
-  return request({
-    url: '/api/blade-system/api-scope/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const addApiScope = (row) => {
-  return request({
-    url: '/api/blade-system/api-scope/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const updateApiScope = (row) => {
-  return request({
-    url: '/api/blade-system/api-scope/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const getMenuApiScope = (id) => {
-  return request({
-    url: '/api/blade-system/api-scope/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}

+ 0 - 77
src/api/system/topmenu.js

@@ -1,77 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-system/topmenu/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-system/topmenu/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-system/topmenu/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-system/topmenu/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-system/topmenu/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const grantTree = () => {
-  return request({
-    url: '/api/blade-system/menu/grant-top-tree',
-    method: 'get',
-  })
-}
-
-export const getTopTree = (topMenuIds) => {
-  return request({
-    url: '/api/blade-system/menu/top-tree-keys',
-    method: 'get',
-    params: {
-      topMenuIds,
-    }
-  })
-}
-
-export const grant = (topMenuIds, menuIds) => {
-  return request({
-    url: '/api/blade-system/topmenu/grant',
-    method: 'post',
-    data: {
-      topMenuIds,
-      menuIds,
-    }
-  })
-}

+ 0 - 120
src/api/system/user.js

@@ -1,120 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params, deptId) => {
-  return request({
-    url: '/api/blade-user/page',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-      deptId,
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-user/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-user/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-user/update',
-    method: 'post',
-    data: row
-  })
-}
-
-export const updatePlatform = (userId, userType, userExt) => {
-  return request({
-    url: '/api/blade-user/update-platform',
-    method: 'post',
-    params: {
-      userId,
-      userType,
-      userExt,
-    }
-  })
-}
-
-export const getUser = (id) => {
-  return request({
-    url: '/api/blade-user/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}
-
-export const getUserPlatform = (id) => {
-  return request({
-    url: '/api/blade-user/platform-detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}
-
-export const getUserInfo = () => {
-  return request({
-    url: '/api/blade-user/info',
-    method: 'get',
-  })
-}
-
-export const resetPassword = (userIds) => {
-  return request({
-    url: '/api/blade-user/reset-password',
-    method: 'post',
-    params: {
-      userIds,
-    }
-  })
-}
-
-export const updatePassword = (oldPassword, newPassword, newPassword1) => {
-  return request({
-    url: '/api/blade-user/update-password',
-    method: 'post',
-    params: {
-      oldPassword,
-      newPassword,
-      newPassword1,
-    }
-  })
-}
-
-export const updateInfo = (row) => {
-  return request({
-    url: '/api/blade-user/update-info',
-    method: 'post',
-    data: row
-  })
-}
-
-export const grant = (userIds, roleIds) => {
-  return request({
-    url: '/api/blade-user/grant',
-    method: 'post',
-    params: {
-      userIds,
-      roleIds,
-    }
-  })
-}

+ 0 - 69
src/api/tool/code.js

@@ -1,69 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-develop/code/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size
-    }
-  })
-}
-
-export const build = (ids) => {
-  return request({
-    url: '/api/blade-develop/code/gen-code',
-    method: 'post',
-    params: {
-      ids,
-      system: 'saber'
-    }
-  })
-}
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-develop/code/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-develop/code/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-develop/code/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const copy = (id) => {
-  return request({
-    url: '/api/blade-develop/code/copy',
-    method: 'post',
-    params: {
-      id,
-    }
-  })
-}
-
-export const getCode = (id) => {
-  return request({
-    url: '/api/blade-develop/code/detail',
-    method: 'get',
-    params: {
-      id,
-    }
-  })
-}

+ 0 - 50
src/api/tool/datasource.js

@@ -1,50 +0,0 @@
-import request from '@/router/axios';
-
-export const getList = (current, size, params) => {
-  return request({
-    url: '/api/blade-develop/datasource/list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const getDetail = (id) => {
-  return request({
-    url: '/api/blade-develop/datasource/detail',
-    method: 'get',
-    params: {
-      id
-    }
-  })
-}
-
-export const remove = (ids) => {
-  return request({
-    url: '/api/blade-develop/datasource/remove',
-    method: 'post',
-    params: {
-      ids,
-    }
-  })
-}
-
-export const add = (row) => {
-  return request({
-    url: '/api/blade-develop/datasource/submit',
-    method: 'post',
-    data: row
-  })
-}
-
-export const update = (row) => {
-  return request({
-    url: '/api/blade-develop/datasource/submit',
-    method: 'post',
-    data: row
-  })
-}
-

+ 0 - 34
src/api/work/process.js

@@ -1,34 +0,0 @@
-import request from '@/router/axios';
-
-// =====================参数===========================
-
-export const historyFlowList = (processInstanceId) => {
-  return request({
-    url: '/api/blade-flow/process/history-flow-list',
-    method: 'get',
-    params: {
-      processInstanceId
-    }
-  })
-}
-
-
-// =====================请假流程===========================
-
-export const leaveProcess = (data) => {
-  return request({
-    url: '/api/blade-desk/process/leave/start-process',
-    method: 'post',
-    data
-  })
-}
-
-export const leaveDetail = (businessId) => {
-  return request({
-    url: '/api/blade-desk/process/leave/detail',
-    method: 'get',
-    params: {
-      businessId
-    }
-  })
-}

+ 0 - 81
src/api/work/work.js

@@ -1,81 +0,0 @@
-import request from '@/router/axios';
-
-export const startList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/work/start-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const claimList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/work/claim-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const todoList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/work/todo-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const sendList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/work/send-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-
-export const doneList = (current, size, params) => {
-  return request({
-    url: '/api/blade-flow/work/done-list',
-    method: 'get',
-    params: {
-      ...params,
-      current,
-      size,
-    }
-  })
-}
-
-export const claimTask = (taskId) => {
-  return request({
-    url: '/api/blade-flow/work/claim-task',
-    method: 'post',
-    params: {
-      taskId
-    }
-  })
-}
-
-
-export const completeTask = (data) => {
-  return request({
-    url: '/api/blade-flow/work/complete-task',
-    method: 'post',
-    data
-  })
-}

+ 19 - 105
src/router/views/index.js

@@ -1,106 +1,20 @@
-import Layout from '@/page/index/'
+import Layout from "@/page/index/";
 
-export default [{
-  path: '/wel',
-  component: Layout,
-  redirect: '/wel/index',
-  children: [{
-    path: 'index',
-    name: '首页',
-    meta: {
-      i18n: 'dashboard'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/wel/index')
-  }, {
-    path: 'dashboard',
-    name: '控制台',
-    meta: {
-      i18n: 'dashboard',
-      menu: false,
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/wel/dashboard')
-  }]
-}, {
-  path: '/test',
-  component: Layout,
-  redirect: '/test/index',
-  children: [{
-    path: 'index',
-    name: '测试页',
-    meta: {
-      i18n: 'test'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/util/test')
-  }]
-}, {
-  path: '/dict-horizontal',
-  component: Layout,
-  redirect: '/dict-horizontal/index',
-  children: [{
-    path: 'index',
-    name: '字典管理',
-    meta: {
-      i18n: 'dict'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/util/demo/dict-horizontal')
-  }]
-}, {
-  path: '/dict-vertical',
-  component: Layout,
-  redirect: '/dict-vertical/index',
-  children: [{
-    path: 'index',
-    name: '字典管理',
-    meta: {
-      i18n: 'dict'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/util/demo/dict-vertical')
-  }]
-}, {
-  path: '/info',
-  component: Layout,
-  redirect: '/info/index',
-  children: [{
-    path: 'index',
-    name: '个人信息',
-    meta: {
-      i18n: 'info'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/system/userinfo')
-  }]
-}, {
-  path: '/work/process/leave',
-  component: Layout,
-  redirect: '/work/process/leave/form',
-  children: [{
-    path: 'form/:processDefinitionId',
-    name: '请假流程',
-    meta: {
-      i18n: 'work'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/work/process/leave/form')
-  }, {
-    path: 'handle/:taskId/:processInstanceId/:businessId',
-    name: '处理请假流程',
-    meta: {
-      i18n: 'work'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/work/process/leave/handle')
-  }, {
-    path: 'detail/:processInstanceId/:businessId',
-    name: '请假流程详情',
-    meta: {
-      i18n: 'work'
-    },
-    component: () =>
-      import( /* webpackChunkName: "views" */ '@/views/work/process/leave/detail')
-  }]
-}]
+export default [
+  {
+    path: "/wel",
+    component: Layout,
+    redirect: "/wel/index",
+    children: [
+      {
+        path: "index",
+        name: "首页",
+        meta: {
+          i18n: "dashboard",
+        },
+        component: () =>
+          import(/* webpackChunkName: "views" */ "@/views/wel/index"),
+      },
+    ],
+  },
+];

+ 0 - 333
src/views/system/client.vue

@@ -1,333 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud :option="option"
-               :table-loading="loading"
-               :data="data"
-               :page.sync="page"
-               @row-del="rowDel"
-               v-model="form"
-               ref="crud"
-               :permission="permissionList"
-               @row-update="rowUpdate"
-               @row-save="rowSave"
-               :before-open="beforeOpen"
-               @search-change="searchChange"
-               @search-reset="searchReset"
-               @selection-change="selectionChange"
-               @current-change="currentChange"
-               @size-change="sizeChange"
-               @refresh-change="refreshChange"
-               @on-load="onLoad">
-      <template slot="menuLeft">
-        <el-button type="danger"
-                   size="small"
-                   icon="el-icon-delete"
-                   plain
-                   v-if="permission.client_delete"
-                   @click="handleDelete">删 除
-        </el-button>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-  import {getList, getDetail, add, update, remove} from "@/api/system/client";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        form: {},
-        query: {},
-        loading: true,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        selectionList: [],
-        option: {
-          height: 'auto',
-          calcHeight: 30,
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          border: true,
-          index: true,
-          viewBtn: true,
-          selection: true,
-          dialogClickModal: false,
-          column: [
-            {
-              label: "应用id",
-              prop: "clientId",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入客户端id",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "应用密钥",
-              prop: "clientSecret",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入客户端密钥",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "授权类型",
-              prop: "authorizedGrantTypes",
-              type: "checkbox",
-              value: "refresh_token,password,authorization_code",
-              dicData: [
-                {
-                  label: "refresh_token",
-                  value: "refresh_token"
-                },
-                {
-                  label: "password",
-                  value: "password"
-                },
-                {
-                  label: "authorization_code",
-                  value: "authorization_code"
-                },
-                {
-                  label: "captcha",
-                  value: "captcha"
-                },
-                {
-                  label: "social",
-                  value: "social"
-                }
-              ],
-              rules: [{
-                required: true,
-                message: "请输入授权类型",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "授权范围",
-              prop: "scope",
-              value: "all",
-              rules: [{
-                required: true,
-                message: "请输入授权范围",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "令牌秒数",
-              prop: "accessTokenValidity",
-              type: "number",
-              value: 3600,
-              rules: [{
-                required: true,
-                message: "请输入令牌过期秒数",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "刷新秒数",
-              prop: "refreshTokenValidity",
-              type: "number",
-              value: 604800,
-              hide: true,
-              rules: [{
-                required: true,
-                message: "请输入刷新令牌过期秒数",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "回调地址",
-              prop: "webServerRedirectUri",
-              hide: true,
-              rules: [{
-                required: true,
-                message: "请输入回调地址",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "资源集合",
-              prop: "resourceIds",
-              hide: true,
-              rules: [{
-                message: "请输入资源集合",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "权限",
-              prop: "authorities",
-              hide: true,
-              rules: [{
-                message: "请输入权限",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "自动授权",
-              prop: "autoapprove",
-              hide: true,
-              rules: [{
-                message: "请输入自动授权",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "附加说明",
-              hide: true,
-              prop: "additionalInformation",
-              span: 24,
-              rules: [{
-                message: "请输入附加说明",
-                trigger: "blur"
-              }]
-            },
-          ]
-        },
-        data: []
-      };
-    },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.client_add),
-          viewBtn: this.vaildData(this.permission.client_view),
-          delBtn: this.vaildData(this.permission.client_delete),
-          editBtn: this.vaildData(this.permission.client_edit)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDetail(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      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;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 363
src/views/system/dept.vue

@@ -1,363 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud :option="option"
-               :table-loading="loading"
-               :data="data"
-               ref="crud"
-               v-model="form"
-               :permission="permissionList"
-               :before-open="beforeOpen"
-               :before-close="beforeClose"
-               @row-del="rowDel"
-               @row-update="rowUpdate"
-               @row-save="rowSave"
-               @search-change="searchChange"
-               @search-reset="searchReset"
-               @selection-change="selectionChange"
-               @current-change="currentChange"
-               @size-change="sizeChange"
-               @refresh-change="refreshChange"
-               @on-load="onLoad"
-               @tree-load="treeLoad">
-      <template slot="menuLeft">
-        <el-button type="danger"
-                   size="small"
-                   icon="el-icon-delete"
-                   v-if="permission.dept_delete"
-                   plain
-                   @click="handleDelete">删 除
-        </el-button>
-      </template>
-      <template slot-scope="scope" slot="menu">
-        <el-button
-          type="text"
-          icon="el-icon-circle-plus-outline"
-          size="small"
-          @click.stop="handleAdd(scope.row,scope.index)"
-          v-if="userInfo.role_name.includes('admin')"
-        >新增子项
-        </el-button>
-      </template>
-      <template slot-scope="{row}"
-                slot="deptCategory">
-        <el-tag>{{row.deptCategoryName}}</el-tag>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-  import {
-    getLazyList,
-    remove,
-    update,
-    add,
-    getDept,
-    getDeptTree
-  } from "@/api/system/dept";
-  import {mapGetters} from "vuex";
-  import website from '@/config/website';
-
-  export default {
-    data() {
-      return {
-        form: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        parentId: 0,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0,
-        },
-        option: {
-          lazy: true,
-          tip: false,
-          simplePage: true,
-          searchShow: true,
-          searchMenuSpan: 6,
-          tree: true,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          menuWidth: 300,
-          dialogClickModal: false,
-          column: [
-            {
-              label: "机构名称",
-              prop: "deptName",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入机构名称",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "所属租户",
-              prop: "tenantId",
-              type: "tree",
-              dicUrl: "/api/blade-system/tenant/select",
-              addDisplay: false,
-              editDisplay: false,
-              viewDisplay: website.tenantMode,
-              span: 24,
-              props: {
-                label: "tenantName",
-                value: "tenantId"
-              },
-              hide: !website.tenantMode,
-              search: website.tenantMode,
-              rules: [{
-                required: true,
-                message: "请输入所属租户",
-                trigger: "click"
-              }]
-            },
-            {
-              label: "机构全称",
-              prop: "fullName",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入机构全称",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "上级机构",
-              prop: "parentId",
-              dicData: [],
-              type: "tree",
-              hide: true,
-              addDisabled: false,
-              props: {
-                label: "title"
-              },
-              rules: [{
-                required: false,
-                message: "请选择上级机构",
-                trigger: "click"
-              }]
-            },
-            {
-              label: "机构类型",
-              type: "select",
-              dicUrl: "/api/blade-system/dict/dictionary?code=org_category",
-              props: {
-                label: "dictValue",
-                value: "dictKey"
-              },
-              dataType: "number",
-              width: 120,
-              prop: "deptCategory",
-              slot: true,
-              rules: [{
-                required: true,
-                message: "请输入机构类型",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "排序",
-              prop: "sort",
-              type: "number",
-              align: "right",
-              width: 80,
-              rules: [{
-                required: true,
-                message: "请输入排序",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "备注",
-              prop: "remark",
-              rules: [{
-                required: false,
-                message: "请输入备注",
-                trigger: "blur"
-              }],
-              hide: true
-            }
-          ]
-        },
-        data: []
-      };
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dept_add, false),
-          viewBtn: this.vaildData(this.permission.dept_view, false),
-          delBtn: this.vaildData(this.permission.dept_delete, false),
-          editBtn: this.vaildData(this.permission.dept_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      initData() {
-        getDeptTree().then(res => {
-          const column = this.findObject(this.option.column, "parentId");
-          column.dicData = res.data.data;
-        });
-      },
-      handleAdd(row) {
-        this.parentId = row.id;
-        const column = this.findObject(this.option.column, "parentId");
-        column.value = row.id;
-        column.addDisabled = true;
-        this.$refs.crud.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        add(row).then((res) => {
-          // 获取新增数据的相关字段
-          const data = res.data.data;
-          row.id = data.id;
-          row.deptCategoryName = data.deptCategoryName;
-          row.tenantId = data.tenantId;
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          // 数据回调进行刷新
-          done(row);
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          // 数据回调进行刷新
-          done(row);
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row, index, done) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            // 数据回调进行刷新
-            done(row);
-          });
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            // 刷新表格数据并重载
-            this.data = [];
-            this.parentId = 0;
-            this.$refs.crud.refreshTable();
-            this.$refs.crud.toggleSelection();
-            // 表格数据重载
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchReset() {
-        this.query = {};
-        this.parentId = 0;
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.parentId = '';
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      beforeOpen(done, type) {
-        if (["add", "edit"].includes(type)) {
-          this.initData();
-        }
-        if (["edit", "view"].includes(type)) {
-          getDept(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeClose(done) {
-        this.parentId = "";
-        const column = this.findObject(this.option.column, "parentId");
-        column.value = "";
-        column.addDisabled = false;
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      onLoad(page, params = {}) {
-        this.loading = true;
-        getLazyList(this.parentId, Object.assign(params, this.query)).then(res => {
-          this.data = res.data.data;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      treeLoad(tree, treeNode, resolve) {
-        const parentId = tree.id;
-        getLazyList(parentId).then(res => {
-          resolve(res.data.data);
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 443
src/views/system/dict.vue

@@ -1,443 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud
-      :option="optionParent"
-      :table-loading="loading"
-      :data="dataParent"
-      :page="pageParent"
-      ref="crud"
-      v-model="formParent"
-      :permission="permissionList"
-      :before-open="beforeOpen"
-      @row-del="rowDel"
-      @row-update="rowUpdate"
-      @row-save="rowSave"
-      @row-click="handleRowClick"
-      @search-change="searchChange"
-      @search-reset="searchReset"
-      @selection-change="selectionChange"
-      @current-change="currentChange"
-      @size-change="sizeChange"
-      @refresh-change="refreshChange"
-      @on-load="onLoadParent"
-    >
-      <template slot="menuLeft">
-        <el-button
-          type="danger"
-          size="small"
-          icon="el-icon-delete"
-          v-if="permission.dict_delete"
-          plain
-          @click="handleDelete"
-        >删 除
-        </el-button>
-      </template>
-      <template slot-scope="scope" slot="menu">
-        <el-button
-          type="text"
-          icon="el-icon-setting"
-          size="small"
-          @click.stop="handleRowClick(scope.row)"
-          v-if="userInfo.role_name.includes('admin')"
-        >字典配置
-        </el-button>
-      </template>
-      <template slot-scope="{row}" slot="code">
-        <el-tag @click="handleRowClick(row)" style="cursor:pointer">{{ row.code }}</el-tag>
-      </template>
-      <template slot-scope="{row}" slot="isSealed">
-        <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
-      </template>
-    </avue-crud>
-    <el-dialog :title="`[${dictValue}]字典配置`"
-               append-to-body
-               :visible.sync="box"
-               width="1000px">
-      <avue-crud
-        :option="optionChild"
-        :table-loading="loadingChild"
-        :data="dataChild"
-        ref="crudChild"
-        v-model="formChild"
-        :permission="permissionList"
-        :before-open="beforeOpenChild"
-        :before-close="beforeCloseChild"
-        @row-del="rowDelChild"
-        @row-update="rowUpdateChild"
-        @row-save="rowSaveChild"
-        @search-change="searchChangeChild"
-        @search-reset="searchResetChild"
-        @selection-change="selectionChangeChild"
-        @current-change="currentChangeChild"
-        @size-change="sizeChangeChild"
-        @refresh-change="refreshChangeChild"
-        @on-load="onLoadChild"
-      >
-        <template slot="menuLeft">
-          <el-button
-            type="danger"
-            size="small"
-            icon="el-icon-delete"
-            v-if="permission.dict_delete"
-            plain
-            @click="handleDelete"
-          >删 除
-          </el-button>
-        </template>
-        <template slot-scope="scope" slot="menu">
-          <el-button
-            type="text"
-            icon="el-icon-circle-plus-outline"
-            size="small"
-            @click.stop="handleAdd(scope.row,scope.index)"
-            v-if="userInfo.role_name.includes('admin')"
-          >新增子项
-          </el-button>
-        </template>
-        <template slot-scope="{row}" slot="isSealed">
-          <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
-        </template>
-      </avue-crud>
-    </el-dialog>
-  </basic-container>
-</template>
-
-<script>
-import {
-  getParentList,
-  getChildList,
-  remove,
-  update,
-  add,
-  getDict,
-  getDictTree
-} from "@/api/system/dict";
-import {optionParent, optionChild} from "@/option/system/dict";
-import {mapGetters} from "vuex";
-
-export default {
-  data() {
-    return {
-      dictValue: '暂无',
-      parentId: -1,
-      formParent: {},
-      formChild: {},
-      selectionList: [],
-      query: {},
-      box: false,
-      loading: true,
-      loadingChild: true,
-      pageParent: {
-        pageSize: 10,
-        pageSizes: [10, 30, 50, 100, 200],
-        currentPage: 1,
-        total: 0
-      },
-      pageChild: {
-        pageSize: 10,
-        pageSizes: [10, 30, 50, 100, 200],
-        currentPage: 1,
-        total: 0
-      },
-      dataParent: [],
-      dataChild: [],
-      optionParent: optionParent,
-      optionChild: optionChild,
-    };
-  },
-  computed: {
-    ...mapGetters(["userInfo", "permission"]),
-    permissionList() {
-      return {
-        addBtn: this.vaildData(this.permission.dict_add, false),
-        delBtn: this.vaildData(this.permission.dict_delete, false),
-        editBtn: this.vaildData(this.permission.dict_edit, false),
-        viewBtn: false,
-      };
-    },
-    ids() {
-      let ids = [];
-      this.selectionList.forEach(ele => {
-        ids.push(ele.id);
-      });
-      return ids.join(",");
-    }
-  },
-  mounted() {
-    this.initData();
-  },
-  methods: {
-    initData() {
-      getDictTree().then(res => {
-        const column = this.findObject(this.optionChild.column, "parentId");
-        column.dicData = res.data.data;
-      });
-    },
-    handleAdd(row) {
-      this.formChild.dictValue = "";
-      this.formChild.dictKey = "";
-      this.formChild.sort = 0;
-      this.formChild.isSealed = 0;
-      this.formChild.remark = "";
-      this.formChild.parentId = row.id;
-      this.$refs.crudChild.rowAdd();
-    },
-    rowSave(row, done, loading) {
-      const form = {
-        ...row,
-        dictKey: -1,
-      };
-      add(form).then(() => {
-        this.onLoadParent(this.pageParent);
-        this.$message({
-          type: "success",
-          message: "操作成功!"
-        });
-        done();
-      }, error => {
-        window.console.log(error);
-        loading();
-      });
-    },
-    rowUpdate(row, index, done, loading) {
-      update(row).then(() => {
-        this.onLoadParent(this.pageParent);
-        this.$message({
-          type: "success",
-          message: "操作成功!"
-        });
-        this.onLoadChild(this.pageChild);
-        done();
-      }, error => {
-        window.console.log(error);
-        loading();
-      });
-    },
-    rowDel(row) {
-      this.$confirm("确定将选择数据删除?", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      })
-        .then(() => {
-          return remove(row.id);
-        })
-        .then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-        });
-    },
-    handleRowClick(row) {
-      this.query = {};
-      this.parentId = row.id;
-      this.dictValue = row.dictValue;
-
-      const code = this.findObject(this.optionChild.column, "code");
-      code.value = row.code;
-      const parentId = this.findObject(this.optionChild.column, "parentId");
-      parentId.value = row.id;
-
-      this.box = true;
-      this.onLoadChild(this.pageChild);
-    },
-    searchReset() {
-      this.query = {};
-      this.onLoadParent(this.pageParent);
-    },
-    searchChange(params, done) {
-      this.query = params;
-      this.pageParent.currentPage = 1;
-      this.onLoadParent(this.pageParent, params);
-      done();
-    },
-    selectionChange(list) {
-      this.selectionList = list;
-    },
-    selectionClear() {
-      this.selectionList = [];
-      this.$refs.crud.toggleSelection();
-    },
-    handleDelete() {
-      if (this.selectionList.length === 0) {
-        this.$message.warning("请选择至少一条数据");
-        return;
-      }
-      this.$confirm("确定将选择数据删除?", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      })
-        .then(() => {
-          return remove(this.ids);
-        })
-        .then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          this.$refs.crud.toggleSelection();
-        });
-    },
-    beforeOpen(done, type) {
-      if (["edit", "view"].includes(type)) {
-        getDict(this.formParent.id).then(res => {
-          this.formParent = res.data.data;
-        });
-      }
-      done();
-    },
-    currentChange(currentPage) {
-      this.pageParent.currentPage = currentPage;
-    },
-    sizeChange(pageSize) {
-      this.pageParent.pageSize = pageSize;
-    },
-    refreshChange() {
-      this.onLoadParent(this.pageParent, this.query);
-    },
-    rowSaveChild(row, done, loading) {
-      add(row).then(() => {
-        this.onLoadChild(this.pageChild);
-        this.$message({
-          type: "success",
-          message: "操作成功!"
-        });
-        done();
-      }, error => {
-        window.console.log(error);
-        loading();
-      });
-    },
-    rowUpdateChild(row, index, done, loading) {
-      update(row).then(() => {
-        this.onLoadChild(this.pageChild);
-        this.$message({
-          type: "success",
-          message: "操作成功!"
-        });
-        done();
-      }, error => {
-        window.console.log(error);
-        loading();
-      });
-    },
-    rowDelChild(row) {
-      this.$confirm("确定将选择数据删除?", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      })
-        .then(() => {
-          return remove(row.id);
-        })
-        .then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-        });
-    },
-    searchResetChild() {
-      this.query = {};
-      this.onLoadChild(this.pageChild);
-    },
-    searchChangeChild(params, done) {
-      this.query = params;
-      this.pageChild.currentPage = 1;
-      this.onLoadChild(this.pageChild, params);
-      done();
-    },
-    selectionChangeChild(list) {
-      this.selectionList = list;
-    },
-    selectionClearChild() {
-      this.selectionList = [];
-      this.$refs.crudChild.toggleSelection();
-    },
-    handleDeleteChild() {
-      if (this.selectionList.length === 0) {
-        this.$message.warning("请选择至少一条数据");
-        return;
-      }
-      this.$confirm("确定将选择数据删除?", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      })
-        .then(() => {
-          return remove(this.ids);
-        })
-        .then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          this.$refs.crudChild.toggleSelection();
-        });
-    },
-    beforeOpenChild(done, type) {
-      if (["add", "edit"].includes(type)) {
-        this.initData();
-      }
-      if (["edit", "view"].includes(type)) {
-        getDict(this.formChild.id).then(res => {
-          this.formChild = res.data.data;
-        });
-      }
-      done();
-    },
-    beforeCloseChild(done) {
-      this.$refs.crudChild.value.parentId = this.parentId;
-      this.$refs.crudChild.option.column.filter(item => {
-        if (item.prop === "parentId") {
-          item.value = this.parentId;
-        }
-      });
-      done();
-    },
-    currentChangeChild(currentPage) {
-      this.pageChild.currentPage = currentPage;
-    },
-    sizeChangeChild(pageSize) {
-      this.pageChild.pageSize = pageSize;
-    },
-    refreshChangeChild() {
-      this.onLoadChild(this.pageChild, this.query);
-    },
-    onLoadParent(page, params = {}) {
-      this.loading = true;
-      getParentList(
-        page.currentPage,
-        page.pageSize,
-        Object.assign(params, this.query)
-      ).then(res => {
-        const data = res.data.data;
-        this.pageParent.total = data.total;
-        this.dataParent = data.records;
-        this.loading = false;
-        this.selectionClear();
-      });
-    },
-    onLoadChild(page, params = {}) {
-      this.loadingChild = true;
-      getChildList(
-        page.currentPage,
-        page.pageSize,
-        this.parentId,
-        Object.assign(params, this.query)
-      ).then(res => {
-        this.dataChild = res.data.data;
-        this.loadingChild = false;
-        this.selectionClear();
-      });
-    }
-  }
-};
-</script>
-

+ 0 - 442
src/views/system/dictbiz.vue

@@ -1,442 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud
-      :option="optionParent"
-      :table-loading="loading"
-      :data="dataParent"
-      :page="pageParent"
-      ref="crud"
-      v-model="formParent"
-      :permission="permissionList"
-      :before-open="beforeOpen"
-      @row-del="rowDel"
-      @row-update="rowUpdate"
-      @row-save="rowSave"
-      @row-click="handleRowClick"
-      @search-change="searchChange"
-      @search-reset="searchReset"
-      @selection-change="selectionChange"
-      @current-change="currentChange"
-      @size-change="sizeChange"
-      @refresh-change="refreshChange"
-      @on-load="onLoadParent"
-    >
-      <template slot="menuLeft">
-        <el-button
-          type="danger"
-          size="small"
-          icon="el-icon-delete"
-          v-if="permission.dictbiz_delete"
-          plain
-          @click="handleDelete"
-        >删 除
-        </el-button>
-      </template>
-      <template slot-scope="scope" slot="menu">
-        <el-button
-          type="text"
-          icon="el-icon-setting"
-          size="small"
-          @click.stop="handleRowClick(scope.row)"
-          v-if="userInfo.role_name.includes('admin')"
-        >字典配置
-        </el-button>
-      </template>
-      <template slot-scope="{row}" slot="code">
-        <el-tag @click="handleRowClick(row)" style="cursor:pointer">{{ row.code }}</el-tag>
-      </template>
-      <template slot-scope="{row}" slot="isSealed">
-        <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
-      </template>
-    </avue-crud>
-    <el-dialog :title="`[${dictValue}]字典配置`"
-               append-to-body
-               :visible.sync="box"
-               width="1000px">
-      <avue-crud
-        :option="optionChild"
-        :table-loading="loadingChild"
-        :data="dataChild"
-        ref="crudChild"
-        v-model="formChild"
-        :permission="permissionList"
-        :before-open="beforeOpenChild"
-        :before-close="beforeCloseChild"
-        @row-del="rowDelChild"
-        @row-update="rowUpdateChild"
-        @row-save="rowSaveChild"
-        @search-change="searchChangeChild"
-        @search-reset="searchResetChild"
-        @selection-change="selectionChangeChild"
-        @current-change="currentChangeChild"
-        @size-change="sizeChangeChild"
-        @refresh-change="refreshChangeChild"
-        @on-load="onLoadChild"
-      >
-        <template slot="menuLeft">
-          <el-button
-            type="danger"
-            size="small"
-            icon="el-icon-delete"
-            v-if="permission.dict_delete"
-            plain
-            @click="handleDelete"
-          >删 除
-          </el-button>
-        </template>
-        <template slot-scope="scope" slot="menu">
-          <el-button
-            type="text"
-            icon="el-icon-circle-plus-outline"
-            size="small"
-            @click.stop="handleAdd(scope.row,scope.index)"
-            v-if="userInfo.role_name.includes('admin')"
-          >新增子项
-          </el-button>
-        </template>
-        <template slot-scope="{row}" slot="isSealed">
-          <el-tag>{{ row.isSealed === 0 ? '否' : '是' }}</el-tag>
-        </template>
-      </avue-crud>
-    </el-dialog>
-  </basic-container>
-</template>
-
-<script>
-  import {
-    getParentList,
-    getChildList,
-    remove,
-    update,
-    add,
-    getDict,
-    getDictTree
-  } from "@/api/system/dictbiz";
-  import {optionParent, optionChild} from "@/option/system/dictbiz";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        dictValue: '暂无',
-        parentId: -1,
-        formParent: {},
-        formChild: {},
-        selectionList: [],
-        query: {},
-        box: false,
-        loading: true,
-        loadingChild: true,
-        pageParent: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        pageChild: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        dataParent: [],
-        dataChild: [],
-        optionParent: optionParent,
-        optionChild: optionChild,
-      };
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dictbiz_add, false),
-          delBtn: this.vaildData(this.permission.dictbiz_delete, false),
-          editBtn: this.vaildData(this.permission.dictbiz_edit, false),
-          viewBtn: false,
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    mounted() {
-      this.initData();
-    },
-    methods: {
-      initData() {
-        getDictTree().then(res => {
-          const column = this.findObject(this.optionChild.column, "parentId");
-          column.dicData = res.data.data;
-        });
-      },
-      handleAdd(row) {
-        this.formChild.dictValue = "";
-        this.formChild.dictKey = "";
-        this.formChild.sort = 0;
-        this.formChild.isSealed = 0;
-        this.formChild.remark = "";
-        this.formChild.parentId = row.id;
-        this.$refs.crudChild.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        const form = {
-          ...row,
-          dictKey: -1,
-        };
-        add(form).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          this.onLoadChild(this.pageChild);
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleRowClick(row) {
-        this.query = {};
-        this.parentId = row.id;
-        this.dictValue = row.dictValue;
-
-        const code = this.findObject(this.optionChild.column, "code");
-        code.value = row.code;
-        const parentId = this.findObject(this.optionChild.column, "parentId");
-        parentId.value = row.id;
-
-        this.box = true;
-        this.onLoadChild(this.pageChild);
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoadParent(this.pageParent);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.pageParent.currentPage = 1;
-        this.onLoadParent(this.pageParent, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formParent.id).then(res => {
-            this.formParent = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.pageParent.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.pageParent.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoadParent(this.pageParent, this.query);
-      },
-      rowSaveChild(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdateChild(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDelChild(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchResetChild() {
-        this.query = {};
-        this.onLoadChild(this.pageChild);
-      },
-      searchChangeChild(params, done) {
-        this.query = params;
-        this.pageChild.currentPage = 1;
-        this.onLoadChild(this.pageChild, params);
-        done();
-      },
-      selectionChangeChild(list) {
-        this.selectionList = list;
-      },
-      selectionClearChild() {
-        this.selectionList = [];
-        this.$refs.crudChild.toggleSelection();
-      },
-      handleDeleteChild() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crudChild.toggleSelection();
-          });
-      },
-      beforeOpenChild(done, type) {
-        if (["add", "edit"].includes(type)) {
-          this.initData();
-        }
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formChild.id).then(res => {
-            this.formChild = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeCloseChild(done) {
-        this.$refs.crudChild.value.parentId = this.parentId;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "parentId") {
-            item.value = this.parentId;
-          }
-        });
-        done();
-      },
-      currentChangeChild(currentPage) {
-        this.pageChild.currentPage = currentPage;
-      },
-      sizeChangeChild(pageSize) {
-        this.pageChild.pageSize = pageSize;
-      },
-      refreshChangeChild() {
-        this.onLoadChild(this.pageChild, this.query);
-      },
-      onLoadParent(page, params = {}) {
-        this.loading = true;
-        getParentList(
-          page.currentPage,
-          page.pageSize,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageParent.total = data.total;
-          this.dataParent = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      onLoadChild(page, params = {}) {
-        this.loadingChild = true;
-        getChildList(
-          page.currentPage,
-          page.pageSize,
-          this.parentId,
-          Object.assign(params, this.query)
-        ).then(res => {
-          this.dataChild = res.data.data;
-          this.loadingChild = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>

+ 0 - 423
src/views/system/menu.vue

@@ -1,423 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud :option="option"
-               :table-loading="loading"
-               :data="data"
-               ref="crud"
-               v-model="form"
-               :permission="permissionList"
-               :before-open="beforeOpen"
-               :before-close="beforeClose"
-               @row-del="rowDel"
-               @row-update="rowUpdate"
-               @row-save="rowSave"
-               @search-change="searchChange"
-               @search-reset="searchReset"
-               @selection-change="selectionChange"
-               @current-change="currentChange"
-               @size-change="sizeChange"
-               @refresh-change="refreshChange"
-               @on-load="onLoad"
-               @tree-load="treeLoad">
-      <template slot="menuLeft">
-        <el-button type="danger"
-                   size="small"
-                   icon="el-icon-delete"
-                   v-if="permission.menu_delete"
-                   plain
-                   @click="handleDelete">删 除
-        </el-button>
-      </template>
-      <template slot-scope="scope" slot="menu">
-        <el-button
-          type="text"
-          icon="el-icon-circle-plus-outline"
-          size="small"
-          @click.stop="handleAdd(scope.row,scope.index)"
-          v-if="userInfo.role_name.includes('admin') && scope.row.category === 1"
-        >新增子项
-        </el-button>
-      </template>
-      <template slot-scope="{row}"
-                slot="source">
-        <div style="text-align:center">
-          <i :class="row.source"/>
-        </div>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-  import {getLazyList, remove, update, add, getMenu} from "@/api/system/menu";
-  import {mapGetters} from "vuex";
-  import iconList from "@/config/iconList";
-  import func from "@/util/func";
-  import {getMenuTree} from "@/api/system/menu";
-
-  export default {
-    data() {
-      return {
-        form: {},
-        query: {},
-        loading: true,
-        selectionList: [],
-        parentId: 0,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0,
-        },
-        option: {
-          lazy: true,
-          tip: false,
-          simplePage: true,
-          searchShow: true,
-          searchMenuSpan: 6,
-          dialogWidth: "60%",
-          tree: true,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          menuWidth: 300,
-          dialogClickModal: false,
-          column: [
-            {
-              label: "菜单名称",
-              prop: "name",
-              search: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入菜单名称",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "路由地址",
-              prop: "path",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入路由地址",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "上级菜单",
-              prop: "parentId",
-              type: "tree",
-              dicData: [],
-              hide: true,
-              addDisabled: false,
-              props: {
-                label: "title"
-              },
-              rules: [
-                {
-                  required: false,
-                  message: "请选择上级菜单",
-                  trigger: "click"
-                }
-              ]
-            },
-            {
-              label: "菜单图标",
-              prop: "source",
-              type: "icon",
-              slot: true,
-              iconList: iconList,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入菜单图标",
-                  trigger: "click"
-                }
-              ]
-            },
-            {
-              label: "菜单编号",
-              prop: "code",
-              search: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入菜单编号",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "菜单类型",
-              prop: "category",
-              type: "radio",
-              dicData: [
-                {
-                  label: "菜单",
-                  value: 1
-                },
-                {
-                  label: "按钮",
-                  value: 2
-                }
-              ],
-              hide: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择菜单类型",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "菜单别名",
-              prop: "alias",
-              search: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入菜单别名",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "新窗口",
-              prop: "isOpen",
-              type: "radio",
-              disabled: false,
-              dicData: [
-                {
-                  label: "否",
-                  value: 1
-                },
-                {
-                  label: "是",
-                  value: 2
-                }
-              ],
-              value: 1,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择新窗口打开",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "菜单排序",
-              prop: "sort",
-              type: "number",
-              row: true,
-              span: 24,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入菜单排序",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "菜单备注",
-              prop: "remark",
-              type: "textarea",
-              span: 24,
-              minRows: 2,
-              hide: true
-            }
-          ]
-        },
-        data: []
-      };
-    },
-    watch: {
-      'form.category'() {
-        const category = func.toInt(this.form.category);
-        this.$refs.crud.option.column.filter(item => {
-          if (item.prop === "path") {
-            item.rules[0].required = category === 1;
-          }
-          if (item.prop === 'isOpen') {
-            item.disabled = category === 2;
-          }
-        });
-      },
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.menu_add, false),
-          viewBtn: this.vaildData(this.permission.menu_view, false),
-          delBtn: this.vaildData(this.permission.menu_delete, false),
-          editBtn: this.vaildData(this.permission.menu_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      initData() {
-        getMenuTree().then(res => {
-          const column = this.findObject(this.option.column, "parentId");
-          column.dicData = res.data.data;
-        });
-      },
-      handleAdd(row) {
-        this.parentId = row.id;
-        const column = this.findObject(this.option.column, "parentId");
-        column.value = row.id;
-        column.addDisabled = true;
-        this.$refs.crud.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        add(row).then((res) => {
-          // 获取新增数据的相关字段
-          const data = res.data.data;
-          row.id = data.id;
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          // 数据回调进行刷新
-          done(row);
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          // 数据回调进行刷新
-          done(row);
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row, index, done) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            // 数据回调进行刷新
-            done(row);
-          });
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            // 刷新表格数据并重载
-            this.data = [];
-            this.parentId = 0;
-            this.$refs.crud.refreshTable();
-            this.$refs.crud.toggleSelection();
-            // 表格数据重载
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchReset() {
-        this.query = {};
-        this.parentId = 0;
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.parentId = '';
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      beforeOpen(done, type) {
-        if (["add", "edit"].includes(type)) {
-          this.initData();
-        }
-        if (["edit", "view"].includes(type)) {
-          getMenu(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeClose(done) {
-        this.parentId = "";
-        const column = this.findObject(this.option.column, "parentId");
-        column.value = "";
-        column.addDisabled = false;
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      onLoad(page, params = {}) {
-        this.loading = true;
-        getLazyList(this.parentId, Object.assign(params, this.query)).then(res => {
-          this.data = res.data.data;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      treeLoad(tree, treeNode, resolve) {
-        const parentId = tree.id;
-        getLazyList(parentId).then(res => {
-          resolve(res.data.data);
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 45
src/views/system/param.vue

@@ -1,45 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud v-bind="bindVal"
-               v-on="onEvent"
-               v-model="form"
-               :permission="permissionList"
-               :page.sync="page">
-      <template slot="menuLeft">
-        <el-button type="danger"
-                   size="small"
-                   icon="el-icon-delete"
-                   v-if="permission.param_delete"
-                   plain
-                   @click="handleDelete">删 除
-        </el-button>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-
-export default window.$crudCommon({
-  data() {
-    return {}
-  },
-  computed: {
-    permissionList() {
-      return {
-        addBtn: this.vaildData(this.permission.param_add, false),
-        viewBtn: this.vaildData(this.permission.param_view, false),
-        delBtn: this.vaildData(this.permission.param_delete, false),
-        editBtn: this.vaildData(this.permission.param_edit, false)
-      };
-    }
-  },
-  methods: {}
-}, {
-  //模块路径
-  name: 'system/param',
-})
-</script>
-
-<style>
-</style>

+ 0 - 281
src/views/system/post.vue

@@ -1,281 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud :option="option"
-               :table-loading="loading"
-               :data="data"
-               :page.sync="page"
-               :permission="permissionList"
-               :before-open="beforeOpen"
-               v-model="form"
-               ref="crud"
-               @row-update="rowUpdate"
-               @row-save="rowSave"
-               @row-del="rowDel"
-               @search-change="searchChange"
-               @search-reset="searchReset"
-               @selection-change="selectionChange"
-               @current-change="currentChange"
-               @size-change="sizeChange"
-               @refresh-change="refreshChange"
-               @on-load="onLoad">
-      <template slot="menuLeft">
-        <el-button type="danger"
-                   size="small"
-                   icon="el-icon-delete"
-                   plain
-                   v-if="permission.post_delete"
-                   @click="handleDelete">删 除
-        </el-button>
-      </template>
-      <template slot-scope="{row}"
-                slot="category">
-        <el-tag>{{row.categoryName}}</el-tag>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-  import {getList, getDetail, add, update, remove} from "@/api/system/post";
-  import {mapGetters} from "vuex";
-  import website from "@/config/website";
-
-  export default {
-    data() {
-      return {
-        form: {},
-        query: {},
-        loading: true,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        selectionList: [],
-        option: {
-          height: 'auto',
-          calcHeight: 30,
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          border: true,
-          index: true,
-          viewBtn: true,
-          selection: true,
-          dialogClickModal: false,
-          column: [
-            {
-              label: "所属租户",
-              prop: "tenantId",
-              type: "tree",
-              dicUrl: "/api/blade-system/tenant/select",
-              addDisplay: false,
-              editDisplay: false,
-              viewDisplay: website.tenantMode,
-              span: 24,
-              props: {
-                label: "tenantName",
-                value: "tenantId"
-              },
-              hide: !website.tenantMode,
-              rules: [{
-                required: true,
-                message: "请输入所属租户",
-                trigger: "click"
-              }]
-            },
-            {
-              label: "岗位类型",
-              prop: "category",
-              type: "select",
-              dicUrl: "/api/blade-system/dict/dictionary?code=post_category",
-              props: {
-                label: "dictValue",
-                value: "dictKey"
-              },
-              dataType: "number",
-              slot: true,
-              search: true,
-              rules: [{
-                required: true,
-                message: "请选择岗位类型",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "岗位编号",
-              prop: "postCode",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入岗位编号",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "岗位名称",
-              prop: "postName",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入岗位名称",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "岗位排序",
-              prop: "sort",
-              type: "number",
-              rules: [{
-                required: true,
-                message: "请输入岗位排序",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "岗位描述",
-              prop: "remark",
-              type: "textarea",
-              span: 24,
-              minRows: 6,
-              hide: true,
-            },
-          ]
-        },
-        data: []
-      };
-    },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.post_add, false),
-          viewBtn: this.vaildData(this.permission.post_view, false),
-          delBtn: this.vaildData(this.permission.post_delete, false),
-          editBtn: this.vaildData(this.permission.post_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDetail(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      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;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 994
src/views/system/user.vue

@@ -1,994 +0,0 @@
-<template>
-  <el-row>
-    <el-col :span="5">
-      <div class="box">
-        <el-scrollbar>
-          <basic-container>
-            <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick"/>
-          </basic-container>
-        </el-scrollbar>
-      </div>
-    </el-col>
-    <el-col :span="19">
-      <basic-container>
-        <avue-crud :option="option"
-                   :search.sync="search"
-                   :table-loading="loading"
-                   :data="data"
-                   ref="crud"
-                   v-model="form"
-                   :permission="permissionList"
-                   @row-del="rowDel"
-                   @row-update="rowUpdate"
-                   @row-save="rowSave"
-                   :before-open="beforeOpen"
-                   :page.sync="page"
-                   @search-change="searchChange"
-                   @search-reset="searchReset"
-                   @selection-change="selectionChange"
-                   @current-change="currentChange"
-                   @size-change="sizeChange"
-                   @refresh-change="refreshChange"
-                   @on-load="onLoad">
-          <template slot="menuLeft">
-            <el-button type="danger"
-                       size="small"
-                       plain
-                       icon="el-icon-delete"
-                       v-if="permission.user_delete"
-                       @click="handleDelete">删 除
-            </el-button>
-            <el-button type="info"
-                       size="small"
-                       plain
-                       v-if="permission.user_role"
-                       icon="el-icon-user"
-                       @click="handleGrant">角色配置
-            </el-button>
-            <el-button type="info"
-                       size="small"
-                       plain
-                       v-if="permission.user_reset"
-                       icon="el-icon-refresh"
-                       @click="handleReset">密码重置
-            </el-button>
-            <el-button type="info"
-                       size="small"
-                       plain
-                       v-if="userInfo.role_name.includes('admin')"
-                       icon="el-icon-setting"
-                       @click="handlePlatform">平台配置
-            </el-button>
-            <el-button type="success"
-                       size="small"
-                       plain
-                       v-if="userInfo.role_name.includes('admin')"
-                       icon="el-icon-upload2"
-                       @click="handleImport">导入
-            </el-button>
-            <el-button type="warning"
-                       size="small"
-                       plain
-                       v-if="userInfo.role_name.includes('admin')"
-                       icon="el-icon-download"
-                       @click="handleExport">导出
-            </el-button>
-          </template>
-          <template slot-scope="{row}"
-                    slot="tenantName">
-            <el-tag>{{row.tenantName}}</el-tag>
-          </template>
-          <template slot-scope="{row}"
-                    slot="roleName">
-            <el-tag>{{row.roleName}}</el-tag>
-          </template>
-          <template slot-scope="{row}"
-                    slot="deptName">
-            <el-tag>{{row.deptName}}</el-tag>
-          </template>
-          <template slot-scope="{row}"
-                    slot="userTypeName">
-            <el-tag>{{row.userTypeName}}</el-tag>
-          </template>
-        </avue-crud>
-        <el-dialog title="用户角色配置"
-                   append-to-body
-                   :visible.sync="roleBox"
-                   width="345px">
-
-          <el-tree :data="roleGrantList"
-                   show-checkbox
-                   check-strictly
-                   default-expand-all
-                   node-key="id"
-                   ref="treeRole"
-                   :default-checked-keys="roleTreeObj"
-                   :props="props">
-          </el-tree>
-
-          <span slot="footer" class="dialog-footer">
-            <el-button @click="roleBox = false">取 消</el-button>
-            <el-button type="primary"
-                       @click="submitRole">确 定</el-button>
-          </span>
-        </el-dialog>
-        <el-dialog title="用户数据导入"
-                   append-to-body
-                   :visible.sync="excelBox"
-                   width="555px">
-          <avue-form :option="excelOption" v-model="excelForm" :upload-after="uploadAfter">
-            <template slot="excelTemplate">
-              <el-button type="primary" @click="handleTemplate">
-                点击下载<i class="el-icon-download el-icon--right"></i>
-              </el-button>
-            </template>
-          </avue-form>
-        </el-dialog>
-        <el-dialog title="用户平台配置"
-                   append-to-body
-                   :visible.sync="platformBox">
-          <avue-crud :option="platformOption"
-                     :table-loading="platformLoading"
-                     :data="platformData"
-                     ref="platformCrud"
-                     v-model="platformForm"
-                     :before-open="platformBeforeOpen"
-                     :page.sync="platformPage"
-                     :permission="platformPermissionList"
-                     @row-update="platformRowUpdate"
-                     @search-change="platformSearchChange"
-                     @search-reset="platformSearchReset"
-                     @selection-change="platformSelectionChange"
-                     @current-change="platformCurrentChange"
-                     @size-change="platformSizeChange"
-                     @refresh-change="platformRefreshChange"
-                     @on-load="platformOnLoad">
-            <template slot-scope="{row}"
-                      slot="tenantName">
-              <el-tag>{{row.tenantName}}</el-tag>
-            </template>
-            <template slot-scope="{row}"
-                      slot="userTypeName">
-              <el-tag>{{row.userTypeName}}</el-tag>
-            </template>
-          </avue-crud>
-        </el-dialog>
-      </basic-container>
-    </el-col>
-  </el-row>
-</template>
-
-<script>
-  import {
-    getList,
-    getUser,
-    getUserPlatform,
-    remove,
-    update,
-    updatePlatform,
-    add,
-    grant,
-    resetPassword
-  } from "@/api/system/user";
-  import {getDeptTree, getDeptLazyTree} from "@/api/system/dept";
-  import {getRoleTree} from "@/api/system/role";
-  import {getPostList} from "@/api/system/post";
-  import {mapGetters} from "vuex";
-  import website from '@/config/website';
-  import {getToken} from '@/util/auth';
-
-  export default {
-    data() {
-      const validatePass = (rule, value, callback) => {
-        if (value === '') {
-          callback(new Error('请输入密码'));
-        } else {
-          callback();
-        }
-      };
-      const validatePass2 = (rule, value, callback) => {
-        if (value === '') {
-          callback(new Error('请再次输入密码'));
-        } else if (value !== this.form.password) {
-          callback(new Error('两次输入密码不一致!'));
-        } else {
-          callback();
-        }
-      };
-      return {
-        form: {},
-        search:{},
-        roleBox: false,
-        excelBox: false,
-        platformBox: false,
-        initFlag: true,
-        selectionList: [],
-        query: {},
-        loading: true,
-        platformLoading: false,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        platformPage: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        init: {
-          roleTree: [],
-          deptTree: [],
-        },
-        props: {
-          label: "title",
-          value: "key"
-        },
-        roleGrantList: [],
-        roleTreeObj: [],
-        treeDeptId: '',
-        treeData: [],
-        treeOption: {
-          nodeKey: 'id',
-          lazy: true,
-          treeLoad: function (node, resolve) {
-            const parentId = (node.level === 0) ? 0 : node.data.id;
-            getDeptLazyTree(parentId).then(res => {
-              resolve(res.data.data.map(item => {
-                return {
-                  ...item,
-                  leaf: !item.hasChildren
-                }
-              }))
-            });
-          },
-          addBtn: false,
-          menu: false,
-          size: 'small',
-          props: {
-            labelText: '标题',
-            label: 'title',
-            value: 'value',
-            children: 'children'
-          }
-        },
-        option: {
-          height: 'auto',
-          calcHeight: 80,
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          //dialogType: 'drawer',
-          dialogClickModal: false,
-          column: [
-            {
-              label: "登录账号",
-              prop: "account",
-              search: true,
-              display: false
-            },
-            {
-              label: "所属租户",
-              prop: "tenantName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "用户姓名",
-              prop: "realName",
-              search: true,
-              display: false
-            },
-            {
-              label: "所属角色",
-              prop: "roleName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "所属部门",
-              prop: "deptName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "用户平台",
-              prop: "userTypeName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "用户平台",
-              type: "select",
-              dicUrl: "/api/blade-system/dict/dictionary?code=user_type",
-              props: {
-                label: "dictValue",
-                value: "dictKey"
-              },
-              dataType: "number",
-              search: true,
-              hide: true,
-              display: false,
-              prop: "userType",
-              rules: [{
-                required: true,
-                message: "请选择用户平台",
-                trigger: "blur"
-              }]
-            },
-          ],
-          group: [
-            {
-              label: '基础信息',
-              prop: 'baseInfo',
-              icon: 'el-icon-user-solid',
-              column: [
-                {
-                  label: "所属租户",
-                  prop: "tenantId",
-                  type: "tree",
-                  dicUrl: "/api/blade-system/tenant/select",
-                  props: {
-                    label: "tenantName",
-                    value: "tenantId"
-                  },
-                  hide: !website.tenantMode,
-                  addDisplay: website.tenantMode,
-                  editDisplay: website.tenantMode,
-                  viewDisplay: website.tenantMode,
-                  rules: [{
-                    required: true,
-                    message: "请输入所属租户",
-                    trigger: "click"
-                  }],
-                  span: 24,
-                },
-                {
-                  label: "登录账号",
-                  prop: "account",
-                  rules: [{
-                    required: true,
-                    message: "请输入登录账号",
-                    trigger: "blur"
-                  }],
-                },
-                {
-                  label: "用户平台",
-                  type: "select",
-                  dicUrl: "/api/blade-system/dict/dictionary?code=user_type",
-                  props: {
-                    label: "dictValue",
-                    value: "dictKey"
-                  },
-                  dataType: "number",
-                  slot: true,
-                  prop: "userType",
-                  rules: [{
-                    required: true,
-                    message: "请选择用户平台",
-                    trigger: "blur"
-                  }]
-                },
-                {
-                  label: '密码',
-                  prop: 'password',
-                  hide: true,
-                  editDisplay: false,
-                  viewDisplay: false,
-                  rules: [{required: true, validator: validatePass, trigger: 'blur'}]
-                },
-                {
-                  label: '确认密码',
-                  prop: 'password2',
-                  hide: true,
-                  editDisplay: false,
-                  viewDisplay: false,
-                  rules: [{required: true, validator: validatePass2, trigger: 'blur'}]
-                },
-              ]
-            },
-            {
-              label: '详细信息',
-              prop: 'detailInfo',
-              icon: 'el-icon-s-order',
-              column: [
-                {
-                  label: "用户昵称",
-                  prop: "name",
-                  hide: true,
-                  rules: [{
-                    required: true,
-                    message: "请输入用户昵称",
-                    trigger: "blur"
-                  }]
-                },
-                {
-                  label: "用户姓名",
-                  prop: "realName",
-                  rules: [{
-                    required: true,
-                    message: "请输入用户姓名",
-                    trigger: "blur"
-                  }, {
-                    min: 2,
-                    max: 5,
-                    message: '姓名长度在2到5个字符'
-                  }]
-                },
-                {
-                  label: "手机号码",
-                  prop: "phone",
-                  overHidden: true
-                },
-                {
-                  label: "电子邮箱",
-                  prop: "email",
-                  hide: true,
-                  overHidden: true
-                },
-                {
-                  label: "用户性别",
-                  prop: "sex",
-                  type: "select",
-                  dicData: [
-                    {
-                      label: "男",
-                      value: 1
-                    },
-                    {
-                      label: "女",
-                      value: 2
-                    },
-                    {
-                      label: "未知",
-                      value: 3
-                    }
-                  ],
-                  hide: true
-                },
-                {
-                  label: "用户生日",
-                  type: "date",
-                  prop: "birthday",
-                  format: "yyyy-MM-dd hh:mm:ss",
-                  valueFormat: "yyyy-MM-dd hh:mm:ss",
-                  hide: true
-                },
-                {
-                  label: "账号状态",
-                  prop: "statusName",
-                  hide: true,
-                  display: false
-                }
-              ]
-            },
-            {
-              label: '职责信息',
-              prop: 'dutyInfo',
-              icon: 'el-icon-s-custom',
-              column: [
-                {
-                  label: "用户编号",
-                  prop: "code",
-                },
-                {
-                  label: "所属角色",
-                  prop: "roleId",
-                  multiple: true,
-                  type: "tree",
-                  dicData: [],
-                  props: {
-                    label: "title"
-                  },
-                  checkStrictly: true,
-                  slot: true,
-                  rules: [{
-                    required: true,
-                    message: "请选择所属角色",
-                    trigger: "click"
-                  }]
-                },
-                {
-                  label: "所属部门",
-                  prop: "deptId",
-                  type: "tree",
-                  multiple: true,
-                  dicData: [],
-                  props: {
-                    label: "title"
-                  },
-                  checkStrictly: true,
-                  slot: true,
-                  rules: [{
-                    required: true,
-                    message: "请选择所属部门",
-                    trigger: "click"
-                  }]
-                },
-                {
-                  label: "所属岗位",
-                  prop: "postId",
-                  type: "tree",
-                  multiple: true,
-                  dicData: [],
-                  props: {
-                    label: "postName",
-                    value: "id"
-                  },
-                  rules: [{
-                    required: true,
-                    message: "请选择所属岗位",
-                    trigger: "click"
-                  }],
-                },
-              ]
-            },
-          ]
-        },
-        data: [],
-        platformQuery: {},
-        platformSelectionList: [],
-        platformData: [],
-        platformForm: {},
-        platformOption: {
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          dialogClickModal: false,
-          menuWidth: 120,
-          editBtnText: '配置',
-          column: [
-            {
-              label: "登录账号",
-              prop: "account",
-              search: true,
-              display: false
-            },
-            {
-              label: "所属租户",
-              prop: "tenantName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "用户姓名",
-              prop: "realName",
-              search: true,
-              display: false
-            },
-            {
-              label: "用户平台",
-              prop: "userTypeName",
-              slot: true,
-              display: false
-            },
-            {
-              label: "用户平台",
-              type: "select",
-              dicUrl: "/api/blade-system/dict/dictionary?code=user_type",
-              props: {
-                label: "dictValue",
-                value: "dictKey"
-              },
-              dataType: "number",
-              search: true,
-              hide: true,
-              display: false,
-              prop: "userType",
-              rules: [{
-                required: true,
-                message: "请选择用户平台",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "用户拓展",
-              prop: "userExt",
-              type: "textarea",
-              minRows: 8,
-              span: 24,
-              overHidden: true,
-              row: true,
-              hide: true,
-            },
-          ],
-        },
-        excelForm: {},
-        excelOption: {
-          submitBtn: false,
-          emptyBtn: false,
-          column: [
-            {
-              label: '模板上传',
-              prop: 'excelFile',
-              type: 'upload',
-              drag: true,
-              loadText: '模板上传中,请稍等',
-              span: 24,
-              propsHttp: {
-                res: 'data'
-              },
-              tip: '请上传 .xls,.xlsx 标准格式文件',
-              action: "/api/blade-user/import-user"
-            },
-            {
-              label: "数据覆盖",
-              prop: "isCovered",
-              type: "switch",
-              align: "center",
-              width: 80,
-              dicData: [
-                {
-                  label: "否",
-                  value: 0
-                },
-                {
-                  label: "是",
-                  value: 1
-                }
-              ],
-              value: 0,
-              slot: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择是否覆盖",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: '模板下载',
-              prop: 'excelTemplate',
-              formslot: true,
-              span: 24,
-            }
-          ]
-        }
-      };
-    },
-    watch: {
-      'form.tenantId'() {
-        if (this.form.tenantId !== '' && this.initFlag) {
-          this.initData(this.form.tenantId);
-        }
-      },
-      'excelForm.isCovered'() {
-        if (this.excelForm.isCovered !== '') {
-          const column = this.findObject(this.excelOption.column, "excelFile");
-          column.action = `/api/blade-user/import-user?isCovered=${this.excelForm.isCovered}`;
-        }
-      }
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.user_add, false),
-          viewBtn: this.vaildData(this.permission.user_view, false),
-          delBtn: this.vaildData(this.permission.user_delete, false),
-          editBtn: this.vaildData(this.permission.user_edit, false)
-        };
-      },
-      platformPermissionList() {
-        return {
-          addBtn: false,
-          viewBtn: false,
-          delBtn: false,
-          editBtn: this.vaildData(this.permission.user_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      },
-    },
-    mounted() {
-      // 非租户模式默认加载管理组数据
-      if (!website.tenantMode) {
-        this.initData(website.tenantId);
-      }
-    },
-    methods: {
-      nodeClick(data) {
-        this.treeDeptId = data.id;
-        this.page.currentPage = 1;
-        this.onLoad(this.page);
-      },
-      initData(tenantId) {
-        getRoleTree(tenantId).then(res => {
-          const column = this.findObject(this.option.group, "roleId");
-          column.dicData = res.data.data;
-        });
-        getDeptTree(tenantId).then(res => {
-          const column = this.findObject(this.option.group, "deptId");
-          column.dicData = res.data.data;
-        });
-        getPostList(tenantId).then(res => {
-          const column = this.findObject(this.option.group, "postId");
-          column.dicData = res.data.data;
-        });
-      },
-      submitRole() {
-        const roleList = this.$refs.treeRole.getCheckedKeys().join(",");
-        grant(this.ids, roleList).then(() => {
-          this.roleBox = false;
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          this.onLoad(this.page);
-        });
-      },
-      rowSave(row, done, loading) {
-        row.deptId = row.deptId.join(",");
-        row.roleId = row.roleId.join(",");
-        row.postId = row.postId.join(",");
-        add(row).then(() => {
-          this.initFlag = false;
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        row.deptId = row.deptId.join(",");
-        row.roleId = row.roleId.join(",");
-        row.postId = row.postId.join(",");
-        update(row).then(() => {
-          this.initFlag = false;
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchReset() {
-        this.query = {};
-        this.treeDeptId = '';
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      handleReset() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择账号密码重置为123456?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return resetPassword(this.ids);
-          })
-          .then(() => {
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      handleGrant() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.roleTreeObj = [];
-        if (this.selectionList.length === 1) {
-          this.roleTreeObj = this.selectionList[0].roleId.split(",");
-        }
-        getRoleTree().then(res => {
-          this.roleGrantList = res.data.data;
-          this.roleBox = true;
-        });
-      },
-      handlePlatform() {
-        this.platformBox = true;
-      },
-      handleImport() {
-        this.excelBox = true;
-      },
-      uploadAfter(res, done, loading, column) {
-        window.console.log(column);
-        this.excelBox = false;
-        this.refreshChange();
-        done();
-      },
-      handleExport() {
-        this.$confirm("是否导出用户数据?", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        }).then(() => {
-          window.open(`/api/blade-user/export-user?${this.website.tokenHeader}=${getToken()}&account=${this.search.account}&realName=${this.search.realName}`);
-        });
-      },
-      handleTemplate() {
-        window.open(`/api/blade-user/export-template?${this.website.tokenHeader}=${getToken()}`);
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getUser(this.form.id).then(res => {
-            this.form = res.data.data;
-            if(this.form.hasOwnProperty("deptId")){
-              this.form.deptId = this.form.deptId.split(",");
-            }
-            if(this.form.hasOwnProperty("roleId")){
-              this.form.roleId = this.form.roleId.split(",");
-            }
-            if(this.form.hasOwnProperty("postId")){
-              this.form.postId = this.form.postId.split(",");
-            }
-          });
-        }
-        this.initFlag = true;
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      onLoad(page, params = {}) {
-        this.loading = true;
-        getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
-          const data = res.data.data;
-          this.page.total = data.total;
-          this.data = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      platformRowUpdate(row, index, done, loading) {
-        updatePlatform(row.id, row.userType, row.userExt).then(() => {
-          this.platformOnLoad(this.platformPage);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      platformBeforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getUserPlatform(this.platformForm.id).then(res => {
-            this.platformForm = res.data.data;
-          });
-        }
-        done();
-      },
-      platformSearchReset() {
-        this.platformQuery = {};
-        this.platformOnLoad(this.platformPage);
-      },
-      platformSearchChange(params, done) {
-        this.platformQuery = params;
-        this.platformPage.currentPage = 1;
-        this.platformOnLoad(this.platformPage, params);
-        done();
-      },
-      platformSelectionChange(list) {
-        this.platformSelectionList = list;
-      },
-      platformSelectionClear() {
-        this.platformSelectionList = [];
-        this.$refs.platformCrud.toggleSelection();
-      },
-      platformCurrentChange(currentPage) {
-        this.platformPage.currentPage = currentPage;
-      },
-      platformSizeChange(pageSize) {
-        this.platformPage.pageSize = pageSize;
-      },
-      platformRefreshChange() {
-        this.platformOnLoad(this.platformPage, this.platformQuery);
-      },
-      platformOnLoad(page, params = {}) {
-        this.platformLoading = true;
-        getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
-          const data = res.data.data;
-          this.platformPage.total = data.total;
-          this.platformData = data.records;
-          this.platformLoading = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-  .box {
-    height: 800px;
-  }
-
-  .el-scrollbar {
-    height: 100%;
-  }
-
-  .box .el-scrollbar__wrap {
-    overflow: scroll;
-  }
-</style>

+ 0 - 94
src/views/system/userinfo.vue

@@ -1,94 +0,0 @@
-<template>
-  <div>
-    <basic-container>
-      <avue-form :option="option"
-                 v-model="form"
-                 @tab-click="handleTabClick"
-                 @submit="handleSubmit"></avue-form>
-    </basic-container>
-  </div>
-</template>
-
-<script>
-  import option from "@/option/user/info";
-  import {getUserInfo, updateInfo, updatePassword} from "@/api/system/user";
-  import md5 from 'js-md5';
-  import func from "@/util/func";
-
-
-  export default {
-    data() {
-      return {
-        index: 0,
-        option: option,
-        form: {}
-      };
-    },
-    created() {
-      this.handleWitch();
-    },
-    methods: {
-      handleSubmit(form, done) {
-        if (this.index === 0) {
-          updateInfo(form).then(res => {
-            if (res.data.success) {
-              this.$message({
-                type: "success",
-                message: "修改信息成功!"
-              });
-            } else {
-              this.$message({
-                type: "error",
-                message: res.data.msg
-              });
-            }
-            done();
-          }, error => {
-            window.console.log(error);
-            done();
-          })
-        } else {
-          updatePassword(md5(form.oldPassword), md5(form.newPassword), md5(form.newPassword1)).then(res => {
-            if (res.data.success) {
-              this.$message({
-                type: "success",
-                message: "修改密码成功!"
-              });
-            } else {
-              this.$message({
-                type: "error",
-                message: res.data.msg
-              });
-            }
-            done();
-          }, error => {
-            window.console.log(error);
-            done();
-          })
-        }
-      },
-      handleWitch() {
-        if (this.index === 0) {
-          getUserInfo().then(res => {
-            const user = res.data.data;
-            this.form = {
-              id: user.id,
-              avatar: user.avatar,
-              name: user.name,
-              realName: user.realName,
-              phone: user.phone,
-              email: user.email,
-            }
-          });
-        }
-      },
-      handleTabClick(tabs) {
-        this.index = func.toInt(tabs.index);
-        this.handleWitch();
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 46
src/views/util/affix.vue

@@ -1,46 +0,0 @@
-<template>
-  <div class="affix">
-    <avue-affix id="avue-view">
-      <span class="affix-affix">固定在最顶部</span>
-    </avue-affix>
-    <div class="affix-line"></div>
-    <avue-affix id="avue-view"
-                :offset-top="50">
-      <span class="affix-affix">固定在距离顶部 50px 的位置</span>
-    </avue-affix>
-    <div class="affix-line"></div>
-    <avue-affix id="avue-view"
-                :offset-top="100">
-      <span class="affix-affix">固定在距离顶部 100px 的位置</span>
-    </avue-affix>
-    <div class="affix-line"></div>
-    <avue-affix id="avue-view"
-                :offset-top="150">
-      <span class="affix-affix">固定在距离顶部 150px 的位置</span>
-    </avue-affix>
-    <div style="height:2000px;">
-      <div style="padding:15px 20px;font-size:18px;">往下拉就会出现图钉</div>
-    </div>
-  </div>
-</template>
-
-<script>
-export default {};
-</script>
-
-<style lang="scss">
-.affix {
-  position: relative;
-  background-color: #fff;
-  &-affix {
-    display: inline-block;
-    color: #fff;
-    padding: 10px 30px;
-    text-align: center;
-    background: rgba(0, 153, 229, 0.9);
-  }
-  &-line {
-    height: 100px;
-  }
-}
-</style>

+ 0 - 22
src/views/util/cache.vue

@@ -1,22 +0,0 @@
-<template>
-  <basic-container>
-    <h3>这个页面会被 keep-alive</h3>
-    <el-tag>在下面的输入框输入任意字符后,切换到其它页面,再回到此页时输入框文字保留,证明被缓存</el-tag>
-    <br /> <br />
-    <el-tag>同时滚动下拉,返回时还会保持滚动条所在的位置</el-tag>
-    <br /> <br />
-    <el-input v-model="value" placeholder="input here" />
-
-    <div style="height:1000px;"></div>
-  </basic-container>
-</template>
-
-<script>
-export default {
-  data() {
-    return {
-      value: ""
-    };
-  }
-};
-</script>

+ 0 - 59
src/views/util/crud-form.vue

@@ -1,59 +0,0 @@
-<template>
-  <basic-container>
-    <h3>点击新增或编辑跳转到新的页面</h3>
-    <avue-crud :option="option"
-               :data="data">
-      <template slot="menuLeft">
-        <el-button type="primary"
-                   size="small"
-                   @click="handleForm()"
-                   icon="el-icon-plus">add</el-button>
-      </template>
-      <template slot="menu"
-                slot-scope="{row}">
-        <el-button size="small"
-                   type="text"
-                   @click="handleForm(row.id)"
-                   icon="el-icon-edit">edit</el-button>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-export default {
-  data() {
-    return {
-      option: {
-        addBtn: false,
-        editBtn: false,
-        column: [
-          {
-            label: "姓名",
-            prop: "name"
-          }
-        ]
-      },
-      data: [
-        {
-          id: 1,
-          name: "small"
-        }
-      ]
-    };
-  },
-  methods: {
-    handleForm(id) {
-      this.$router.push({
-        path: "/form-detail/index",
-        query: {
-          id: id
-        }
-      });
-    }
-  }
-};
-</script>
-
-<style>
-</style>

+ 0 - 199
src/views/util/data.vue

@@ -1,199 +0,0 @@
-<template>
-  <basic-container>
-    <h3>数据展示</h3>
-    <avue-data-pay :option="option"></avue-data-pay>
-  </basic-container>
-</template>
-
-<script>
-  export default {
-    data() {
-      return {
-        option: {
-          span: 8,
-          data: [
-            {
-              title: "后台模版",
-              src: "/img/bg/vip1.png",
-              money: "299",
-              dismoney: "199",
-              tip: "/永久",
-              color: "#808695",
-              subtext: "购买",
-              click: () => {
-                this.box = true;
-              },
-              list: [
-                {
-                  title: "点击体验",
-                  href: "https://cli1.avue.top",
-                  check: true
-                },
-                {
-                  title: "面向全屏幕尺寸的响应式适配能力",
-                  check: true
-                },
-                {
-                  title: "支持IE9+等系列浏览器",
-                  check: true
-                },
-                {
-                  title: "全新的前端错误日志监控机制",
-                  check: true
-                },
-                {
-                  title: "基于最新的avuex底层开发",
-                  check: true
-                },
-                {
-                  title: "前端路由动态服务端加载",
-                  check: true
-                },
-                {
-                  title: "灵活的多款主题自由配置",
-                  check: true
-                },
-                {
-                  title: "模块的可拆卸化,达到开箱即用",
-                  check: true
-                },
-                {
-                  title: "免费的私人git私服"
-                },
-                {
-                  title: "专属会员群"
-                },
-                {
-                  title: "前端最新干货分享"
-                },
-                {
-                  title: "赠送 Avue-cli脚手架文档(价值¥59.99)",
-                  href: "https://www.kancloud.cn/smallwei/avue"
-                },
-                {
-                  title: "赠送 Avue 修仙系列视频教程",
-                  href: "https://www.bilibili.com/video/av24644922",
-                  check: true
-                }
-              ]
-            },
-            {
-              title: "Avuex源码",
-              src: "/img/bg/vip2.png",
-              color: "#ffa820",
-              money: "999",
-              dismoney: "399",
-              tip: "/永久",
-              subtext: "购买",
-              click: () => {
-                this.box = true;
-              },
-              list: [
-                {
-                  title: "一键集成表格的导出excel,打印,等功能",
-                  check: true
-                },
-                {
-                  title: "底层代码可重用轻松对接多个UI框架",
-                  check: true
-                },
-                {
-                  title: "底层更加完善的开发错误调试机制",
-                  check: true
-                },
-                {
-                  title: "一套代码多个终端自适应",
-                  check: true
-                },
-                {
-                  title: "一键集成表格的导出excel,打印,等常用功能",
-                  check: true
-                },
-                {
-                  title: "表格的批量操作,表单的级联操作更加便捷",
-                  check: true
-                },
-                {
-                  title: "新增大量常用组件(搜索,选项卡)",
-                  check: true
-                },
-                {
-                  title: "新增大量全新可配置的骚属性",
-                  check: true
-                },
-                {
-                  title: "丰富的数据展示模版组件包",
-                  check: true
-                },
-                {
-                  title: "专属的开发者文档,助你快速掌握",
-                  check: true
-                },
-                {
-                  title: "赠送 Avue-cli脚手架文档(价值¥59.99)",
-                  href: "https://www.kancloud.cn/smallwei/avue",
-                  check: true
-                },
-                {
-                  title: "赠送 Avue 修仙系列视频教程",
-                  href: "https://www.bilibili.com/video/av24644922",
-                  check: true
-                }
-              ]
-            },
-            {
-              title: "全家桶",
-              src: "/img/bg/vip3.png",
-              color: "#ef4868",
-              money: "999.99",
-              dismoney: "399.99",
-              tip: "/永久",
-              subtext: "购买",
-              click: () => {
-                this.box = true;
-              },
-              list: [
-                {
-                  title: "授权商业化开发,永久更新授权使用",
-                  check: true
-                },
-                {
-                  title: "后期更新和新产品将全部免费",
-                  check: true
-                },
-                {
-                  title: "拥有avuex系列的全部特权和全部源码",
-                  check: true
-                },
-                {
-                  title: "免费的私人git私服",
-                  check: true
-                },
-                {
-                  title: "专属会员群",
-                  check: true
-                },
-                {
-                  title: "前端最新干货分享",
-                  check: true
-                },
-                {
-                  title: "赠送 Avue-cli脚手架文档(价值¥59.99)",
-                  href: "https://www.kancloud.cn/smallwei/avue",
-                  check: true
-                },
-                {
-                  title: "赠送 Avue 修仙系列视频教程",
-                  href: "https://www.bilibili.com/video/av24644922",
-                  check: true
-                }
-              ]
-            }
-          ]
-        }
-      };
-    }
-  };
-</script>
-<style>
-</style>

+ 0 - 359
src/views/util/demo/dict-classic.vue

@@ -1,359 +0,0 @@
-<template>
-  <basic-container>
-    <avue-crud
-      :option="option"
-      :table-loading="loading"
-      :data="data"
-      ref="crud"
-      v-model="form"
-      :permission="permissionList"
-      :before-open="beforeOpen"
-      :before-close="beforeClose"
-      @row-del="rowDel"
-      @row-update="rowUpdate"
-      @row-save="rowSave"
-      @search-change="searchChange"
-      @search-reset="searchReset"
-      @selection-change="selectionChange"
-      @current-change="currentChange"
-      @size-change="sizeChange"
-      @refresh-change="refreshChange"
-      @on-load="onLoad"
-    >
-      <template slot="menuLeft">
-        <el-button
-          type="danger"
-          size="small"
-          icon="el-icon-delete"
-          v-if="permission.dict_delete"
-          plain
-          @click="handleDelete"
-        >删 除
-        </el-button>
-      </template>
-      <template slot-scope="{row}" slot="isSealed">
-        <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-      </template>
-      <template slot-scope="scope" slot="menu">
-        <el-button
-          type="text"
-          icon="el-icon-check"
-          size="small"
-          @click.stop="handleAdd(scope.row,scope.index)"
-        >新增子项
-        </el-button>
-      </template>
-    </avue-crud>
-  </basic-container>
-</template>
-
-<script>
-  import {
-    getList,
-    remove,
-    update,
-    add,
-    getDict,
-    getDictTree
-  } from "@/api/system/dict";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        form: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        option: {
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          tree: true,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          menuWidth: 300,
-          dialogWidth: 880,
-          column: [
-            {
-              label: "字典编号",
-              prop: "code",
-              search: true,
-              span: 24,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典编号",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典名称",
-              prop: "dictValue",
-              search: true,
-              align: "center",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典名称",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "上级字典",
-              prop: "parentId",
-              type: "tree",
-              dicData: [],
-              hide: true,
-              props: {
-                label: "title"
-              },
-              rules: [
-                {
-                  required: false,
-                  message: "请选择上级字典",
-                  trigger: "click"
-                }
-              ]
-            },
-            {
-              label: "字典键值",
-              prop: "dictKey",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典键值",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典排序",
-              prop: "sort",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典排序",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "封存",
-              prop: "isSealed",
-              type: "select",
-              dicData: [
-                {
-                  label: "否",
-                  value: 0
-                },
-                {
-                  label: "是",
-                  value: 1
-                }
-              ],
-              slot: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择封存",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典备注",
-              prop: "remark",
-              search: true,
-              hide: true
-            }
-          ]
-        },
-        data: []
-      };
-    },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dict_add, false),
-          viewBtn: this.vaildData(this.permission.dict_view, false),
-          delBtn: this.vaildData(this.permission.dict_delete, false),
-          editBtn: this.vaildData(this.permission.dict_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    mounted() {
-      getDictTree().then(res => {
-        const column = this.findObject(this.optionChild.column, "parentId");
-        column.dicData = res.data.data;
-      });
-    },
-    methods: {
-      handleAdd(row) {
-        this.$refs.crud.value.code = row.code;
-        this.$refs.crud.value.parentId = row.id;
-        this.$refs.crud.option.column.filter(item => {
-          if (item.prop === "code") {
-            item.value = row.code;
-            item.addDisabled = true;
-          }
-          if (item.prop === "parentId") {
-            item.value = row.id;
-            item.addDisabled = true;
-          }
-        });
-        this.$refs.crud.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoad(this.page);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeClose(done) {
-        this.$refs.crud.tableForm = {};
-        this.$refs.crud.value.code = "";
-        this.$refs.crud.value.parentId = "";
-        this.$refs.crud.value.addDisabled = false;
-        this.$refs.crud.option.column.filter(item => {
-          if (item.prop === "code") {
-            item.value = "";
-            item.addDisabled = false;
-          }
-          if (item.prop === "parentId") {
-            item.value = "";
-            item.addDisabled = false;
-          }
-        });
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      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;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 469
src/views/util/demo/dict-horizontal.vue

@@ -1,469 +0,0 @@
-<template>
-  <div>
-    <basic-container>
-      <el-row>
-        <el-col :span="12">
-          <avue-crud
-            :option="option"
-            :table-loading="loading"
-            :data="dataParent"
-            :page="pageParent"
-            ref="crud"
-            v-model="formParent"
-            :permission="permissionList"
-            :before-open="beforeOpen"
-            @row-del="rowDel"
-            @row-update="rowUpdate"
-            @row-save="rowSave"
-            @row-click="handleRowClick"
-            @search-change="searchChange"
-            @search-reset="searchReset"
-            @selection-change="selectionChange"
-            @current-change="currentChange"
-            @size-change="sizeChange"
-            @refresh-change="refreshChange"
-            @on-load="onLoadParent"
-          >
-            <template slot="menuLeft">
-              <el-button
-                type="danger"
-                size="small"
-                icon="el-icon-delete"
-                v-if="permission.dict_delete"
-                plain
-                @click="handleDelete"
-              >删 除
-              </el-button>
-            </template>
-            <template slot-scope="{row}" slot="isSealed">
-              <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-            </template>
-          </avue-crud>
-        </el-col>
-        <el-col :span="12">
-          <avue-crud
-            :option="option"
-            :table-loading="loading"
-            :data="dataChild"
-            :page="pageChild"
-            ref="crudChild"
-            v-model="formChild"
-            :permission="permissionList"
-            :before-open="beforeOpenChild"
-            @row-del="rowDelChild"
-            @row-update="rowUpdateChild"
-            @row-save="rowSaveChild"
-            @search-change="searchChangeChild"
-            @search-reset="searchResetChild"
-            @selection-change="selectionChangeChild"
-            @current-change="currentChangeChild"
-            @size-change="sizeChangeChild"
-            @refresh-change="refreshChangeChild"
-            @on-load="onLoadChild"
-          >
-            <template slot="menuLeft">
-              <el-button
-                type="danger"
-                size="small"
-                icon="el-icon-delete"
-                v-if="permission.dict_delete"
-                plain
-                @click="handleDelete"
-              >删 除
-              </el-button>
-            </template>
-            <template slot-scope="{row}" slot="isSealed">
-              <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-            </template>
-          </avue-crud>
-        </el-col>
-      </el-row>
-    </basic-container>
-  </div>
-</template>
-
-<script>
-  import {
-    getParentList,
-    getChildList,
-    remove,
-    update,
-    add,
-    getDict,
-  } from "@/api/system/dict";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        parentId: 0,
-        formParent: {},
-        formChild: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        pageParent: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        pageChild: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        dataParent: [],
-        dataChild: [],
-        option: {
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          tree: true,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          menuWidth: 300,
-          dialogWidth: 880,
-          column: [
-            {
-              label: "字典编号",
-              prop: "code",
-              search: true,
-              span: 24,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典编号",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典键值",
-              prop: "dictKey",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典键值",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典名称",
-              prop: "dictValue",
-              search: true,
-              align: "center",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典名称",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典排序",
-              prop: "sort",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典排序",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "封存",
-              prop: "isSealed",
-              type: "select",
-              dicData: [
-                {
-                  label: "否",
-                  value: 0
-                },
-                {
-                  label: "是",
-                  value: 1
-                }
-              ],
-              slot: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择封存",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典备注",
-              prop: "remark",
-              search: true,
-              hide: true
-            }
-          ]
-        }
-      };
-    },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dict_add, false),
-          viewBtn: this.vaildData(this.permission.dict_view, false),
-          delBtn: this.vaildData(this.permission.dict_delete, false),
-          editBtn: this.vaildData(this.permission.dict_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleRowClick(row) {
-        this.parentId = row.id;
-        this.onLoadChild(this.pageChild);
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoadParent(this.pageParent);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.pageParent.currentPage = 1;
-        this.onLoadParent(this.pageParent, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formParent.id).then(res => {
-            this.formParent = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.pageParent.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.pageParent.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoadParent(this.page, this.query);
-      },
-      rowSaveChild(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdateChild(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDelChild(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchResetChild() {
-        this.query = {};
-        this.onLoadChild(this.pageChild);
-      },
-      searchChangeChild(params, done) {
-        this.query = params;
-        this.pageChild.currentPage = 1;
-        this.onLoadChild(this.pageChild, params);
-        done();
-      },
-      selectionChangeChild(list) {
-        this.selectionList = list;
-      },
-      selectionClearChild() {
-        this.selectionList = [];
-        this.$refs.crudChild.toggleSelection();
-      },
-      handleDeleteChild() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crudChild.toggleSelection();
-          });
-      },
-      beforeOpenChild(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formChild.id).then(res => {
-            this.formChild = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChangeChild(currentPage) {
-        this.pageChild.currentPage = currentPage;
-      },
-      sizeChangeChild(pageSize) {
-        this.pageChild.pageSize = pageSize;
-      },
-      refreshChangeChild() {
-        this.onLoadChild(this.pageChild, this.query);
-      },
-      onLoadParent(page, params = {}) {
-        this.loading = true;
-        getParentList(
-          page.currentPage,
-          page.pageSize,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageParent.total = data.total;
-          this.dataParent = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      onLoadChild(page, params = {}) {
-        this.loading = true;
-        getChildList(
-          page.currentPage,
-          page.pageSize,
-          this.parentId,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageChild.total = data.total;
-          this.dataChild = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 474
src/views/util/demo/dict-vertical.vue

@@ -1,474 +0,0 @@
-<template>
-  <div>
-    <basic-container>
-      <el-row>
-        <el-col :span="24">
-          <avue-crud
-            :option="option"
-            :table-loading="loading"
-            :data="dataParent"
-            :page="pageParent"
-            ref="crud"
-            v-model="formParent"
-            :permission="permissionList"
-            :before-open="beforeOpen"
-            @row-del="rowDel"
-            @row-update="rowUpdate"
-            @row-save="rowSave"
-            @row-click="handleRowClick"
-            @search-change="searchChange"
-            @search-reset="searchReset"
-            @selection-change="selectionChange"
-            @current-change="currentChange"
-            @size-change="sizeChange"
-            @refresh-change="refreshChange"
-            @on-load="onLoadParent"
-          >
-            <template slot="menuLeft">
-              <el-button
-                type="danger"
-                size="small"
-                icon="el-icon-delete"
-                v-if="permission.dict_delete"
-                plain
-                @click="handleDelete"
-              >删 除
-              </el-button>
-            </template>
-            <template slot-scope="{row}" slot="isSealed">
-              <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-            </template>
-          </avue-crud>
-        </el-col>
-      </el-row>
-    </basic-container>
-    <basic-container>
-      <el-row>
-        <el-col :span="24">
-          <avue-crud
-            :option="option"
-            :table-loading="loading"
-            :data="dataChild"
-            :page="pageChild"
-            ref="crudChild"
-            v-model="formChild"
-            :permission="permissionList"
-            :before-open="beforeOpenChild"
-            @row-del="rowDelChild"
-            @row-update="rowUpdateChild"
-            @row-save="rowSaveChild"
-            @search-change="searchChangeChild"
-            @search-reset="searchResetChild"
-            @selection-change="selectionChangeChild"
-            @current-change="currentChangeChild"
-            @size-change="sizeChangeChild"
-            @refresh-change="refreshChangeChild"
-            @on-load="onLoadChild"
-          >
-            <template slot="menuLeft">
-              <el-button
-                type="danger"
-                size="small"
-                icon="el-icon-delete"
-                v-if="permission.dict_delete"
-                plain
-                @click="handleDelete"
-              >删 除
-              </el-button>
-            </template>
-            <template slot-scope="{row}" slot="isSealed">
-              <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-            </template>
-          </avue-crud>
-        </el-col>
-      </el-row>
-    </basic-container>
-  </div>
-</template>
-
-<script>
-  import {
-    getParentList,
-    getChildList,
-    remove,
-    update,
-    add,
-    getDict,
-  } from "@/api/system/dict";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        parentId: 0,
-        formParent: {},
-        formChild: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        pageParent: {
-          pageSize: 5,
-          pageSizes: [5, 10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        pageChild: {
-          pageSize: 5,
-          pageSizes: [5, 10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        dataParent: [],
-        dataChild: [],
-        option: {
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          tree: true,
-          border: true,
-          index: true,
-          selection: true,
-          viewBtn: true,
-          height: 300,
-          menuWidth: 300,
-          dialogWidth: 880,
-          column: [
-            {
-              label: "字典编号",
-              prop: "code",
-              search: true,
-              span: 24,
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典编号",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典键值",
-              prop: "dictKey",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典键值",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典名称",
-              prop: "dictValue",
-              search: true,
-              align: "center",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典名称",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典排序",
-              prop: "sort",
-              type: "number",
-              rules: [
-                {
-                  required: true,
-                  message: "请输入字典排序",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "封存",
-              prop: "isSealed",
-              type: "select",
-              dicData: [
-                {
-                  label: "否",
-                  value: 0
-                },
-                {
-                  label: "是",
-                  value: 1
-                }
-              ],
-              slot: true,
-              rules: [
-                {
-                  required: true,
-                  message: "请选择封存",
-                  trigger: "blur"
-                }
-              ]
-            },
-            {
-              label: "字典备注",
-              prop: "remark",
-              search: true,
-              hide: true
-            }
-          ]
-        }
-      };
-    },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dict_add, false),
-          viewBtn: this.vaildData(this.permission.dict_view, false),
-          delBtn: this.vaildData(this.permission.dict_delete, false),
-          editBtn: this.vaildData(this.permission.dict_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    methods: {
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleRowClick(row) {
-        this.parentId = row.id;
-        this.onLoadChild(this.pageChild);
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoadParent(this.pageParent);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.pageParent.currentPage = 1;
-        this.onLoadParent(this.pageParent, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formParent.id).then(res => {
-            this.formParent = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.pageParent.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.pageParent.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoadParent(this.page, this.query);
-      },
-      rowSaveChild(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdateChild(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDelChild(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchResetChild() {
-        this.query = {};
-        this.onLoadChild(this.pageChild);
-      },
-      searchChangeChild(params, done) {
-        this.query = params;
-        this.pageChild.currentPage = 1;
-        this.onLoadChild(this.pageChild, params);
-        done();
-      },
-      selectionChangeChild(list) {
-        this.selectionList = list;
-      },
-      selectionClearChild() {
-        this.selectionList = [];
-        this.$refs.crudChild.toggleSelection();
-      },
-      handleDeleteChild() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crudChild.toggleSelection();
-          });
-      },
-      beforeOpenChild(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formChild.id).then(res => {
-            this.formChild = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChangeChild(currentPage) {
-        this.pageChild.currentPage = currentPage;
-      },
-      sizeChangeChild(pageSize) {
-        this.pageChild.pageSize = pageSize;
-      },
-      refreshChangeChild() {
-        this.onLoadChild(this.pageChild, this.query);
-      },
-      onLoadParent(page, params = {}) {
-        this.loading = true;
-        getParentList(
-          page.currentPage,
-          page.pageSize,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageParent.total = data.total;
-          this.dataParent = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      onLoadChild(page, params = {}) {
-        this.loading = true;
-        getChildList(
-          page.currentPage,
-          page.pageSize,
-          this.parentId,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageChild.total = data.total;
-          this.dataChild = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 454
src/views/util/demo/dict.vue

@@ -1,454 +0,0 @@
-<template>
-  <el-row>
-    <el-col :span="11">
-      <basic-container>
-        <el-card class="box-card">
-          <div slot="header" class="clearfix">
-            <span>字典列表</span>
-          </div>
-          <div class="clearfix">
-            <avue-crud
-              :option="optionParent"
-              :table-loading="loading"
-              :data="dataParent"
-              :page="pageParent"
-              ref="crud"
-              v-model="formParent"
-              :permission="permissionList"
-              :before-open="beforeOpen"
-              @row-del="rowDel"
-              @row-update="rowUpdate"
-              @row-save="rowSave"
-              @row-click="handleRowClick"
-              @search-change="searchChange"
-              @search-reset="searchReset"
-              @selection-change="selectionChange"
-              @current-change="currentChange"
-              @size-change="sizeChange"
-              @refresh-change="refreshChange"
-              @on-load="onLoadParent"
-            >
-              <template slot="menuLeft">
-                <el-button
-                  type="danger"
-                  size="small"
-                  icon="el-icon-delete"
-                  v-if="permission.dict_delete"
-                  plain
-                  @click="handleDelete"
-                >删 除
-                </el-button>
-              </template>
-              <template slot-scope="{row}" slot="isSealed">
-                <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-              </template>
-            </avue-crud>
-          </div>
-        </el-card>
-      </basic-container>
-    </el-col>
-    <el-col :span="13">
-      <basic-container>
-        <el-card class="box-card">
-          <div slot="header" class="clearfix">
-            <span>[{{dictValue}}] 字典详情</span>
-          </div>
-          <div class="clearfix">
-            <avue-crud
-              :option="optionChild"
-              :table-loading="loadingChild"
-              :data="dataChild"
-              ref="crudChild"
-              v-model="formChild"
-              :permission="permissionList"
-              :before-open="beforeOpenChild"
-              :before-close="beforeCloseChild"
-              @row-del="rowDelChild"
-              @row-update="rowUpdateChild"
-              @row-save="rowSaveChild"
-              @search-change="searchChangeChild"
-              @search-reset="searchResetChild"
-              @selection-change="selectionChangeChild"
-              @current-change="currentChangeChild"
-              @size-change="sizeChangeChild"
-              @refresh-change="refreshChangeChild"
-              @on-load="onLoadChild"
-            >
-              <template slot="menuLeft">
-                <el-button
-                  type="danger"
-                  size="small"
-                  icon="el-icon-delete"
-                  v-if="permission.dict_delete"
-                  plain
-                  @click="handleDelete"
-                >删 除
-                </el-button>
-              </template>
-              <template slot-scope="scope" slot="menu">
-                <el-button
-                  type="text"
-                  icon="el-icon-circle-plus-outline"
-                  size="small"
-                  @click.stop="handleAdd(scope.row,scope.index)"
-                  v-if="userInfo.role_name.includes('admin')"
-                >新增子项
-                </el-button>
-              </template>
-              <template slot-scope="{row}" slot="isSealed">
-                <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-              </template>
-            </avue-crud>
-          </div>
-        </el-card>
-      </basic-container>
-    </el-col>
-  </el-row>
-</template>
-
-<script>
-  import {
-    getParentList,
-    getChildList,
-    remove,
-    update,
-    add,
-    getDict,
-    getDictTree
-  } from "@/api/system/dict";
-  import {optionParent, optionChild} from "@/option/system/dict";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        dictValue: '暂无',
-        parentId: -1,
-        formParent: {},
-        formChild: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        loadingChild: true,
-        pageParent: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        pageChild: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        dataParent: [],
-        dataChild: [],
-        optionParent: optionParent,
-        optionChild: optionChild,
-      };
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dict_add, false),
-          delBtn: this.vaildData(this.permission.dict_delete, false),
-          editBtn: this.vaildData(this.permission.dict_edit, false),
-          viewBtn: false,
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    mounted() {
-      this.initData();
-    },
-    methods: {
-      initData() {
-        getDictTree().then(res => {
-          const column = this.findObject(this.optionChild.column, "parentId");
-          column.dicData = res.data.data;
-        });
-      },
-      handleAdd(row) {
-        this.$refs.crudChild.value.dictValue = "";
-        this.$refs.crudChild.value.dictKey = "";
-        this.$refs.crudChild.value.sort = 0;
-        this.$refs.crudChild.value.isSealed = 0;
-        this.$refs.crudChild.value.remark = "";
-        this.$refs.crudChild.value.parentId = row.id;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "parentId") {
-            item.value = row.id;
-          }
-        });
-        this.$refs.crudChild.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        const form = {
-          ...row,
-          dictKey: -1,
-        };
-        add(form).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          this.onLoadChild(this.pageChild);
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleRowClick(row) {
-        this.query = {};
-        this.parentId = row.id;
-        this.dictValue = row.dictValue;
-        this.$refs.crudChild.value.code = row.code;
-        this.$refs.crudChild.value.parentId = row.id;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "code") {
-            item.value = row.code;
-          }
-          if (item.prop === "parentId") {
-            item.value = row.id;
-          }
-        });
-        this.onLoadChild(this.pageChild);
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoadParent(this.pageParent);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.pageParent.currentPage = 1;
-        this.onLoadParent(this.pageParent, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formParent.id).then(res => {
-            this.formParent = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.pageParent.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.pageParent.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoadParent(this.pageParent, this.query);
-      },
-      rowSaveChild(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdateChild(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDelChild(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchResetChild() {
-        this.query = {};
-        this.onLoadChild(this.pageChild);
-      },
-      searchChangeChild(params, done) {
-        this.query = params;
-        this.pageChild.currentPage = 1;
-        this.onLoadChild(this.pageChild, params);
-        done();
-      },
-      selectionChangeChild(list) {
-        this.selectionList = list;
-      },
-      selectionClearChild() {
-        this.selectionList = [];
-        this.$refs.crudChild.toggleSelection();
-      },
-      handleDeleteChild() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crudChild.toggleSelection();
-          });
-      },
-      beforeOpenChild(done, type) {
-        if (["add", "edit"].includes(type)) {
-          this.initData();
-        }
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formChild.id).then(res => {
-            this.formChild = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeCloseChild(done) {
-        this.$refs.crudChild.value.parentId = this.parentId;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "parentId") {
-            item.value = this.parentId;
-          }
-        });
-        done();
-      },
-      currentChangeChild(currentPage) {
-        this.pageChild.currentPage = currentPage;
-      },
-      sizeChangeChild(pageSize) {
-        this.pageChild.pageSize = pageSize;
-      },
-      refreshChangeChild() {
-        this.onLoadChild(this.pageChild, this.query);
-      },
-      onLoadParent(page, params = {}) {
-        this.loading = true;
-        getParentList(
-          page.currentPage,
-          page.pageSize,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageParent.total = data.total;
-          this.dataParent = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      onLoadChild(page, params = {}) {
-        this.loadingChild = true;
-        getChildList(
-          page.currentPage,
-          page.pageSize,
-          this.parentId,
-          Object.assign(params, this.query)
-        ).then(res => {
-          this.dataChild = res.data.data;
-          this.loadingChild = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>
-

+ 0 - 447
src/views/util/demo/dictbiz.vue

@@ -1,447 +0,0 @@
-<template>
-  <el-row>
-    <el-col :span="11">
-      <basic-container>
-        <el-card class="box-card">
-          <div slot="header" class="clearfix">
-            <span>业务字典列表</span>
-          </div>
-          <div class="clearfix">
-            <avue-crud
-              :option="optionParent"
-              :table-loading="loading"
-              :data="dataParent"
-              :page="pageParent"
-              ref="crud"
-              v-model="formParent"
-              :permission="permissionList"
-              :before-open="beforeOpen"
-              @row-del="rowDel"
-              @row-update="rowUpdate"
-              @row-save="rowSave"
-              @row-click="handleRowClick"
-              @search-change="searchChange"
-              @search-reset="searchReset"
-              @selection-change="selectionChange"
-              @current-change="currentChange"
-              @size-change="sizeChange"
-              @refresh-change="refreshChange"
-              @on-load="onLoadParent"
-            >
-              <template slot="menuLeft">
-                <el-button
-                  type="danger"
-                  size="small"
-                  icon="el-icon-delete"
-                  v-if="permission.dict_delete"
-                  plain
-                  @click="handleDelete"
-                >删 除
-                </el-button>
-              </template>
-              <template slot-scope="{row}" slot="isSealed">
-                <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-              </template>
-            </avue-crud>
-          </div>
-        </el-card>
-      </basic-container>
-    </el-col>
-    <el-col :span="13">
-      <basic-container>
-        <el-card class="box-card">
-          <div slot="header" class="clearfix">
-            <span>[{{dictValue}}] 业务字典详情</span>
-          </div>
-          <div class="clearfix">
-            <avue-crud
-              :option="optionChild"
-              :table-loading="loadingChild"
-              :data="dataChild"
-              ref="crudChild"
-              v-model="formChild"
-              :permission="permissionList"
-              :before-open="beforeOpenChild"
-              :before-close="beforeCloseChild"
-              @row-del="rowDelChild"
-              @row-update="rowUpdateChild"
-              @row-save="rowSaveChild"
-              @search-change="searchChangeChild"
-              @search-reset="searchResetChild"
-              @selection-change="selectionChangeChild"
-              @current-change="currentChangeChild"
-              @size-change="sizeChangeChild"
-              @refresh-change="refreshChangeChild"
-              @on-load="onLoadChild"
-            >
-              <template slot="menuLeft">
-                <el-button
-                  type="danger"
-                  size="small"
-                  icon="el-icon-delete"
-                  v-if="permission.dict_delete"
-                  plain
-                  @click="handleDelete"
-                >删 除
-                </el-button>
-              </template>
-              <template slot-scope="scope" slot="menu">
-                <el-button
-                  type="text"
-                  icon="el-icon-circle-plus-outline"
-                  size="small"
-                  @click.stop="handleAdd(scope.row,scope.index)"
-                  v-if="userInfo.role_name.includes('admin')"
-                >新增子项
-                </el-button>
-              </template>
-              <template slot-scope="{row}" slot="isSealed">
-                <el-tag>{{row.isSealed===0?'否':'是'}}</el-tag>
-              </template>
-            </avue-crud>
-          </div>
-        </el-card>
-      </basic-container>
-    </el-col>
-  </el-row>
-</template>
-
-<script>
-  import {
-    getParentList,
-    getChildList,
-    remove,
-    update,
-    add,
-    getDict,
-    getDictTree
-  } from "@/api/system/dictbiz";
-  import {optionParent, optionChild} from "@/option/system/dictbiz";
-  import {mapGetters} from "vuex";
-
-  export default {
-    data() {
-      return {
-        dictValue: '暂无',
-        parentId: -1,
-        formParent: {},
-        formChild: {},
-        selectionList: [],
-        query: {},
-        loading: true,
-        loadingChild: true,
-        pageParent: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        pageChild: {
-          pageSize: 10,
-          pageSizes: [10, 30, 50, 100, 200],
-          currentPage: 1,
-          total: 0
-        },
-        dataParent: [],
-        dataChild: [],
-        optionParent: optionParent,
-        optionChild: optionChild,
-      };
-    },
-    computed: {
-      ...mapGetters(["userInfo", "permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.dictbiz_add, false),
-          delBtn: this.vaildData(this.permission.dictbiz_delete, false),
-          editBtn: this.vaildData(this.permission.dictbiz_edit, false),
-          viewBtn: false,
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
-        });
-        return ids.join(",");
-      }
-    },
-    mounted() {
-      this.initData();
-    },
-    methods: {
-      initData() {
-        getDictTree().then(res => {
-          const column = this.findObject(this.optionChild.column, "parentId");
-          column.dicData = res.data.data;
-        });
-      },
-      handleAdd(row) {
-        this.$refs.crudChild.value.parentId = row.id;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "parentId") {
-            item.value = row.id;
-          }
-        });
-        this.$refs.crudChild.rowAdd();
-      },
-      rowSave(row, done, loading) {
-        const form = {
-          ...row,
-          dictKey: -1,
-        };
-        add(form).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadParent(this.pageParent);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      handleRowClick(row) {
-        this.query = {};
-        this.parentId = row.id;
-        this.dictValue = row.dictValue;
-        this.$refs.crudChild.value.code = row.code;
-        this.$refs.crudChild.value.parentId = row.id;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "code") {
-            item.value = row.code;
-          }
-          if (item.prop === "parentId") {
-            item.value = row.id;
-          }
-        });
-        this.onLoadChild(this.pageChild);
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoadParent(this.pageParent);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.pageParent.currentPage = 1;
-        this.onLoadParent(this.pageParent, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadParent(this.pageParent);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crud.toggleSelection();
-          });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formParent.id).then(res => {
-            this.formParent = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.pageParent.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.pageParent.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoadParent(this.pageParent, this.query);
-      },
-      rowSaveChild(row, done, loading) {
-        add(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdateChild(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoadChild(this.pageChild);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowDelChild(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(row.id);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-          });
-      },
-      searchResetChild() {
-        this.query = {};
-        this.onLoadChild(this.pageChild);
-      },
-      searchChangeChild(params, done) {
-        this.query = params;
-        this.pageChild.currentPage = 1;
-        this.onLoadChild(this.pageChild, params);
-        done();
-      },
-      selectionChangeChild(list) {
-        this.selectionList = list;
-      },
-      selectionClearChild() {
-        this.selectionList = [];
-        this.$refs.crudChild.toggleSelection();
-      },
-      handleDeleteChild() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
-          .then(() => {
-            return remove(this.ids);
-          })
-          .then(() => {
-            this.onLoadChild(this.pageChild);
-            this.$message({
-              type: "success",
-              message: "操作成功!"
-            });
-            this.$refs.crudChild.toggleSelection();
-          });
-      },
-      beforeOpenChild(done, type) {
-        if (["add", "edit"].includes(type)) {
-          this.initData();
-        }
-        if (["edit", "view"].includes(type)) {
-          getDict(this.formChild.id).then(res => {
-            this.formChild = res.data.data;
-          });
-        }
-        done();
-      },
-      beforeCloseChild(done) {
-        this.$refs.crudChild.value.parentId = this.parentId;
-        this.$refs.crudChild.option.column.filter(item => {
-          if (item.prop === "parentId") {
-            item.value = this.parentId;
-          }
-        });
-        done();
-      },
-      currentChangeChild(currentPage) {
-        this.pageChild.currentPage = currentPage;
-      },
-      sizeChangeChild(pageSize) {
-        this.pageChild.pageSize = pageSize;
-      },
-      refreshChangeChild() {
-        this.onLoadChild(this.pageChild, this.query);
-      },
-      onLoadParent(page, params = {}) {
-        this.loading = true;
-        getParentList(
-          page.currentPage,
-          page.pageSize,
-          Object.assign(params, this.query)
-        ).then(res => {
-          const data = res.data.data;
-          this.pageParent.total = data.total;
-          this.dataParent = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
-      },
-      onLoadChild(page, params = {}) {
-        this.loadingChild = true;
-        getChildList(
-          page.currentPage,
-          page.pageSize,
-          this.parentId,
-          Object.assign(params, this.query)
-        ).then(res => {
-          this.dataChild = res.data.data;
-          this.loadingChild = false;
-          this.selectionClear();
-        });
-      }
-    }
-  };
-</script>

+ 0 - 40
src/views/util/form-detail.vue

@@ -1,40 +0,0 @@
-<template>
-  <basic-container>
-    <h3>{{$route.query.id?'编辑':'新增'}}</h3>
-    <avue-form :option="option"
-               v-model="form">
-      <template slot="menuForm">
-        <el-button icon="el-icon-back"
-                   @click="handleBack()">返 回</el-button>
-      </template>
-    </avue-form>
-  </basic-container>
-</template>
-
-<script>
-export default {
-  data() {
-    return {
-      form: {},
-      option: {
-        labelWidth: 110,
-        column: [
-          {
-            label: "姓名",
-            prop: "name"
-          }
-        ]
-      }
-    };
-  },
-  methods: {
-    handleBack() {
-      this.$router.$avueRouter.closeTag();
-      this.$router.back();
-    }
-  }
-};
-</script>
-
-<style>
-</style>

+ 0 - 82
src/views/util/permission.vue

@@ -1,82 +0,0 @@
-<template>
-  <div>
-    <basic-container>
-      <h3>表格权限控制</h3>
-      <avue-crud ref="crud"
-                 :permission="permission"
-                 :option="option"
-                 :data="data">
-        <template slot="expand"
-                  slot-scope="scope">
-          {{scope}}
-        </template>
-      </avue-crud>
-    </basic-container>
-    <basic-container>
-      权限开关
-      <el-switch :active-value="false"
-                 :inactive-value="true"
-                 v-model="text"
-                 active-color="#13ce66"
-                 inactive-color="#ff4949">
-      </el-switch>
-      <p> 具体参考<a
-        href="https://avuex.avue.top/#/doc/crud-permission">https://avuex.avue.top/#/doc/crud-permission</a>
-      </p>
-    </basic-container>
-  </div>
-</template>
-
-<script>
-  export default {
-    data() {
-      return {
-        text: false,
-        permission: {},
-        option: {
-          expand: true,
-          column: [
-            {
-              label: "姓名",
-              prop: "name"
-            },
-            {
-              label: "年龄",
-              prop: "sex"
-            }
-          ]
-        },
-        data: [
-          {
-            id: 1,
-            name: "张三",
-            sex: 12
-          },
-          {
-            id: 2,
-            name: "李四",
-            sex: 20
-          }
-        ]
-      };
-    },
-    watch: {
-      text() {
-        if (this.text === true) {
-          this.permission = {
-            delBtn: false,
-            addBtn: false
-          };
-        } else {
-          this.permission = {
-            delBtn: true,
-            addBtn: true
-          };
-        }
-      }
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 122
src/views/util/store.vue

@@ -1,122 +0,0 @@
-<template>
-  <basic-container>
-    <h3>存储</h3>
-    <el-tag class="title"
-            size="small">基本读写删(持久化存储)
-    </el-tag>
-    <div class="box">
-      <el-button type="primary"
-                 size="small"
-                 @click="setItem({name:'username', value:'avuex'});">set('username', 'avuex')
-      </el-button>
-
-      <el-button type="success"
-                 size="small"
-                 @click="getItem({name:'username'});">get('username')
-      </el-button>
-
-      <el-button type="danger"
-                 size="small"
-                 @click="delItem({name:'username'});">remove('username')
-      </el-button>
-    </div>
-    <el-tag class="title"
-            size="small">设置session(session存储)
-    </el-tag>
-    <div class="box">
-      <el-button type="primary"
-                 size="small"
-                 @click="setItem({name:'username', value:'avuex',type:'session'});">set('username', 'avuex')
-      </el-button>
-
-      <el-button type="success"
-                 size="small"
-                 @click="getItem({name:'username',type:'session'});">get('username')
-      </el-button>
-
-      <el-button type="danger"
-                 size="small"
-                 @click="delItem({name:'username',type:'session'});">remove('username')
-      </el-button>
-    </div>
-    <el-tag class="title"
-            size="small">获取所有可以获得的数据
-    </el-tag>
-    <div class="box">
-      <el-button type="success"
-                 size="small"
-                 @click="getAll()">getAll(持久化存储)
-      </el-button>
-      <el-button type="success"
-                 size="small"
-                 @click="getAll({type:'session'})">getAll(session存储)
-      </el-button>
-      <el-button type="danger"
-                 size="small"
-                 @click="clearAll()">delAll(持久化存储)
-      </el-button>
-      <el-button type="danger"
-                 size="small"
-                 @click="clearAll({type:'session'})">delAll(session存储)
-      </el-button>
-    </div>
-  </basic-container>
-
-</template>
-
-<script>
-  import {
-    setStore,
-    getStore,
-    removeStore,
-    clearStore,
-    getAllStore
-  } from "@/util/store";
-
-  export default {
-    name: "store",
-    methods: {
-      setItem(params = {}) {
-        const {name, value, type} = params;
-        setStore({
-          name: name,
-          content: value,
-          type: type
-        });
-        this.$message(`设置数据 ${name} = ${value}`);
-      },
-      getItem(params = {}) {
-        const {name, type} = params;
-        const content = getStore({
-          name: name,
-          type: type
-        });
-        this.$message(`获取数据 ${name} = ${content}`);
-      },
-      delItem(params = {}) {
-        const {name, type} = params;
-        removeStore({name, type});
-        this.$message(`删除数据 ${name}`);
-      },
-      clearAll(params = {}) {
-        clearStore(params);
-        this.$message(`清除全部数据完成`);
-      },
-      getAll(params = {}) {
-        const list = getAllStore(params);
-        window.console.log(list);
-        this.$message(`结果已经打印到控制台`);
-      }
-    }
-  };
-</script>
-
-<style lang="scss">
-  .title {
-    margin-bottom: 10px;
-  }
-
-  .box {
-    margin-bottom: 20px;
-  }
-</style>

+ 0 - 129
src/views/util/table.vue

@@ -1,129 +0,0 @@
-<template>
-  <basic-container>
-    <h3>表格例子</h3>
-    <avue-crud :option="option"
-               :page.sync="page"
-               :data="data" />
-  </basic-container>
-</template>
-
-<script>
-  export default {
-    data() {
-      return {
-        page: {
-          total: 122
-        },
-        data: [
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          },
-          {
-            username: "smallwei",
-            name: "avue",
-            password: "123456",
-            newpassword: "123456",
-            date: "2019-01-01",
-            textarea: "这是一条很长很长很长很长很长很长很长很长的个性签名"
-          }
-        ],
-        option: {
-          column: [
-            {
-              label: "用户名",
-              prop: "username",
-              span: 14,
-              row: true
-            },
-            {
-              label: "姓名",
-              prop: "name",
-              span: 14,
-              row: true
-            },
-            {
-              label: "密码",
-              prop: "password",
-              type: "password",
-              span: 14,
-              row: true
-            },
-            {
-              label: "确认密码",
-              prop: "newpassword",
-              type: "password",
-              hide: true,
-              span: 14,
-              row: true
-            },
-            {
-              label: "申请日期",
-              prop: "date",
-              type: "date",
-              span: 14,
-              row: true
-            },
-            {
-              label: "个性签名",
-              prop: "textarea",
-              type: "textarea",
-              minRows: 8,
-              span: 24,
-              overHidden: true,
-              row: true
-            }
-          ]
-        }
-      };
-    }
-  };
-</script>
-
-<style>
-</style>

+ 0 - 27
src/views/util/tags.vue

@@ -1,27 +0,0 @@
-<template>
-  <basic-container>
-    <h3>标签</h3>
-    <el-button type="primary"
-               size="small"
-               @click="$router.push('/test/index')">打开一个页面
-    </el-button>
-    <el-button type="primary"
-               size="small"
-               @click="$router.$avueRouter.closeTag('/test/index')">关闭打开的页面
-    </el-button>
-    <el-button type="primary"
-               size="small"
-               @click="$router.$avueRouter.closeTag()">关闭本标签
-    </el-button>
-
-  </basic-container>
-</template>
-
-<script>
-  export default {
-    methods: {}
-  };
-</script>
-
-<style>
-</style>

+ 0 - 21
src/views/util/test.vue

@@ -1,21 +0,0 @@
-<template>
-  <div>
-    <basic-container>测试页</basic-container>
-  </div>
-</template>
-
-<script>
-  export default {
-    name: "wel",
-    data() {
-      return {};
-    },
-    computed: {},
-    created() {
-    },
-    methods: {}
-  };
-</script>
-
-<style scoped="scoped" lang="scss">
-</style>

+ 0 - 28
src/views/util/top.vue

@@ -1,28 +0,0 @@
-<template>
-  <div>
-    <div style="height:2000px;background-color:#fff;">
-      <div style="padding:15px 20px;font-size:18px;">往下拉就会出现返回菜单</div>
-    </div>
-    <avue-back-top id="avue-view"></avue-back-top>
-    <avue-back-top id="avue-view"
-                   :height="100"
-                   :bottom="200">
-      <div class="top">返回顶端</div>
-    </avue-back-top>
-  </div>
-</template>
-
-<script>
-export default {};
-</script>
-
-<style scoped>
-.top {
-  padding: 10px;
-  font-size: 14px;
-  background: rgba(0, 153, 229, 0.7);
-  color: #fff;
-  text-align: center;
-  border-radius: 2px;
-}
-</style>