eoss-ui 0.5.97 → 0.5.99

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 (103) hide show
  1. package/lib/button-group.js +8 -4
  2. package/lib/button.js +8 -4
  3. package/lib/calendar.js +2 -2
  4. package/lib/card.js +2 -2
  5. package/lib/cascader.js +2 -2
  6. package/lib/checkbox-group.js +9 -4
  7. package/lib/clients.js +2 -2
  8. package/lib/data-table-form.js +9 -4
  9. package/lib/data-table.js +31 -18
  10. package/lib/date-picker.js +8 -4
  11. package/lib/dialog.js +12 -7
  12. package/lib/enterprise.js +2 -2
  13. package/lib/eoss-ui.common.js +767 -797
  14. package/lib/error-page.js +2 -2
  15. package/lib/flow-group.js +8 -4
  16. package/lib/flow-list.js +8 -4
  17. package/lib/flow.js +9 -4
  18. package/lib/form.js +9 -4
  19. package/lib/handle-user.js +8 -4
  20. package/lib/handler.js +22 -18
  21. package/lib/icon.js +8 -4
  22. package/lib/icons.js +3 -3
  23. package/lib/index.js +1 -1
  24. package/lib/input-number.js +8 -4
  25. package/lib/input.js +8 -4
  26. package/lib/label.js +2 -2
  27. package/lib/layout.js +2 -2
  28. package/lib/login.js +13 -7
  29. package/lib/main.js +2720 -2759
  30. package/lib/menu.js +2 -2
  31. package/lib/nav.js +8 -4
  32. package/lib/notify.js +2 -2
  33. package/lib/page.js +8 -4
  34. package/lib/pagination.js +8 -4
  35. package/lib/player.js +10 -6
  36. package/lib/qr-code.js +10 -6
  37. package/lib/radio-group.js +8 -4
  38. package/lib/retrial-auth.js +15 -11
  39. package/lib/select-ganged.js +15 -11
  40. package/lib/select.js +8 -4
  41. package/lib/selector-panel.js +9 -4
  42. package/lib/selector.js +8 -4
  43. package/lib/sizer.js +8 -4
  44. package/lib/steps.js +8 -4
  45. package/lib/switch.js +8 -4
  46. package/lib/table-form.js +8 -4
  47. package/lib/tabs-panel.js +2 -2
  48. package/lib/tabs.js +8 -4
  49. package/lib/theme-chalk/base.css +1 -1
  50. package/lib/theme-chalk/fonts/iconfont.ttf +0 -0
  51. package/lib/theme-chalk/fonts/iconfont.woff +0 -0
  52. package/lib/theme-chalk/icon.css +1 -1
  53. package/lib/theme-chalk/index.css +1 -1
  54. package/lib/theme-chalk/main.css +1 -1
  55. package/lib/theme-chalk/menu.css +1 -1
  56. package/lib/theme-chalk/simplicity.css +1 -1
  57. package/lib/theme-chalk/sizer.css +1 -1
  58. package/lib/theme-chalk/upload.css +1 -1
  59. package/lib/tips.js +8 -4
  60. package/lib/toolbar.js +2 -2
  61. package/lib/tree-group.js +8 -4
  62. package/lib/tree.js +8 -4
  63. package/lib/upload.js +9 -4
  64. package/lib/utils/util.js +6 -2
  65. package/lib/wujie.js +151 -147
  66. package/lib/wxlogin.js +8 -4
  67. package/package.json +1 -1
  68. package/packages/.DS_Store +0 -0
  69. package/packages/data-table/src/main.vue +18 -12
  70. package/packages/dialog/src/main.vue +1 -1
  71. package/packages/handler/.DS_Store +0 -0
  72. package/packages/handler/src/main.vue +6 -6
  73. package/packages/icons/src/icon.json +1 -1
  74. package/packages/login/.DS_Store +0 -0
  75. package/packages/login/src/main.vue +2 -1
  76. package/packages/main/.DS_Store +0 -0
  77. package/packages/main/src/.DS_Store +0 -0
  78. package/packages/main/src/default/index.vue +34 -12
  79. package/packages/main/src/main.vue +28 -3
  80. package/packages/main/src/{default → public}/settings.vue +53 -21
  81. package/packages/main/src/simplicity/handler.vue +21 -28
  82. package/packages/main/src/simplicity/index.vue +132 -114
  83. package/packages/theme-chalk/lib/base.css +1 -1
  84. package/packages/theme-chalk/lib/fonts/iconfont.ttf +0 -0
  85. package/packages/theme-chalk/lib/fonts/iconfont.woff +0 -0
  86. package/packages/theme-chalk/lib/icon.css +1 -1
  87. package/packages/theme-chalk/lib/index.css +1 -1
  88. package/packages/theme-chalk/lib/main.css +1 -1
  89. package/packages/theme-chalk/lib/menu.css +1 -1
  90. package/packages/theme-chalk/lib/simplicity.css +1 -1
  91. package/packages/theme-chalk/lib/sizer.css +1 -1
  92. package/packages/theme-chalk/lib/upload.css +1 -1
  93. package/packages/theme-chalk/src/.DS_Store +0 -0
  94. package/packages/theme-chalk/src/fonts/iconfont.ttf +0 -0
  95. package/packages/theme-chalk/src/fonts/iconfont.woff +0 -0
  96. package/packages/theme-chalk/src/icon.scss +8 -0
  97. package/packages/theme-chalk/src/main.scss +16 -0
  98. package/packages/theme-chalk/src/mixins/util.scss +0 -0
  99. package/packages/theme-chalk/src/simplicity.scss +197 -0
  100. package/src/.DS_Store +0 -0
  101. package/src/index.js +1 -1
  102. package/src/utils/util.js +6 -2
  103. package/packages/main/src/simplicity/settings.vue +0 -119
