eoss-ui 0.6.51 → 0.6.53

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 (76) hide show
  1. package/lib/button-group.js +58 -55
  2. package/lib/button.js +58 -55
  3. package/lib/checkbox-group.js +61 -58
  4. package/lib/data-table-form.js +58 -55
  5. package/lib/data-table.js +65 -62
  6. package/lib/date-picker.js +58 -55
  7. package/lib/dialog.js +58 -55
  8. package/lib/eoss-ui.common.js +422 -335
  9. package/lib/flow-group.js +58 -55
  10. package/lib/flow-list.js +87 -61
  11. package/lib/flow.js +187 -144
  12. package/lib/form.js +62 -59
  13. package/lib/handle-user.js +58 -55
  14. package/lib/handler.js +58 -55
  15. package/lib/icon.js +58 -55
  16. package/lib/index.js +1 -1
  17. package/lib/input-number.js +58 -55
  18. package/lib/input.js +59 -56
  19. package/lib/login.js +61 -58
  20. package/lib/main.js +126 -103
  21. package/lib/menu.js +1 -1
  22. package/lib/nav.js +61 -58
  23. package/lib/page.js +58 -55
  24. package/lib/pagination.js +58 -55
  25. package/lib/player.js +58 -55
  26. package/lib/qr-code.js +58 -55
  27. package/lib/radio-group.js +61 -58
  28. package/lib/retrial-auth.js +58 -55
  29. package/lib/select-ganged.js +59 -56
  30. package/lib/select.js +61 -57
  31. package/lib/selector-panel.js +61 -58
  32. package/lib/selector.js +58 -55
  33. package/lib/sizer.js +58 -55
  34. package/lib/steps.js +61 -58
  35. package/lib/switch.js +58 -55
  36. package/lib/table-form.js +58 -55
  37. package/lib/tabs.js +58 -55
  38. package/lib/theme-chalk/index.css +1 -1
  39. package/lib/theme-chalk/upload.css +1 -1
  40. package/lib/tips.js +61 -58
  41. package/lib/tree-group.js +58 -55
  42. package/lib/tree.js +61 -58
  43. package/lib/upload.js +72 -69
  44. package/lib/utils/util.js +54 -51
  45. package/lib/wujie.js +58 -55
  46. package/lib/wxlogin.js +58 -55
  47. package/package.json +2 -2
  48. package/packages/checkbox-group/src/main.vue +2 -2
  49. package/packages/data-table/src/main.vue +3 -3
  50. package/packages/flow/src/reset.vue +4 -6
  51. package/packages/flow/src/startTaskRead.vue +180 -136
  52. package/packages/flow-list/src/main.vue +25 -2
  53. package/packages/form/src/main.vue +3 -3
  54. package/packages/input/src/main.vue +2 -2
  55. package/packages/login/src/main.vue +2 -2
  56. package/packages/main/src/default/index.vue +7 -1
  57. package/packages/main/src/main.vue +4 -1
  58. package/packages/main/src/public/search.vue +8 -3
  59. package/packages/main/src/simplicity/apps.vue +2 -2
  60. package/packages/main/src/simplicity/index.vue +3 -3
  61. package/packages/main/src/simplicity/user.vue +2 -2
  62. package/packages/menu/src/main.vue +2 -2
  63. package/packages/nav/src/main.vue +2 -2
  64. package/packages/radio-group/src/main.vue +2 -2
  65. package/packages/select/src/main.vue +4 -3
  66. package/packages/select-ganged/src/main.vue +2 -2
  67. package/packages/selector-panel/src/main.vue +2 -2
  68. package/packages/steps/src/main.vue +2 -2
  69. package/packages/theme-chalk/lib/index.css +1 -1
  70. package/packages/theme-chalk/lib/upload.css +1 -1
  71. package/packages/theme-chalk/src/upload.scss +1 -0
  72. package/packages/tips/src/main.vue +2 -2
  73. package/packages/tree/src/main.vue +2 -2
  74. package/packages/upload/src/main.vue +18 -10
  75. package/src/index.js +1 -1
  76. package/src/utils/util.js +15 -12
@@ -12,126 +12,135 @@
12
12
  class="demo-dynamic"
13
13
  label-width="110px"
14
14
  >
