@ibiz-template/runtime 0.7.13-alpha.0 → 0.7.13

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 (45) hide show
  1. package/dist/index.esm.js +264 -51
  2. package/dist/index.system.min.js +1 -1
  3. package/out/app-hub.d.ts.map +1 -1
  4. package/out/app-hub.js +8 -1
  5. package/out/controller/hub.controller.d.ts +73 -2
  6. package/out/controller/hub.controller.d.ts.map +1 -1
  7. package/out/controller/hub.controller.js +88 -12
  8. package/out/controller/notification/internal-message.controller.js +1 -1
  9. package/out/engine/view-base.engine.d.ts +8 -1
  10. package/out/engine/view-base.engine.d.ts.map +1 -1
  11. package/out/engine/view-base.engine.js +14 -3
  12. package/out/interface/controller/app.d.ts +55 -7
  13. package/out/interface/controller/app.d.ts.map +1 -1
  14. package/out/interface/service/service/i-auth.service.d.ts +11 -0
  15. package/out/interface/service/service/i-auth.service.d.ts.map +1 -1
  16. package/out/interface/util/i-app-util/i-app-util.d.ts +77 -0
  17. package/out/interface/util/i-app-util/i-app-util.d.ts.map +1 -0
  18. package/out/interface/util/i-app-util/i-app-util.js +1 -0
  19. package/out/interface/util/i-short-cut/i-short-cut.d.ts +11 -3
  20. package/out/interface/util/i-short-cut/i-short-cut.d.ts.map +1 -1
  21. package/out/interface/util/index.d.ts +1 -0
  22. package/out/interface/util/index.d.ts.map +1 -1
  23. package/out/service/service/auth/v7-auth.service.d.ts +64 -0
  24. package/out/service/service/auth/v7-auth.service.d.ts.map +1 -1
  25. package/out/service/service/auth/v7-auth.service.js +85 -7
  26. package/out/service/service/authority/authority.service.d.ts.map +1 -1
  27. package/out/service/service/authority/authority.service.js +5 -3
  28. package/out/service/service/internal-message/internal-message.service.js +2 -2
  29. package/out/types.d.ts +9 -1
  30. package/out/types.d.ts.map +1 -1
  31. package/out/ui-action/provider/loginout-ui-action-provider.d.ts.map +1 -1
  32. package/out/ui-action/provider/loginout-ui-action-provider.js +1 -4
  33. package/out/utils/file-util/file-util.d.ts +1 -1
  34. package/out/utils/file-util/file-util.d.ts.map +1 -1
  35. package/out/utils/file-util/file-util.js +14 -1
  36. package/out/utils/index.d.ts +1 -1
  37. package/out/utils/index.d.ts.map +1 -1
  38. package/out/utils/index.js +1 -1
  39. package/out/utils/short-cut/short-cut-util.d.ts +24 -0
  40. package/out/utils/short-cut/short-cut-util.d.ts.map +1 -1
  41. package/out/utils/short-cut/short-cut-util.js +27 -0
  42. package/package.json +1 -1
  43. package/out/utils/short-cut/index.d.ts +0 -2
  44. package/out/utils/short-cut/index.d.ts.map +0 -1
  45. package/out/utils/short-cut/index.js +0 -1