package/lib/tips.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 65);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 66);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -2175,6 +2175,7 @@ var isLogined = function isLogined(_ref8) {
2175
2175
  next && next();
2176
2176
  } else {
2177
2177
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2178
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2178
2179
  ajax({
2179
2180
  method: 'post',
2180
2181
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2273,7 +2274,10 @@ var isLogined = function isLogined(_ref8) {
2273
2274
  }
2274
2275
  });
2275
2276
  }
2276
- }).catch(function (e) {});
2277
+ loadingInstance.close();
2278
+ }).catch(function (e) {
2279
+ loadingInstance.close();
2280
+ });
2277
2281
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2278
2282
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2279
2283
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2676,7 +2680,7 @@ var setScale = function setScale() {
2676
2680
  } else {
2677
2681
  n = 1;
2678
2682
  }
2679
- if (zoom === 1) {
2683
+ if (zoom === 1 && window.innerWidth === width) {
2680
2684
  document.body.style.removeProperty('transform');
2681
2685
  document.body.style.removeProperty('width');
2682
2686
  document.body.style.removeProperty('height');
@@ -3771,7 +3775,7 @@ module.exports = require("json-bigint");
3771
3775
 
3772
3776
  /***/ }),
3773
3777
 
3774
- /***/ 65:
3778
+ /***/ 66:
3775
3779
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3776
3780
 
3777
3781
  "use strict";
package/lib/toolbar.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 81);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 82);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -192,7 +192,7 @@ function normalizeComponent(
192
192
 
193
193
  /***/ }),
194
194
 
195
- /***/ 81:
195
+ /***/ 82:
196
196
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
197
197
 
198
198
  "use strict";
package/lib/tree-group.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 67);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 68);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -2175,6 +2175,7 @@ var isLogined = function isLogined(_ref8) {
2175
2175
  next && next();
2176
2176
  } else {
2177
2177
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2178
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2178
2179
  ajax({
2179
2180
  method: 'post',
2180
2181
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2273,7 +2274,10 @@ var isLogined = function isLogined(_ref8) {
2273
2274
  }
2274
2275
  });
2275
2276
  }
2276
- }).catch(function (e) {});
2277
+ loadingInstance.close();
2278
+ }).catch(function (e) {
2279
+ loadingInstance.close();
2280
+ });
2277
2281
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2278
2282
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2279
2283
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2676,7 +2680,7 @@ var setScale = function setScale() {
2676
2680
  } else {
2677
2681
  n = 1;
2678
2682
  }
