eoss-ui 0.4.66 → 0.4.67

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.
package/lib/main.js CHANGED
@@ -2951,7 +2951,7 @@ module.exports = require("stompjs");
2951
2951
  // ESM COMPAT FLAG
2952
2952
  __webpack_require__.r(__webpack_exports__);
2953
2953
 
2954
- // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/main/src/main.vue?vue&type=template&id=9f517a06&
2954
+ // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/main/src/main.vue?vue&type=template&id=3f8b642a&
2955
2955
  var render = function () {
2956
2956
  var _vm = this
2957
2957
  var _h = _vm.$createElement
@@ -3377,10 +3377,10 @@ var staticRenderFns = []
3377
3377
  render._withStripped = true
3378
3378
 
3379
3379
 
3380
- // CONCATENATED MODULE: ./packages/main/src/main.vue?vue&type=template&id=9f517a06&
3380
+ // CONCATENATED MODULE: ./packages/main/src/main.vue?vue&type=template&id=3f8b642a&
3381
3381
 
3382
- // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/main/src/userinfo.vue?vue&type=template&id=c2c69d4a&
3383
- var userinfovue_type_template_id_c2c69d4a_render = function () {
3382
+ // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/main/src/userinfo.vue?vue&type=template&id=799780ee&
3383
+ var userinfovue_type_template_id_799780ee_render = function () {
3384
3384
  var _vm = this
3385
3385
  var _h = _vm.$createElement
3386
3386
  var _c = _vm._self._c || _h
@@ -3396,11 +3396,11 @@ var userinfovue_type_template_id_c2c69d4a_render = function () {
3396
3396
  2
3397
3397
  )
3398
3398
  }
3399
- var userinfovue_type_template_id_c2c69d4a_staticRenderFns = []
3400
- userinfovue_type_template_id_c2c69d4a_render._withStripped = true
3399
+ var userinfovue_type_template_id_799780ee_staticRenderFns = []
3400
+ userinfovue_type_template_id_799780ee_render._withStripped = true
3401
3401
 
3402
3402
 
3403
- // CONCATENATED MODULE: ./packages/main/src/userinfo.vue?vue&type=template&id=c2c69d4a&
3403
+ // CONCATENATED MODULE: ./packages/main/src/userinfo.vue?vue&type=template&id=799780ee&
3404
3404
 
3405
3405
  // EXTERNAL MODULE: ./src/config/api.js
3406
3406
  var api = __webpack_require__(1);
@@ -3436,6 +3436,10 @@ var util = __webpack_require__(0);
3436
3436
  showNotify: {
3437
3437
  type: Boolean,
3438
3438
  default: true
3439
+ },
3440
+ secret: {
3441
+ type: Boolean,
3442
+ default: true
3439
3443
  }
3440
3444
  },
3441
3445
  data: function data() {
@@ -3720,11 +3724,11 @@ var util = __webpack_require__(0);
3720
3724
  email: this.values.email,
3721
3725
  officeTel: this.values.officetel,
3722
3726
  phone: this.values.phone,
3723
- oldPassword: initLogin && initLogin.secret && this.values.oldpassword ? util["a" /* default */].esmEncrypt({
3727
+ oldPassword: this.secret && initLogin && initLogin.secret && this.values.oldpassword ? util["a" /* default */].esmEncrypt({
3724
3728
  data: this.values.oldpassword,
3725
3729
  key: initLogin.secret
3726
3730
  }) : this.values.oldpassword,
3727
- password: initLogin && initLogin.secret && this.values.password ? util["a" /* default */].esmEncrypt({
3731
+ password: this.secret && initLogin && initLogin.secret && this.values.password ? util["a" /* default */].esmEncrypt({
3728
3732
  data: this.values.password,
3729
3733
  key: initLogin.secret
3730
3734
  }) : this.values.password
@@ -3823,8 +3827,8 @@ var componentNormalizer = __webpack_require__(3);
3823
3827
 
3824
3828
  var component = Object(componentNormalizer["a" /* default */])(
3825
3829
  src_userinfovue_type_script_lang_js_,
3826
- userinfovue_type_template_id_c2c69d4a_render,
3827
- userinfovue_type_template_id_c2c69d4a_staticRenderFns,
3830
+ userinfovue_type_template_id_799780ee_render,
3831
+ userinfovue_type_template_id_799780ee_staticRenderFns,
3828
3832
  false,
3829
3833
  null,
3830
3834
  null,
@@ -6003,10 +6007,10 @@ var log = util["a" /* default */].getParams('console');
6003
6007
  this.homePage = results[i];
6004
6008
  if (this.isHomePage) {
6005
6009
  if (this.menus) {
6006
- var _ids4 = null;
6007
- this.homePage && (_ids4 = this.getId(this.menus, this.homePage));
6008
- if (_ids4) {
6009
- this.defaultActive = _ids4;
6010
+ var ids = null;
6011
+ this.homePage && (ids = this.getId(this.menus, this.homePage));
6012
+ if (ids) {
6013
+ this.defaultActive = ids;
6010
6014
  } else if (this.homePage) {
6011
6015
  this.handleJump(this.homePage);
6012
6016
  }
@@ -6156,9 +6160,9 @@ var log = util["a" /* default */].getParams('console');
6156
6160
  _this5.menus = JSON.parse(JSON.stringify(res.results));
6157
6161
  var applicationid = util["a" /* default */].getParams('applicationid') || util["a" /* default */].getParams('applicationId');
6158
6162
  if (applicationid) {
6159
- var _ids5 = _this5.getId(_this5.menus, applicationid);
6160
- if (_ids5) {
6161
- _this5.defaultActive = _ids5;
6163
+ var ids = _this5.getId(_this5.menus, applicationid);
6164
+ if (ids) {
6165
+ _this5.defaultActive = ids;
6162
6166
  }
6163
6167
  } else if (util["a" /* default */].win.location.hash) {
6164
6168
  var hash = util["a" /* default */].win.location.hash;
@@ -6166,26 +6170,26 @@ var log = util["a" /* default */].getParams('console');
6166
6170
  hash = hash.split('?')[0];
6167
6171
  }
6168
6172
  if (hash !== '#/' && hash !== '#/main') {
6169
- var _ids6 = _this5.getId(_this5.menus, util["a" /* default */].win.location.hash, true);
6170
- if (_ids6) {
6171
- _this5.defaultActive = _ids6;
6172
- _this5.navIds = _ids6;
6173
- _this5.setTitle(_ids6[0]);
6173
+ var _ids4 = _this5.getId(_this5.menus, util["a" /* default */].win.location.hash, true);
6174
+ if (_ids4) {
6175
+ _this5.defaultActive = _ids4;
6176
+ _this5.navIds = _ids4;
6177
+ _this5.setTitle(_ids4[0]);
6174
6178
  }
6175
6179
  } else if (sessionStorage.getItem('jump') && _this5.history) {
6176
- var _ids7 = _this5.getId(_this5.menus, sessionStorage.getItem('jump'), true);
6177
- if (_ids7) {
6178
- _this5.defaultActive = _ids7;
6179
- _this5.navIds = _ids7;
6180
- _this5.setTitle(_ids7[0]);
6180
+ var _ids5 = _this5.getId(_this5.menus, sessionStorage.getItem('jump'), true);
6181
+ if (_ids5) {
6182
+ _this5.defaultActive = _ids5;
6183
+ _this5.navIds = _ids5;
6184
+ _this5.setTitle(_ids5[0]);
6181
6185
  }
6182
6186
  }
6183
6187
  } else if (sessionStorage.getItem('jump') && _this5.history) {
6184
- var _ids8 = _this5.getId(_this5.menus, sessionStorage.getItem('jump'), true);
6185
- if (_ids8) {
6186
- _this5.defaultActive = _ids8;
6187
- _this5.navIds = _ids8;
6188
- _this5.setTitle(_ids8[0]);
6188
+ var _ids6 = _this5.getId(_this5.menus, sessionStorage.getItem('jump'), true);
6189
+ if (_ids6) {
6190
+ _this5.defaultActive = _ids6;
6191
+ _this5.navIds = _ids6;
6192
+ _this5.setTitle(_ids6[0]);
6189
6193
  }
6190
6194
  }
6191
6195
  _this5.setTips(_this5.menus);
@@ -6211,9 +6215,9 @@ var log = util["a" /* default */].getParams('console');
6211
6215
  if (this.homePage || !util["a" /* default */].getStorage('mainConfig')) {
6212
6216
  this.isDefault = true;
6213
6217
  if (this.homePage && (!this.defaultActive || !this.defaultActive.length)) {
6214
- var _ids9 = this.getId(this.menus, this.homePage);
6215
- if (_ids9) {
6216
- this.defaultActive = _ids9;
6218
+ var ids = this.getId(this.menus, this.homePage);
6219
+ if (ids) {
6220
+ this.defaultActive = ids;
6217
6221
  this.isDefault = false;
6218
6222
  this.setDefault(res, this.defaultActive);
6219
6223
  return false;
@@ -6477,11 +6481,14 @@ var log = util["a" /* default */].getParams('console');
6477
6481
  switch (type) {
6478
6482
  case 'nav':
6479
6483
  this.tabs = [];
6480
- this.active = '';
6484
+ //this.active = '';
6481
6485
  if (this.layout === 'topside') {
6482
- this.navIds = [node.id];
6483
- this.menu = node.children;
6484
- this.title = node.text;
6486
+ if (this.title !== node.text) {
6487
+ this.navIds = [node.id];
6488
+ this.menu = node.children;
6489
+ this.active = node.id;
6490
+ this.title = node.text;
6491
+ }
6485
6492
  if (this.setFirstAsDefault) {
6486
6493
  var subNode = this.getFirst(node);
6487
6494
  if (subNode) {
@@ -6491,7 +6498,7 @@ var log = util["a" /* default */].getParams('console');
6491
6498
  }
6492
6499
  } else {
6493
6500
  this.navIds = this.getId(this.menus, node.url, true);
6494
- this.setTitle(ids[0]);
6501
+ this.setTitle(this.navIds[0]);
6495
6502
  this.tabsId = fourthTabs ? node.id : '';
6496
6503
  }
6497
6504
  break;
@@ -6500,7 +6507,10 @@ var log = util["a" /* default */].getParams('console');
6500
6507
  this.navIds = [node.id];
6501
6508
  this.tabs = [];
6502
6509
  this.menu = node.children;
6503
- this.title = node.text;
6510
+ if (this.title !== node.text) {
6511
+ this.active = '';
6512
+ this.title = node.text;
6513
+ }
6504
6514
  if (this.setFirstAsDefault) {
6505
6515
  var _subNode = this.getFirst(node);
6506
6516
  if (_subNode) {
@@ -6516,6 +6526,10 @@ var log = util["a" /* default */].getParams('console');
6516
6526
  if (node.url) {
6517
6527
  this.tabs = [];
6518
6528
  }
6529
+ if (this.title !== node.text) {
6530
+ this.active = [node.id];
6531
+ this.title = node.text;
6532
+ }
6519
6533
  if (this.setFirstAsDefault) {
6520
6534
  var _subNode2 = this.getFirst(node);
6521
6535
  this.active = [node.id];
@@ -6566,16 +6580,18 @@ var log = util["a" /* default */].getParams('console');
6566
6580
  this.navIds = this.getId(this.menus, this.tabs[0].url, true);
6567
6581
  }
6568
6582
  }
6569
- } else if (this.setFirstAsDefault) {
6570
- this.tabs = [];
6571
- var _subNode3 = this.getFirst(node);
6572
- if (_subNode3) {
6573
- if (this.biserial) {
6574
- this.$set(this.active, 1, _subNode3.id);
6575
- } else {
6576
- this.active = _subNode3.id;
6583
+ } else {
6584
+ if (this.setFirstAsDefault) {
6585
+ this.tabs = [];
6586
+ var _subNode3 = this.getFirst(node);
6587
+ if (_subNode3) {
6588
+ if (this.biserial) {
6589
+ this.$set(this.active, 1, _subNode3.id);
6590
+ } else {
6591
+ this.active = _subNode3.id;
6592
+ }
6593
+ this.navIds = this.getId(this.menus, _subNode3.url, true);
6577
6594
  }
6578
- this.navIds = this.getId(this.menus, _subNode3.url, true);
6579
6595
  }
6580
6596
  }
6581
6597
  break;
@@ -6810,6 +6826,9 @@ var log = util["a" /* default */].getParams('console');
6810
6826
  return false;
6811
6827
  },
6812
6828
  handleLayout: function handleLayout(res, old) {
6829
+ if (res == old) {
6830
+ return;
6831
+ }
6813
6832
  this.layout = res;
6814
6833
  switch (res) {
6815
6834
  case 'topnav':
package/lib/menu.js CHANGED
@@ -292,7 +292,9 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
292
292
  return {
293
293
  maxH: '',
294
294
  maxW: '',
295
- menuId: null
295
+ menuId: null,
296
+ defaultOpeneds: [],
297
+ isChange: false
296
298
  };
297
299
  },
298
300
  mounted: function mounted() {},
@@ -314,6 +316,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
314
316
  handleSelect: function handleSelect(key, keyPath, item) {
315
317
  var _this2 = this;
316
318
 
319
+ this.isChange = true;
317
320
  if (this.menuId !== null && keyPath.indexOf(this.menuId) == -1) {
318
321
  this.$refs.menu.close(this.menuId);
319
322
  } else {
@@ -390,7 +393,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
390
393
  }
391
394
  }));
392
395
  return [h('el-submenu', {
393
- class: ['es-submenu', 'es-submenu-' + this.mode],
396
+ class: ['es-submenu', 'es-submenu-' + this.mode, item.id === this.active && !this.isChange ? 'es-menu-item-focus' : ''],
394
397
  props: {
395
398
  popperClass: popper,
396
399
  popperAppendToBody: true,
@@ -408,7 +411,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
408
411
  }
409
412
  }));
410
413
  return [h('el-submenu', {
411
- class: ['es-submenu', 'es-submenu-' + this.mode],
414
+ class: ['es-submenu', 'es-submenu-' + this.mode, item.id === this.active && !this.isChange ? 'es-menu-item-focus' : ''],
412
415
  props: {
413
416
  popperClass: popper,
414
417
  popperAppendToBody: true,
@@ -492,6 +495,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
492
495
  class: ['es-menu', 'es-menu-' + this.mode, { 'es-menu-collapse': this.collapse }, { 'es-menu-nav': this.subNav }],
493
496
  ref: 'menu',
494
497
  props: {
498
+ defaultOpeneds: this.defaultOpeneds,
495
499
  defaultActive: this.active,
496
500
  collapse: this.collapse,
497
501
  mode: this.mode,
package/lib/nav.js CHANGED
@@ -2872,7 +2872,7 @@ module.exports = require("qs");
2872
2872
  // ESM COMPAT FLAG
2873
2873
  __webpack_require__.r(__webpack_exports__);
2874
2874
 
2875
- // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/nav/src/main.vue?vue&type=template&id=57ae81a0&
2875
+ // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/nav/src/main.vue?vue&type=template&id=1e79807a&
2876
2876
  var render = function () {
2877
2877
  var _vm = this
2878
2878
  var _h = _vm.$createElement
@@ -3015,7 +3015,7 @@ var staticRenderFns = []
3015
3015
  render._withStripped = true
3016
3016
 
3017
3017
 
3018
- // CONCATENATED MODULE: ./packages/nav/src/main.vue?vue&type=template&id=57ae81a0&
3018
+ // CONCATENATED MODULE: ./packages/nav/src/main.vue?vue&type=template&id=1e79807a&
3019
3019
 
3020
3020
  // EXTERNAL MODULE: ./src/utils/util.js
3021
3021
  var util = __webpack_require__(0);
@@ -3152,6 +3152,7 @@ var util = __webpack_require__(0);
3152
3152
  biserial: {
3153
3153
  handler: function handler(val) {
3154
3154
  this.isShow = !val;
3155
+ this.resetHeight();
3155
3156
  }
3156
3157
  },
3157
3158
  defaultActive: {
package/lib/player.js CHANGED
@@ -2746,7 +2746,7 @@ var formContents = '/config/admin/online/onlineForm/render';
2746
2746
 
2747
2747
  /***/ }),
2748
2748
 
2749
- /***/ 14:
2749
+ /***/ 15:
2750
2750
  /***/ (function(module, exports) {
2751
2751
 
2752
2752
  module.exports = require("video.js");
@@ -2921,7 +2921,7 @@ render._withStripped = true
2921
2921
  // CONCATENATED MODULE: ./packages/player/src/main.vue?vue&type=template&id=29c1659e&
2922
2922
 
2923
2923
  // EXTERNAL MODULE: external "video.js"
2924
- var external_video_js_ = __webpack_require__(14);
2924
+ var external_video_js_ = __webpack_require__(15);
2925
2925
  var external_video_js_default = /*#__PURE__*/__webpack_require__.n(external_video_js_);
2926
2926
 
2927
2927
  // EXTERNAL MODULE: external "video.js/dist/lang/zh-CN.json"
@@ -2879,7 +2879,7 @@ module.exports = require("axios");
2879
2879
  // ESM COMPAT FLAG
2880
2880
  __webpack_require__.r(__webpack_exports__);
2881
2881
 
2882
- // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/radio-group/src/main.vue?vue&type=template&id=34723cb0&
2882
+ // CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./packages/radio-group/src/main.vue?vue&type=template&id=64807cce&
2883
2883
  var render = function () {
2884
2884
  var _vm = this
2885
2885
  var _h = _vm.$createElement
@@ -3012,7 +3012,7 @@ var staticRenderFns = []
3012
3012
  render._withStripped = true
3013
3013
 
3014
3014
 
3015
- // CONCATENATED MODULE: ./packages/radio-group/src/main.vue?vue&type=template&id=34723cb0&
3015
+ // CONCATENATED MODULE: ./packages/radio-group/src/main.vue?vue&type=template&id=64807cce&
3016
3016
 
3017
3017
  // EXTERNAL MODULE: ./src/config/api.js
3018
3018
  var api = __webpack_require__(1);
@@ -3090,6 +3090,14 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3090
3090
  /* harmony default export */ var mainvue_type_script_lang_js_ = ({
3091
3091
  name: 'EsRadioGroup',
3092
3092
  inheritAttrs: false,
3093
+ inject: {
3094
+ esForm: {
3095
+ default: ''
3096
+ },
3097
+ sysCodes: {
3098
+ default: ''
3099
+ }
3100
+ },
3093
3101
  props: {
3094
3102
  method: {
3095
3103
  type: String,
@@ -3151,11 +3159,13 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3151
3159
  isNoParamRequest: {
3152
3160
  type: Boolean,
3153
3161
  default: true
3154
- }
3162
+ },
3163
+ dataKey: String
3155
3164
  },
3156
3165
  data: function data() {
3157
3166
  return {
3158
- options: null
3167
+ options: null,
3168
+ canceled: false
3159
3169
  };
3160
3170
  },
3161
3171
 
@@ -3244,6 +3254,18 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3244
3254
  handler: function handler() {
3245
3255
  this.url && this.getData(this.url);
3246
3256
  }
3257
+ },
3258
+ sysCodes: {
3259
+ deep: true,
3260
+ handler: function handler(val) {
3261
+ if (this.canceled && val && (this.sysCode && val[this.sysCode] || this.dataKey && val[this.dataKey])) {
3262
+ if (this.parseData) {
3263
+ this.options = this.parseData(JSON.parse(JSON.stringify(val[this.sysCode || this.dataKey])));
3264
+ } else {
3265
+ this.options = JSON.parse(JSON.stringify(val[this.sysCode || this.dataKey]));
3266
+ }
3267
+ }
3268
+ }
3247
3269
  }
3248
3270
  },
3249
3271
  created: function created() {},
@@ -3270,16 +3292,23 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3270
3292
  data: params
3271
3293
  }).then(function (res) {
3272
3294
  _this2.loading = false;
3295
+ _this2.canceled = false;
3273
3296
  if (res.rCode === 0) {
3274
3297
  _this2.options = JSON.parse(JSON.stringify(res.results));
3275
- if (sysCode) {
3298
+ if (sysCode || _this2.dataKey) {
3299
+ _this2.esForm && _this2.esForm.setSysCodes(sysCode || _this2.dataKey, JSON.parse(JSON.stringify(_this2.options)));
3276
3300
  store["a" /* default */].set(sysCode, JSON.parse(JSON.stringify(res.results)));
3277
3301
  }
3278
3302
  }
3279
3303
  }).catch(function (err) {
3280
3304
  _this2.loading = false;
3281
- if (err.message && err.message !== 'canceled') {
3282
- _this2.$message.error(err.message);
3305
+ if (err.message) {
3306
+ if (err.message !== 'canceled') {
3307
+ _this2.$message.error(err.message);
3308
+ }
3309
+ if (err.message === 'canceled' && sysCode) {
3310
+ _this2.canceled = true;
3311
+ }
3283
3312
  }
3284
3313
  });
3285
3314
  },
@@ -2910,6 +2910,14 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
2910
2910
  };
2911
2911
  },
2912
2912
 
2913
+ inject: {
2914
+ esForm: {
2915
+ default: ''
2916
+ },
2917
+ sysCodes: {
2918
+ default: ''
2919
+ }
2920
+ },
2913
2921
  props: {
2914
2922
  method: {
2915
2923
  type: String,
@@ -3003,7 +3011,8 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
3003
3011
  type: String,
3004
3012
  default: 'hasSub'
3005
3013
  },
3006
- defaultValue: Boolean
3014
+ defaultValue: Boolean,
3015
+ dataKey: String
3007
3016
  },
3008
3017
  data: function data() {
3009
3018
  return {
@@ -3015,7 +3024,8 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
3015
3024
  wheres: [{}],
3016
3025
  first: true,
3017
3026
  height: undefined,
3018
- gangedNum: null
3027
+ gangedNum: null,
3028
+ canceled: false
3019
3029
  };
3020
3030
  },
3021
3031
 
@@ -3128,13 +3138,23 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
3128
3138
  params: this.param,
3129
3139
  data: this.param
3130
3140
  }).then(function (res) {
3141
+ _this.canceled = false;
3131
3142
  if (res.rCode === 0) {
3132
3143
  _this.lists = res.results;
3133
3144
  _this.getChildren(_this.results, _this.values);
3145
+ if (sysCode || _this.dataKey) {
3146
+ _this.esForm && _this.esForm.setSysCodes(sysCode || _this.dataKey, JSON.parse(JSON.stringify(_this.lists)));
3147
+ store.set(sysCode, JSON.parse(JSON.stringify(_this.lists)));
3148
+ }
3134
3149
  }
3135
- }).catch(function (e) {
3136
- if (err.message && err.message !== 'canceled') {
3137
- _this.$message.error(err.message);
3150
+ }).catch(function (err) {
3151
+ if (err.message) {
3152
+ if (err.message !== 'canceled') {
3153
+ _this.$message.error(err.message);
3154
+ }
3155
+ if (err.message === 'canceled' && sysCode) {
3156
+ _this.canceled = true;
3157
+ }
3138
3158
  }
3139
3159
  });
3140
3160
  },
package/lib/select.js CHANGED
@@ -2746,6 +2746,13 @@ var formContents = '/config/admin/online/onlineForm/render';
2746
2746
 
2747
2747
  /***/ }),
2748
2748
 
2749
+ /***/ 14:
2750
+ /***/ (function(module, exports) {
2751
+
2752
+ module.exports = require("slate");
2753
+
2754
+ /***/ }),
2755
+
2749
2756
  /***/ 2:
2750
2757
  /***/ (function(module, exports) {
2751
2758
 
@@ -2902,6 +2909,9 @@ var store = __webpack_require__(8);
2902
2909
  // EXTERNAL MODULE: ./src/utils/util.js
2903
2910
  var util = __webpack_require__(0);
2904
2911
 
2912
+ // EXTERNAL MODULE: external "slate"
2913
+ var external_slate_ = __webpack_require__(14);
2914
+
2905
2915
  // CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./packages/select/src/main.vue?vue&type=script&lang=js&
2906
2916
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
2907
2917
 
@@ -2910,6 +2920,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
2910
2920
 
2911
2921
 
2912
2922
 
2923
+
2913
2924
  /* harmony default export */ var mainvue_type_script_lang_js_ = ({
2914
2925
  name: 'EsSelect',
2915
2926
  componentName: 'EsSelect',
@@ -2920,6 +2931,14 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
2920
2931
  };
2921
2932
  },
2922
2933
 
2934
+ inject: {
2935
+ esForm: {
2936
+ default: ''
2937
+ },
2938
+ sysCodes: {
2939
+ default: ''
2940
+ }
2941
+ },
2923
2942
  props: {
2924
2943
  value: [String, Array, Object, Number],
2925
2944
  method: {
@@ -3028,7 +3047,8 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3028
3047
  isNoParamRequest: {
3029
3048
  type: Boolean,
3030
3049
  default: true
3031
- }
3050
+ },
3051
+ dataKey: String
3032
3052
  },
3033
3053
  data: function data() {
3034
3054
  return {
@@ -3036,7 +3056,8 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3036
3056
  options: '',
3037
3057
  valKey: this.valueKey,
3038
3058
  label: this.labelKey,
3039
- hidden: false
3059
+ hidden: false,
3060
+ canceled: false
3040
3061
  };
3041
3062
  },
3042
3063
 
@@ -3119,6 +3140,18 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3119
3140
  this.getData(this.sysCode);
3120
3141
  }
3121
3142
  }
3143
+ },
3144
+ sysCodes: {
3145
+ deep: true,
3146
+ handler: function handler(val) {
3147
+ if (this.canceled && val && (this.sysCode && val[this.sysCode] || this.dataKey && val[this.dataKey])) {
3148
+ if (this.parseData) {
3149
+ this.options = this.parseData(JSON.parse(JSON.stringify(val[this.sysCode || this.dataKey])));
3150
+ } else {
3151
+ this.options = JSON.parse(JSON.stringify(val[this.sysCode || this.dataKey]));
3152
+ }
3153
+ }
3154
+ }
3122
3155
  }
3123
3156
  },
3124
3157
  mounted: function mounted() {
@@ -3201,13 +3234,15 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3201
3234
  data: params
3202
3235
  }).then(function (res) {
3203
3236
  _this3.loading = false;
3237
+ _this3.canceled = false;
3204
3238
  if (res.rCode === 0) {
3205
3239
  if (_this3.parseData) {
3206
- _this3.options = _this3.parseData(res.results);
3240
+ _this3.options = _this3.parseData(JSON.parse(JSON.stringify(res.results)));
3207
3241
  } else {
3208
3242
  _this3.options = JSON.parse(JSON.stringify(res.results));
3209
3243
  }
3210
- if (sysCode) {
3244
+ if (sysCode || _this3.dataKey) {
3245
+ _this3.esForm && _this3.esForm.setSysCodes(sysCode || _this3.dataKey, JSON.parse(JSON.stringify(_this3.options)));
3211
3246
  store["a" /* default */].set(sysCode, JSON.parse(JSON.stringify(_this3.options)));
3212
3247
  }
3213
3248
  } else {
@@ -3215,16 +3250,21 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3215
3250
  }
3216
3251
  }).catch(function (err) {
3217
3252
  _this3.loading = false;
3218
- if (err.message && err.message !== 'canceled') {
3219
- _this3.$message.error(err.message);
3253
+ if (err.message) {
3254
+ if (err.message !== 'canceled') {
3255
+ _this3.$message.error(err.message);
3256
+ }
3257
+ if (err.message === 'canceled' && sysCode) {
3258
+ _this3.canceled = true;
3259
+ }
3220
3260
  }
3221
3261
  });
3222
3262
  },
3223
3263
  search: function search(query) {
3224
3264
  var _this4 = this;
3225
3265
 
3226
- if (query !== '') {
3227
- if (this.url !== '') {
3266
+ if (query && query !== '') {
3267
+ if (this.url && this.url !== '') {
3228
3268
  this.loading = true;
3229
3269
  var params = {};
3230
3270
  params[this.remoteKey] = query;
@@ -3237,13 +3277,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3237
3277
  }).then(function (res) {
3238
3278
  _this4.loading = false;
3239
3279
  if (res.rCode === 0) {
3240
- _this4.options = res.results.filter(function (item) {
3241
- if (item[_this4.label]) {
3242
- return item[_this4.label].toLowerCase().indexOf(query.toLowerCase()) > -1;
3243
- } else {
3244
- return item.label.toLowerCase().indexOf(query.toLowerCase()) > -1;
3245
- }
3246
- });
3280
+ _this4.options = JSON.parse(JSON.stringify(res.results));
3247
3281
  }
3248
3282
  }).catch(function (err) {
3249
3283
  _this4.loading = false;
@@ -3358,6 +3392,9 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3358
3392
  this.onLoadsub({ data: data, params: params, node: node }).then(function (res) {
3359
3393
  _this6.loading = false;
3360
3394
  _this6.$set(data, 'children', JSON.parse(JSON.stringify(res)));
3395
+ if (_this6.dataKey && _this6.esForm) {
3396
+ _this6.esForm.setSysCodes(_this6.dataKey, JSON.parse(JSON.stringify(_this6.options)));
3397
+ }
3361
3398
  }).catch(function (e) {
3362
3399
  _this6.loading = false;
3363
3400
  });
@@ -3382,6 +3419,9 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
3382
3419
  } else {
3383
3420
  console.error('tree数据格式错误');
3384
3421
  }
3422
+ if (_this6.dataKey && _this6.esForm) {
3423
+ _this6.esForm.setSysCodes(_this6.dataKey, JSON.parse(JSON.stringify(_this6.options)));
3424
+ }
3385
3425
  }
3386
3426
  }).catch(function (err) {
3387
3427
  _this6.loading = false;