eoss-ui 0.5.49 → 0.5.50

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 (54) hide show
  1. package/lib/button-group.js +59 -44
  2. package/lib/button.js +59 -44
  3. package/lib/checkbox-group.js +59 -44
  4. package/lib/data-table-form.js +59 -44
  5. package/lib/data-table.js +75 -53
  6. package/lib/date-picker.js +59 -44
  7. package/lib/dialog.js +59 -44
  8. package/lib/eoss-ui.common.js +139 -111
  9. package/lib/flow-group.js +59 -44
  10. package/lib/flow-list.js +59 -44
  11. package/lib/flow.js +59 -44
  12. package/lib/form.js +72 -51
  13. package/lib/handle-user.js +59 -44
  14. package/lib/handler.js +59 -44
  15. package/lib/index.js +1 -1
  16. package/lib/input-number.js +59 -44
  17. package/lib/input.js +59 -44
  18. package/lib/login.js +59 -44
  19. package/lib/main.js +74 -59
  20. package/lib/nav.js +59 -44
  21. package/lib/page.js +59 -44
  22. package/lib/player.js +59 -44
  23. package/lib/qr-code.js +59 -44
  24. package/lib/radio-group.js +59 -44
  25. package/lib/retrial-auth.js +59 -44
  26. package/lib/select-ganged.js +59 -44
  27. package/lib/select.js +59 -44
  28. package/lib/selector-panel.js +59 -44
  29. package/lib/selector.js +59 -44
  30. package/lib/sizer.js +59 -44
  31. package/lib/steps.js +59 -44
  32. package/lib/switch.js +59 -44
  33. package/lib/table-form.js +59 -44
  34. package/lib/tabs.js +59 -44
  35. package/lib/theme-chalk/index.css +1 -1
  36. package/lib/theme-chalk/tree.css +1 -1
  37. package/lib/tips.js +59 -44
  38. package/lib/tree-group.js +59 -44
  39. package/lib/tree.js +77 -62
  40. package/lib/upload.js +59 -44
  41. package/lib/utils/util.js +59 -44
  42. package/lib/wujie.js +59 -44
  43. package/lib/wxlogin.js +59 -44
  44. package/package.json +1 -1
  45. package/packages/data-table/src/main.vue +9 -0
  46. package/packages/form/src/main.vue +9 -1
  47. package/packages/main/src/main.vue +1 -1
  48. package/packages/main/src/userinfo.vue +5 -5
  49. package/packages/theme-chalk/lib/index.css +1 -1
  50. package/packages/theme-chalk/lib/tree.css +1 -1
  51. package/packages/theme-chalk/src/tree.scss +7 -1
  52. package/packages/tree/src/main.vue +6 -6
  53. package/src/index.js +1 -1
  54. package/src/utils/util.js +20 -6