2679
- if (zoom === 1) {
2683
+ if (zoom === 1 && window.innerWidth === width) {
2680
2684
  document.body.style.removeProperty('transform');
2681
2685
  document.body.style.removeProperty('width');
2682
2686
  document.body.style.removeProperty('height');
@@ -3764,7 +3768,7 @@ module.exports = require("json-bigint");
3764
3768
 
3765
3769
  /***/ }),
3766
3770
 
3767
- /***/ 67:
3771
+ /***/ 68:
3768
3772
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3769
3773
 
3770
3774
  "use strict";
package/lib/tree.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 66);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 67);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -2175,6 +2175,7 @@ var isLogined = function isLogined(_ref8) {
2175
2175
  next && next();
2176
2176
  } else {
2177
2177
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2178
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2178
2179
  ajax({
2179
2180
  method: 'post',
2180
2181
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2273,7 +2274,10 @@ var isLogined = function isLogined(_ref8) {
2273
2274
  }
2274
2275
  });
2275
2276
  }
2276
- }).catch(function (e) {});
2277
+ loadingInstance.close();
2278
+ }).catch(function (e) {
2279
+ loadingInstance.close();
2280
+ });
2277
2281
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2278
2282
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2279
2283
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2676,7 +2680,7 @@ var setScale = function setScale() {
2676
2680
  } else {
2677
2681
  n = 1;
2678
2682
  }
2679
- if (zoom === 1) {
2683
+ if (zoom === 1 && window.innerWidth === width) {
2680
2684
  document.body.style.removeProperty('transform');
2681
2685
  document.body.style.removeProperty('width');
2682
2686
  document.body.style.removeProperty('height');
@@ -3771,7 +3775,7 @@ module.exports = require("json-bigint");
3771
3775
 
3772
3776
  /***/ }),
3773
3777
 
3774
- /***/ 66:
3778
+ /***/ 67:
3775
3779
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3776
3780
 
3777
3781
  "use strict";
package/lib/upload.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 36);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 37);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ([
@@ -2174,6 +2174,7 @@ var isLogined = function isLogined(_ref8) {
2174
2174
  next && next();
2175
2175
  } else {
2176
2176
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2177
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2177
2178
  ajax({
2178
2179
  method: 'post',
2179
2180
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2272,7 +2273,10 @@ var isLogined = function isLogined(_ref8) {
2272
2273
  }
2273
2274
  });
2274
2275
  }
2275
- }).catch(function (e) {});
2276
+ loadingInstance.close();
2277
+ }).catch(function (e) {
2278
+ loadingInstance.close();
2279
+ });
2276
2280
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2277
2281
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2278
2282
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2675,7 +2679,7 @@ var setScale = function setScale() {
2675
2679
  } else {
2676
2680
  n = 1;
2677
2681
  }
2678
- if (zoom === 1) {
2682
+ if (zoom === 1 && window.innerWidth === width) {
2679
2683
  document.body.style.removeProperty('transform');
2680
2684
  document.body.style.removeProperty('width');
2681
2685
  document.body.style.removeProperty('height');
@@ -3970,7 +3974,8 @@ module.exports = require("js-base64");
3970
3974
  /* 33 */,
3971
3975
  /* 34 */,
3972
3976
  /* 35 */,
3973
- /* 36 */
3977
+ /* 36 */,
3978
+ /* 37 */
3974
3979
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3975
3980
 
3976
3981
  "use strict";
package/lib/utils/util.js CHANGED
@@ -2092,6 +2092,7 @@ var isLogined = function isLogined(_ref8) {
2092
2092
  next && next();
2093
2093
  } else {
2094
2094
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2095
+ var loadingInstance = _eossElement.Loading.service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2095
2096
  ajax({
2096
2097
  method: 'post',
2097
2098
  url: _api.authCenter,
@@ -2190,7 +2191,10 @@ var isLogined = function isLogined(_ref8) {
2190
2191
  }
2191
2192
  });
2192
2193
  }
2193
- }).catch(function (e) {});
2194
+ loadingInstance.close();
2195
+ }).catch(function (e) {
2196
+ loadingInstance.close();
2197
+ });
2194
2198
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2195
2199
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2196
2200
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2593,7 +2597,7 @@ var setScale = function setScale() {
2593
2597
  } else {
2594
2598
  n = 1;
2595
2599
  }
