lt-business-component 1.0.86 → 1.0.88

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.
@@ -48181,7 +48181,7 @@ var getLocalDate = function getLocalDate(value, showTime) {
48181
48181
  };
48182
48182
  var loadProfile = /*#__PURE__*/function () {
48183
48183
  var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(name) {
48184
- var list, baseURL, modelName, i, files, j, path, _name, ps, url, _j;
48184
+ var list, baseURL, modelName, i, localEnvieonmemt, ps, url, j, files, _j, path, _name;
48185
48185
  return _regenerator().w(function (_context) {
48186
48186
  while (1) switch (_context.n) {
48187
48187
  case 0:
@@ -48195,12 +48195,34 @@ var loadProfile = /*#__PURE__*/function () {
48195
48195
  list.push("/" + name[i] + ".json");
48196
48196
  }
48197
48197
  }
48198
- if (false) // removed by dead control flow
48199
- {}
48200
- files = [];
48198
+ localEnvieonmemt = LtConfig.runMode;
48199
+ if (!(localEnvieonmemt === "Dev")) {
48200
+ _context.n = 1;
48201
+ break;
48202
+ }
48203
+ ps = [];
48204
+ url = window.__POWERED_BY_QIANKUN__ ? "http://localhost:".concat(LtConfig.port, "/script/") : baseURL + "script";
48201
48205
  for (j = 0; j < list.length; j++) {
48202
- path = list[j].substr(0, list[j].lastIndexOf("/"));
48203
- _name = list[j].substr(list[j].lastIndexOf("/") + 1);
48206
+ (function (fname) {
48207
+ ps.push($axios.get(url + fname + "?" + new Date().getTime()).then(function (response) {
48208
+ return response.data;
48209
+ }).catch(function () {
48210
+ message.warning("文件" + fname + "解析失败");
48211
+ }));
48212
+ })(list[j]);
48213
+ }
48214
+ return _context.a(2, $axios.all(ps).then(function (res) {
48215
+ if (typeof name == "string") {
48216
+ return res[0];
48217
+ } else {
48218
+ return res;
48219
+ }
48220
+ }));
48221
+ case 1:
48222
+ files = [];
48223
+ for (_j = 0; _j < list.length; _j++) {
48224
+ path = list[_j].substr(0, list[_j].lastIndexOf("/"));
48225
+ _name = list[_j].substr(list[_j].lastIndexOf("/") + 1);
48204
48226
  files.push({
48205
48227
  model: modelName + path,
48206
48228
  fileName: _name
@@ -48234,25 +48256,6 @@ var loadProfile = /*#__PURE__*/function () {
48234
48256
  }).catch(function (e) {
48235
48257
  message.warning(e);
48236
48258
  }));
48237
- case 1:
48238
- ps = [];
48239
- url = window.__POWERED_BY_QIANKUN__ ? "http://localhost:".concat(LtConfig.port, "/script/") : baseURL + "script";
48240
- for (_j = 0; _j < list.length; _j++) {
48241
- (function (fname) {
48242
- ps.push($axios.get(url + fname + "?" + new Date().getTime()).then(function (response) {
48243
- return response.data;
48244
- }).catch(function () {
48245
- message.warning("文件" + fname + "解析失败");
48246
- }));
48247
- })(list[_j]);
48248
- }
48249
- return _context.a(2, $axios.all(ps).then(function (res) {
48250
- if (typeof name == "string") {
48251
- return res[0];
48252
- } else {
48253
- return res;
48254
- }
48255
- }));
48256
48259
  case 2:
48257
48260
  return _context.a(2);
48258
48261
  }
@@ -77467,13 +77470,13 @@ var mainvue_type_script_setup_true_lang_tsx_hoisted_1 = ["onClick"];
77467
77470
  return showData;
77468
77471
  };
77469
77472
  var getAndCols = /*#__PURE__*/function () {
77470
- var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
77473
+ var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(fileName) {
77471
77474
  return _regenerator().w(function (_context) {
77472
77475
  while (1) switch (_context.n) {
77473
77476
  case 0:
77474
77477
  initLoading.value = true;
77475
77478
  _context.n = 1;
77476
- return loadProfile("main/main-list").then(function (res) {
77479
+ return loadProfile(fileName).then(function (res) {
77477
77480
  initLoading.value = false;
77478
77481
  formatShowListData(res.List);
77479
77482
  isShowList.value = true;
@@ -77485,7 +77488,7 @@ var mainvue_type_script_setup_true_lang_tsx_hoisted_1 = ["onClick"];
77485
77488
  }
77486
77489
  }, _callee);
77487
77490
  }));
77488
- return function getAndCols() {
77491
+ return function getAndCols(_x) {
77489
77492
  return _ref.apply(this, arguments);
77490
77493
  };
77491
77494
  }();
@@ -77505,8 +77508,12 @@ var mainvue_type_script_setup_true_lang_tsx_hoisted_1 = ["onClick"];
77505
77508
  return _regenerator().w(function (_context2) {
77506
77509
  while (1) switch (_context2.n) {
77507
77510
  case 0:
77511
+ if (!props.fileName) {
77512
+ _context2.n = 1;
77513
+ break;
77514
+ }
77508
77515
  _context2.n = 1;
77509
- return getAndCols();
77516
+ return getAndCols(props.fileName);
77510
77517
  case 1:
77511
77518
  return _context2.a(2);
77512
77519
  }
@@ -77577,10 +77584,10 @@ var mainvue_type_script_setup_true_lang_tsx_hoisted_1 = ["onClick"];
77577
77584
  }));
77578
77585
  ;// ./packages/components/main-list/src/main.vue?vue&type=script&setup=true&lang=tsx
77579
77586
 
77580
- ;// ./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-12.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/components/main-list/src/main.vue?vue&type=style&index=0&id=17ac636f&lang=css
77587
+ ;// ./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-12.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/components/main-list/src/main.vue?vue&type=style&index=0&id=34ea974a&lang=css
77581
77588
  // extracted by mini-css-extract-plugin
77582
77589
 
77583
- ;// ./packages/components/main-list/src/main.vue?vue&type=style&index=0&id=17ac636f&lang=css
77590
+ ;// ./packages/components/main-list/src/main.vue?vue&type=style&index=0&id=34ea974a&lang=css
77584
77591
 
77585
77592
  ;// ./packages/components/main-list/src/main.vue
77586
77593