eoss-ui 0.4.25 → 0.4.27

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.
@@ -690,7 +690,7 @@ export default {
690
690
  if (ids) {
691
691
  this.defaultActive = ids;
692
692
  }
693
- } else {
693
+ } else if (util.win.location.hash) {
694
694
  let hash = util.win.location.hash;
695
695
  if (hash) {
696
696
  hash = hash.split('?')[0];
@@ -700,6 +700,24 @@ export default {
700
700
  if (ids) {
701
701
  this.defaultActive = ids;
702
702
  }
703
+ } else if (sessionStorage.getItem('jump')) {
704
+ let ids = this.getId(
705
+ this.menus,
706
+ sessionStorage.getItem('jump'),
707
+ true
708
+ );
709
+ if (ids) {
710
+ this.defaultActive = ids;
711
+ }
712
+ }
713
+ } else if (sessionStorage.getItem('jump')) {
714
+ let ids = this.getId(
715
+ this.menus,
716
+ sessionStorage.getItem('jump'),
717
+ true
718
+ );
719
+ if (ids) {
720
+ this.defaultActive = ids;
703
721
  }
704
722
  }
705
723
  this.setMenu(this.menus);
@@ -930,7 +948,7 @@ export default {
930
948
  if (ids) {
931
949
  this.defaultActive = ids;
932
950
  }
933
- } else {
951
+ } else if (util.win.location.hash) {
934
952
  let hash = util.win.location.hash;
935
953
  if (hash) {
936
954
  hash = hash.split('?')[0];
@@ -940,6 +958,24 @@ export default {
940
958
  if (ids) {
941
959
  this.defaultActive = ids;
942
960
  }
961
+ } else if (sessionStorage.getItem('jump')) {
962
+ let ids = this.getId(
963
+ this.menus,
964
+ sessionStorage.getItem('jump'),
965
+ true
966
+ );
967
+ if (ids) {
968
+ this.defaultActive = ids;
969
+ }
970
+ }
971
+ } else if (sessionStorage.getItem('jump')) {
972
+ let ids = this.getId(
973
+ this.menus,
974
+ sessionStorage.getItem('jump'),
975
+ true
976
+ );
977
+ if (ids) {
978
+ this.defaultActive = ids;
943
979
  }
944
980
  }
945
981
  this.setTips(this.menus);
@@ -1223,8 +1259,18 @@ export default {
1223
1259
  },
1224
1260
  //应用导航交互
1225
1261
  handleSelect(res, type) {
1226
- this.isDefault = false;
1227
1262
  const { node } = res;
1263
+ if (
1264
+ node.extendData &&
1265
+ node.extendData.businessStatus == 0 &&
1266
+ node.extendData.businessWarnMsg
1267
+ ) {
1268
+ this.$alert(node.extendData.businessWarnMsg, '提示', {
1269
+ type: 'warning'
1270
+ });
1271
+ return;
1272
+ }
1273
+ this.isDefault = false;
1228
1274
  switch (type) {
1229
1275
  case 'nav':
1230
1276
  this.tabs = [];
@@ -1399,6 +1445,7 @@ export default {
1399
1445
  //跳转页面
1400
1446
  handleJump(page, type, res) {
1401
1447
  console.log(page);
1448
+ sessionStorage.setItem('jump', page);
1402
1449
  if (util.win.location.hash === page) {
1403
1450
  this.refresh = true;
1404
1451
  return;
@@ -1649,7 +1696,7 @@ export default {
1649
1696
  },
1650
1697
  openPage(url, name, width, height) {
1651
1698
  let src = url;
1652
- if (!util.startWith(url, ['http', '/'])) {
1699
+ if (!util.startWith(url, ['http', '/'], true)) {
1653
1700
  let pathname = window.location.pathname;
1654
1701
  if (pathname !== '/') {
1655
1702
  pathname = pathname.split('/');
@@ -166,7 +166,7 @@ export default {
166
166
  h(
167
167
  'div',
168
168
  {
169
- class: `es-menu-title-text es-menu-title-${this.mode}`
169
+ class: [`es-menu-title-text es-menu-title-${this.mode}`]
170
170
  },
171
171
  [
172
172
  h(
@@ -200,7 +200,12 @@ export default {
200
200
  let doms = [
201
201
  h('template', { slot: 'title' }, this.titleIcons ? title : [title[1]])
202
202
  ];
203
- if (this.deep && item.children && item.children.length) {
203
+ if (
204
+ this.deep &&
205
+ item.children &&
206
+ item.children.length &&
207
+ (!item.extendData || item.extendData.businessStatus != 0)
208
+ ) {
204
209
  doms = doms.concat(
205
210
  item.children.map((ele, index) => {
206
211
  if (!ele) {
@@ -230,7 +235,8 @@ export default {
230
235
  this.deep &&
231
236
  this.mode === 'horizontal' &&
232
237
  item.fourthTabs &&
233
- item.fourthTabs.length
238
+ item.fourthTabs.length &&
239
+ (!item.extendData || item.extendData.businessStatus != 0)
234
240
  ) {
235
241
  doms = doms.concat(
236
242
  item.fourthTabs.map((ele, index) => {
@@ -262,10 +268,12 @@ export default {
262
268
  h(
263
269
  'el-menu-item',
264
270
  {
265
- class:
266
- 'es-menu-item ' + (this.deep ? '' : `es-item-${this.mode}`),
271
+ class: [
272
+ 'es-menu-item ' + (this.deep ? '' : `es-item-${this.mode}`)
273
+ ],
267
274
  props: {
268
- paddingLeft: this.paddingLeft
275
+ paddingLeft: this.paddingLeft,
276
+ disabled: item.extendData && item.extendData.businessStatus == 0
269
277
  },
270
278
  attrs: {
271
279
  data: item,
@@ -289,7 +297,11 @@ export default {
289
297
  render(h) {
290
298
  let doms = [];
291
299
  this.data.forEach((item) => {
292
- if (item.children && item.children.length) {
300
+ if (
301
+ item.children &&
302
+ item.children.length &&
303
+ (!item.extendData || item.extendData.businessStatus != 0)
304
+ ) {
293
305
  doms = doms.concat(this.getSub(item, h, 'es-sub-menu'));
294
306
  } else {
295
307
  const title = [
@@ -310,7 +322,7 @@ export default {
310
322
  h(
311
323
  'div',
312
324
  {
313
- class: `es-menu-title-text es-menu-title-${this.mode}`
325
+ class: [`es-menu-title-text es-menu-title-${this.mode}`]
314
326
  },
315
327
  [
316
328
  h(
@@ -348,7 +360,8 @@ export default {
348
360
  {
349
361
  class: [`es-menu-item-${this.mode}`],
350
362
  props: {
351
- paddingLeft: this.paddingLeft
363
+ paddingLeft: this.paddingLeft,
364
+ disabled: item.extendData && item.extendData.businessStatus == 0
352
365
  },
353
366
  attrs: {
354
367
  data: item,
@@ -0,0 +1 @@
1
+ .es-icons{display:inline-block}.es-icons.es-icon-readonly{-webkit-appearance:none;background-color:#fff;background-image:none;border-radius:3px;border:1px solid #d9d9d9;-webkit-box-sizing:border-box;box-sizing:border-box;color:rgba(0,0,0,.75);display:inline-block;font-size:inherit;height:40px;line-height:40px;outline:0;padding:0 15px;-webkit-transition:border-color .2s cubic-bezier(.645,.045,.355,1);transition:border-color .2s cubic-bezier(.645,.045,.355,1);width:100%;position:relative}.es-icons .el-input-group__prepend{width:auto;line-height:38px;position:absolute;z-index:3;left:2px;top:2px;right:62px;bottom:2px;border:0;background-color:#fff;padding:0 12px}.es-icons .es-iconfont{color:#606266;font-size:20px}.es-icons .el-input__inner{border-radius:3px!important;color:transparent;padding-right:60px}.es-icons .el-input__suffix{height:auto;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.es-icon-list{clear:both;overflow:hidden;list-style:none;padding:0!important;border:1px solid #eaeefb;border-radius:4px}.es-icon-list li{float:left;width:148px;text-align:center;height:120px;line-height:120px;color:#666;font-size:13px;border-right:1px solid #eee;border-bottom:1px solid #eee;margin-right:-1px;margin-bottom:-1px;-webkit-box-sizing:border-box;box-sizing:border-box}.es-icon-list li span{display:inline-block;line-height:normal;vertical-align:middle;font-family:'Helvetica Neue',Helvetica,'PingFang SC','Hiragino Sans GB','Microsoft YaHei',SimSun,sans-serif;color:#99a9bf;-webkit-transition:color .15s linear;transition:color .15s linear}.es-icon-list li i{display:block;font-size:32px;margin-bottom:15px;color:#606266;-webkit-transition:color .15s linear;transition:color .15s linear}.es-icon-list li .icon-name{display:inline-block;padding:0 3px;height:1em}.es-icon-list li:hover i,.es-icon-list li:hover span{color:#5cb6ff}