2596
- if (zoom === 1) {
2600
+ if (zoom === 1 && window.innerWidth === width) {
2597
2601
  document.body.style.removeProperty('transform');
2598
2602
  document.body.style.removeProperty('width');
2599
2603
  document.body.style.removeProperty('height');
package/lib/wujie.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 69);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 70);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -2175,6 +2175,7 @@ var isLogined = function isLogined(_ref8) {
2175
2175
  next && next();
2176
2176
  } else {
2177
2177
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2178
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2178
2179
  ajax({
2179
2180
  method: 'post',
2180
2181
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2273,7 +2274,10 @@ var isLogined = function isLogined(_ref8) {
2273
2274
  }
2274
2275
  });
2275
2276
  }
2276
- }).catch(function (e) {});
2277
+ loadingInstance.close();
2278
+ }).catch(function (e) {
2279
+ loadingInstance.close();
2280
+ });
2277
2281
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2278
2282
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2279
2283
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2676,7 +2680,7 @@ var setScale = function setScale() {
2676
2680
  } else {
2677
2681
  n = 1;
2678
2682
  }
2679
- if (zoom === 1) {
2683
+ if (zoom === 1 && window.innerWidth === width) {
2680
2684
  document.body.style.removeProperty('transform');
2681
2685
  document.body.style.removeProperty('width');
2682
2686
  document.body.style.removeProperty('height');
@@ -3764,7 +3768,150 @@ module.exports = require("json-bigint");
3764
3768
 
3765
3769
  /***/ }),
3766
3770
 
