eoss-ui 0.4.67 → 0.4.68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/lib/button-group.js +11 -11
  2. package/lib/button.js +11 -11
  3. package/lib/card.js +2 -2
  4. package/lib/cascader.js +2 -2
  5. package/lib/checkbox-group.js +12 -12
  6. package/lib/clients.js +2 -2
  7. package/lib/data-table-form.js +11 -12
  8. package/lib/data-table.js +11 -12
  9. package/lib/date-picker.js +11 -11
  10. package/lib/dialog.js +13 -16
  11. package/lib/enterprise.js +2 -2
  12. package/lib/eoss-ui.common.js +637 -2744
  13. package/lib/error-page.js +2 -2
  14. package/lib/flow-group.js +17 -15
  15. package/lib/flow-list.js +377 -1358
  16. package/lib/flow.js +20 -36
  17. package/lib/form.js +37 -37
  18. package/lib/handle-user.js +12 -12
  19. package/lib/handler.js +12 -12
  20. package/lib/icons.js +4 -4
  21. package/lib/index.js +1 -1
  22. package/lib/input-number.js +18 -18
  23. package/lib/input.js +43 -43
  24. package/lib/label.js +2 -2
  25. package/lib/login.js +110 -101
  26. package/lib/main.js +83 -72
  27. package/lib/menu.js +5 -2
  28. package/lib/nav.js +11 -11
  29. package/lib/notify.js +4 -4
  30. package/lib/page.js +18 -18
  31. package/lib/pagination.js +2 -2
  32. package/lib/player.js +23 -23
  33. package/lib/qr-code.js +13 -13
  34. package/lib/radio-group.js +12 -12
  35. package/lib/retrial-auth.js +12 -12
  36. package/lib/select-ganged.js +11 -11
  37. package/lib/select.js +14 -14
  38. package/lib/selector-panel.js +66 -56
  39. package/lib/selector.js +14 -14
  40. package/lib/sizer.js +12 -12
  41. package/lib/steps.js +11 -11
  42. package/lib/switch.js +11 -11
  43. package/lib/table-form.js +36 -36
  44. package/lib/tabs-panel.js +2 -2
  45. package/lib/tabs.js +11 -11
  46. package/lib/theme-chalk/index.css +1 -1
  47. package/lib/tips.js +19 -19
  48. package/lib/toolbar.js +2 -2
  49. package/lib/tree-group.js +11 -11
  50. package/lib/tree.js +12 -12
  51. package/lib/upload.js +12 -12
  52. package/lib/wujie.js +11 -11
  53. package/lib/wxlogin.js +11 -11
  54. package/package.json +1 -1
  55. package/packages/flow/src/processForm.vue +0 -3
  56. package/packages/flow-group/src/main.vue +4 -2
  57. package/packages/flow-list/src/main.vue +1 -99
  58. package/packages/main/src/main.vue +56 -39
  59. package/packages/main/src/message.vue +7 -8
  60. package/packages/menu/src/main.vue +3 -0
  61. package/packages/theme-chalk/lib/index.css +1 -1
  62. package/packages/theme-chalk/src/index.scss +0 -1
  63. package/src/index.js +1 -4
  64. package/lib/editor.js +0 -1345
  65. package/lib/theme-chalk/editor.css +0 -1
  66. package/packages/editor/index.js +0 -5
  67. package/packages/editor/src/color.vue +0 -148
  68. package/packages/editor/src/editor.vue +0 -25
  69. package/packages/editor/src/main.vue +0 -114
  70. package/packages/editor/src/minx.js +0 -213
  71. package/packages/editor/src/toolbar.vue +0 -224
  72. package/packages/flow-list/src/flow-table.vue +0 -441
  73. package/packages/theme-chalk/lib/editor.css +0 -1
  74. package/packages/theme-chalk/src/editor.scss +0 -94
@@ -365,7 +365,10 @@ export default {
365
365
  type: String,
366
366
  default: '/main'
367
367
  },