package/lib/wujie.js CHANGED
@@ -151,6 +151,7 @@ var JSONbigToString = json_bigint__WEBPACK_IMPORTED_MODULE_3___default()({ store
151
151
  * @param {Object} [loading] - loading加载对象
152
152
  * @param {String} [publicKey] - sm2加密公钥
153
153
  * @param {Array} [secret] - 要加密的字段属性名称,默认所有
154
+ * @param {Array} [encodes] - 需要对参数值进行encodeURIComponent编码的参数值名称
154
155
  **/
155
156
  // 请求
156
157
  var pendingRequest = new Map();
@@ -186,7 +187,9 @@ var ajax = function ajax(_ref) {
186
187
  defaults = _ref$defaults === undefined ? false : _ref$defaults,
187
188
  loading = _ref.loading,
188
189
  publicKey = _ref.publicKey,
189
- secret = _ref.secret;
190
+ secret = _ref.secret,
191
+ _ref$encodes = _ref.encodes,
192
+ encodes = _ref$encodes === undefined ? ['cd'] : _ref$encodes;
190
193
 
191
194
  var header = headers || {};
192
195
  if (!method) {
@@ -416,6 +419,17 @@ var ajax = function ajax(_ref) {
416
419
  if (!mix) {
417
420
  if (method === 'get') {
418
421
  data = {};
422
+ // params = qs.stringify(params, {arrayFormat: 'brackets'});
423
+ if (encodes && encodes.length) {
424
+ var other = {};
425
+ for (var i in params) {
426
+ if (encodes.includes(i)) {
427
+ other[i] = encodeURIComponent(params[i]);
428
+ delete params[i];
429
+ }
430
+ }
431
+ url = urlJoinParams({ url: url, param: other });
432
+ }
419
433
  } else {
420
434
  params = {};
421
435
  }
@@ -432,10 +446,10 @@ var ajax = function ajax(_ref) {
432
446
  }
433
447
  });
434
448
  } else {
435
- for (var i in params) {
436
- if (params[i] !== '' && params[i] !== null) {
437
- params[i] = esmEncrypt({
438
- data: params[i],
449
+ for (var _i in params) {
450
+ if (params[_i] !== '' && params[_i] !== null) {
451
+ params[_i] = esmEncrypt({
452
+ data: params[_i],
439
453
  key: publicKey
440
454
  });
441
455
  }
@@ -453,10 +467,10 @@ var ajax = function ajax(_ref) {
453
467
  }
454
468
  });
455
469
  } else {
456
- for (var _i in data) {
457
- if (data[_i] !== '' && data[_i] !== null) {
458
- data[_i] = esmEncrypt({
459
- data: data[_i],
470
+ for (var _i2 in data) {
471
+ if (data[_i2] !== '' && data[_i2] !== null) {
472
+ data[_i2] = esmEncrypt({
473
+ data: data[_i2],
460
474
  key: publicKey
461
475
  });
462
476
  }
@@ -503,10 +517,10 @@ var arrUnique = function arrUnique(data, key) {
503
517
  }
504
518
  } else {
505
519
  var obj = {};
506
- for (var _i2 = 0; _i2 < data.length; _i2++) {
507
- if (!obj[data[_i2][key]]) {
508
- newArr.push(data[_i2]);
509
- obj[data[_i2][key]] = true;
520
+ for (var _i3 = 0; _i3 < data.length; _i3++) {
521
+ if (!obj[data[_i3][key]]) {
522
+ newArr.push(data[_i3]);
523
+ obj[data[_i3][key]] = true;
510
524
  }
511
525
  }
512
526
  }
@@ -985,12 +999,12 @@ var exportXls = function exportXls(_ref6) {
985
999
  }
986
1000
  tbody += '</tr>';
987
1001
  }
988
- for (var _i3 in others) {
989
- fields.splice(_i3, 0, others[_i3][0]);
990
- aligns.splice(_i3, 0, others[_i3][1]);
1002
+ for (var _i4 in others) {
1003
+ fields.splice(_i4, 0, others[_i4][0]);
1004
+ aligns.splice(_i4, 0, others[_i4][1]);
991
1005
  }
992
1006
 
993
- var _loop2 = function _loop2(_i4) {
1007
+ var _loop2 = function _loop2(_i5) {
994
1008
  tbody += '<tr>';
995
1009
 
996
1010
  var _loop3 = function _loop3(_x2) {
@@ -998,9 +1012,9 @@ var exportXls = function exportXls(_ref6) {
998
1012
  var valueKey = keys[fields[_x2]] && keys[fields[_x2]].valueKey ? keys[fields[_x2]].valueKey : 'value';
999
1013
  var labelKey = keys[fields[_x2]] && keys[fields[_x2]].labelKey ? keys[fields[_x2]].labelKey : 'name';
1000
1014
  if (option[fields[_x2]]) {
1001
- if (Array.isArray(data[_i4][fields[_x2]])) {
1015
+ if (Array.isArray(data[_i5][fields[_x2]])) {
1002
1016
  field = [];
1003
- data[_i4][fields[_x2]].forEach(function (ele) {
1017
+ data[_i5][fields[_x2]].forEach(function (ele) {
1004
1018
  option[fields[_x2]].forEach(function (item) {
1005
1019
  // eslint-disable-next-line eqeqeq
1006
1020
  if (item[valueKey] == ele) {
@@ -1010,9 +1024,9 @@ var exportXls = function exportXls(_ref6) {
1010
1024
  });
1011
1025
  });
1012
1026
  field = field.join(' ');
1013
- } else if (typeof data[_i4][fields[_x2]] === 'string' && keys[fields[_x2]] && keys[fields[_x2]].multiple) {
1027
+ } else if (typeof data[_i5][fields[_x2]] === 'string' && keys[fields[_x2]] && keys[fields[_x2]].multiple) {
1014
1028
  field = [];
1015
- data[_i4][fields[_x2]].split(',').forEach(function (ele) {
1029
+ data[_i5][fields[_x2]].split(',').forEach(function (ele) {
1016
1030
  option[fields[_x2]].forEach(function (item) {
1017
1031
  // eslint-disable-next-line eqeqeq
1018
1032
  if (item[valueKey] == ele) {
@@ -1025,24 +1039,24 @@ var exportXls = function exportXls(_ref6) {
1025
1039
  } else {
1026
1040
  option[fields[_x2]].forEach(function (item) {
1027
1041
  // eslint-disable-next-line eqeqeq
1028
- if (item[valueKey] == data[_i4][fields[_x2]]) {
1042
+ if (item[valueKey] == data[_i5][fields[_x2]]) {
1029
1043
  field = item[labelKey];
1030
1044
  return;
1031
1045
  }
1032
1046
  });
1033
1047
  }
1034
- } else if (_typeof(data[_i4][fields[_x2]]) === 'object' && keys[fields[_x2]]) {
1035
- if (Array.isArray(data[_i4][fields[_x2]])) {
1036
- data[_i4][fields[_x2]].forEach(function (item) {
1048
+ } else if (_typeof(data[_i5][fields[_x2]]) === 'object' && keys[fields[_x2]]) {
1049
+ if (Array.isArray(data[_i5][fields[_x2]])) {
1050
+ data[_i5][fields[_x2]].forEach(function (item) {
1037
1051
  field = [];
1038
1052
  field.push({}.toString.call(item) === '[object Object]' ? item[labelKey] : item);
1039
1053
  });
1040
1054
  field = field.join(' ');
1041
1055
  } else {
1042
- field = data[_i4][fields[_x2]][labelKey];
1056
+ field = data[_i5][fields[_x2]][labelKey];
1043
1057
  }
1044
1058
  } else {
1045
- field = data[_i4][fields[_x2]];
1059
+ field = data[_i5][fields[_x2]];
1046
1060
  }
1047
1061
  tbody += '<td align="' + aligns[_x2] + '">' + field + '</td>';
1048
1062
  };
@@ -1053,8 +1067,8 @@ var exportXls = function exportXls(_ref6) {
1053
1067
  tbody += '</tr>';
1054
1068
  };
1055
1069
 
1056
- for (var _i4 = 0; _i4 < data.length; _i4++) {
1057
- _loop2(_i4);
1070
+ for (var _i5 = 0; _i5 < data.length; _i5++) {
1071
+ _loop2(_i5);
1058
1072
  }
1059
1073
  if (!name) {
1060
1074
  name = 'table_' + new Date().getTime();
@@ -1510,8 +1524,8 @@ var getRgb = function getRgb($color) {
1510
1524
  $color = colorNew;
1511
1525
  }
1512
1526
  // 处理六位的颜色值,转为RGB
1513
- for (var _i5 = 1; _i5 < 7; _i5 += 2) {
1514
- rgb.push(parseInt('0x' + $color.slice(_i5, _i5 + 2), 16));
1527
+ for (var _i6 = 1; _i6 < 7; _i6 += 2) {
1528
+ rgb.push(parseInt('0x' + $color.slice(_i6, _i6 + 2), 16));
1515
1529
  }
1516
1530
  } else {
1517
1531
  rgb = $color.replace(/(?:\(|\)|rgb|RGB)*/g, '').split(',');
@@ -2600,22 +2614,22 @@ var setStorage = function setStorage(_ref14) {
2600
2614
  localStorage.setItem(key[i], value);
2601
2615
  }
2602
2616
  } else {
2603
- for (var _i6 in key) {
2604
- var val = _typeof(key[_i6]) === 'object' ? JSON.stringify(key[_i6]) : key[_i6];
2605
- localStorage.setItem(_i6, val);
2617
+ for (var _i7 in key) {
2618
+ var val = _typeof(key[_i7]) === 'object' ? JSON.stringify(key[_i7]) : key[_i7];
2619
+ localStorage.setItem(_i7, val);
2606
2620
  }
2607
2621
  }
2608
2622
  } else {
2609
2623
  if (typeof key === 'string') {
2610
2624
  sessionStorage.setItem(key, value);
2611
2625
  } else if (Array.isArray(key)) {
2612
- for (var _i7 in key) {
2613
- sessionStorage.setItem(key[_i7], value);
2626
+ for (var _i8 in key) {
2627
+ sessionStorage.setItem(key[_i8], value);
2614
2628
  }
2615
2629
  } else {
2616
- for (var _i8 in key) {
2617
- var _val = _typeof(key[_i8]) === 'object' ? JSON.stringify(key[_i8]) : key[_i8];
2618
- sessionStorage.setItem(_i8, _val);
2630
+ for (var _i9 in key) {
2631
+ var _val = _typeof(key[_i9]) === 'object' ? JSON.stringify(key[_i9]) : key[_i9];
2632
+ sessionStorage.setItem(_i9, _val);
2619
2633
  }
2620
2634
  }
2621
2635
  }
@@ -2833,17 +2847,18 @@ var toFunction = function toFunction(str) {
2833
2847
  * @date 2022年5月7日
2834
2848
  * @param {string} [$color] - 颜色值
2835
2849
  **/
2836
- var updateTheme = function updateTheme($color, send) {
2837
- $color = $color ? $color : '#409eff';
2850
+ var updateTheme = function updateTheme(color, send) {
2851
+ color = color ? color : '#409eff';
2838
2852
  if (send === undefined) {
2839
2853
  send = true;
2840
2854
  }
2841
- document.documentElement.style.setProperty('--theme-primary', $color);
2855
+ localStorage.setItem('theme', color);
2856
+ document.documentElement.style.setProperty('--theme-primary', color);
2842
2857
  for (var i = 1; i < 11; i++) {
2843
2858
  if (i === 6) {
2844
- document.documentElement.style.setProperty('--theme-primary-light-' + i, $color);
2859
+ document.documentElement.style.setProperty('--theme-primary-light-' + i, color);
2845
2860
  } else {
2846
- var light = getColor($color, i);
2861
+ var light = getColor(color, i);
2847
2862
  document.documentElement.style.setProperty('--theme-primary-light-' + i, light);
2848
2863
  }
2849
2864
  }
package/lib/wxlogin.js CHANGED
@@ -151,6 +151,7 @@ var JSONbigToString = json_bigint__WEBPACK_IMPORTED_MODULE_3___default()({ store
151
151
  * @param {Object} [loading] - loading加载对象
152
152
  * @param {String} [publicKey] - sm2加密公钥
153
153
  * @param {Array} [secret] - 要加密的字段属性名称,默认所有
154
+ * @param {Array} [encodes] - 需要对参数值进行encodeURIComponent编码的参数值名称
154
155
  **/
155
156
  // 请求
156
157
  var pendingRequest = new Map();
@@ -186,7 +187,9 @@ var ajax = function ajax(_ref) {
186
187
  defaults = _ref$defaults === undefined ? false : _ref$defaults,
187
188
  loading = _ref.loading,
188
189
  publicKey = _ref.publicKey,
189
- secret = _ref.secret;
190
+ secret = _ref.secret,
191
+ _ref$encodes = _ref.encodes,
192
+ encodes = _ref$encodes === undefined ? ['cd'] : _ref$encodes;
190
193
 
191
194
  var header = headers || {};
192
195
  if (!method) {
@@ -416,6 +419,17 @@ var ajax = function ajax(_ref) {
416
419
  if (!mix) {
417
420
  if (method === 'get') {
418
421
  data = {};
422
+ // params = qs.stringify(params, {arrayFormat: 'brackets'});
423
+ if (encodes && encodes.length) {
424
+ var other = {};
425
+ for (var i in params) {
426
+ if (encodes.includes(i)) {
427
+ other[i] = encodeURIComponent(params[i]);
428
+ delete params[i];
429
+ }
430
+ }
431
+ url = urlJoinParams({ url: url, param: other });
432
+ }
419
433
  } else {
420
434
  params = {};
421
435
  }
@@ -432,10 +446,10 @@ var ajax = function ajax(_ref) {
432
446
  }
433
447
  });
434
448
  } else {
435
- for (var i in params) {
436
- if (params[i] !== '' && params[i] !== null) {
437
- params[i] = esmEncrypt({
438
- data: params[i],
449
+ for (var _i in params) {
450
+ if (params[_i] !== '' && params[_i] !== null) {
451
+ params[_i] = esmEncrypt({
452
+ data: params[_i],
439
453
  key: publicKey
440
454
  });
441
455
  }
@@ -453,10 +467,10 @@ var ajax = function ajax(_ref) {
453
467
  }
454
468
  });
455
469
  } else {
456
- for (var _i in data) {
457
- if (data[_i] !== '' && data[_i] !== null) {
458
- data[_i] = esmEncrypt({
459
- data: data[_i],
470
+ for (var _i2 in data) {
471
+ if (data[_i2] !== '' && data[_i2] !== null) {
472
+ data[_i2] = esmEncrypt({
473
+ data: data[_i2],
460
474
  key: publicKey
461
475
  });
462
476
  }
@@ -503,10 +517,10 @@ var arrUnique = function arrUnique(data, key) {
503
517
  }
504
518
  } else {
505
519
  var obj = {};
506
- for (var _i2 = 0; _i2 < data.length; _i2++) {
507
- if (!obj[data[_i2][key]]) {
508
- newArr.push(data[_i2]);
509
- obj[data[_i2][key]] = true;
520
+ for (var _i3 = 0; _i3 < data.length; _i3++) {
521
+ if (!obj[data[_i3][key]]) {
522
+ newArr.push(data[_i3]);
523
+ obj[data[_i3][key]] = true;
510
524
  }
511
525
  }
512
526
  }
@@ -985,12 +999,12 @@ var exportXls = function exportXls(_ref6) {
985
999
  }
986
1000
  tbody += '</tr>';
987
1001
  }
988
- for (var _i3 in others) {
989
- fields.splice(_i3, 0, others[_i3][0]);
990
- aligns.splice(_i3, 0, others[_i3][1]);
1002
+ for (var _i4 in others) {
1003
+ fields.splice(_i4, 0, others[_i4][0]);
1004
+ aligns.splice(_i4, 0, others[_i4][1]);
991
1005
  }
992
1006
 
993
- var _loop2 = function _loop2(_i4) {
1007
+ var _loop2 = function _loop2(_i5) {
994
1008
  tbody += '<tr>';
995
1009
 
996
1010
  var _loop3 = function _loop3(_x2) {
@@ -998,9 +1012,9 @@ var exportXls = function exportXls(_ref6) {
998
1012
  var valueKey = keys[fields[_x2]] && keys[fields[_x2]].valueKey ? keys[fields[_x2]].valueKey : 'value';
999
1013
  var labelKey = keys[fields[_x2]] && keys[fields[_x2]].labelKey ? keys[fields[_x2]].labelKey : 'name';
1000
1014
  if (option[fields[_x2]]) {
1001
- if (Array.isArray(data[_i4][fields[_x2]])) {
1015
+ if (Array.isArray(data[_i5][fields[_x2]])) {
1002
1016
  field = [];
1003
- data[_i4][fields[_x2]].forEach(function (ele) {
1017
+ data[_i5][fields[_x2]].forEach(function (ele) {
1004
1018
  option[fields[_x2]].forEach(function (item) {
1005
1019
  // eslint-disable-next-line eqeqeq
1006
1020
  if (item[valueKey] == ele) {
@@ -1010,9 +1024,9 @@ var exportXls = function exportXls(_ref6) {
1010
1024
  });
1011
1025
  });
1012
1026
  field = field.join(' ');
1013
- } else if (typeof data[_i4][fields[_x2]] === 'string' && keys[fields[_x2]] && keys[fields[_x2]].multiple) {
1027
+ } else if (typeof data[_i5][fields[_x2]] === 'string' && keys[fields[_x2]] && keys[fields[_x2]].multiple) {
1014
1028
  field = [];
1015
- data[_i4][fields[_x2]].split(',').forEach(function (ele) {
1029
+ data[_i5][fields[_x2]].split(',').forEach(function (ele) {
1016
1030
  option[fields[_x2]].forEach(function (item) {
1017
1031
  // eslint-disable-next-line eqeqeq
1018
1032
  if (item[valueKey] == ele) {
@@ -1025,24 +1039,24 @@ var exportXls = function exportXls(_ref6) {
1025
1039
  } else {
1026
1040
  option[fields[_x2]].forEach(function (item) {
1027
1041
  // eslint-disable-next-line eqeqeq
1028
- if (item[valueKey] == data[_i4][fields[_x2]]) {
1042
+ if (item[valueKey] == data[_i5][fields[_x2]]) {
1029
1043
  field = item[labelKey];
1030
1044
  return;
1031
1045
  }
1032
1046
  });
1033
1047
  }
1034
- } else if (_typeof(data[_i4][fields[_x2]]) === 'object' && keys[fields[_x2]]) {
1035
- if (Array.isArray(data[_i4][fields[_x2]])) {
1036
- data[_i4][fields[_x2]].forEach(function (item) {
1048
+ } else if (_typeof(data[_i5][fields[_x2]]) === 'object' && keys[fields[_x2]]) {
1049
+ if (Array.isArray(data[_i5][fields[_x2]])) {
1050
+ data[_i5][fields[_x2]].forEach(function (item) {
1037
1051
  field = [];
1038
1052
  field.push({}.toString.call(item) === '[object Object]' ? item[labelKey] : item);
1039
1053
  });
1040
1054
  field = field.join(' ');
1041
1055
  } else {
1042
- field = data[_i4][fields[_x2]][labelKey];
1056
+ field = data[_i5][fields[_x2]][labelKey];
1043
1057
  }
1044
1058
  } else {
1045
- field = data[_i4][fields[_x2]];
1059
+ field = data[_i5][fields[_x2]];
1046
1060
  }
1047
1061
  tbody += '<td align="' + aligns[_x2] + '">' + field + '</td>';
1048
1062
  };
@@ -1053,8 +1067,8 @@ var exportXls = function exportXls(_ref6) {
1053
1067
  tbody += '</tr>';
1054
1068
  };
1055
1069
 
1056
- for (var _i4 = 0; _i4 < data.length; _i4++) {
1057
- _loop2(_i4);
1070
+ for (var _i5 = 0; _i5 < data.length; _i5++) {
1071
+ _loop2(_i5);
1058
1072
  }
1059
1073
  if (!name) {
1060
1074
  name = 'table_' + new Date().getTime();
@@ -1510,8 +1524,8 @@ var getRgb = function getRgb($color) {
1510
1524
  $color = colorNew;
1511
1525
  }
1512
1526
  // 处理六位的颜色值,转为RGB
1513
- for (var _i5 = 1; _i5 < 7; _i5 += 2) {
1514
- rgb.push(parseInt('0x' + $color.slice(_i5, _i5 + 2), 16));
1527
+ for (var _i6 = 1; _i6 < 7; _i6 += 2) {
1528
+ rgb.push(parseInt('0x' + $color.slice(_i6, _i6 + 2), 16));
1515
1529
  }
1516
1530
  } else {
1517
1531
  rgb = $color.replace(/(?:\(|\)|rgb|RGB)*/g, '').split(',');
@@ -2600,22 +2614,22 @@ var setStorage = function setStorage(_ref14) {
2600
2614
  localStorage.setItem(key[i], value);
2601
2615
  }
2602
2616
  } else {
2603
- for (var _i6 in key) {
2604
- var val = _typeof(key[_i6]) === 'object' ? JSON.stringify(key[_i6]) : key[_i6];
2605
- localStorage.setItem(_i6, val);
2617
+ for (var _i7 in key) {
2618
+ var val = _typeof(key[_i7]) === 'object' ? JSON.stringify(key[_i7]) : key[_i7];
2619
+ localStorage.setItem(_i7, val);
2606
2620
  }
2607
2621
  }
2608
2622
  } else {
2609
2623
  if (typeof key === 'string') {
2610
2624
  sessionStorage.setItem(key, value);
2611
2625
  } else if (Array.isArray(key)) {
2612
- for (var _i7 in key) {
2613
- sessionStorage.setItem(key[_i7], value);
2626
+ for (var _i8 in key) {
2627
+ sessionStorage.setItem(key[_i8], value);
2614
2628
  }
2615
2629
  } else {
2616
- for (var _i8 in key) {
2617
- var _val = _typeof(key[_i8]) === 'object' ? JSON.stringify(key[_i8]) : key[_i8];
2618
- sessionStorage.setItem(_i8, _val);
2630
+ for (var _i9 in key) {
2631
+ var _val = _typeof(key[_i9]) === 'object' ? JSON.stringify(key[_i9]) : key[_i9];
2632
+ sessionStorage.setItem(_i9, _val);
2619
2633
  }
2620
2634
  }
2621
2635
  }
@@ -2833,17 +2847,18 @@ var toFunction = function toFunction(str) {
2833
2847
  * @date 2022年5月7日
2834
2848
  * @param {string} [$color] - 颜色值
2835
2849
  **/
2836
- var updateTheme = function updateTheme($color, send) {
2837
- $color = $color ? $color : '#409eff';
2850
+ var updateTheme = function updateTheme(color, send) {
2851
+ color = color ? color : '#409eff';
2838
2852
  if (send === undefined) {
2839
2853
  send = true;
2840
2854
  }
2841
- document.documentElement.style.setProperty('--theme-primary', $color);
2855
+ localStorage.setItem('theme', color);
2856
+ document.documentElement.style.setProperty('--theme-primary', color);
2842
2857
  for (var i = 1; i < 11; i++) {
2843
2858
  if (i === 6) {
2844
- document.documentElement.style.setProperty('--theme-primary-light-' + i, $color);
2859
+ document.documentElement.style.setProperty('--theme-primary-light-' + i, color);
2845
2860
  } else {
2846
- var light = getColor($color, i);
2861
+ var light = getColor(color, i);
2847
2862
  document.documentElement.style.setProperty('--theme-primary-light-' + i, light);
2848
2863
  }
2849
2864
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eoss-ui",
3
- "version": "0.5.49",
3
+ "version": "0.5.50",
4
4
  "description": "eoss内部业务组件",
5
5
  "main": "lib/eoss-ui.common.js",
6
6
  "files": [
@@ -199,6 +199,7 @@ export default {
199
199
  type: String,
200
200
  default: 'get'
201
201
  },
202
+ isEncodeURI: Boolean,
202
203
  format: {
203
204
  type: Boolean,
204
205
  default: true
@@ -377,6 +378,12 @@ export default {
377
378
  isJoin: {
378
379
  type: Boolean,
379
380
  default: true
381
+ },
382
+ ajaxConfig: {
383
+ type: Object,
384
+ default() {
385
+ return {};
386
+ }
380
387
  }
381
388
  },
382
389
  data() {
@@ -913,6 +920,7 @@ export default {
913
920
  this.tableLoading = true;
914
921
  util
915
922
  .ajax({
923
+ ...this.ajaxConfig,
916
924
  url: this.url,
917
925
  method: this.method,
918
926
  format: this.format,
@@ -1049,6 +1057,7 @@ export default {
1049
1057
  let keys = Object.keys(params);
1050
1058
  util
1051
1059
  .ajax({
1060
+ ...(handle.ajaxConfig || {}),
1052
1061
  url: handle.action,
1053
1062
  data:
1054
1063
  keys.length == 1 && handle.format === false
@@ -4042,7 +4042,13 @@ export default {
4042
4042
  zoom: false,
4043
4043
  showMsg: true,
4044
4044
  validated: Function,
4045
- enterSubmit: Boolean
4045
+ enterSubmit: Boolean,
4046
+ ajaxConfig: {
4047
+ type: Object,
4048
+ default() {
4049
+ return {};
4050
+ }
4051
+ }
4046
4052
  },
4047
4053
  data() {
4048
4054
  return {
@@ -4905,6 +4911,7 @@ export default {
4905
4911
  }
4906
4912
  await util
4907
4913
  .ajax({
4914
+ ...this.ajaxConfig,
4908
4915
  url:
4909
4916
  typeof this.action === 'object'
4910
4917
  ? this.action[this.actionType]
@@ -4984,6 +4991,7 @@ export default {
4984
4991
  }
4985
4992
  await util
4986
4993
  .ajax({
4994
+ ...this.ajaxConfig,
4987
4995
  url:
4988
4996
  typeof this.action === 'object'
4989
4997
  ? this.action[this.actionType]
@@ -1064,7 +1064,7 @@ export default {
1064
1064
  if (typeof id === 'string') {
1065
1065
  this.isTabs = false;
1066
1066
  }
1067
- if (item.pid === 'root') {
1067
+ if (item.pid === 'root' || Array.isArray(id)) {
1068
1068
  return [item.id].concat(id);
1069
1069
  } else if (typeof id === 'string') {
1070
1070
  return [item.id, id];
@@ -49,10 +49,10 @@ export default {
49
49
  job: '',
50
50
  orgName: '',
51
51
  depName: '',
52
- idcard: '',
52
+ idCard: '',
53
53
  phone: '',
54
54
  email: '',
55
- officetel: '',
55
+ officeTel: '',
56
56
  oldpassword: '',
57
57
  password: '',
58
58
  notify: []
@@ -272,10 +272,10 @@ export default {
272
272
  this.results = results.simpleUserInfo;
273
273
  this.values.orgName = results.simpleUserInfo.orgName;
274
274
  this.values.depName = results.simpleUserInfo.depName;
275
- this.values.idcard = results.simpleUserInfo.idcard;
275
+ this.values.idCard = results.simpleUserInfo.idCard;
276
276
  this.values.phone = results.simpleUserInfo.phone;
277
277
  this.values.email = results.simpleUserInfo.email;
278
- this.values.officetel = results.simpleUserInfo.officetel;
278
+ this.values.officeTel = results.simpleUserInfo.officeTel;
279
279
  if (results.userScanBindImgUrl) {
280
280
  this.userScanBindImgUrl = results.userScanBindImgUrl;
281
281
  this.qrcode =
@@ -356,7 +356,7 @@ export default {
356
356
  url: updateUserInfo,
357
357
  params: {
358
358
  email: this.values.email,
359
- officeTel: this.values.officetel,
359
+ officeTel: this.values.officeTel,
360
360
  phone: this.values.phone,
361
361
  oldPassword:
362
362
  this.secret &&