3767
- /***/ 69:
3771
+ /***/ 7:
3772
+ /***/ (function(module, __webpack_exports__, __webpack_require__) {
3773
+
3774
+ "use strict";
3775
+ /* harmony import */ var sockjs_client__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8);
3776
+ /* harmony import */ var sockjs_client__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(sockjs_client__WEBPACK_IMPORTED_MODULE_0__);
3777
+ /* harmony import */ var stompjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9);
3778
+ /* harmony import */ var stompjs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(stompjs__WEBPACK_IMPORTED_MODULE_1__);
3779
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
3780
+
3781
+
3782
+
3783
+
3784
+ var WebSocket = function () {
3785
+ // 构造函数
3786
+ function WebSocket() {
3787
+ _classCallCheck(this, WebSocket);
3788
+
3789
+ this.host = sessionStorage.getItem('wshost') || '';
3790
+ this.tryTimes = 1; // 重连次数
3791
+ this.callback = null; // 回调函数
3792
+ this.client = null; // stomp对象
3793
+ this.reconTimeout = null; // 重连延时器
3794
+ this.debug = true; // 调试
3795
+ this.interval = 20; // 重连间隔时间
3796
+ this.vm = null;
3797
+ this.nextDate = 0;
3798
+ this.connects = 1;
3799
+ this.recon = false;
3800
+ this.sendTimeout = null;
3801
+ this.socket = null;
3802
+ this.subscription = null;
3803
+ }
3804
+
3805
+ /** socket连接 */
3806
+
3807
+
3808
+ WebSocket.prototype.connect = function connect() {
3809
+ var _this = this;
3810
+
3811
+ if (!this.client) {
3812
+ // 连接SockJS
3813
+ this.socket = new sockjs_client__WEBPACK_IMPORTED_MODULE_0___default.a(this.host + this.url, { timeout: 60000 });
3814
+ this.client = stompjs__WEBPACK_IMPORTED_MODULE_1___default.a.over(this.socket);
3815
+ }
3816
+
3817
+ // 日志不打印
3818
+ if (!this.debug) {
3819
+ this.client.debug = function () {};
3820
+ }
3821
+
3822
+ // 向服务器发起websocket连接
3823
+ this.client.connect({}, function () {
3824
+ _this.recon = true;
3825
+ // tryTimes定义重置
3826
+ _this.connects = 1;
3827
+ // 订阅消息
3828
+ _this.subscribe();
3829
+ }, function (error) {
3830
+ _this.unsubscribe();
3831
+ _this.client = null;
3832
+ var diffSecond = parseInt((new Date() - _this.nextDate) / 1000, 10);
3833
+ if (_this.connects > 5 && diffSecond < _this.interval) {
3834
+ _this.error && _this.error(error);
3835
+ } else {
3836
+ _this.reconTimeout = setTimeout(function () {
3837
+ _this.connect();
3838
+ _this.connects++;
3839
+ }, 5000);
3840
+ }
3841
+ });
3842
+ }; // 清除订阅
3843
+
3844
+
3845
+ WebSocket.prototype.unsubscribe = function unsubscribe() {
3846
+ if (this.subscription) {
3847
+ this.subscription.unsubscribe();
3848
+ this.subscription = null;
3849
+ }
3850
+ };
3851
+ /** 订阅服务端 */
3852
+
3853
+
3854
+ WebSocket.prototype.subscribe = function subscribe() {
3855
+ var _this2 = this;
3856
+
3857
+ // 订阅服务端提供的某个topic
3858
+ this.subscription = this.client.subscribe(this.take, function (response) {
3859
+ if (response && (_this2.callback || _this2.success)) {
3860
+ var callback = _this2.callback || _this2.success;
3861
+ callback(JSON.parse(response.body));
3862
+ }
3863
+ });
3864
+ };
3865
+
3866
+ /** 赋值、初始化socket */
3867
+
3868
+
3869
+ WebSocket.prototype.init = function init(option, vm) {
3870
+ for (var i in option) {
3871
+ this[i] = option[i];
3872
+ }
3873
+ this.vm = vm;
3874
+ // 初始化连接
3875
+ this.connect();
3876
+ };
3877
+
3878
+ /** 发送消息 */
3879
+
3880
+
3881
+ WebSocket.prototype.send = function send(data) {
3882
+ var _this3 = this;
3883
+
3884
+ if (this.recon) {
3885
+ clearTimeout(this.sendTimeout);
3886
+ this.client.send(this.take, {}, typeof data === 'string' ? data : JSON.stringify(data));
3887
+ } else {
3888
+ this.sendTimeout = setTimeout(function () {
3889
+ _this3.send(data);
3890
+ }, 1000);
3891
+ }
3892
+ };
3893
+
3894
+ /** 销毁 */
3895
+
3896
+
3897
+ WebSocket.prototype.destroy = function destroy() {
3898
+ // 断开连接,清除定时器
3899
+ this.unsubscribe();
3900
+ if (this.client) {
3901
+ this.client.disconnect();
3902
+ };
3903
+ this.reconTimeout && clearTimeout(this.reconTimeout);
3904
+ this.sendTimeout && clearTimeout(this.sendTimeout);
3905
+ };
3906
+
3907
+ return WebSocket;
3908
+ }();
3909
+
3910
+ /* harmony default export */ __webpack_exports__["a"] = (WebSocket);
3911
+
3912
+ /***/ }),
3913
+
3914
+ /***/ 70:
3768
3915
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3769
3916
 
3770
3917
  "use strict";
@@ -4005,149 +4152,6 @@ main.install = function (Vue) {
4005
4152
 
4006
4153
  /***/ }),
4007
4154
 