368
- setFirstAsDefault: Boolean,
368
+ setFirstAsDefault: {
369
+ type: Boolean,
370
+ default: true
371
+ },
369
372
  pathUrl: {
370
373
  type: String,
371
374
  default: '/primary'
@@ -641,8 +644,10 @@ export default {
641
644
  menuSuccess(res) {
642
645
  // this.menus
643
646
  this.menuType = 'custom';
644
- this.customMenu = res;
645
- this.setMenu(res);
647
+ if (res && res.length) {
648
+ this.customMenu = res;
649
+ this.setMenu(res);
650
+ }
646
651
  },
647
652
  //获取主题模板JSON
648
653
  getMainDetail(id) {
@@ -682,8 +687,10 @@ export default {
682
687
  if (_that.showDefault && _that.data === undefined) {
683
688
  _that.getMenu();
684
689
  } else if (_that.showDefault) {
685
- _that.menus = JSON.parse(JSON.stringify(_that.data));
686
- _that.setMenu(_that.data);
690
+ if (_that.data && _that.data.length) {
691
+ _that.menus = JSON.parse(JSON.stringify(_that.data));
692
+ _that.setMenu(_that.data);
693
+ }
687
694
  }
688
695
  })
689
696
  .catch((err) => {
@@ -838,7 +845,7 @@ export default {
838
845
  if (i === 'indexUrl') {
839
846
  this.homePage = results[i];
840
847
  if (this.isHomePage) {
841
- if (this.menus) {
848
+ if (this.menus && this.menus.length) {
842
849
  let ids = null;
843
850
  this.homePage && (ids = this.getId(this.menus, this.homePage));
844
851
  if (ids) {
@@ -995,26 +1002,43 @@ export default {
995
1002
  .ajax({ url: this.action, params: this.param ? this.param : {} })
996
1003
  .then((res) => {
997
1004
  if (res.rCode === 0) {
998
- this.menus = JSON.parse(JSON.stringify(res.results));
999
- let applicationid =
1000
- util.getParams('applicationid') ||
1001
- util.getParams('applicationId');
1002
- if (applicationid) {
1003
- let ids = this.getId(this.menus, applicationid);
1004
- if (ids) {
1005
- this.defaultActive = ids;
1006
- }
1007
- } else if (util.win.location.hash) {
1008
- let hash = util.win.location.hash;
1009
- if (hash) {
1010
- hash = hash.split('?')[0];
1011
- }
1012
- if (hash !== '#/' && hash !== '#/main') {
1013
- let ids = this.getId(this.menus, util.win.location.hash, true);
1005
+ if (res.results && res.results.length) {
1006
+ this.menus = JSON.parse(JSON.stringify(res.results));
1007
+ let applicationid =
1008
+ util.getParams('applicationid') ||
1009
+ util.getParams('applicationId');
1010
+ if (applicationid) {
1011
+ let ids = this.getId(this.menus, applicationid);
1014
1012
  if (ids) {
1015
1013
  this.defaultActive = ids;
1016
- this.navIds = ids;
1017
- this.setTitle(ids[0]);
1014
+ }
1015
+ } else if (util.win.location.hash) {
1016
+ let hash = util.win.location.hash;
1017
+ if (hash) {
1018
+ hash = hash.split('?')[0];
1019
+ }
1020
+ if (hash !== '#/' && hash !== '#/main') {
1021
+ let ids = this.getId(
1022
+ this.menus,
1023
+ util.win.location.hash,
1024
+ true
1025
+ );
1026
+ if (ids) {
1027
+ this.defaultActive = ids;
1028
+ this.navIds = ids;
1029
+ this.setTitle(ids[0]);
1030
+ }
1031
+ } else if (sessionStorage.getItem('jump') && this.history) {
1032
+ let ids = this.getId(
1033
+ this.menus,
1034
+ sessionStorage.getItem('jump'),
1035
+ true
1036
+ );
1037
+ if (ids) {
1038
+ this.defaultActive = ids;
1039
+ this.navIds = ids;
1040
+ this.setTitle(ids[0]);
1041
+ }
1018
1042
  }
1019
1043
  } else if (sessionStorage.getItem('jump') && this.history) {
1020
1044
  let ids = this.getId(
@@ -1028,21 +1052,12 @@ export default {
1028
1052
  this.setTitle(ids[0]);
1029
1053
  }
1030
1054
  }
1031
- } else if (sessionStorage.getItem('jump') && this.history) {
1032
- let ids = this.getId(
1033
- this.menus,
1034
- sessionStorage.getItem('jump'),
1035
- true
1036
- );
1037
- if (ids) {
1038
- this.defaultActive = ids;
1039
- this.navIds = ids;
1040
- this.setTitle(ids[0]);
1041
- }
1055
+ this.setTips(this.menus);
1056
+ store.set('nav', this.menus);
1057
+ this.setMenu(this.menus);
1058
+ } else {
1059
+ this.$message.error('未分配菜单权限,请联系管理员!');
1042
1060
  }
1043
- this.setTips(this.menus);
1044
- store.set('nav', this.menus);
1045
- this.setMenu(this.menus);
1046
1061
  } else {
1047
1062
  let msg = res.msg || '系统错误,请联系管理员!';
1048
1063
  this.$message.error(msg);
@@ -1541,7 +1556,9 @@ export default {
1541
1556
  this.active = [];
1542
1557
  this.defaultActive = [];
1543
1558
  this.tabs = [];
1544
- this.setMenu(this.menus);
1559
+ if (this.menus && this.menus.length) {
1560
+ this.setMenu(this.menus);
1561
+ }
1545
1562
  this.$nextTick(() => {
1546
1563
  this.reset = true;
1547
1564
  });
@@ -38,9 +38,7 @@
38
38
  </div>
39
39
  </el-card>
40
40
  <p class="es-msg-tips" v-if="loading">加载中...</p>
41
- <p class="es-msg-tips" v-if="noMore && count > 0">
42
- 没有更多了
43
- </p>
41
+ <p class="es-msg-tips" v-if="noMore && count > 0">没有更多了</p>
44
42
  </div>
45
43
  </el-scrollbar>
46
44
  </div>
@@ -100,6 +98,7 @@ export default {
100
98
  return this.msgs.length >= this.count;
101
99
  },
102
100
  disabled() {
101
+ console.log(this.loading, this.noMore);
103
102
  return this.loading || this.noMore;
104
103
  }
105
104
  },
@@ -145,7 +144,7 @@ export default {
145
144
  pageSize: this.pageSize
146
145
  }
147
146
  })
148
- .then(res => {
147
+ .then((res) => {
149
148
  if (res && res.rCode === 0) {
150
149
  this.pageCount = res.results.pageCount;
151
150
  this.loading = false;
@@ -160,7 +159,7 @@ export default {
160
159
  this.$message.error(msg);
161
160
  }
162
161
  })
163
- .catch(err => {
162
+ .catch((err) => {
164
163
  this.loading = false;
165
164
  if (err.message && err.message !== 'canceled') {
166
165
  this.$message.error(err.message);
@@ -177,7 +176,7 @@ export default {
177
176
  id: res.id
178
177
  }
179
178
  })
180
- .then(res => {
179
+ .then((res) => {
181
180
  if (res.rCode == 0) {
182
181
  this.count -= 1;
183
182
  this.msgs.splice(i, 1);
@@ -193,12 +192,12 @@ export default {
193
192
  .ajax({
194
193
  url: ignoreAllSysMsg
195
194
  })
196
- .then(res => {
195
+ .then((res) => {
197
196
  this.count = 0;
198
197
  this.msgs = [];
199
198
  this.$emit('ignore', { type: 'ignore', value: 'all' });
200
199
  })
201
- .catch(err => {
200
+ .catch((err) => {
202
201
  if (err.message && err.message !== 'canceled') {
203
202
  this.$message.error(err.message);
204
203
  }
@@ -196,6 +196,9 @@ export default {
196
196
  'es-dot-right': item.tips && typeof item.tips === 'boolean'
197
197
  }
198
198
  ],
199
+ attrs:{
200
+ title: item.text.length > 18 ? item.text : undefined,
201
+ },
199
202
  props:
200
203
  typeof item.tips === 'boolean' && item.tips
201
204
  ? {