15
- <div :style="`max-height: ${typeCode?'unset' : '290px'}; overflow-y: auto; margin-bottom: 10px`">
16
- <el-form-item
17
- prop="handleExplain"
18
- label="当前步骤"
19
- v-if="type === 'transfer'"
15
+ <div
16
+ :style="`max-height: ${
17
+ typeCode ? 'unset' : '290px'
18
+ }; overflow-y: auto; margin-bottom: 10px`"
20
19
  >
21
- <el-input readonly v-model="nextNode.nodeName"></el-input>
22
- </el-form-item>
23
- <el-form-item
24
- v-if="type == 'transfer' && transferInfo.isSinglePage"
25
- prop="handleExplain"
26
- label="意见"
27
- >
28
- <el-input
29
- v-model="nextNode.handleExplain"
30
- placeholder="请填写意见"
31
- ></el-input>
32
- </el-form-item>
33
- <el-form-item
34
- prop="nextUser"
35
- :label="
36
- type === 'transfer'
37
- ? '转办对象'
38
- : configInfo.isCdjxjTaskHandle == 'true'
39
- ? '接收人'
40
- : '办理用户'
41
- "
42
- >
43
- <SelectUser
44
- :nextUser="nextNode.nextUser"
45
- :options="userOptions"
46
- :multiple="type != 'transfer' ? multiple : false"
47
- :mix="type != 'transfer'"
48
- :selectUserList="selectUserList"
49
- :types="
50
- type == 'transfer'
51
- ? ['employee', 'persongroup']
52
- : ['employee', 'enterprise', 'department', 'persongroup']
20
+ <el-form-item
21
+ prop="handleExplain"
22
+ label="当前步骤"
23
+ v-if="type === 'transfer'"
24
+ >
25
+ <el-input readonly v-model="nextNode.nodeName"></el-input>
26
+ </el-form-item>
27
+ <el-form-item
28
+ v-if="type == 'transfer' && transferInfo.isSinglePage"
29
+ prop="handleExplain"
30
+ label="意见"
31
+ >
32
+ <el-input
33
+ v-model="nextNode.handleExplain"
34
+ placeholder="请填写意见"
35
+ ></el-input>
36
+ </el-form-item>
37
+ <el-form-item
38
+ prop="nextUser"
39
+ :label="
40
+ type === 'transfer'
41
+ ? '转办对象'
42
+ : configInfo.isCdjxjTaskHandle == 'true'
43
+ ? '接收人'
44
+ : '办理用户'
53
45
  "
54
- @change="changeSelectUser($event, 'nextUser')"
55
- :tabs="tabs"
56
- :where="{ type: 'user' }"
57
- />
58
- </el-form-item>
46
+ >
47
+ <SelectUser
48
+ :nextUser="nextNode.nextUser"
49
+ :options="userOptions"
50
+ :multiple="type != 'transfer' ? multiple : false"
51
+ :mix="type != 'transfer'"
52
+ :selectUserList="selectUserList"
53
+ :types="
54
+ type == 'transfer'
55
+ ? ['employee', 'persongroup']
56
+ : ['employee', 'enterprise', 'department', 'persongroup']
57
+ "
58
+ @change="changeSelectUser($event, 'nextUser')"
59
+ :tabs="tabs"
60
+ :where="{ type: 'user' }"
61
+ />
62
+ </el-form-item>
59
63
 
60
- <el-form-item
61
- v-if="configInfo.isCdjxjTaskHandle != 'true' && type != 'transfer'"
62
- prop="cy"
63
- label="常用群组"
64
- ><el-checkbox-group v-model="selectCheck">
65
- <el-checkbox
66
- @change="handleSelectCheck($event, item)"
67
- v-for="item in configInfo.groups"
68
- :label="item.name"
69
- :key="item.id"
70
- >{{ item.name }}</el-checkbox
64
+ <el-form-item
65
+ v-if="configInfo.isCdjxjTaskHandle != 'true' && type != 'transfer'"
66
+ prop="cy"
67
+ label="常用群组"
68
+ ><el-checkbox-group v-model="selectCheck">
69
+ <el-checkbox
70
+ @change="handleSelectCheck($event, item)"
71
+ v-for="item in configInfo.groups"
72
+ :label="item.name"
73
+ :key="item.id"
74
+ >{{ item.name }}</el-checkbox
75
+ >
76
+ </el-checkbox-group>
77
+ </el-form-item>
78
+ <el-form-item
79
+ v-if="configInfo.fyDoresult == 'true'"
80
+ prop="showDoresult"
81
+ label="流程意见"
82
+ ><el-radio v-model="nextNode.showDoresult" label="0">分阅</el-radio>
83
+ <el-radio v-model="nextNode.showDoresult" label="1">不分阅</el-radio>
84
+ </el-form-item>
85
+ <el-form-item
86
+ v-if="configInfo.fyeh == 'true'"
87
+ prop="isInHistory"
88
+ label="分阅记录"
89
+ ><el-radio v-model="nextNode.isInHistory" label="0">记录</el-radio>
90
+ <el-radio v-model="nextNode.isInHistory" label="1">不记录</el-radio>
91
+ </el-form-item>
92
+ <el-form-item
93
+ v-if="configInfo.download"
94
+ prop="isDownload"
95
+ label="打印下载文件"
96
+ ><el-radio v-model="nextNode.isDownload" label="0">允许</el-radio>
97
+ <el-radio v-model="nextNode.isDownload" label="1">不允许</el-radio>
98
+ </el-form-item>
99
+ <el-form-item
100
+ prop="handleExplain"
101
+ :label="configInfo.isCdjxjTaskHandle == 'true' ? '附言' : '办理说明'"
102
+ v-if="type != 'transfer'"
103
+ >
104
+ <el-input
105
+ v-model="nextNode.handleExplain"
106
+ placeholder="请填写办理说明"
107
+ ></el-input>
108
+ </el-form-item>
109
+ <el-form-item
110
+ v-if="configInfo.isCdjxjTaskHandle != 'true'"
111
+ prop="noticeType"
112
+ label="通知方式"
113
+ :rules="[
114
+ { required: false, message: `请选择通知方式`, trigger: 'blur' }
115
+ ]"
116
+ >
117
+ <el-checkbox-group
118
+ v-model="nextNode.noticeType"
119
+ style="display: contents"
71
120
  >
72
- </el-checkbox-group>
73
- </el-form-item>
74
- <el-form-item
75
- v-if="configInfo.fyDoresult == 'true'"
76
- prop="showDoresult"
77
- label="流程意见"
78
- ><el-radio v-model="nextNode.showDoresult" label="0">分阅</el-radio>
79
- <el-radio v-model="nextNode.showDoresult" label="1">不分阅</el-radio>
80
- </el-form-item>
81
- <el-form-item
82
- v-if="configInfo.fyeh == 'true'"
83
- prop="isInHistory"
84
- label="分阅记录"
85
- ><el-radio v-model="nextNode.isInHistory" label="0">记录</el-radio>
86
- <el-radio v-model="nextNode.isInHistory" label="1">不记录</el-radio>
87
- </el-form-item>
88
- <el-form-item
89
- v-if="configInfo.download"
90
- prop="isDownload"
91
- label="打印下载文件"
92
- ><el-radio v-model="nextNode.isDownload" label="0">允许</el-radio>
93
- <el-radio v-model="nextNode.isDownload" label="1">不允许</el-radio>
94
- </el-form-item>
95
- <el-form-item
96
- prop="handleExplain"
97
- :label="configInfo.isCdjxjTaskHandle == 'true' ? '附言' : '办理说明'"
98
- v-if="type != 'transfer'"
99
- >
100
- <el-input
101
- v-model="nextNode.handleExplain"
102
- placeholder="请填写办理说明"
103
- ></el-input>
104
- </el-form-item>
105
- <el-form-item
106
- v-if="configInfo.isCdjxjTaskHandle != 'true'"
107
- prop="noticeType"
108
- label="通知方式"
109
- :rules="[
110
- { required: false, message: `请选择通知方式`, trigger: 'blur' }
111
- ]"
112
- >
113
- <el-checkbox-group v-model="nextNode.noticeType" style="display:contents">
114
- <el-checkbox
115
- v-for="item of noticeList"
116
- :key="item.cciValue"
117
- :label="item.cciValue"
118
- :disabled="readOnlyNotificationType
121
+ <el-checkbox
122
+ v-for="item of noticeList"
123
+ :key="item.cciValue"
124
+ :label="item.cciValue"
125
+ :disabled="
126
+ readOnlyNotificationType
119
127
  ? readOnlyNotificationType.indexOf(item.cciValue) != -1
120
- : false"
121
- >
122
- {{ item.shortName }}
123
- </el-checkbox>
124
- </el-checkbox-group>
125
- </el-form-item>
126
- <el-form-item
127
- v-show="
128
- nextNode.noticeType.length != 0 &&
129
- configInfo.isCdjxjTaskHandle != 'true'
130
- "
131
- prop="nextNode"
132
- label="通知消息"
133
- >
134
- <es-input
128
+ : false
129
+ "
130
+ >
131
+ {{ item.shortName }}
132
+ </el-checkbox>
133
+ </el-checkbox-group>
134
+ </el-form-item>
135
+ <el-form-item
136
+ v-show="
137
+ nextNode.noticeType.length != 0 &&
138
+ configInfo.isCdjxjTaskHandle != 'true'
139
+ "
140
+ prop="nextNode"
141
+ label="通知消息"
142
+ >
143
+ <es-input
135
144
  style="
136
145
  border-color: #ccc;
137
146
  padding: 5px;
@@ -140,11 +149,11 @@
140
149
  "
141
150
  type="textarea"
142
151
  v-model="newsNoice"
143
- :readonly="notificationMessageReadOnly =='true'"
152
+ :readonly="notificationMessageReadOnly == 'true'"
144
153
  />
145
- <!-- <span>{{ newsInfo }}</span> -->
146
- </el-form-item>
147
- </div>
154
+ <!-- <span>{{ newsInfo }}</span> -->
155
+ </el-form-item>
156
+ </div>
148
157
  <el-form-item>
149
158
  <div style="text-align: right">
150
159
  <el-button type="primary" size="small" @click="submit('nextNode')">
@@ -162,6 +171,7 @@ import {
162
171
  taskReadHtml,
163
172
  toStartTaskRead,
164
173
  toTaskTransferIndex,
174
+ getNotificationMsg,
165
175
  taskTransfer,
166
176
  findCodeValues
167
177
  } from 'eoss-ui/src/config/api';
@@ -179,14 +189,18 @@ export default {
179
189
  type: { type: String, default: '' },
180
190
  option: { type: String, default: '' },
181
191
  typeCode: { type: String, default: '' },
182
- taskExamine: { type: Object, default: () => {} }
192
+ taskExamine: { type: Object, default: () => {} },
193
+ readParams: {
194
+ type: [Object,undefined],
195
+ default: undefined
196
+ },
183
197
  },
184
198
  data() {
185
199
  return {
186
200
  loading: false,
187
- newsNoice:'',
188
- readOnlyNotificationType:'',
189
- notificationMessageReadOnly:false,
201
+ newsNoice: '',
202
+ readOnlyNotificationType: '',
203
+ notificationMessageReadOnly: false,
190
204
  nextNode: {
191
205
  nextUser: [],
192
206
  userInfo: [],
@@ -236,13 +250,35 @@ export default {
236
250
  }
237
251
  },
238
252
  mounted() {
239
- this.newsNoice = this.newsInfo
253
+ this.newsNoice = this.newsInfo;
254
+ if(this.readParams){
255
+ this.getMessage()
256
+ }
240
257
  this.getFind();
241
- if(util.getStorage('mainConfig')){
242
- this.orgId = JSON.parse(util.getStorage('mainConfig')).userModel.orgId
258
+ if (util.getStorage('mainConfig')) {
259
+ this.orgId = JSON.parse(util.getStorage('mainConfig')).userModel.orgId;
243
260
  }
244
261
  },
245
262
  methods: {
263
+ //获取通知信息
264
+ getMessage() {
265
+ let params = {
266
+ appId: this.readParams.appId
267
+ };
268
+ util
269
+ .ajax({ url: getNotificationMsg, params, methods: 'post' })
270
+ .then((res) => {
271
+ if (res.status === 'success') {
272
+ this.newsNoice = res.message;
273
+ }
274
+ })
275
+ .catch((err) => {
276
+ this.loading = false;
277
+ if (err.message && err.message !== 'canceled') {
278
+ this.$message.error(err.message);
279
+ }
280
+ });
281
+ },
246
282
  toTaskTransfer() {
247
283
  const { opinion, pendingId, taskExamine } = this;
248
284
  let params = {
@@ -404,7 +440,10 @@ export default {
404
440
  util
405
441
  .ajax({
406
442
  url: findCodeValues,
407
- params: { ccCode: 'notification_type',userId:util.getStorage('userId') }
443
+ params: {
444
+ ccCode: 'notification_type',
445
+ userId: util.getStorage('userId')
446
+ }
408
447
  })
409
448
  .then((res) => {
410
449
  const { status, data } = res;
@@ -431,7 +470,7 @@ export default {
431
470
  // 转办提交
432
471
  subTaskTransfer() {
433
472
  const { choiceDeptId, choiceOrgId, bCode, bName } = this.taskExamine;
434
- const { opinion, pendingId, nextNode, newsNoice, multiple,type } = this;
473
+ const { opinion, pendingId, nextNode, newsNoice, multiple, type } = this;
435
474
  let params = {
436
475
  url: taskTransfer,
437
476
  data: {
@@ -439,9 +478,10 @@ export default {
439
478
  choiceOrgId,
440
479
  bCode,
441
480
  bName,
442
- nextUserId: multiple && type != 'transfer'
443
- ? nextNode.nextUser.join(',')
444
- : nextNode.nextUser,
481
+ nextUserId:
482
+ multiple && type != 'transfer'
483
+ ? nextNode.nextUser.join(',')
484
+ : nextNode.nextUser,
445
485
  opinion,
446
486
  pendingId,
447
487
  notificationType: nextNode.noticeType.join(','),
@@ -523,6 +563,9 @@ export default {
523
563
  fyeh != 'true' && delete params.isInHistory;
524
564
  !download && delete params.isDownload;
525
565
  isCdjxjTaskHandle == 'true' && delete params.noticeType;
566
+ if (this.readParams) {
567
+ params = { ...params, ...this.readParams };
568
+ }
526
569
  util
527
570
  .ajax({
528
571
  url: taskReadHtml,
@@ -567,13 +610,14 @@ export default {
567
610
  url: findSysCodes
568
611
  })
569
612
  .then((res) => {
570
- const { status, message,data } = res;
613
+ const { status, message, data } = res;
571
614
  this.loading = false;
572
615
  if (status === 'success') {
573
616
  this.nextNode.noticeType = message.split(',');
574
- if(data){
575
- this.notificationMessageReadOnly = data.notificationMessageReadOnly
576
- this.readOnlyNotificationType = data.readOnlyNotificationType
617
+ if (data) {
618
+ this.notificationMessageReadOnly =
619
+ data.notificationMessageReadOnly;
620
+ this.readOnlyNotificationType = data.readOnlyNotificationType;
577
621
  }
578
622
  } else {
579
623
  this.$message.error(message || '系统错误,请联系管理员!');
@@ -581,7 +625,7 @@ export default {
581
625
  this.getNodeType();
582
626
  if (this.type === 'transfer') {
583
627
  this.toTaskTransfer();
584
- } else {
628
+ } else if(!this.readParams) {
585
629
  this.toStartTaskRead();
586
630
  }
587
631
  })
@@ -124,6 +124,10 @@ export default {
124
124
  type: Array,
125
125
  default: () => []
126
126
  },
127
+ headFields: {
128
+ type: Array,
129
+ default: () => []
130
+ },
127
131
  contents: {
128
132
  type: Array,
129
133
  default() {
@@ -745,7 +749,9 @@ export default {
745
749
  : params.row.pendstate == 1
746
750
  ? 'green'
747
751
  : 'deepskyblue',
748
- cursor: this.hasCircularReadWithdrawAuthority?'pointer' :'unset'
752
+ cursor: this.hasCircularReadWithdrawAuthority
753
+ ? 'pointer'
754
+ : 'unset'
749
755
  },
750
756
  domProps: {
751
757
  innerHTML:
@@ -844,16 +850,33 @@ export default {
844
850
  };
845
851
  },
846
852
  content() {
853
+ const _that = this;
847
854
  let newContents = JSON.parse(JSON.stringify(this.contents));
848
855
  if (this.contents.indexOf('circular') != -1) {
849
856
  newContents = newContents.filter((item) => item != 'splitReading');
850
857
  }
851
858
  let contents = newContents.map((item) => {
852
859
  if (typeof item === 'string') {
860
+ let data = [];
861
+ if (_that.headFields.length > 0) {
862
+ _that.headFields.map((headFiled) => {
863
+ _that.theads[item].map((theadItem) => {
864
+ if (theadItem.field === headFiled.field) {
865
+ theadItem = headFiled;
866
+ data.push(theadItem);
867
+ }
868
+ });
869
+ });
870
+ _that.theads[item].map(x => {
871
+ if(x.type == 'handle'){
872
+ data.push(x);
873
+ }
874
+ })
875
+ }
853
876
  return {
854
877
  type: item,
855
878
  toolbar: this.toolbars[item],
856
- thead: this.theads[item],
879
+ thead: data.length > 0 ? data : this.theads[item],
857
880
  showFormBtn: false
858
881
  };
859
882
  } else {
@@ -2178,7 +2178,7 @@
2178
2178
  </template>
2179
2179
  <script>
2180
2180
  import { formContents } from 'eoss-ui/src/config/api.js';
2181
- import { debounce } from 'throttle-debounce';
2181
+ import { throttle } from 'throttle-debounce';
2182
2182
  import util from 'eoss-ui/src/utils/util';
2183
2183
  import rules from 'eoss-ui/src/utils/rules.js';
2184
2184
  const pageView = util.getParams('pageView');
@@ -2709,10 +2709,10 @@ export default {
2709
2709
  }
2710
2710
  },
2711
2711
  beforeCreate() {
2712
- this.getContent = debounce(500, () => {
2712
+ this.getContent = throttle(500, () => {
2713
2713
  this.getContents();
2714
2714
  });
2715
- this.getValue = debounce(500, () => {
2715
+ this.getValue = throttle(500, () => {
2716
2716
  this.getValues();
2717
2717
  });
2718
2718
  },
@@ -1,5 +1,5 @@
1
1
  <script>
2
- import { debounce } from 'throttle-debounce';
2
+ import { throttle } from 'throttle-debounce';
3
3
  import util from 'eoss-ui/src/utils/util';
4
4
  import rules from 'eoss-ui/src/utils/rules.js';
5
5
  export default {
@@ -125,7 +125,7 @@ export default {
125
125
  }
126
126
  },
127
127
  beforeCreate() {
128
- this.getData = debounce(500, (query, callback, isChange) => {
128
+ this.getData = throttle(500, (query, callback, isChange) => {
129
129
  this.getDatas(query, callback, isChange);
130
130
  });
131
131
  },
@@ -461,7 +461,7 @@
461
461
  </div>
462
462
  </template>
463
463
  <script>
464
- import { debounce } from 'throttle-debounce';
464
+ import { throttle } from 'throttle-debounce';
465
465
  import resetPassword from './resetPassword.vue';
466
466
  import store from 'eoss-ui/src/utils/store';
467
467
  import util from 'eoss-ui/src/utils/util';
@@ -998,7 +998,7 @@ export default {
998
998
  };
999
999
  },
1000
1000
  beforeCreate() {
1001
- this.setScale = debounce(300, () => {
1001
+ this.setScale = throttle(300, () => {
1002
1002
  util.setScale();
1003
1003
  });
1004
1004
  util.removeStorage([
@@ -1267,6 +1267,8 @@ export default {
1267
1267
  }
1268
1268
  } else if (item.url == url) {
1269
1269
  return item.id;
1270
+ } else if (item.url && url.indexOf(item.url) > -1) {
1271
+ return item.id;
1270
1272
  } else {
1271
1273
  if (item.url) {
1272
1274
  try {
@@ -1809,7 +1811,11 @@ export default {
1809
1811
  if (node.url) {
1810
1812
  this.selectPage = node.url;
1811
1813
  this.refresh = false;
1812
- this.handleJump(node.url, Number(node.urlopenmode), node);
1814
+ let type = Number(node.urlopenmode);
1815
+ if (type != 1) {
1816
+ this.drawer.visible = false;
1817
+ }
1818
+ this.handleJump(node.url, type, node);
1813
1819
  }
1814
1820
  },
1815
1821
  hasRouter(res, url) {
@@ -52,6 +52,7 @@ import Simplicity from './simplicity/index.vue';
52
52
  import MainDefault from './default/index.vue';
53
53
  import util from 'eoss-ui/src/utils/util';
54
54
  import WujieVue from 'wujie-vue2';
55
+ import { isArray } from 'lodash';
55
56
  export default {
56
57
  name: 'EsMain',
57
58
  inheritAttrs: false,
@@ -161,7 +162,9 @@ export default {
161
162
  this.$refs.main.handleRefresh(args);
162
163
  break;
163
164
  case 'jumpMenu':
164
- this.$refs.main.jumpMenu(args);
165
+ Array.isArray(args)
166
+ ? this.$refs.main.jumpMenu(...args)
167
+ : this.$refs.main.jumpMenu(args);
165
168
  break;
166
169
  case 'emit':
167
170
  const { origin, ...data } = args;
@@ -68,6 +68,7 @@
68
68
  :label="item.name"
69
69
  :name="item.id || String(index + 1)"
70
70
  :key="item.id"
71
+ lazy
71
72
  v-loading="loadings[item.id || String(index)]"
72
73
  element-loading-background="rgba(0, 0, 0, 0.01)"
73
74
  element-loading-text="加载中..."
@@ -139,7 +140,7 @@
139
140
  <script>
140
141
  import util from 'eoss-ui/src/utils/util';
141
142
  import { searchType } from 'eoss-ui/src/config/api.js';
142
- import { debounce } from 'throttle-debounce';
143
+ import { throttle } from 'throttle-debounce';
143
144
  export default {
144
145
  name: 'Search',
145
146
  components: {},
@@ -231,10 +232,12 @@ export default {
231
232
  }
232
233
  },
233
234
  beforeCreate() {
234
- this.handleSearchAll = debounce(500, (res) => {
235
+ this.handleSearchAll = throttle(500, (res) => {
236
+ console.log(res, 999);
235
237
  this.searchAll(res);
236
238
  });
237
- this.handleSearchd = debounce(500, (obj, index) => {
239
+ this.handleSearchd = throttle(500, (obj, index) => {
240
+ console.log(obj, index, 6666);
238
241
  this.handleSearch(obj, index, false);
239
242
  });
240
243
  },
@@ -319,6 +322,7 @@ export default {
319
322
  searchAll(keyWords) {
320
323
  for (let i = 0; i < this.types.length; i++) {
321
324
  let item = this.types[i];
325
+ console.log(item, 8888);
322
326
  if (keyWords && !this.hides.includes(item.name) && !item.hide) {
323
327
  if (item.name == '菜单' && this.menus.length) {
324
328
  this.isLoading = false;
@@ -379,6 +383,7 @@ export default {
379
383
  return records;
380
384
  },
381
385
  handleSearch(obj, index, reset) {
386
+ console.log(obj, reset, 77777);
382
387
  if (obj.pageNum < obj.pageCount && this.keyWords) {
383
388
  this.$set(this.loadings, obj.id || String(index), true);
384
389
  if (this.active == '0') {
@@ -192,7 +192,7 @@
192
192
 
193
193
  <script>
194
194
  import util from 'eoss-ui/src/utils/util';
195
- import { debounce } from 'throttle-debounce';
195
+ import { throttle } from 'throttle-debounce';
196
196
  import { recordUserApp } from 'eoss-ui/src/config/api.js';
197
197
  export default {
198
198
  name: 'Apps',
@@ -300,7 +300,7 @@ export default {
300
300
  }
301
301
  },
302
302
  beforeCreate() {
303
- this.getApps = debounce(500, () => {
303
+ this.getApps = throttle(500, () => {
304
304
  this.getApp();
305
305
  });
306
306
  },
@@ -1962,15 +1962,15 @@ export default {
1962
1962
  clearTimeout(this.sysMsgOut);
1963
1963
  }
1964
1964
  },
1965
- jumpMenu(res, close) {
1965
+ jumpMenu(res, close, params = {}) {
1966
1966
  let apps = res;
1967
- let param = null;
1967
+ let param = params;
1968
1968
  let reload = true;
1969
1969
  if (typeof res === 'string') {
1970
1970
  apps = res.split(',');
1971
1971
  } else if (typeof res === 'object') {
1972
1972
  apps = res.appCode.split(',');
1973
- param = res.param;
1973
+ res.param && (param = { ...res.param, ...params });
1974
1974
  reload = Object.prototype.hasOwnProperty.call(res, 'reload')
1975
1975
  ? res.reload
1976
1976
  : true;
@@ -77,7 +77,7 @@
77
77
  import avatar from './avatar.vue';
78
78
  import userInfo from './userinfo.vue';
79
79
  import util from 'eoss-ui/src/utils/util';
80
- import { debounce } from 'throttle-debounce';
80
+ import { throttle } from 'throttle-debounce';
81
81
  import {
82
82
  initUserSet,
83
83
  switchUserTo,
@@ -116,7 +116,7 @@ export default {
116
116
  }
117
117
  },
118
118
  beforeCreate() {
119
- this.setNoticeType = debounce(1000, () => {
119
+ this.setNoticeType = throttle(1000, () => {
120
120
  this.setNotice();
121
121
  });
122
122
  },