4008
- /***/ 7:
4009
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
4010
-
4011
- "use strict";
4012
- /* harmony import */ var sockjs_client__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8);
4013
- /* harmony import */ var sockjs_client__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(sockjs_client__WEBPACK_IMPORTED_MODULE_0__);
4014
- /* harmony import */ var stompjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9);
4015
- /* harmony import */ var stompjs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(stompjs__WEBPACK_IMPORTED_MODULE_1__);
4016
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
4017
-
4018
-
4019
-
4020
-
4021
- var WebSocket = function () {
4022
- // 构造函数
4023
- function WebSocket() {
4024
- _classCallCheck(this, WebSocket);
4025
-
4026
- this.host = sessionStorage.getItem('wshost') || '';
4027
- this.tryTimes = 1; // 重连次数
4028
- this.callback = null; // 回调函数
4029
- this.client = null; // stomp对象
4030
- this.reconTimeout = null; // 重连延时器
4031
- this.debug = true; // 调试
4032
- this.interval = 20; // 重连间隔时间
4033
- this.vm = null;
4034
- this.nextDate = 0;
4035
- this.connects = 1;
4036
- this.recon = false;
4037
- this.sendTimeout = null;
4038
- this.socket = null;
4039
- this.subscription = null;
4040
- }
4041
-
4042
- /** socket连接 */
4043
-
4044
-
4045
- WebSocket.prototype.connect = function connect() {
4046
- var _this = this;
4047
-
4048
- if (!this.client) {
4049
- // 连接SockJS
4050
- this.socket = new sockjs_client__WEBPACK_IMPORTED_MODULE_0___default.a(this.host + this.url, { timeout: 60000 });
4051
- this.client = stompjs__WEBPACK_IMPORTED_MODULE_1___default.a.over(this.socket);
4052
- }
4053
-
4054
- // 日志不打印
4055
- if (!this.debug) {
4056
- this.client.debug = function () {};
4057
- }
4058
-
4059
- // 向服务器发起websocket连接
4060
- this.client.connect({}, function () {
4061
- _this.recon = true;
4062
- // tryTimes定义重置
4063
- _this.connects = 1;
4064
- // 订阅消息
4065
- _this.subscribe();
4066
- }, function (error) {
4067
- _this.unsubscribe();
4068
- _this.client = null;
4069
- var diffSecond = parseInt((new Date() - _this.nextDate) / 1000, 10);
4070
- if (_this.connects > 5 && diffSecond < _this.interval) {
4071
- _this.error && _this.error(error);
4072
- } else {
4073
- _this.reconTimeout = setTimeout(function () {
4074
- _this.connect();
4075
- _this.connects++;
4076
- }, 5000);
4077
- }
4078
- });
4079
- }; // 清除订阅
4080
-
4081
-
4082
- WebSocket.prototype.unsubscribe = function unsubscribe() {
4083
- if (this.subscription) {
4084
- this.subscription.unsubscribe();
4085
- this.subscription = null;
4086
- }
4087
- };
4088
- /** 订阅服务端 */
4089
-
4090
-
4091
- WebSocket.prototype.subscribe = function subscribe() {
4092
- var _this2 = this;
4093
-
4094
- // 订阅服务端提供的某个topic
4095
- this.subscription = this.client.subscribe(this.take, function (response) {
4096
- if (response && (_this2.callback || _this2.success)) {
4097
- var callback = _this2.callback || _this2.success;
4098
- callback(JSON.parse(response.body));
4099
- }
4100
- });
4101
- };
4102
-
4103
- /** 赋值、初始化socket */
4104
-
4105
-
4106
- WebSocket.prototype.init = function init(option, vm) {
4107
- for (var i in option) {
4108
- this[i] = option[i];
4109
- }
4110
- this.vm = vm;
4111
- // 初始化连接
4112
- this.connect();
4113
- };
4114
-
4115
- /** 发送消息 */
4116
-
4117
-
4118
- WebSocket.prototype.send = function send(data) {
4119
- var _this3 = this;
4120
-
4121
- if (this.recon) {
4122
- clearTimeout(this.sendTimeout);
4123
- this.client.send(this.take, {}, typeof data === 'string' ? data : JSON.stringify(data));
4124
- } else {
4125
- this.sendTimeout = setTimeout(function () {
4126
- _this3.send(data);
4127
- }, 1000);
4128
- }
4129
- };
4130
-
4131
- /** 销毁 */
4132
-
4133
-
4134
- WebSocket.prototype.destroy = function destroy() {
4135
- // 断开连接,清除定时器
4136
- this.unsubscribe();
4137
- if (this.client) {
4138
- this.client.disconnect();
4139
- };
4140
- this.reconTimeout && clearTimeout(this.reconTimeout);
4141
- this.sendTimeout && clearTimeout(this.sendTimeout);
4142
- };
4143
-
4144
- return WebSocket;
4145
- }();
4146
-
4147
- /* harmony default export */ __webpack_exports__["a"] = (WebSocket);
4148
-
4149
- /***/ }),
4150
-
4151
4155
  /***/ 8:
4152
4156
  /***/ (function(module, exports) {
4153
4157
 
package/lib/wxlogin.js CHANGED
@@ -82,7 +82,7 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 70);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 71);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
@@ -2175,6 +2175,7 @@ var isLogined = function isLogined(_ref8) {
2175
2175
  next && next();
2176
2176
  } else {
2177
2177
  if (!token && Object.prototype.hasOwnProperty.call(to.query, 'serverId') && Object.prototype.hasOwnProperty.call(to.query, 'authType')) {
2178
+ var loadingInstance = eoss_element__WEBPACK_IMPORTED_MODULE_5__["Loading"].service({ text: '页面加载中', spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.65)' });
2178
2179
  ajax({
2179
2180
  method: 'post',
2180
2181
  url: _config_api__WEBPACK_IMPORTED_MODULE_0__[/* authCenter */ "b"],
@@ -2273,7 +2274,10 @@ var isLogined = function isLogined(_ref8) {
2273
2274
  }
2274
2275
  });
2275
2276
  }
2276
- }).catch(function (e) {});
2277
+ loadingInstance.close();
2278
+ }).catch(function (e) {
2279
+ loadingInstance.close();
2280
+ });
2277
2281
  } else if (token || to.path === '/' || to.path === '/404' || to.path === '/error' || typeof exclude === 'boolean' && exclude || exclude.indexOf(to.path) > -1 || exclude.indexOf(to.name) > -1 || to.path === '/login' || token && to.path === '/main') {
2278
2282
  if (redirect && (to.path === '/main' || to.path === '/login')) {
2279
2283
  window.location.replace(urlJoinParams({ url: '.' + to.path + '.html', param: to.query }));
@@ -2676,7 +2680,7 @@ var setScale = function setScale() {
2676
2680
  } else {
2677
2681
  n = 1;
2678
2682
  }
2679
- if (zoom === 1) {
2683
+ if (zoom === 1 && window.innerWidth === width) {
2680
2684
  document.body.style.removeProperty('transform');
2681
2685
  document.body.style.removeProperty('width');
2682
2686
  document.body.style.removeProperty('height');
@@ -3907,7 +3911,7 @@ var WebSocket = function () {
3907
3911
 
3908
3912
  /***/ }),
3909
3913
 
3910
- /***/ 70:
3914
+ /***/ 71:
3911
3915
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3912
3916
 
3913
3917
  "use strict";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eoss-ui",
3
- "version": "0.5.97",
3
+ "version": "0.5.99",
4
4
  "description": "eoss内部业务组件",
5
5
  "main": "lib/eoss-ui.common.js",
6
6
  "files": [
Binary file
@@ -454,9 +454,13 @@ export default {
454
454
  default: true
455
455
  },
456
456
  index: {
457
- type: [Boolean, Number],
457
+ type: [Number, Function],
458
458
  default: 1
459
459
  },
460
+ accumulated: {
461
+ type: Boolean,
462
+ default: true
463
+ },
460
464
  immediate: {
461
465
  type: Boolean,
462
466
  default: true
@@ -594,17 +598,19 @@ export default {
594
598
  }
595
599
  if (this.numbers && !types.includes('index')) {
596
600
  let index = 1;
597
- if (this.orders == 'desc') {
598
- index = (num) => {
599
- return this.config.totalCount - num;
600
- };
601
- } else if (this.infiniteScroll) {
602
- index = typeof this.index == 'boolean' ? 1 : this.index;
603
- } else if (this.index || this.index === 0) {
604
- index =
605
- this.index === true
606
- ? (this.config.pageNum - 1) * this.config.pageSize + 1
607
- : this.index;
601
+ if (typeof this.index === 'function') {
602
+ index = this.index;
603
+ } else {
604
+ if (this.orders == 'desc') {
605
+ index = (num) => {
606
+ return this.config.totalCount - num;
607
+ };
608
+ } else if (this.accumulated) {
609
+ index =
610
+ (this.config.pageNum - 1) * this.config.pageSize + this.index;
611
+ } else {
612
+ index = this.index;
613
+ }
608
614
  }
609
615
  thead.push({
610
616
  type: 'index',