package/dist/index.esm.js CHANGED
@@ -5135,6 +5135,7 @@ var FileUtil = class {
5135
5135
  * @memberof FileUtil
5136
5136
  */
5137
5137
  async fileDownload(url, name) {
5138
+ var _a;
5138
5139
  const response = await ibiz.net.request(url, {
5139
5140
  method: "get",
5140
5141
  responseType: "blob",
@@ -5147,7 +5148,17 @@ var FileUtil = class {
5147
5148
  if (!response.data) {
5148
5149
  throw new RuntimeError5(ibiz.i18n.t("runtime.platform.fileStreamData"));
5149
5150
  } else {
5150
- const fileName = name;
5151
+ let fileName = "";
5152
+ const disposition = (_a = qs2.parse(response.headers["content-disposition"], {
5153
+ delimiter: ";"
5154
+ })) == null ? void 0 : _a.filename;
5155
+ if (disposition) {
5156
+ if (disposition.startsWith('"') && disposition.endsWith('"')) {
5157
+ fileName = disposition.substring(1, disposition.length - 1);
5158
+ }
5159
+ }
5160
+ if (name)
5161
+ fileName = name;
5151
5162
  downloadFileFromBlob(response.data, fileName);
5152
5163
  }
5153
5164
  }
@@ -5181,6 +5192,7 @@ var FileUtil = class {
5181
5192
  };
5182
5193
 
5183
5194
  // src/utils/short-cut/short-cut-util.ts
5195
+ import { QXEvent as QXEvent2 } from "qx-util";
5184
5196
  var ShortCutUtil = class {
5185
5197
  /**
5186
5198
  * Creates an instance of ShortCutUtil.
@@ -5195,6 +5207,13 @@ var ShortCutUtil = class {
5195
5207
  * @memberof ShortCutUtil
5196
5208
  */
5197
5209
  this.$ShortCut = [];
5210
+ /**
5211
+ * 事件监听器
5212
+ *
5213
+ * @protected
5214
+ * @memberof ShortCutUtil
5215
+ */
5216
+ this.evt = new QXEvent2();
5198
5217
  this.initShortCut();
5199
5218
  }
5200
5219
  /**
@@ -5223,8 +5242,27 @@ var ShortCutUtil = class {
5223
5242
  * @memberof ShortCutUtil
5224
5243
  */
5225
5244
  saveShortCut() {
5245
+ this.evt.emit("change", this.$ShortCut);
5226
5246
  window.localStorage.setItem("IbizShortCut", JSON.stringify(this.$ShortCut));
5227
5247
  }
5248
+ /**
5249
+ * 订阅数据改变事件
5250
+ *
5251
+ * @param {(data: IShortCut) => void} callback 回调
5252
+ * @memberof ShortCutUtil
5253
+ */
5254
+ onChange(callback) {
5255
+ this.evt.on("change", callback);
5256
+ }
5257
+ /**
5258
+ * 取消订阅
5259
+ *
5260
+ * @param {(data: IShortCut) => void} callback
5261
+ * @memberof ShortCutUtil
5262
+ */
5263
+ offChange(callback) {
5264
+ this.evt.off("change", callback);
5265
+ }
5228
5266
  /**
5229
5267
  * 计算快捷方式key
5230
5268
  *
@@ -6664,7 +6702,7 @@ function getErrorViewProvider(code) {
6664
6702
 
6665
6703
  // src/service/utils/app-counter/app-counter.ts
6666
6704
  import { IBizContext, RuntimeError as RuntimeError14 } from "@ibiz-template/core";
6667
- import { notNilEmpty as notNilEmpty5, QXEvent as QXEvent2 } from "qx-util";
6705
+ import { notNilEmpty as notNilEmpty5, QXEvent as QXEvent3 } from "qx-util";
6668
6706
  import { clone as clone3 } from "ramda";
6669
6707
  var AppCounter = class {
6670
6708
  /**
@@ -6679,7 +6717,7 @@ var AppCounter = class {
6679
6717
  this.destroyed = false;
6680
6718
  this.context = IBizContext.create();
6681
6719
  this.params = {};
6682
- this.evt = new QXEvent2();
6720
+ this.evt = new QXEvent3();
6683
6721
  /**
6684
6722
  * 计数器数据
6685
6723
  *
@@ -7014,7 +7052,7 @@ import {
7014
7052
  RuntimeModelError as RuntimeModelError7
7015
7053
  } from "@ibiz-template/core";
7016
7054
  import { clone as clone4, isNil as isNil5 } from "ramda";
7017
- import { QXEvent as QXEvent3, notNilEmpty as notNilEmpty6 } from "qx-util";
7055
+ import { QXEvent as QXEvent4, notNilEmpty as notNilEmpty6 } from "qx-util";
7018
7056
  var DynamicCodeListCache = class {
7019
7057
  constructor(codeList) {
7020
7058
  /**
@@ -7059,7 +7097,7 @@ var DynamicCodeListCache = class {
7059
7097
  * @date 2024-04-10 17:04:00
7060
7098
  * @protected
7061
7099
  */
7062
- this.evt = new QXEvent3();
7100
+ this.evt = new QXEvent4();
7063
7101
  /**
7064
7102
  * 常见关键字
7065
7103
  *
@@ -10361,8 +10399,8 @@ var AuthorityService = class {
10361
10399
  if (this.enablePermission) {
10362
10400
  const app = await ibiz.hub.getApp(this.appModel.appId);
10363
10401
  const opPriv = await app.getOPPriv(dataAccessAction, appDeId);
10364
- if (opPriv && opPriv.mapSysUniResMode && opPriv.mapSysUniResCode) {
10365
- return !!this.calcByResCode(opPriv.mapSysUniResCode);
10402
+ if (this.enablePermission && (opPriv == null ? void 0 : opPriv.mapSysUniResCode) && !this.calcByResCode(opPriv.mapSysUniResCode)) {
10403
+ return false;
10366
10404
  }
10367
10405
  }
10368
10406
  if (appDeId) {
@@ -10385,6 +10423,13 @@ var V7AuthService = class {
10385
10423
  get isAnonymous() {
10386
10424
  return getCookie(CoreConst.IS_ANONYMOUS) === "1";
10387
10425
  }
10426
+ /**
10427
+ * 使用匿名账号登录
10428
+ *
10429
+ * @author tony001
10430
+ * @date 2024-05-14 17:05:47
10431
+ * @return {*} {Promise<boolean>}
10432
+ */
10388
10433
  async anonymousLogin() {
10389
10434
  const { anonymousUser, anonymousPwd } = ibiz.env;
10390
10435
  if (!anonymousUser || !anonymousPwd) {
@@ -10407,8 +10452,20 @@ var V7AuthService = class {
10407
10452
  }
10408
10453
  return result;
10409
10454
  }
10455
+ /**
10456
+ * 登录
10457
+ *
10458
+ * @author tony001
10459
+ * @date 2024-05-14 17:05:54
10460
+ * @param {string} loginName
10461
+ * @param {string} password
10462
+ * @param {boolean} [remember]
10463
+ * @param {IData} [headers]
10464
+ * @return {*} {Promise<boolean>}
10465
+ */
10410
10466
  async login(loginName, password, remember, headers) {
10411
10467
  try {
10468
+ this.clearAuthData();
10412
10469
  const res = await ibiz.net.post(
10413
10470
  "/v7/login",
10414
10471
  {
@@ -10447,16 +10504,17 @@ var V7AuthService = class {
10447
10504
  }
10448
10505
  return false;
10449
10506
  }
10507
+ /**
10508
+ * 登出
10509
+ *
10510
+ * @author tony001
10511
+ * @date 2024-05-14 17:05:04
10512
+ * @return {*} {Promise<boolean>}
10513
+ */
10450
10514
  async logout() {
10451
10515
  try {
10452
10516
  await ibiz.net.get("/v7/logout");
10453
- clearCookie(CoreConst.TOKEN);
10454
- clearCookie(CoreConst.TOKEN_EXPIRES);
10455
- clearCookie(CoreConst.TOKEN_REMEMBER);
10456
- clearCookie(CoreConst.REFRESH_TOKEN);
10457
- clearCookie(CoreConst.IS_ANONYMOUS);
10458
- ibiz.appData = void 0;
10459
- ibiz.orgData = void 0;
10517
+ this.clearAuthData();
10460
10518
  return true;
10461
10519
  } catch (err) {
10462
10520
  ibiz.notification.error({
@@ -10466,6 +10524,33 @@ var V7AuthService = class {
10466
10524
  }
10467
10525
  return false;
10468
10526
  }
10527
+ /**
10528
+ * 变更密码
10529
+ *
10530
+ * @author tony001
10531
+ * @date 2024-05-14 17:05:22
10532
+ * @param {string} oldPwd
10533
+ * @param {string} newPwd
10534
+ * @return {*} {Promise<boolean>}
10535
+ */
10536
+ async changePwd(oldPwd, newPwd) {
10537
+ try {
10538
+ await ibiz.net.post("/uaa/changepwd", {
10539
+ oldPwd,
10540
+ newPwd
10541
+ });
10542
+ return true;
10543
+ } catch (err) {
10544
+ return false;
10545
+ }
10546
+ }
10547
+ /**
10548
+ * 页面未关闭情况下,自动延长登录时间
10549
+ *
10550
+ * @author tony001
10551
+ * @date 2024-05-14 17:05:38
10552
+ * @return {*} {Promise<void>}
10553
+ */
10469
10554
  async extendLogin() {
10470
10555
  if (this.isAnonymous) {
10471
10556
  return;
@@ -10510,6 +10595,13 @@ var V7AuthService = class {
10510
10595
  }, wait);
10511
10596
  }
10512
10597
  }
10598
+ /**
10599
+ * 通过refreshToken换算token
10600
+ *
10601
+ * @author tony001
10602
+ * @date 2024-05-14 17:05:45
10603
+ * @return {*} {Promise<void>}
10604
+ */
10513
10605
  async refreshToken() {
10514
10606
  const remember = getCookie(CoreConst.TOKEN_REMEMBER);
10515
10607
  const refreshToken = getCookie(CoreConst.REFRESH_TOKEN);
@@ -10535,6 +10627,13 @@ var V7AuthService = class {
10535
10627
  }
10536
10628
  }
10537
10629
  }
10630
+ /**
10631
+ * 获取当前环境的权限信息(无登录则返回undefined)
10632
+ *
10633
+ * @author tony001
10634
+ * @date 2024-05-14 17:05:57
10635
+ * @return {*} {(IAuthInfo | undefined)}
10636
+ */
10538
10637
  getAuthInfo() {
10539
10638
  const token = getCookie(CoreConst.TOKEN);
10540
10639
  const isAnonymous = !!getCookie(CoreConst.IS_ANONYMOUS);
@@ -10556,6 +10655,22 @@ var V7AuthService = class {
10556
10655
  ibiz.appData = res.data;
10557
10656
  }
10558
10657
  }
10658
+ /**
10659
+ * 清空权限数据
10660
+ *
10661
+ * @author tony001
10662
+ * @date 2024-05-14 17:05:18
10663
+ * @protected
10664
+ */
10665
+ clearAuthData() {
10666
+ clearCookie(CoreConst.TOKEN);
10667
+ clearCookie(CoreConst.TOKEN_EXPIRES);
10668
+ clearCookie(CoreConst.TOKEN_REMEMBER);
10669
+ clearCookie(CoreConst.REFRESH_TOKEN);
10670
+ clearCookie(CoreConst.IS_ANONYMOUS);
10671
+ ibiz.appData = void 0;
10672
+ ibiz.orgData = void 0;
10673
+ }
10559
10674
  };
10560
10675
 
10561
10676
  // src/service/service/async-action/async-action.service.ts
@@ -12875,7 +12990,7 @@ var InternalMessageService = class {
12875
12990
  const fetchParams = {
12876
12991
  page: 0,
12877
12992
  size: 20,
12878
- sort: "update_time,desc"
12993
+ sort: "timestamp,desc"
12879
12994
  };
12880
12995
  Object.assign(fetchParams, params);
12881
12996
  const res = await ibiz.net.post(
@@ -12939,7 +13054,7 @@ var InternalMessageService = class {
12939
13054
  const res = await ibiz.net.post("".concat(this.baseUrl, "/fetch_cur_receiver"), {
12940
13055
  page: 0,
12941
13056
  size: 1,
12942
- sort: "update_time,desc",
13057
+ sort: "timestamp,desc",
12943
13058
  searchconds: [
12944
13059
  {
12945
13060
  condtype: "GROUP",
@@ -13792,7 +13907,7 @@ var MapData = class {
13792
13907
  };
13793
13908
 
13794
13909
  // src/service/vo/panel-data/panel-data.ts
13795
- import { QXEvent as QXEvent4 } from "qx-util";
13910
+ import { QXEvent as QXEvent5 } from "qx-util";
13796
13911
  function updateKeyDefine3(target, keys) {
13797
13912
  keys.forEach((key) => {
13798
13913
  if (!Object.prototype.hasOwnProperty.call(target, key)) {
@@ -13807,7 +13922,7 @@ function updateKeyDefine3(target, keys) {
13807
13922
  }
13808
13923
  var PanelData = class {
13809
13924
  constructor(fields, origin) {
13810
- const _evt = new QXEvent4();
13925
+ const _evt = new QXEvent5();
13811
13926
  const keyMap = {};
13812
13927
  const reverseKeyMap = {};
13813
13928
  fields.forEach((field) => {
@@ -14029,7 +14144,7 @@ var GanttCodeListNodeData = class extends TreeCodeListNodeData {
14029
14144
  };
14030
14145
 
14031
14146
  // src/service/mqtt/mqtt.service.ts
14032
- import { QXEvent as QXEvent5, createUUID as createUUID7 } from "qx-util";
14147
+ import { QXEvent as QXEvent6, createUUID as createUUID7 } from "qx-util";
14033
14148
  var MqttService = class {
14034
14149
  /**
14035
14150
  * Creates an instance of MqttService.
@@ -14050,7 +14165,7 @@ var MqttService = class {
14050
14165
  * @author chitanda
14051
14166
  * @date 2023-10-23 15:10:06
14052
14167
  */
14053
- this.evt = new QXEvent5();
14168
+ this.evt = new QXEvent6();
14054
14169
  /**
14055
14170
  * 连接选项
14056
14171
  *
@@ -15148,7 +15263,7 @@ var LoadingState = class {
15148
15263
  };
15149
15264
 
15150
15265
  // src/controller/ctx/ctx.ts
15151
- import { QXEvent as QXEvent6 } from "qx-util";
15266
+ import { QXEvent as QXEvent7 } from "qx-util";
15152
15267
 
15153
15268
  // src/controller/ctx/ctx.state.ts
15154
15269
  var CTXState = class {
@@ -15178,7 +15293,7 @@ var CTX = class {
15178
15293
  * @date 2023-04-26 07:54:46
15179
15294
  * @protected
15180
15295
  */
15181
- this.evt = new QXEvent6(3e3);
15296
+ this.evt = new QXEvent7(3e3);
15182
15297
  /**
15183
15298
  * 当前视图控制器集合(包含自身视图控制器,部件控制器,和下一层级的视图的控制器)
15184
15299
  * @author lxm
@@ -15521,8 +15636,8 @@ var ButtonContainerState = class {
15521
15636
  };
15522
15637
 
15523
15638
  // src/controller/utils/event/qx-event-ex.ts
15524
- import { clearAll, QXEvent as QXEvent7 } from "qx-util";
15525
- var QXEventEx = class extends QXEvent7 {
15639
+ import { clearAll, QXEvent as QXEvent8 } from "qx-util";
15640
+ var QXEventEx = class extends QXEvent8 {
15526
15641
  constructor() {
15527
15642
  super(...arguments);
15528
15643
  this.anyEventFns = [];
@@ -23377,10 +23492,7 @@ var LoginOutUIActionProvider = class extends UIActionProviderBase {
23377
23492
  desc: ibiz.i18n.t("runtime.uiAction.wantLogout")
23378
23493
  });
23379
23494
  if (confirm) {
23380
- const bol = await ibiz.hub.controller.logout();
23381
- if (bol) {
23382
- window.location.reload();
23383
- }
23495
+ await ibiz.hub.controller.logout();
23384
23496
  }
23385
23497
  return {};
23386
23498
  }
@@ -39217,35 +39329,118 @@ var GanttController = class extends TreeGridExController {
39217
39329
  // src/controller/hub.controller.ts
39218
39330
  var HubController = class {
39219
39331
  constructor() {
39332
+ /**
39333
+ * 全局共享数据对象
39334
+ *
39335
+ * @author tony001
39336
+ * @date 2024-05-14 14:05:22
39337
+ * @type {IData}
39338
+ */
39220
39339
  this.session = {};
39221
39340
  }
39222
- login(loginName, password) {
39223
- return ibiz.auth.login(loginName, password);
39341
+ /**
39342
+ * 登录(包含调用登录逻辑,及跳转应用界面)
39343
+ *
39344
+ * @author tony001
39345
+ * @date 2024-05-14 16:05:04
39346
+ * @param {string} loginName
39347
+ * @param {string} password
39348
+ * @param {(boolean | undefined)} [remember]
39349
+ * @param {(IData | undefined)} [headers]
39350
+ * @param {(IData | undefined)} [opts]
39351
+ * @return {*} {Promise<boolean>}
39352
+ */
39353
+ async login(loginName, password, remember, headers, opts) {
39354
+ const bol = await ibiz.appUtil.login(
39355
+ loginName,
39356
+ password,
39357
+ remember,
39358
+ headers,
39359
+ opts
39360
+ );
39361
+ return bol;
39224
39362
  }
39225
- async logout() {
39226
- const bol = await ibiz.auth.logout();
39227
- if (bol) {
39228
- const l = window.location;
39229
- if (l.search.indexOf("isAnonymous=true") !== -1) {
39230
- const href = "".concat(l.origin).concat(l.pathname).concat(l.hash);
39231
- window.history.replaceState({}, "", href);
39232
- }
39233
- }
39363
+ /**
39364
+ * 登出(包含调用登录逻辑,及跳转登录页)
39365
+ *
39366
+ * @author tony001
39367
+ * @date 2024-05-14 16:05:01
39368
+ * @param {(IData | undefined)} [opts]
39369
+ * @return {*} {Promise<boolean>}
39370
+ */
39371
+ async logout(opts) {
39372
+ const bol = await ibiz.appUtil.logout(opts);
39373
+ return bol;
39374
+ }
39375
+ /**
39376
+ * 变更密码
39377
+ *
39378
+ * @author tony001
39379
+ * @date 2024-05-14 16:05:54
39380
+ * @param {string} oldPwd
39381
+ * @param {string} newPwd
39382
+ * @param {(IData | undefined)} [opts]
39383
+ * @return {*} {Promise<boolean>}
39384
+ */
39385
+ async changePwd(oldPwd, newPwd, opts) {
39386
+ const bol = await ibiz.appUtil.changePwd(oldPwd, newPwd, opts);
39387
+ return bol;
39388
+ }
39389
+ /**
39390
+ * 切换组织(包括界面刷新)
39391
+ *
39392
+ * @author tony001
39393
+ * @date 2024-05-14 16:05:09
39394
+ * @param {string} oldOrgId
39395
+ * @param {string} newOrgId
39396
+ * @param {(IData | undefined)} [opts]
39397
+ * @return {*} {Promise<boolean>}
39398
+ */
39399
+ async switchOrg(oldOrgId, newOrgId, opts) {
39400
+ const bol = await ibiz.appUtil.switchOrg(oldOrgId, newOrgId, opts);
39401
+ return bol;
39402
+ }
39403
+ /**
39404
+ * 切换主题
39405
+ *
39406
+ * @author tony001
39407
+ * @date 2024-05-14 16:05:12
39408
+ * @param {string} oldTheme
39409
+ * @param {string} newTheme
39410
+ * @param {(IData | undefined)} [opts]
39411
+ * @return {*} {Promise<boolean>}
39412
+ */
39413
+ async switchTheme(oldTheme, newTheme, opts) {
39414
+ const bol = await ibiz.appUtil.switchTheme(oldTheme, newTheme, opts);
39415
+ return bol;
39416
+ }
39417
+ /**
39418
+ * 切换语言
39419
+ *
39420
+ * @author tony001
39421
+ * @date 2024-05-14 16:05:01
39422
+ * @param {string} oldLanguage
39423
+ * @param {string} newLanguage
39424
+ * @param {(IData | undefined)} [opts]
39425
+ * @return {*} {Promise<boolean>}
39426
+ */
39427
+ async switchLanguage(oldLanguage, newLanguage, opts) {
39428
+ const bol = await ibiz.appUtil.switchTheme(oldLanguage, newLanguage, opts);
39234
39429
  return bol;
39235
39430
  }
39236
39431
  };
39237
39432
 
39238
39433
  // src/controller/notification/notice.controller.ts
39239
- import { QXEvent as QXEvent10 } from "qx-util";
39434
+ import { QXEvent as QXEvent11 } from "qx-util";
39240
39435
 
39241
39436
  // src/controller/notification/async-action.controller.ts
39242
- import { QXEvent as QXEvent8 } from "qx-util";
39437
+ import { QXEvent as QXEvent9 } from "qx-util";
39243
39438
  import { clone as clone33 } from "ramda";
39244
39439
  import { isNil as isNil34, isNumber as isNumber2 } from "lodash-es";
39245
39440
  import dayjs8 from "dayjs";
39246
39441
  var AsyncActionController = class {
39247
39442
  constructor() {
39248
- this.evt = new QXEvent8();
39443
+ this.evt = new QXEvent9();
39249
39444
  this.total = 0;
39250
39445
  this.actions = [];
39251
39446
  /**
@@ -39382,7 +39577,7 @@ var AsyncActionController = class {
39382
39577
  };
39383
39578
 
39384
39579
  // src/controller/notification/internal-message.controller.ts
39385
- import { QXEvent as QXEvent9 } from "qx-util";
39580
+ import { QXEvent as QXEvent10 } from "qx-util";
39386
39581
  function isHTML(str) {
39387
39582
  if (str === "")
39388
39583
  return false;
@@ -39391,7 +39586,7 @@ function isHTML(str) {
39391
39586
  }
39392
39587
  var InternalMessageController = class {
39393
39588
  constructor() {
39394
- this.evt = new QXEvent9();
39589
+ this.evt = new QXEvent10();
39395
39590
  this.total = 0;
39396
39591
  this.unreadCount = 0;
39397
39592
  /**
@@ -39454,7 +39649,7 @@ var InternalMessageController = class {
39454
39649
  const fetchParams = {
39455
39650
  page: this.page,
39456
39651
  size: this.size,
39457
- sort: "update_time,desc"
39652
+ sort: "timestamp,desc"
39458
39653
  };
39459
39654
  if (this.unreadOnly) {
39460
39655
  fetchParams.searchconds = [
@@ -39551,7 +39746,7 @@ var InternalMessageController = class {
39551
39746
  // src/controller/notification/notice.controller.ts
39552
39747
  var NoticeController = class {
39553
39748
  constructor() {
39554
- this.evt = new QXEvent10();
39749
+ this.evt = new QXEvent11();
39555
39750
  this.total = 0;
39556
39751
  this.asyncAction = new AsyncActionController();
39557
39752
  this.internalMessage = new InternalMessageController();
@@ -39851,7 +40046,14 @@ var AppHub = class {
39851
40046
  async getAppDataEntity(id, appId2 = ibiz.env.appId) {
39852
40047
  if (this.dataEntities.has(appId2)) {
39853
40048
  const map = this.dataEntities.get(appId2);
39854
- if (map.has(id)) {
40049
+ if (id.indexOf(".") === -1) {
40050
+ const targetEntity = Array.from(map.values()).find(
40051
+ (value) => value.codeName === id
40052
+ );
40053
+ if (targetEntity) {
40054
+ return targetEntity;
40055
+ }
40056
+ } else if (map.has(id)) {
39855
40057
  return map.get(id);
39856
40058
  }
39857
40059
  }
@@ -40224,11 +40426,18 @@ var ViewEngineBase = class {
40224
40426
  }
40225
40427
  return void 0;
40226
40428
  }
40429
+ /**
40430
+ * 快捷方式
40431
+ *
40432
+ * @param {*} args
40433
+ * @return {*} {(Promise<any>)}
40434
+ * @memberof ViewEngineBase
40435
+ */
40227
40436
  // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types
40228
40437
  async onShortCut(args) {
40229
40438
  const { data } = args;
40230
40439
  const { context, model, params, modal } = this.view;
40231
- if (!["ROUTE_MODAL", "MODAL", "DRAWER"].includes(modal.mode)) {
40440
+ if (["EMBED", "POPOVER"].includes(modal.mode)) {
40232
40441
  throw new Error(
40233
40442
  ibiz.i18n.t("runtime.engine.minimization", { mode: modal.mode })
40234
40443
  );
@@ -40239,16 +40448,20 @@ var ViewEngineBase = class {
40239
40448
  });
40240
40449
  const isExist = ibiz.util.shortCut.isExist(key);
40241
40450
  if (!isExist) {
40451
+ const caption = data && data[0].srfmajortext || model.caption;
40242
40452
  ibiz.util.shortCut.addShortCut({
40243
40453
  key,
40244
- name: data && data[0].srfmajortext,
40454
+ caption,
40455
+ icon: model.sysImage,
40245
40456
  appViewId: model.id,
40246
40457
  context: IBizContext7.create(context),
40247
40458
  params: { ...params },
40248
- openMode: modal.mode
40459
+ openMode: modal.mode,
40460
+ fullPath: window.location.hash
40249
40461
  });
40250
40462
  this.view.state.isShortCut = true;
40251
- return { closeView: true };
40463
+ this.view.closeView();
40464
+ return null;
40252
40465
  }
40253
40466
  ibiz.util.shortCut.removeShortCut(key);
40254
40467
  this.view.state.isShortCut = false;