@ibiz-template/runtime 0.3.5-alpha.0 → 0.3.5
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/dist/index.esm.js +299 -161
- package/dist/index.system.min.js +2 -2
- package/dist/index.system.min.js.map +1 -1
- package/out/constant/index.d.ts +1 -0
- package/out/constant/index.d.ts.map +1 -1
- package/out/constant/index.js +1 -0
- package/out/constant/platform-type.d.ts +43 -0
- package/out/constant/platform-type.d.ts.map +1 -0
- package/out/constant/platform-type.js +44 -0
- package/out/constant/view-call-tag.d.ts +5 -1
- package/out/constant/view-call-tag.d.ts.map +1 -1
- package/out/constant/view-call-tag.js +4 -0
- package/out/controller/control/chart/generator/funnel-series-generator.js +1 -1
- package/out/controller/control/chart/generator/pie-series-generator.js +1 -1
- package/out/index.d.ts +1 -0
- package/out/index.d.ts.map +1 -1
- package/out/index.js +1 -0
- package/out/install.d.ts.map +1 -1
- package/out/install.js +6 -0
- package/out/interface/provider/i-platform-provider.d.ts +49 -0
- package/out/interface/provider/i-platform-provider.d.ts.map +1 -0
- package/out/interface/provider/i-platform-provider.js +1 -0
- package/out/interface/provider/index.d.ts +1 -0
- package/out/interface/provider/index.d.ts.map +1 -1
- package/out/interface/service/service/i-auth.service.d.ts +1 -1
- package/out/interface/service/service/i-auth.service.d.ts.map +1 -1
- package/out/platform/index.d.ts +3 -0
- package/out/platform/index.d.ts.map +1 -0
- package/out/platform/index.js +2 -0
- package/out/platform/platform-util.d.ts +11 -0
- package/out/platform/platform-util.d.ts.map +1 -0
- package/out/platform/platform-util.js +50 -0
- package/out/platform/provider/browser-platform-provider.d.ts +13 -0
- package/out/platform/provider/browser-platform-provider.d.ts.map +1 -0
- package/out/platform/provider/browser-platform-provider.js +12 -0
- package/out/platform/provider/index.d.ts +12 -0
- package/out/platform/provider/index.d.ts.map +1 -0
- package/out/platform/provider/index.js +17 -0
- package/out/platform/provider/platform-provider-base.d.ts +18 -0
- package/out/platform/provider/platform-provider-base.d.ts.map +1 -0
- package/out/platform/provider/platform-provider-base.js +42 -0
- package/out/register/helper/index.d.ts +1 -0
- package/out/register/helper/index.d.ts.map +1 -1
- package/out/register/helper/index.js +1 -0
- package/out/register/helper/platform-register.d.ts +23 -0
- package/out/register/helper/platform-register.d.ts.map +1 -0
- package/out/register/helper/platform-register.js +44 -0
- package/out/service/service/auth/v7-auth.service.d.ts +1 -1
- package/out/service/service/auth/v7-auth.service.d.ts.map +1 -1
- package/out/service/service/auth/v7-auth.service.js +6 -2
- package/out/types.d.ts +10 -1
- package/out/types.d.ts.map +1 -1
- package/out/ui-action/provider/front-ui-action-provider.d.ts +1 -1
- package/out/ui-action/provider/front-ui-action-provider.d.ts.map +1 -1
- package/out/ui-action/provider/front-ui-action-provider.js +8 -9
- package/package.json +3 -3
- package/src/constant/index.ts +1 -0
- package/src/constant/platform-type.ts +50 -0
- package/src/constant/view-call-tag.ts +4 -0
- package/src/controller/control/chart/generator/funnel-series-generator.ts +1 -1
- package/src/controller/control/chart/generator/pie-series-generator.ts +1 -1
- package/src/index.ts +1 -0
- package/src/install.ts +6 -0
- package/src/interface/provider/i-platform-provider.ts +55 -0
- package/src/interface/provider/index.ts +1 -0
- package/src/interface/service/service/i-auth.service.ts +5 -1
- package/src/platform/index.ts +2 -0
- package/src/platform/platform-util.ts +57 -0
- package/src/platform/provider/browser-platform-provider.ts +12 -0
- package/src/platform/provider/index.ts +19 -0
- package/src/platform/provider/platform-provider-base.ts +50 -0
- package/src/register/helper/index.ts +1 -0
- package/src/register/helper/platform-register.ts +56 -0
- package/src/service/service/auth/v7-auth.service.ts +10 -2
- package/src/types.ts +11 -0
- package/src/ui-action/provider/front-ui-action-provider.ts +23 -5
package/dist/index.esm.js
CHANGED
|
@@ -71,7 +71,7 @@ var RegisterCenter = class {
|
|
|
71
71
|
};
|
|
72
72
|
|
|
73
73
|
// src/command/app/app-func/app-func.ts
|
|
74
|
-
import { ModelError as ModelError15, RuntimeError as
|
|
74
|
+
import { ModelError as ModelError15, RuntimeError as RuntimeError21 } from "@ibiz-template/core";
|
|
75
75
|
|
|
76
76
|
// src/utils/handlebars/utils/helper/helper.ts
|
|
77
77
|
var HelperUtil = class {
|
|
@@ -2307,6 +2307,7 @@ var ViewCallTag = /* @__PURE__ */ ((ViewCallTag2) => {
|
|
|
2307
2307
|
ViewCallTag2["GET_ALL_DATA"] = "GetAllData";
|
|
2308
2308
|
ViewCallTag2["VALIDATE"] = "Validate";
|
|
2309
2309
|
ViewCallTag2["TOGGLE_COLLAPSE"] = "ToggleCollapse";
|
|
2310
|
+
ViewCallTag2["WF_WITHDRAW"] = "WFWithdraw";
|
|
2310
2311
|
return ViewCallTag2;
|
|
2311
2312
|
})(ViewCallTag || {});
|
|
2312
2313
|
|
|
@@ -2333,6 +2334,19 @@ var ValueOP = /* @__PURE__ */ ((ValueOP2) => {
|
|
|
2333
2334
|
return ValueOP2;
|
|
2334
2335
|
})(ValueOP || {});
|
|
2335
2336
|
|
|
2337
|
+
// src/constant/platform-type.ts
|
|
2338
|
+
var PlatformType = /* @__PURE__ */ ((PlatformType2) => {
|
|
2339
|
+
PlatformType2["IOS"] = "IOS";
|
|
2340
|
+
PlatformType2["ANDROID"] = "Android";
|
|
2341
|
+
PlatformType2["WECHAT"] = "WeChat";
|
|
2342
|
+
PlatformType2["QQ"] = "QQ";
|
|
2343
|
+
PlatformType2["DINGTALK"] = "DingTalk";
|
|
2344
|
+
PlatformType2["BROWSER"] = "Browser";
|
|
2345
|
+
PlatformType2["WCMP"] = "WeChatMiniProgram";
|
|
2346
|
+
PlatformType2["DESKTOP"] = "Desktop";
|
|
2347
|
+
return PlatformType2;
|
|
2348
|
+
})(PlatformType || {});
|
|
2349
|
+
|
|
2336
2350
|
// src/constant/studio-event.ts
|
|
2337
2351
|
var StudioViewEvents = class {
|
|
2338
2352
|
};
|
|
@@ -2592,7 +2606,7 @@ async function handleAllSettled(values, isThrow = true) {
|
|
|
2592
2606
|
}
|
|
2593
2607
|
|
|
2594
2608
|
// src/command/app/open-app-view/open-app-view.ts
|
|
2595
|
-
import { ModelError as ModelError14, RuntimeError as
|
|
2609
|
+
import { ModelError as ModelError14, RuntimeError as RuntimeError20 } from "@ibiz-template/core";
|
|
2596
2610
|
import { clone as clone13 } from "ramda";
|
|
2597
2611
|
|
|
2598
2612
|
// src/service/utils/de-dq-cond/ps-de-dq-cond-engine.ts
|
|
@@ -3422,8 +3436,103 @@ function getAsyncActionProvider(actiontype) {
|
|
|
3422
3436
|
}
|
|
3423
3437
|
}
|
|
3424
3438
|
|
|
3439
|
+
// src/platform/provider/platform-provider-base.ts
|
|
3440
|
+
import { downloadFileFromBlob, RuntimeError as RuntimeError9 } from "@ibiz-template/core";
|
|
3441
|
+
var PlatformProviderBase = class {
|
|
3442
|
+
back() {
|
|
3443
|
+
throw new Error("Method not implemented.");
|
|
3444
|
+
}
|
|
3445
|
+
init() {
|
|
3446
|
+
throw new Error("Method not implemented.");
|
|
3447
|
+
}
|
|
3448
|
+
async login(loginName, passWord, _verificationCode) {
|
|
3449
|
+
return ibiz.auth.login(loginName, passWord);
|
|
3450
|
+
}
|
|
3451
|
+
async download(url, name) {
|
|
3452
|
+
const response = await ibiz.net.request(url, {
|
|
3453
|
+
method: "get",
|
|
3454
|
+
responseType: "blob"
|
|
3455
|
+
});
|
|
3456
|
+
if (response.status !== 200) {
|
|
3457
|
+
throw new RuntimeError9("\u4E0B\u8F7D\u6587\u4EF6\u5931\u8D25");
|
|
3458
|
+
}
|
|
3459
|
+
if (!response.data) {
|
|
3460
|
+
throw new RuntimeError9("\u6587\u4EF6\u6D41\u6570\u636E\u4E0D\u5B58\u5728");
|
|
3461
|
+
} else {
|
|
3462
|
+
const fileName = name;
|
|
3463
|
+
downloadFileFromBlob(response.data, fileName);
|
|
3464
|
+
return Promise.resolve(true);
|
|
3465
|
+
}
|
|
3466
|
+
}
|
|
3467
|
+
};
|
|
3468
|
+
|
|
3469
|
+
// src/platform/provider/browser-platform-provider.ts
|
|
3470
|
+
var BrowserPlatformProvider = class extends PlatformProviderBase {
|
|
3471
|
+
};
|
|
3472
|
+
|
|
3473
|
+
// src/platform/provider/index.ts
|
|
3474
|
+
function install() {
|
|
3475
|
+
const browserPlatformProvider = new BrowserPlatformProvider();
|
|
3476
|
+
registerPlatformProvider("Browser" /* BROWSER */, () => browserPlatformProvider);
|
|
3477
|
+
}
|
|
3478
|
+
|
|
3479
|
+
// src/platform/platform-util.ts
|
|
3480
|
+
var ua = window.navigator.userAgent.toLowerCase();
|
|
3481
|
+
function isAndroid() {
|
|
3482
|
+
return /Android|Adr/i.test(ua);
|
|
3483
|
+
}
|
|
3484
|
+
function isIos() {
|
|
3485
|
+
return /iPhone|iPod|iPad/i.test(ua);
|
|
3486
|
+
}
|
|
3487
|
+
function isWeChat() {
|
|
3488
|
+
return /MicroMessenger/i.test(ua);
|
|
3489
|
+
}
|
|
3490
|
+
function isDingDing() {
|
|
3491
|
+
return /DingTalk/i.test(ua);
|
|
3492
|
+
}
|
|
3493
|
+
function isWxMp() {
|
|
3494
|
+
return /miniProgram/i.test(ua) || window.__wxjs_environment === "miniprogram";
|
|
3495
|
+
}
|
|
3496
|
+
function getPlatformType() {
|
|
3497
|
+
if (isAndroid()) {
|
|
3498
|
+
return "Android" /* ANDROID */;
|
|
3499
|
+
}
|
|
3500
|
+
if (isIos()) {
|
|
3501
|
+
return "IOS" /* IOS */;
|
|
3502
|
+
}
|
|
3503
|
+
if (isWeChat()) {
|
|
3504
|
+
return "WeChat" /* WECHAT */;
|
|
3505
|
+
}
|
|
3506
|
+
if (isDingDing()) {
|
|
3507
|
+
return "DingTalk" /* DINGTALK */;
|
|
3508
|
+
}
|
|
3509
|
+
if (isWxMp()) {
|
|
3510
|
+
return "WeChatMiniProgram" /* WCMP */;
|
|
3511
|
+
}
|
|
3512
|
+
return "Browser" /* BROWSER */;
|
|
3513
|
+
}
|
|
3514
|
+
|
|
3515
|
+
// src/register/helper/platform-register.ts
|
|
3516
|
+
var PLATFORM_PROVIDER_PREFIX = "PLATFORM";
|
|
3517
|
+
function registerPlatformProvider(key, callback) {
|
|
3518
|
+
ibiz.register.register("".concat(PLATFORM_PROVIDER_PREFIX, "_").concat(key), callback);
|
|
3519
|
+
}
|
|
3520
|
+
function getProvider11(key) {
|
|
3521
|
+
return ibiz.register.get(
|
|
3522
|
+
"".concat(PLATFORM_PROVIDER_PREFIX, "_").concat(key)
|
|
3523
|
+
);
|
|
3524
|
+
}
|
|
3525
|
+
function getPlatformProvider() {
|
|
3526
|
+
const platformType = getPlatformType();
|
|
3527
|
+
const provider = getProvider11(platformType);
|
|
3528
|
+
if (!provider) {
|
|
3529
|
+
return getProvider11("Browser" /* BROWSER */);
|
|
3530
|
+
}
|
|
3531
|
+
return provider;
|
|
3532
|
+
}
|
|
3533
|
+
|
|
3425
3534
|
// src/service/utils/app-counter/app-counter.ts
|
|
3426
|
-
import { IBizContext, RuntimeError as
|
|
3535
|
+
import { IBizContext, RuntimeError as RuntimeError10 } from "@ibiz-template/core";
|
|
3427
3536
|
import { notNilEmpty as notNilEmpty5, QXEvent } from "qx-util";
|
|
3428
3537
|
import { clone as clone2 } from "ramda";
|
|
3429
3538
|
var AppCounter = class {
|
|
@@ -3528,7 +3637,7 @@ var AppCounter = class {
|
|
|
3528
3637
|
* @return {*} {Promise<IData>}
|
|
3529
3638
|
*/
|
|
3530
3639
|
async load() {
|
|
3531
|
-
throw new
|
|
3640
|
+
throw new RuntimeError10("\u672A\u5B9E\u73B0\u8BA1\u6570\u5668\u52A0\u8F7D\u65B9\u6CD5");
|
|
3532
3641
|
}
|
|
3533
3642
|
/**
|
|
3534
3643
|
* 计数器刷新
|
|
@@ -3961,7 +4070,7 @@ import { where, equals, clone as clone3, isNil as isNil5, isEmpty as isEmpty5 }
|
|
|
3961
4070
|
import { createUUID } from "qx-util";
|
|
3962
4071
|
|
|
3963
4072
|
// src/service/utils/service-exist-util/service-exist-util.ts
|
|
3964
|
-
import { RuntimeError as
|
|
4073
|
+
import { RuntimeError as RuntimeError11 } from "@ibiz-template/core";
|
|
3965
4074
|
import { isEmpty as isEmpty4, isNil as isNil4 } from "ramda";
|
|
3966
4075
|
function isExistSrfKey(funcName, entity) {
|
|
3967
4076
|
if (entity != null) {
|
|
@@ -3970,14 +4079,14 @@ function isExistSrfKey(funcName, entity) {
|
|
|
3970
4079
|
return true;
|
|
3971
4080
|
}
|
|
3972
4081
|
}
|
|
3973
|
-
throw new
|
|
4082
|
+
throw new RuntimeError11("\u6267\u884C\u300C".concat(funcName, "\u300D\u4E0D\u5B58\u5728\u300Csrfkey\u300D\u65E0\u6CD5\u5904\u7406"));
|
|
3974
4083
|
}
|
|
3975
4084
|
function isExistSessionId(funcName, context) {
|
|
3976
4085
|
const { srfsessionid } = context;
|
|
3977
4086
|
if (!isNil4(srfsessionid) && !isEmpty4(srfsessionid)) {
|
|
3978
4087
|
return true;
|
|
3979
4088
|
}
|
|
3980
|
-
throw new
|
|
4089
|
+
throw new RuntimeError11("\u6267\u884C\u300C".concat(funcName, "\u300D\u4E0D\u5B58\u5728\u300Csrfsessionid\u300D\u65E0\u6CD5\u5904\u7406"));
|
|
3981
4090
|
}
|
|
3982
4091
|
|
|
3983
4092
|
// src/service/utils/de-cache/de-cache.ts
|
|
@@ -4468,7 +4577,7 @@ var SearchFilter = class {
|
|
|
4468
4577
|
};
|
|
4469
4578
|
|
|
4470
4579
|
// src/service/service/code-list/code-list.service.ts
|
|
4471
|
-
import { RuntimeError as
|
|
4580
|
+
import { RuntimeError as RuntimeError12 } from "@ibiz-template/core";
|
|
4472
4581
|
var CodeListService = class {
|
|
4473
4582
|
constructor(appModel) {
|
|
4474
4583
|
this.appModel = appModel;
|
|
@@ -4615,7 +4724,7 @@ var CodeListService = class {
|
|
|
4615
4724
|
async get(tag, context, params) {
|
|
4616
4725
|
const codeList = this.allCodeLists.get(tag);
|
|
4617
4726
|
if (!codeList) {
|
|
4618
|
-
throw new
|
|
4727
|
+
throw new RuntimeError12("\u627E\u4E0D\u5230".concat(tag, "\u4EE3\u7801\u8868"));
|
|
4619
4728
|
}
|
|
4620
4729
|
if (codeList.codeListType === "STATIC") {
|
|
4621
4730
|
return this.getStatic(codeList);
|
|
@@ -4737,11 +4846,11 @@ CounterService.counterMap = /* @__PURE__ */ new Map();
|
|
|
4737
4846
|
// src/service/service/entity/de.service.ts
|
|
4738
4847
|
import {
|
|
4739
4848
|
ModelError as ModelError13,
|
|
4740
|
-
RuntimeError as
|
|
4849
|
+
RuntimeError as RuntimeError16
|
|
4741
4850
|
} from "@ibiz-template/core";
|
|
4742
4851
|
|
|
4743
4852
|
// src/service/service/work-flow/work-flow.service.ts
|
|
4744
|
-
import { RuntimeError as
|
|
4853
|
+
import { RuntimeError as RuntimeError13 } from "@ibiz-template/core";
|
|
4745
4854
|
var WorkFlowService = class {
|
|
4746
4855
|
/**
|
|
4747
4856
|
* Creates an instance of WorkFlowService.
|
|
@@ -5061,7 +5170,7 @@ var WorkFlowService = class {
|
|
|
5061
5170
|
case "sendcopy":
|
|
5062
5171
|
return this.wfSendCopy(context, params, data);
|
|
5063
5172
|
default: {
|
|
5064
|
-
throw new
|
|
5173
|
+
throw new RuntimeError13("\u300C".concat(methodName, "\u300D\u672A\u5B9E\u73B0"));
|
|
5065
5174
|
}
|
|
5066
5175
|
}
|
|
5067
5176
|
}
|
|
@@ -5103,7 +5212,7 @@ var FileService = class {
|
|
|
5103
5212
|
// src/service/service/entity/method/de-action.ts
|
|
5104
5213
|
import {
|
|
5105
5214
|
HttpResponse as HttpResponse3,
|
|
5106
|
-
RuntimeError as
|
|
5215
|
+
RuntimeError as RuntimeError15,
|
|
5107
5216
|
RuntimeModelError as RuntimeModelError19
|
|
5108
5217
|
} from "@ibiz-template/core";
|
|
5109
5218
|
import { isArray as isArray6, isNil as isNil8 } from "lodash-es";
|
|
@@ -5704,7 +5813,7 @@ var Method = class {
|
|
|
5704
5813
|
};
|
|
5705
5814
|
|
|
5706
5815
|
// src/de-logic/index.ts
|
|
5707
|
-
import { HttpError as HttpError2, HttpResponse as HttpResponse2, RuntimeError as
|
|
5816
|
+
import { HttpError as HttpError2, HttpResponse as HttpResponse2, RuntimeError as RuntimeError14 } from "@ibiz-template/core";
|
|
5708
5817
|
import { isArray as isArray5 } from "lodash-es";
|
|
5709
5818
|
import { clone as clone9 } from "ramda";
|
|
5710
5819
|
|
|
@@ -6757,7 +6866,7 @@ async function execDELogicById(deDELogicId, dataEntityId, context, data, params)
|
|
|
6757
6866
|
context.srfappid
|
|
6758
6867
|
);
|
|
6759
6868
|
if (!deLogic) {
|
|
6760
|
-
throw new
|
|
6869
|
+
throw new RuntimeError14("".concat(dataEntityId, "\u627E\u4E0D\u5230\u5B9E\u4F53\u903B\u8F91").concat(deDELogicId));
|
|
6761
6870
|
}
|
|
6762
6871
|
return execDELogic(deLogic, context, data, params);
|
|
6763
6872
|
}
|
|
@@ -6916,7 +7025,7 @@ var DEActionMethod = class extends Method {
|
|
|
6916
7025
|
*/
|
|
6917
7026
|
async create(context, data, params) {
|
|
6918
7027
|
if (!data) {
|
|
6919
|
-
throw new
|
|
7028
|
+
throw new RuntimeError15("create\u884C\u4E3A\u6CA1\u6709\u4F20data");
|
|
6920
7029
|
}
|
|
6921
7030
|
if (this.isLocalMode) {
|
|
6922
7031
|
return this.createTemp(context, this.createEntity(data));
|
|
@@ -6958,7 +7067,7 @@ var DEActionMethod = class extends Method {
|
|
|
6958
7067
|
*/
|
|
6959
7068
|
async update(context, data, params) {
|
|
6960
7069
|
if (!data) {
|
|
6961
|
-
throw new
|
|
7070
|
+
throw new RuntimeError15("update\u884C\u4E3A\u6CA1\u6709\u4F20data");
|
|
6962
7071
|
}
|
|
6963
7072
|
if (this.isLocalMode) {
|
|
6964
7073
|
return this.updateTemp(context, this.createEntity(data));
|
|
@@ -7430,7 +7539,7 @@ var DEService = class {
|
|
|
7430
7539
|
if (method) {
|
|
7431
7540
|
return method.exec(context, params, params2);
|
|
7432
7541
|
}
|
|
7433
|
-
throw new
|
|
7542
|
+
throw new RuntimeError16("".concat(this.model.codeName, "\u672A\u652F\u6301\u300C").concat(id, "\u300D\u65B9\u6CD5"));
|
|
7434
7543
|
}
|
|
7435
7544
|
getDraft(context, params, params2) {
|
|
7436
7545
|
return this.exec("GetDraft", context, params, params2);
|
|
@@ -7466,7 +7575,7 @@ var DEService = class {
|
|
|
7466
7575
|
if (method) {
|
|
7467
7576
|
return method.exec(context, params, params2);
|
|
7468
7577
|
}
|
|
7469
|
-
throw new
|
|
7578
|
+
throw new RuntimeError16("".concat(this.model.codeName, "\u672A\u652F\u6301\u300C").concat(id, "\u300D\u65B9\u6CD5"));
|
|
7470
7579
|
}
|
|
7471
7580
|
/**
|
|
7472
7581
|
* 实体级别 AI 聊天会话
|
|
@@ -7826,7 +7935,7 @@ var ControlService = class {
|
|
|
7826
7935
|
};
|
|
7827
7936
|
|
|
7828
7937
|
// src/service/service/control/md-control.service.ts
|
|
7829
|
-
import { RuntimeError as
|
|
7938
|
+
import { RuntimeError as RuntimeError17 } from "@ibiz-template/core";
|
|
7830
7939
|
import { isArray as isArray8 } from "qx-util";
|
|
7831
7940
|
var MDControlService = class extends ControlService {
|
|
7832
7941
|
/**
|
|
@@ -7935,7 +8044,7 @@ var MDControlService = class extends ControlService {
|
|
|
7935
8044
|
* @returns {*} {Promise<IHttpResponse>}
|
|
7936
8045
|
*/
|
|
7937
8046
|
async exportData(_dataExport, _context, _params = {}) {
|
|
7938
|
-
throw new
|
|
8047
|
+
throw new RuntimeError17("\u672A\u5B9E\u73B0");
|
|
7939
8048
|
}
|
|
7940
8049
|
/**
|
|
7941
8050
|
* 处理响应
|
|
@@ -7970,7 +8079,7 @@ var MDControlService = class extends ControlService {
|
|
|
7970
8079
|
};
|
|
7971
8080
|
|
|
7972
8081
|
// src/service/service/authority/authority.service.ts
|
|
7973
|
-
import { RuntimeError as
|
|
8082
|
+
import { RuntimeError as RuntimeError18 } from "@ibiz-template/core";
|
|
7974
8083
|
|
|
7975
8084
|
// src/service/service/authority/de-authority.service.ts
|
|
7976
8085
|
var DeAuthorityService = class {
|
|
@@ -8106,7 +8215,7 @@ var AuthorityService = class {
|
|
|
8106
8215
|
this.appModel.appId
|
|
8107
8216
|
);
|
|
8108
8217
|
if (!entityModel) {
|
|
8109
|
-
throw new
|
|
8218
|
+
throw new RuntimeError18("\u672A\u627E\u5230\u5E94\u7528\u5B9E\u4F53[".concat(id, "]"));
|
|
8110
8219
|
}
|
|
8111
8220
|
const constructor = this.constructorCache.get(id);
|
|
8112
8221
|
let service;
|
|
@@ -8177,9 +8286,13 @@ var AuthorityService = class {
|
|
|
8177
8286
|
import { CoreConst } from "@ibiz-template/core";
|
|
8178
8287
|
import { clearCookie, setCookie } from "qx-util";
|
|
8179
8288
|
var V7AuthService = class {
|
|
8180
|
-
async login(loginname, password) {
|
|
8289
|
+
async login(loginname, password, rememberme) {
|
|
8181
8290
|
try {
|
|
8182
|
-
const res = await ibiz.net.post("/v7/login", {
|
|
8291
|
+
const res = await ibiz.net.post("/v7/login", {
|
|
8292
|
+
loginname,
|
|
8293
|
+
password,
|
|
8294
|
+
rememberme
|
|
8295
|
+
});
|
|
8183
8296
|
const { data } = res;
|
|
8184
8297
|
if (data && data.token) {
|
|
8185
8298
|
setCookie(CoreConst.TOKEN, data.token, 0, true);
|
|
@@ -8829,7 +8942,7 @@ var MqttService = class {
|
|
|
8829
8942
|
};
|
|
8830
8943
|
|
|
8831
8944
|
// src/service/de-service-util.ts
|
|
8832
|
-
import { RuntimeError as
|
|
8945
|
+
import { RuntimeError as RuntimeError19 } from "@ibiz-template/core";
|
|
8833
8946
|
var DEServiceUtil = class {
|
|
8834
8947
|
/**
|
|
8835
8948
|
* Creates an instance of DEServiceUtil.
|
|
@@ -8884,7 +8997,7 @@ var DEServiceUtil = class {
|
|
|
8884
8997
|
this.appModel.appId
|
|
8885
8998
|
);
|
|
8886
8999
|
if (!entityModel) {
|
|
8887
|
-
throw new
|
|
9000
|
+
throw new RuntimeError19("\u672A\u627E\u5230\u5E94\u7528\u5B9E\u4F53[".concat(id, "]"));
|
|
8888
9001
|
}
|
|
8889
9002
|
const constructor = this.constructorCache.get(id);
|
|
8890
9003
|
let service;
|
|
@@ -8947,7 +9060,7 @@ var _OpenAppViewCommand = class _OpenAppViewCommand {
|
|
|
8947
9060
|
const context = clone13(_context);
|
|
8948
9061
|
const appView = await ibiz.hub.config.view.get(appViewId);
|
|
8949
9062
|
if (!appView) {
|
|
8950
|
-
throw new
|
|
9063
|
+
throw new RuntimeError20("\u5E94\u7528\u89C6\u56FE[".concat(appViewId, "]\u4E0D\u5B58\u5728"));
|
|
8951
9064
|
}
|
|
8952
9065
|
if ((context.srfkey || params.srfuf === 0 /* CREATE */) && appView.appDataEntityId) {
|
|
8953
9066
|
const deName = calcDeCodeNameById(appView.appDataEntityId);
|
|
@@ -9036,7 +9149,7 @@ var _OpenAppViewCommand = class _OpenAppViewCommand {
|
|
|
9036
9149
|
*/
|
|
9037
9150
|
async openPopover(appView, event, context, params = {}) {
|
|
9038
9151
|
if (!event) {
|
|
9039
|
-
throw new
|
|
9152
|
+
throw new RuntimeError20("\u6C14\u6CE1\u6253\u5F00\u7F3A\u5C11event");
|
|
9040
9153
|
}
|
|
9041
9154
|
return ibiz.openView.popover(appView.id, event, context, params);
|
|
9042
9155
|
}
|
|
@@ -9091,7 +9204,7 @@ var _AppFuncCommand = class _AppFuncCommand {
|
|
|
9091
9204
|
async exec(appFuncId, context, params = {}, opts = {}) {
|
|
9092
9205
|
const appFunc = ibiz.hub.getApp(context.srfappid).getAppFunc(appFuncId);
|
|
9093
9206
|
if (!appFunc) {
|
|
9094
|
-
throw new
|
|
9207
|
+
throw new RuntimeError21("\u627E\u4E0D\u5230\u53EB".concat(appFuncId, "\u7684\u5E94\u7528\u529F\u80FD"));
|
|
9095
9208
|
}
|
|
9096
9209
|
const { navigateContexts, navigateParams, appFuncType } = appFunc;
|
|
9097
9210
|
const _context = context.clone();
|
|
@@ -9125,7 +9238,7 @@ var _AppFuncCommand = class _AppFuncCommand {
|
|
|
9125
9238
|
*/
|
|
9126
9239
|
async openAppView(appFunc, context, params, opts) {
|
|
9127
9240
|
if (!appFunc.appViewId) {
|
|
9128
|
-
throw new
|
|
9241
|
+
throw new RuntimeError21("\u5E94\u7528\u89C6\u56FE[".concat(appFunc.appViewId, "]\u4E0D\u5B58\u5728"));
|
|
9129
9242
|
}
|
|
9130
9243
|
return ibiz.commands.execute(
|
|
9131
9244
|
OpenAppViewCommand.TAG,
|
|
@@ -9159,7 +9272,7 @@ var _AppFuncCommand = class _AppFuncCommand {
|
|
|
9159
9272
|
*/
|
|
9160
9273
|
openPdAppFunc(appFunc, context, params) {
|
|
9161
9274
|
ibiz.log.warn("openPdAppFunc", appFunc, context, params);
|
|
9162
|
-
throw new
|
|
9275
|
+
throw new RuntimeError21("\u672A\u5B9E\u73B0");
|
|
9163
9276
|
}
|
|
9164
9277
|
/**
|
|
9165
9278
|
* 执行 JavaScript 脚本
|
|
@@ -9173,7 +9286,7 @@ var _AppFuncCommand = class _AppFuncCommand {
|
|
|
9173
9286
|
*/
|
|
9174
9287
|
executeJavaScript(appFunc, context, params) {
|
|
9175
9288
|
ibiz.log.warn("executeJavaScript", appFunc, context, params);
|
|
9176
|
-
throw new
|
|
9289
|
+
throw new RuntimeError21("\u672A\u5B9E\u73B0");
|
|
9177
9290
|
}
|
|
9178
9291
|
/**
|
|
9179
9292
|
* 自定义应用功能
|
|
@@ -9187,7 +9300,7 @@ var _AppFuncCommand = class _AppFuncCommand {
|
|
|
9187
9300
|
*/
|
|
9188
9301
|
custom(appFunc, context, params) {
|
|
9189
9302
|
ibiz.log.warn("custom", appFunc, context, params);
|
|
9190
|
-
throw new
|
|
9303
|
+
throw new RuntimeError21("\u672A\u5B9E\u73B0");
|
|
9191
9304
|
}
|
|
9192
9305
|
};
|
|
9193
9306
|
/**
|
|
@@ -9208,7 +9321,7 @@ function installCommand() {
|
|
|
9208
9321
|
}
|
|
9209
9322
|
|
|
9210
9323
|
// src/app-hub.ts
|
|
9211
|
-
import { RuntimeError as
|
|
9324
|
+
import { RuntimeError as RuntimeError56 } from "@ibiz-template/core";
|
|
9212
9325
|
|
|
9213
9326
|
// src/application.ts
|
|
9214
9327
|
import { Net, getToken } from "@ibiz-template/core";
|
|
@@ -9400,7 +9513,7 @@ var Convert = class {
|
|
|
9400
9513
|
};
|
|
9401
9514
|
|
|
9402
9515
|
// src/hub/config/app-view-config-service.ts
|
|
9403
|
-
import { RuntimeError as
|
|
9516
|
+
import { RuntimeError as RuntimeError22 } from "@ibiz-template/core";
|
|
9404
9517
|
var AppViewConfigService = class {
|
|
9405
9518
|
constructor() {
|
|
9406
9519
|
/**
|
|
@@ -9420,7 +9533,7 @@ var AppViewConfigService = class {
|
|
|
9420
9533
|
if (!this.viewConfigs.has(key)) {
|
|
9421
9534
|
const model = await ibiz.hub.getAppView(key);
|
|
9422
9535
|
if (!model) {
|
|
9423
|
-
throw new
|
|
9536
|
+
throw new RuntimeError22("\u89C6\u56FE[".concat(key, "]\u4E0D\u5B58\u5728"));
|
|
9424
9537
|
}
|
|
9425
9538
|
this.set(model.id, {
|
|
9426
9539
|
id: model.id,
|
|
@@ -9476,14 +9589,14 @@ var PanelNotifyState = /* @__PURE__ */ ((PanelNotifyState2) => {
|
|
|
9476
9589
|
|
|
9477
9590
|
// src/controller/common/view/view.controller.ts
|
|
9478
9591
|
import { createUUID as createUUID7, notNilEmpty as notNilEmpty6 } from "qx-util";
|
|
9479
|
-
import { IBizContext as IBizContext2, RuntimeError as
|
|
9592
|
+
import { IBizContext as IBizContext2, RuntimeError as RuntimeError29 } from "@ibiz-template/core";
|
|
9480
9593
|
import { isEmpty as isEmpty8, isNil as isNil18, isNotNil as isNotNil2 } from "ramda";
|
|
9481
9594
|
|
|
9482
9595
|
// src/controller/utils/loading/loading.state.ts
|
|
9483
9596
|
import { NOOP } from "@ibiz-template/core";
|
|
9484
9597
|
|
|
9485
9598
|
// src/controller/utils/counter/counter.ts
|
|
9486
|
-
import { RuntimeError as
|
|
9599
|
+
import { RuntimeError as RuntimeError23 } from "@ibiz-template/core";
|
|
9487
9600
|
var Counter = class {
|
|
9488
9601
|
/**
|
|
9489
9602
|
* Creates an instance of Counter.
|
|
@@ -9545,7 +9658,7 @@ var Counter = class {
|
|
|
9545
9658
|
return;
|
|
9546
9659
|
}
|
|
9547
9660
|
if (this.count === 0) {
|
|
9548
|
-
throw new
|
|
9661
|
+
throw new RuntimeError23("\u9519\u8BEF\u7684\u8C03\u7528\uFF01decrement\u4E0D\u80FD\u5BF9count\u4E3A0\u8C03\u7528");
|
|
9549
9662
|
}
|
|
9550
9663
|
this.count -= 1;
|
|
9551
9664
|
if (this.count === 0) {
|
|
@@ -10105,7 +10218,7 @@ function getOriginData(data) {
|
|
|
10105
10218
|
}
|
|
10106
10219
|
|
|
10107
10220
|
// src/controller/utils/value-rule/value-rule.ts
|
|
10108
|
-
import { RuntimeError as
|
|
10221
|
+
import { RuntimeError as RuntimeError24 } from "@ibiz-template/core";
|
|
10109
10222
|
import { isNilOrEmpty as isNilOrEmpty7, isNumber } from "qx-util";
|
|
10110
10223
|
import { isNil as isNil14 } from "ramda";
|
|
10111
10224
|
function generateRules(itemVRs, name, valueItemName) {
|
|
@@ -10155,7 +10268,7 @@ function generateRules(itemVRs, name, valueItemName) {
|
|
|
10155
10268
|
deRule.groupCond
|
|
10156
10269
|
);
|
|
10157
10270
|
if (!isPast) {
|
|
10158
|
-
callback(new
|
|
10271
|
+
callback(new RuntimeError24(infoMessage || deRule.ruleInfo));
|
|
10159
10272
|
}
|
|
10160
10273
|
return true;
|
|
10161
10274
|
},
|
|
@@ -10225,7 +10338,7 @@ function generateEditorRules(editor) {
|
|
|
10225
10338
|
}
|
|
10226
10339
|
|
|
10227
10340
|
// src/controller/utils/value-ex/value-ex.ts
|
|
10228
|
-
import { RuntimeError as
|
|
10341
|
+
import { RuntimeError as RuntimeError25 } from "@ibiz-template/core";
|
|
10229
10342
|
import { isNil as isNil15, mergeLeft } from "ramda";
|
|
10230
10343
|
var ValueExUtil = class {
|
|
10231
10344
|
/**
|
|
@@ -10257,7 +10370,7 @@ var ValueExUtil = class {
|
|
|
10257
10370
|
const { valueType, objectNameField, textSeparator } = this.mergeDefault(options);
|
|
10258
10371
|
if (["OBJECTS", "OBJECT"].includes(valueType)) {
|
|
10259
10372
|
if (!objectNameField) {
|
|
10260
|
-
throw new
|
|
10373
|
+
throw new RuntimeError25("\u7F3A\u5C11objectNameField");
|
|
10261
10374
|
}
|
|
10262
10375
|
const textKey = objectNameField.toLowerCase();
|
|
10263
10376
|
if (valueType === "OBJECTS") {
|
|
@@ -10273,7 +10386,7 @@ var ValueExUtil = class {
|
|
|
10273
10386
|
};
|
|
10274
10387
|
|
|
10275
10388
|
// src/controller/utils/value-default/value-default.ts
|
|
10276
|
-
import { RuntimeError as
|
|
10389
|
+
import { RuntimeError as RuntimeError26, ModelError as ModelError16 } from "@ibiz-template/core";
|
|
10277
10390
|
import dayjs from "dayjs";
|
|
10278
10391
|
import { createUUID as createUUID6 } from "qx-util";
|
|
10279
10392
|
import { isNil as isNil16, isNotNil } from "ramda";
|
|
@@ -10314,7 +10427,7 @@ function getDefaultValue(opts, origins) {
|
|
|
10314
10427
|
case "SESSION":
|
|
10315
10428
|
case "APPLICATION":
|
|
10316
10429
|
if (!((_a = ibiz.appData) == null ? void 0 : _a.context)) {
|
|
10317
|
-
throw new
|
|
10430
|
+
throw new RuntimeError26("appdata.context\u4E0D\u5B58\u5728");
|
|
10318
10431
|
}
|
|
10319
10432
|
return ibiz.appData.context[defaultValue];
|
|
10320
10433
|
case "CONTEXT":
|
|
@@ -10328,7 +10441,7 @@ function getDefaultValue(opts, origins) {
|
|
|
10328
10441
|
|
|
10329
10442
|
// src/controller/utils/data-file-util/data-file-util.ts
|
|
10330
10443
|
import {
|
|
10331
|
-
RuntimeError as
|
|
10444
|
+
RuntimeError as RuntimeError27
|
|
10332
10445
|
} from "@ibiz-template/core";
|
|
10333
10446
|
var asyncImportUrl = "asyncimportdata2";
|
|
10334
10447
|
var importUrl = "importdata2";
|
|
@@ -10382,11 +10495,11 @@ async function importData(file, appDataEntity, dataImport) {
|
|
|
10382
10495
|
}
|
|
10383
10496
|
async function exportData(header, data, fileName) {
|
|
10384
10497
|
if (!ibiz.util.getExcelUtil) {
|
|
10385
|
-
throw new
|
|
10498
|
+
throw new RuntimeError27("ibiz.util.getExportExcel\u4E0D\u5B58\u5728");
|
|
10386
10499
|
}
|
|
10387
10500
|
const exportExcel = await ibiz.util.getExcelUtil();
|
|
10388
10501
|
if (!exportExcel) {
|
|
10389
|
-
throw new
|
|
10502
|
+
throw new RuntimeError27("\u5BFC\u51FA\u6A21\u5757\u52A0\u8F7D\u9519\u8BEF");
|
|
10390
10503
|
}
|
|
10391
10504
|
try {
|
|
10392
10505
|
exportExcel.exportJsonToExcel({
|
|
@@ -10612,7 +10725,7 @@ var BaseController = class {
|
|
|
10612
10725
|
};
|
|
10613
10726
|
|
|
10614
10727
|
// src/controller/utils/view-msg/view-msg-controller.ts
|
|
10615
|
-
import { RuntimeError as
|
|
10728
|
+
import { RuntimeError as RuntimeError28, RuntimeModelError as RuntimeModelError21 } from "@ibiz-template/core";
|
|
10616
10729
|
import { isNil as isNil17, mergeRight as mergeRight2 } from "ramda";
|
|
10617
10730
|
var ViewMsgController = class _ViewMsgController {
|
|
10618
10731
|
constructor(msgGroupId) {
|
|
@@ -10638,7 +10751,7 @@ var ViewMsgController = class _ViewMsgController {
|
|
|
10638
10751
|
(item) => item.id === this.msgGroupId
|
|
10639
10752
|
);
|
|
10640
10753
|
if (!msgGroup) {
|
|
10641
|
-
throw new
|
|
10754
|
+
throw new RuntimeError28("\u627E\u4E0D\u5230\u89C6\u56FE\u6D88\u606F\u7EC4".concat(this.msgGroupId, "\u7684\u6A21\u578B"));
|
|
10642
10755
|
}
|
|
10643
10756
|
this.msgGroup = msgGroup;
|
|
10644
10757
|
const msgDetailsViewMsgIds = msgGroup.appViewMsgGroupDetails.map(
|
|
@@ -10652,7 +10765,7 @@ var ViewMsgController = class _ViewMsgController {
|
|
|
10652
10765
|
}
|
|
10653
10766
|
});
|
|
10654
10767
|
if (msgDetailsViewMsgIds.length) {
|
|
10655
|
-
throw new
|
|
10768
|
+
throw new RuntimeError28(
|
|
10656
10769
|
"\u6CA1\u6709\u627E\u5230".concat(msgDetailsViewMsgIds.join(","), "\u89C6\u56FE\u6D88\u606F\u6A21\u578B")
|
|
10657
10770
|
);
|
|
10658
10771
|
}
|
|
@@ -11064,7 +11177,7 @@ var ViewController = class extends BaseController {
|
|
|
11064
11177
|
async callUIAction(key, args) {
|
|
11065
11178
|
const result = this.call(key, args);
|
|
11066
11179
|
if (result === void 0) {
|
|
11067
|
-
throw new
|
|
11180
|
+
throw new RuntimeError29("\u6CA1\u6709\u5F15\u64CE\u652F\u6301\u9884\u7F6E\u754C\u9762\u884C\u4E3A".concat(key));
|
|
11068
11181
|
}
|
|
11069
11182
|
return result;
|
|
11070
11183
|
}
|
|
@@ -11655,7 +11768,7 @@ var ControlController = class extends BaseController {
|
|
|
11655
11768
|
};
|
|
11656
11769
|
|
|
11657
11770
|
// src/controller/common/control/md-control.controller.ts
|
|
11658
|
-
import { isElementSame, RuntimeError as
|
|
11771
|
+
import { isElementSame, RuntimeError as RuntimeError30 } from "@ibiz-template/core";
|
|
11659
11772
|
import { debounce } from "lodash-es";
|
|
11660
11773
|
var MDControlController = class extends ControlController {
|
|
11661
11774
|
constructor() {
|
|
@@ -11847,7 +11960,7 @@ var MDControlController = class extends ControlController {
|
|
|
11847
11960
|
async remove(args) {
|
|
11848
11961
|
const { context, params, data } = this.handlerAbilityParams(args);
|
|
11849
11962
|
if (!(data == null ? void 0 : data.length)) {
|
|
11850
|
-
throw new
|
|
11963
|
+
throw new RuntimeError30("\u672A\u9009\u4E2D\u6570\u636E");
|
|
11851
11964
|
}
|
|
11852
11965
|
if ((args == null ? void 0 : args.silent) !== true) {
|
|
11853
11966
|
const del = await ibiz.confirm.error({
|
|
@@ -11983,7 +12096,7 @@ var MDControlController = class extends ControlController {
|
|
|
11983
12096
|
(importItem) => importItem.id === dedataImportId
|
|
11984
12097
|
);
|
|
11985
12098
|
if (!dataImport) {
|
|
11986
|
-
throw new
|
|
12099
|
+
throw new RuntimeError30("\u65E0\u5BFC\u5165\u6A21\u578B\uFF01");
|
|
11987
12100
|
}
|
|
11988
12101
|
const modal = ibiz.overlay.createModal(
|
|
11989
12102
|
"DataImport",
|
|
@@ -12013,7 +12126,7 @@ var MDControlController = class extends ControlController {
|
|
|
12013
12126
|
// src/controller/control/app-menu/app-menu.controller.ts
|
|
12014
12127
|
import {
|
|
12015
12128
|
findRecursiveChild,
|
|
12016
|
-
RuntimeError as
|
|
12129
|
+
RuntimeError as RuntimeError31,
|
|
12017
12130
|
RuntimeModelError as RuntimeModelError23
|
|
12018
12131
|
} from "@ibiz-template/core";
|
|
12019
12132
|
var AppMenuController = class extends ControlController {
|
|
@@ -12053,7 +12166,7 @@ var AppMenuController = class extends ControlController {
|
|
|
12053
12166
|
childrenFields: ["appMenuItems"]
|
|
12054
12167
|
});
|
|
12055
12168
|
if (!menuItem) {
|
|
12056
|
-
throw new
|
|
12169
|
+
throw new RuntimeError31("\u627E\u4E0D\u5230\u540D\u4E3A".concat(id, "\u7684\u83DC\u5355\u9879"));
|
|
12057
12170
|
}
|
|
12058
12171
|
this.evt.emit("onClick", {
|
|
12059
12172
|
eventArg: id,
|
|
@@ -12143,7 +12256,7 @@ var AppMenuController = class extends ControlController {
|
|
|
12143
12256
|
// src/controller/control/app-menu-icon-view/app-menu-icon-view.controller.ts
|
|
12144
12257
|
import {
|
|
12145
12258
|
findRecursiveChild as findRecursiveChild2,
|
|
12146
|
-
RuntimeError as
|
|
12259
|
+
RuntimeError as RuntimeError32,
|
|
12147
12260
|
RuntimeModelError as RuntimeModelError24
|
|
12148
12261
|
} from "@ibiz-template/core";
|
|
12149
12262
|
var AppMenuIconViewController = class extends AppMenuController {
|
|
@@ -12153,7 +12266,7 @@ var AppMenuIconViewController = class extends AppMenuController {
|
|
|
12153
12266
|
childrenFields: ["appMenuItems"]
|
|
12154
12267
|
});
|
|
12155
12268
|
if (!menuItem) {
|
|
12156
|
-
throw new
|
|
12269
|
+
throw new RuntimeError32("\u627E\u4E0D\u5230\u540D\u4E3A".concat(id, "\u7684\u83DC\u5355\u9879"));
|
|
12157
12270
|
}
|
|
12158
12271
|
this.evt.emit("onClick", {
|
|
12159
12272
|
eventArg: id,
|
|
@@ -12181,7 +12294,7 @@ var AppMenuIconViewController = class extends AppMenuController {
|
|
|
12181
12294
|
import dayjs2 from "dayjs";
|
|
12182
12295
|
|
|
12183
12296
|
// src/controller/control/calendar/calendar.service.ts
|
|
12184
|
-
import { RuntimeError as
|
|
12297
|
+
import { RuntimeError as RuntimeError33 } from "@ibiz-template/core";
|
|
12185
12298
|
var CalendarService = class extends MDControlService {
|
|
12186
12299
|
/**
|
|
12187
12300
|
* 执行查询多条数据的方法
|
|
@@ -12231,11 +12344,11 @@ var CalendarService = class extends MDControlService {
|
|
|
12231
12344
|
setCalendarConfigData(items, index) {
|
|
12232
12345
|
const { sysCalendarItems } = this.model;
|
|
12233
12346
|
if (!sysCalendarItems) {
|
|
12234
|
-
throw new
|
|
12347
|
+
throw new RuntimeError33("\u672A\u627E\u5230\u65E5\u5386\u9879\u6A21\u578B");
|
|
12235
12348
|
}
|
|
12236
12349
|
const calendarItem = sysCalendarItems[index];
|
|
12237
12350
|
if (!calendarItem) {
|
|
12238
|
-
throw new
|
|
12351
|
+
throw new RuntimeError33("\u672A\u627E\u5230\u65E5\u5386\u9879\u6A21\u578B");
|
|
12239
12352
|
}
|
|
12240
12353
|
return items.map((item) => {
|
|
12241
12354
|
return new CalendarItemData(calendarItem, item);
|
|
@@ -12449,11 +12562,11 @@ var CalendarController = class extends MDControlController {
|
|
|
12449
12562
|
};
|
|
12450
12563
|
|
|
12451
12564
|
// src/controller/control/chart/chart.controller.ts
|
|
12452
|
-
import { RuntimeError as
|
|
12565
|
+
import { RuntimeError as RuntimeError35 } from "@ibiz-template/core";
|
|
12453
12566
|
|
|
12454
12567
|
// src/controller/control/chart/generator/chart-options-generator.ts
|
|
12455
12568
|
import { mergeDeepRight as mergeDeepRight3 } from "ramda";
|
|
12456
|
-
import { RuntimeError as
|
|
12569
|
+
import { RuntimeError as RuntimeError34 } from "@ibiz-template/core";
|
|
12457
12570
|
|
|
12458
12571
|
// src/controller/control/chart/generator/line-series-generator.ts
|
|
12459
12572
|
import { RuntimeModelError as RuntimeModelError26 } from "@ibiz-template/core";
|
|
@@ -12977,7 +13090,7 @@ var BarSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
12977
13090
|
var FunnelSeriesGenerator = class extends BaseSeriesGenerator {
|
|
12978
13091
|
calcStaticOptions() {
|
|
12979
13092
|
const options = super.calcStaticOptions();
|
|
12980
|
-
options.label.formatter = "{b}: {d}%
|
|
13093
|
+
options.label.formatter = "{b}: {d}%";
|
|
12981
13094
|
options.label.position = "outer";
|
|
12982
13095
|
return options;
|
|
12983
13096
|
}
|
|
@@ -12997,7 +13110,7 @@ var FunnelSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
12997
13110
|
var PieSeriesGenerator = class extends BaseSeriesGenerator {
|
|
12998
13111
|
calcStaticOptions() {
|
|
12999
13112
|
const options = super.calcStaticOptions();
|
|
13000
|
-
options.label.formatter = "{b}: {d}%
|
|
13113
|
+
options.label.formatter = "{b}: {d}%";
|
|
13001
13114
|
options.label.position = "outside";
|
|
13002
13115
|
return options;
|
|
13003
13116
|
}
|
|
@@ -13456,7 +13569,7 @@ var ChartOptionsGenerator2 = class {
|
|
|
13456
13569
|
getChartDataByParams(params) {
|
|
13457
13570
|
const generator = this.seriesGeneratorIndexMap.get(params.seriesIndex);
|
|
13458
13571
|
if (!generator) {
|
|
13459
|
-
throw new
|
|
13572
|
+
throw new RuntimeError34("\u627E\u4E0D\u5230".concat(params.seriesIndex, "\u5E8F\u5217\u7684generator\uFF01"));
|
|
13460
13573
|
}
|
|
13461
13574
|
return generator.getChartDataByParams(params);
|
|
13462
13575
|
}
|
|
@@ -13570,10 +13683,10 @@ var ChartController = class extends MDControlController {
|
|
|
13570
13683
|
*/
|
|
13571
13684
|
updateChart() {
|
|
13572
13685
|
if (!this.chart) {
|
|
13573
|
-
throw new
|
|
13686
|
+
throw new RuntimeError35("chart\u5BF9\u8C61\u6CA1\u6709\u6B63\u786E\u521D\u59CB\u5316");
|
|
13574
13687
|
}
|
|
13575
13688
|
if (!this.options) {
|
|
13576
|
-
throw new
|
|
13689
|
+
throw new RuntimeError35("options\u8FD8\u6CA1\u8BA1\u7B97");
|
|
13577
13690
|
}
|
|
13578
13691
|
this.chart.setOption(this.options);
|
|
13579
13692
|
this.resizeChart();
|
|
@@ -13618,7 +13731,7 @@ var CaptionBarController = class extends ControlController {
|
|
|
13618
13731
|
};
|
|
13619
13732
|
|
|
13620
13733
|
// src/controller/control/toolbar/toolbar.controllerr.ts
|
|
13621
|
-
import { recursiveIterate, RuntimeError as
|
|
13734
|
+
import { recursiveIterate, RuntimeError as RuntimeError44 } from "@ibiz-template/core";
|
|
13622
13735
|
|
|
13623
13736
|
// src/ui-action/provider/backend-ui-action-provider.ts
|
|
13624
13737
|
import { RuntimeModelError as RuntimeModelError47 } from "@ibiz-template/core";
|
|
@@ -13628,7 +13741,7 @@ import { isArray as isArray9 } from "qx-util";
|
|
|
13628
13741
|
import { RuntimeModelError as RuntimeModelError46 } from "@ibiz-template/core";
|
|
13629
13742
|
|
|
13630
13743
|
// src/ui-logic/index.ts
|
|
13631
|
-
import { RuntimeError as
|
|
13744
|
+
import { RuntimeError as RuntimeError41 } from "@ibiz-template/core";
|
|
13632
13745
|
|
|
13633
13746
|
// src/ui-logic/ui-logic.ts
|
|
13634
13747
|
import { ModelError as ModelError24, RuntimeModelError as RuntimeModelError45 } from "@ibiz-template/core";
|
|
@@ -14164,7 +14277,7 @@ var EndNode2 = class extends UILogicNode {
|
|
|
14164
14277
|
};
|
|
14165
14278
|
|
|
14166
14279
|
// src/ui-logic/ui-logic-node/prepare-js-param-node/prepare-js-param-node.ts
|
|
14167
|
-
import { ModelError as ModelError21, RuntimeError as
|
|
14280
|
+
import { ModelError as ModelError21, RuntimeError as RuntimeError36 } from "@ibiz-template/core";
|
|
14168
14281
|
import { clone as clone17 } from "ramda";
|
|
14169
14282
|
var PrepareJSParamNode = class extends UILogicNode {
|
|
14170
14283
|
async exec(ctx) {
|
|
@@ -14214,7 +14327,7 @@ var PrepareJSParamNode = class extends UILogicNode {
|
|
|
14214
14327
|
setParamValue(nodeParam, ctx) {
|
|
14215
14328
|
const { dstFieldName, dstDEUILogicParamId } = nodeParam;
|
|
14216
14329
|
if (!dstDEUILogicParamId) {
|
|
14217
|
-
throw new
|
|
14330
|
+
throw new RuntimeError36("\u6CA1\u6709\u76EE\u6807\u53C2\u6570\u5BF9\u8C61id");
|
|
14218
14331
|
}
|
|
14219
14332
|
let dstField = dstFieldName;
|
|
14220
14333
|
if (ctx.isEntityParam(dstDEUILogicParamId)) {
|
|
@@ -14331,7 +14444,7 @@ var PrepareJSParamNode = class extends UILogicNode {
|
|
|
14331
14444
|
};
|
|
14332
14445
|
|
|
14333
14446
|
// src/ui-logic/ui-logic-node/view-ctrl-invoke-node/view-ctrl-invoke-node.ts
|
|
14334
|
-
import { RuntimeError as
|
|
14447
|
+
import { RuntimeError as RuntimeError37, RuntimeModelError as RuntimeModelError33 } from "@ibiz-template/core";
|
|
14335
14448
|
import { isFunction } from "lodash-es";
|
|
14336
14449
|
var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
14337
14450
|
async exec(ctx) {
|
|
@@ -14348,14 +14461,14 @@ var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
|
14348
14461
|
}
|
|
14349
14462
|
const invokeParam = ctx.params[invokeParamId];
|
|
14350
14463
|
if (!invokeParam) {
|
|
14351
|
-
throw new
|
|
14464
|
+
throw new RuntimeError37("\u6CA1\u6709\u627E\u5230\u64CD\u4F5C\u53C2\u6570".concat(invokeParamId));
|
|
14352
14465
|
}
|
|
14353
14466
|
const invokeCtrl = ctx.params[invokeCtrlId];
|
|
14354
14467
|
if (!invokeCtrl) {
|
|
14355
|
-
throw new
|
|
14468
|
+
throw new RuntimeError37("\u6CA1\u6709\u627E\u5230\u754C\u9762\u5BF9\u8C61".concat(invokeCtrlId));
|
|
14356
14469
|
}
|
|
14357
14470
|
if (!invokeCtrl[invokeMethod] || !isFunction(invokeCtrl[invokeMethod])) {
|
|
14358
|
-
throw new
|
|
14471
|
+
throw new RuntimeError37("\u6CA1\u6709\u627E\u5230\u8C03\u7528\u65B9\u6CD5".concat(invokeMethod));
|
|
14359
14472
|
}
|
|
14360
14473
|
await invokeCtrl[invokeMethod](invokeParam);
|
|
14361
14474
|
}
|
|
@@ -14581,16 +14694,16 @@ var DataSetNode2 = class extends UILogicNode {
|
|
|
14581
14694
|
};
|
|
14582
14695
|
|
|
14583
14696
|
// src/ui-logic/ui-logic-node/throw-exception-node/throw-exception-node.ts
|
|
14584
|
-
import { RuntimeError as
|
|
14697
|
+
import { RuntimeError as RuntimeError38 } from "@ibiz-template/core";
|
|
14585
14698
|
var ThrowExceptionNode2 = class extends UILogicNode {
|
|
14586
14699
|
async exec(_ctx) {
|
|
14587
14700
|
const { errorInfo } = this.model;
|
|
14588
|
-
throw new
|
|
14701
|
+
throw new RuntimeError38(errorInfo);
|
|
14589
14702
|
}
|
|
14590
14703
|
};
|
|
14591
14704
|
|
|
14592
14705
|
// src/ui-logic/ui-logic-node/view-ctrl-fire-event-node/view-ctrl-fire-event-node.ts
|
|
14593
|
-
import { RuntimeError as
|
|
14706
|
+
import { RuntimeError as RuntimeError39, RuntimeModelError as RuntimeModelError43 } from "@ibiz-template/core";
|
|
14594
14707
|
var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
14595
14708
|
async exec(ctx) {
|
|
14596
14709
|
ctx.isEndNode = true;
|
|
@@ -14606,18 +14719,18 @@ var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
|
14606
14719
|
}
|
|
14607
14720
|
const invokeCtrl = ctx.params[fireCtrlId];
|
|
14608
14721
|
if (!invokeCtrl) {
|
|
14609
|
-
throw new
|
|
14722
|
+
throw new RuntimeError39("\u6CA1\u6709\u627E\u5230\u89E6\u53D1\u5BF9\u8C61".concat(fireCtrlId));
|
|
14610
14723
|
}
|
|
14611
14724
|
const eventParam = ctx.params[eventParamId];
|
|
14612
14725
|
if (!eventParam) {
|
|
14613
|
-
throw new
|
|
14726
|
+
throw new RuntimeError39("\u6CA1\u6709\u627E\u5230\u4E8B\u4EF6\u53C2\u6570\u5BF9\u8C61".concat(eventParamId));
|
|
14614
14727
|
}
|
|
14615
14728
|
await invokeCtrl.evt.emit(eventName, eventParam);
|
|
14616
14729
|
}
|
|
14617
14730
|
};
|
|
14618
14731
|
|
|
14619
14732
|
// src/ui-logic/ui-logic-node/execute-de-logic-node/execute-de-logic-node.ts
|
|
14620
|
-
import { RuntimeError as
|
|
14733
|
+
import { RuntimeError as RuntimeError40, RuntimeModelError as RuntimeModelError44 } from "@ibiz-template/core";
|
|
14621
14734
|
var ExecuteDELogicNode = class extends UILogicNode {
|
|
14622
14735
|
async exec(ctx) {
|
|
14623
14736
|
const {
|
|
@@ -14637,7 +14750,7 @@ var ExecuteDELogicNode = class extends UILogicNode {
|
|
|
14637
14750
|
}
|
|
14638
14751
|
const dstParam = ctx.params[dstDEUILogicParamId];
|
|
14639
14752
|
if (!dstParam) {
|
|
14640
|
-
throw new
|
|
14753
|
+
throw new RuntimeError40("\u6CA1\u6709\u627E\u5230\u4F20\u5165\u53C2\u6570".concat(dstDEUILogicParamId));
|
|
14641
14754
|
}
|
|
14642
14755
|
const result = await execDELogicById(
|
|
14643
14756
|
dstAppDELogicId,
|
|
@@ -14941,7 +15054,7 @@ async function execUILogic(deUILogicId, appDataEntityId, parameters) {
|
|
|
14941
15054
|
const app = ibiz.hub.getApp(parameters.context.srfappid);
|
|
14942
15055
|
const deUILogic = await app.getDEUILogic(deUILogicId, appDataEntityId);
|
|
14943
15056
|
if (!deUILogic) {
|
|
14944
|
-
throw new
|
|
15057
|
+
throw new RuntimeError41(
|
|
14945
15058
|
"\u627E\u4E0D\u5230\u5B9E\u4F53".concat(appDataEntityId, "\u7684\u754C\u9762\u903B\u8F91").concat(deUILogicId)
|
|
14946
15059
|
);
|
|
14947
15060
|
}
|
|
@@ -14954,7 +15067,7 @@ async function execUILogic(deUILogicId, appDataEntityId, parameters) {
|
|
|
14954
15067
|
}
|
|
14955
15068
|
|
|
14956
15069
|
// src/ui-action/uiaction-util.ts
|
|
14957
|
-
import { RuntimeError as
|
|
15070
|
+
import { RuntimeError as RuntimeError42 } from "@ibiz-template/core";
|
|
14958
15071
|
var UIActionUtil = class {
|
|
14959
15072
|
/**
|
|
14960
15073
|
* 执行界面行为
|
|
@@ -14969,7 +15082,7 @@ var UIActionUtil = class {
|
|
|
14969
15082
|
static async exec(actionId, params) {
|
|
14970
15083
|
const action = await getUIActionById(actionId);
|
|
14971
15084
|
if (!action) {
|
|
14972
|
-
throw new
|
|
15085
|
+
throw new RuntimeError42("\u6CA1\u627E\u5230".concat(actionId, "\u7684\u754C\u9762\u884C\u4E3A\u6A21\u578B"));
|
|
14973
15086
|
}
|
|
14974
15087
|
if (action.actionTarget === "SINGLEDATA") {
|
|
14975
15088
|
const validateResult = await params.view.call("Validate" /* VALIDATE */);
|
|
@@ -15378,7 +15491,7 @@ import {
|
|
|
15378
15491
|
StringUtil,
|
|
15379
15492
|
RuntimeModelError as RuntimeModelError48,
|
|
15380
15493
|
ModelError as ModelError25,
|
|
15381
|
-
RuntimeError as
|
|
15494
|
+
RuntimeError as RuntimeError43
|
|
15382
15495
|
} from "@ibiz-template/core";
|
|
15383
15496
|
var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
15384
15497
|
async execAction(action, args) {
|
|
@@ -15470,6 +15583,12 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15470
15583
|
*/
|
|
15471
15584
|
async executePrint(action, args) {
|
|
15472
15585
|
var _a, _b;
|
|
15586
|
+
const { resultParams } = await this.handleParams(
|
|
15587
|
+
action,
|
|
15588
|
+
args.context,
|
|
15589
|
+
args.data,
|
|
15590
|
+
args.params
|
|
15591
|
+
);
|
|
15473
15592
|
const appDataEntity = await ibiz.hub.getAppDataEntity(
|
|
15474
15593
|
action.appDataEntityId
|
|
15475
15594
|
);
|
|
@@ -15480,22 +15599,26 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15480
15599
|
let requestUrl = "";
|
|
15481
15600
|
const { context } = args;
|
|
15482
15601
|
if (context && context[appDataEntity.codeName.toLowerCase()]) {
|
|
15483
|
-
requestUrl += "/".concat((_b = appDataEntity.codeName2) == null ? void 0 : _b.toLowerCase(), "/printdata/").concat(context[appDataEntity.codeName.toLowerCase()]
|
|
15602
|
+
requestUrl += "/".concat((_b = appDataEntity.codeName2) == null ? void 0 : _b.toLowerCase(), "/printdata/").concat(context[appDataEntity.codeName.toLowerCase()]);
|
|
15484
15603
|
} else {
|
|
15485
|
-
throw new
|
|
15604
|
+
throw new RuntimeError43("\u6CA1\u6709\u627E\u5230\u6570\u636E\u4E3B\u952E");
|
|
15486
15605
|
}
|
|
15487
15606
|
const res = await ibiz.net.request(requestUrl, {
|
|
15488
15607
|
method: "get",
|
|
15489
|
-
responseType: "blob"
|
|
15608
|
+
responseType: "blob",
|
|
15609
|
+
params: {
|
|
15610
|
+
srfprinttag: appDEPrint.codeName,
|
|
15611
|
+
...resultParams
|
|
15612
|
+
}
|
|
15490
15613
|
});
|
|
15491
15614
|
if (res.ok) {
|
|
15492
15615
|
const link = window.URL.createObjectURL(res.data);
|
|
15493
15616
|
window.open(link, "_blank");
|
|
15494
15617
|
} else {
|
|
15495
|
-
throw new
|
|
15618
|
+
throw new RuntimeError43("\u6253\u5370\u5931\u8D25");
|
|
15496
15619
|
}
|
|
15497
15620
|
} else {
|
|
15498
|
-
throw new
|
|
15621
|
+
throw new RuntimeError43("\u6CA1\u6709\u627E\u5230\u5B9E\u4F53\u6253\u5370\u9879");
|
|
15499
15622
|
}
|
|
15500
15623
|
}
|
|
15501
15624
|
/**
|
|
@@ -15533,7 +15656,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15533
15656
|
refreshMode: 1
|
|
15534
15657
|
};
|
|
15535
15658
|
}
|
|
15536
|
-
throw new
|
|
15659
|
+
throw new RuntimeError43("\u6CA1\u6709\u627E\u5230\u5B9E\u4F53\u5BFC\u5165\u9879");
|
|
15537
15660
|
}
|
|
15538
15661
|
/**
|
|
15539
15662
|
* 执行导出行为
|
|
@@ -15542,8 +15665,14 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15542
15665
|
* @param {IUILogicParams} args
|
|
15543
15666
|
* @return {*}
|
|
15544
15667
|
*/
|
|
15545
|
-
async executeDataExport(action,
|
|
15668
|
+
async executeDataExport(action, args) {
|
|
15546
15669
|
var _a, _b;
|
|
15670
|
+
const { resultParams } = await this.handleParams(
|
|
15671
|
+
action,
|
|
15672
|
+
args.context,
|
|
15673
|
+
args.data,
|
|
15674
|
+
args.params
|
|
15675
|
+
);
|
|
15547
15676
|
const appDataEntity = await ibiz.hub.getAppDataEntity(
|
|
15548
15677
|
action.appDataEntityId
|
|
15549
15678
|
);
|
|
@@ -15555,12 +15684,12 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15555
15684
|
const params = {
|
|
15556
15685
|
page: 0,
|
|
15557
15686
|
size: appDEDataExport.maxRowCount ? appDEDataExport.maxRowCount : 1e3,
|
|
15558
|
-
|
|
15687
|
+
...args.params,
|
|
15688
|
+
...resultParams
|
|
15559
15689
|
};
|
|
15560
15690
|
const res = await ibiz.net.request(url, {
|
|
15561
15691
|
method: "post",
|
|
15562
|
-
data: params
|
|
15563
|
-
responseType: "blob"
|
|
15692
|
+
data: params
|
|
15564
15693
|
});
|
|
15565
15694
|
if (res.status === 200) {
|
|
15566
15695
|
let fileName = "".concat(appDataEntity.logicName, "\u8868.xlsx");
|
|
@@ -15577,10 +15706,10 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
15577
15706
|
URL.revokeObjectURL(elink.href);
|
|
15578
15707
|
document.body.removeChild(elink);
|
|
15579
15708
|
} else {
|
|
15580
|
-
throw new
|
|
15709
|
+
throw new RuntimeError43("\u5BFC\u51FA\u8BF7\u6C42\u5931\u8D25");
|
|
15581
15710
|
}
|
|
15582
15711
|
} else {
|
|
15583
|
-
throw new
|
|
15712
|
+
throw new RuntimeError43("\u6CA1\u6709\u627E\u5230\u5B9E\u4F53\u5BFC\u51FA\u9879");
|
|
15584
15713
|
}
|
|
15585
15714
|
}
|
|
15586
15715
|
};
|
|
@@ -15648,7 +15777,7 @@ var ToolbarController = class extends ControlController {
|
|
|
15648
15777
|
const actionId = item.uiactionId;
|
|
15649
15778
|
const uiAction = await getUIActionById(actionId);
|
|
15650
15779
|
if (!uiAction) {
|
|
15651
|
-
throw new
|
|
15780
|
+
throw new RuntimeError44("\u6CA1\u6709\u627E\u5230\u754C\u9762\u884C\u4E3A\u6A21\u578B".concat(actionId));
|
|
15652
15781
|
}
|
|
15653
15782
|
const enableLoading = ["SYS", "BACKEND", "WFBACKEND"].includes(uiAction.uiactionMode) && uiAction.showBusyIndicator !== false;
|
|
15654
15783
|
if (enableLoading) {
|
|
@@ -16670,7 +16799,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
16670
16799
|
import { RuntimeModelError as RuntimeModelError51 } from "@ibiz-template/core";
|
|
16671
16800
|
|
|
16672
16801
|
// src/controller/control/exp-bar/exp-bar.controller.ts
|
|
16673
|
-
import { RuntimeError as
|
|
16802
|
+
import { RuntimeError as RuntimeError45, RuntimeModelError as RuntimeModelError50 } from "@ibiz-template/core";
|
|
16674
16803
|
var ExpBarControlController = class extends ControlController {
|
|
16675
16804
|
constructor() {
|
|
16676
16805
|
super(...arguments);
|
|
@@ -16996,7 +17125,7 @@ var ExpBarControlController = class extends ControlController {
|
|
|
16996
17125
|
if (["GRID", "DATAVIEW", "LIST"].includes(((_a = this.XDataModel) == null ? void 0 : _a.controlType) || "")) {
|
|
16997
17126
|
return this.XDataModel.navAppViewId;
|
|
16998
17127
|
}
|
|
16999
|
-
throw new
|
|
17128
|
+
throw new RuntimeError45("\u591A\u8282\u70B9\u89C6\u56FE\u7531\u5B50\u7C7B\u5B9E\u73B0");
|
|
17000
17129
|
}
|
|
17001
17130
|
/**
|
|
17002
17131
|
* 获取导航视图
|
|
@@ -17139,7 +17268,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
17139
17268
|
};
|
|
17140
17269
|
|
|
17141
17270
|
// src/controller/control/exp-bar/tree-exp-bar.controller.ts
|
|
17142
|
-
import { RuntimeError as
|
|
17271
|
+
import { RuntimeError as RuntimeError46, RuntimeModelError as RuntimeModelError52 } from "@ibiz-template/core";
|
|
17143
17272
|
var TreeExpBarController = class extends ExpBarControlController {
|
|
17144
17273
|
constructor() {
|
|
17145
17274
|
super(...arguments);
|
|
@@ -17214,7 +17343,7 @@ var TreeExpBarController = class extends ExpBarControlController {
|
|
|
17214
17343
|
const deData = node.deData || node;
|
|
17215
17344
|
const nodeModel = this.getNodeModel(node.nodeId);
|
|
17216
17345
|
if (!nodeModel) {
|
|
17217
|
-
throw new
|
|
17346
|
+
throw new RuntimeError46("\u627E\u4E0D\u5230".concat(node.nodeId, "\u7684\u8282\u70B9\u6A21\u578B"));
|
|
17218
17347
|
}
|
|
17219
17348
|
const result = this.prepareParams(nodeModel, deData, context, params);
|
|
17220
17349
|
result.context.currentSrfNav = nodeId;
|
|
@@ -19030,7 +19159,7 @@ var FormMDCtrlContentTypeController = class {
|
|
|
19030
19159
|
import { clone as clone20 } from "ramda";
|
|
19031
19160
|
|
|
19032
19161
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-control/form-mdctrl-control.controller.ts
|
|
19033
|
-
import { RuntimeError as
|
|
19162
|
+
import { RuntimeError as RuntimeError47 } from "@ibiz-template/core";
|
|
19034
19163
|
var FormMDCtrlControlController = class extends FormMDCtrlContentTypeController {
|
|
19035
19164
|
/**
|
|
19036
19165
|
* 初始化
|
|
@@ -19045,7 +19174,7 @@ var FormMDCtrlControlController = class extends FormMDCtrlContentTypeController
|
|
|
19045
19174
|
const { model } = this.parent;
|
|
19046
19175
|
const { contentControl } = model;
|
|
19047
19176
|
if (!contentControl) {
|
|
19048
|
-
throw new
|
|
19177
|
+
throw new RuntimeError47("\u8868\u5355\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5D4C\u5165\u90E8\u4EF6");
|
|
19049
19178
|
}
|
|
19050
19179
|
this.controlModel = contentControl;
|
|
19051
19180
|
const controlProvider = await getControlProvider(this.controlModel);
|
|
@@ -19163,7 +19292,7 @@ import { isArray as isArray10 } from "lodash-es";
|
|
|
19163
19292
|
import {
|
|
19164
19293
|
awaitTimeout,
|
|
19165
19294
|
mergeInLeft,
|
|
19166
|
-
RuntimeError as
|
|
19295
|
+
RuntimeError as RuntimeError48,
|
|
19167
19296
|
mergeDefaultInLeft as mergeDefaultInLeft2
|
|
19168
19297
|
} from "@ibiz-template/core";
|
|
19169
19298
|
import { debounce as debounce2 } from "lodash-es";
|
|
@@ -19609,7 +19738,7 @@ var EditFormController = class extends FormController {
|
|
|
19609
19738
|
}
|
|
19610
19739
|
const isValid = await this.validate();
|
|
19611
19740
|
if (!isValid) {
|
|
19612
|
-
throw new
|
|
19741
|
+
throw new RuntimeError48("\u8BF7\u68C0\u67E5\u8868\u5355\u586B\u5199\uFF01");
|
|
19613
19742
|
}
|
|
19614
19743
|
if (!silent) {
|
|
19615
19744
|
await this.startLoading();
|
|
@@ -19735,7 +19864,7 @@ var EditFormController = class extends FormController {
|
|
|
19735
19864
|
(item) => item.id === formItemUpdateId
|
|
19736
19865
|
);
|
|
19737
19866
|
if (!formItemUpdate) {
|
|
19738
|
-
throw new
|
|
19867
|
+
throw new RuntimeError48("\u6CA1\u627E\u5230".concat(formItemUpdateId, "\u8868\u5355\u9879\u66F4\u65B0"));
|
|
19739
19868
|
}
|
|
19740
19869
|
const { appDEMethodId, defiupdateDetails, customCode, scriptCode } = formItemUpdate;
|
|
19741
19870
|
const updateItems = defiupdateDetails == null ? void 0 : defiupdateDetails.map((item) => item.id);
|
|
@@ -19779,7 +19908,7 @@ var EditFormController = class extends FormController {
|
|
|
19779
19908
|
async wfStart(args) {
|
|
19780
19909
|
const isValid = await this.validate();
|
|
19781
19910
|
if (!isValid) {
|
|
19782
|
-
throw new
|
|
19911
|
+
throw new RuntimeError48("\u8BF7\u68C0\u67E5\u8868\u5355\u586B\u5199\uFF01");
|
|
19783
19912
|
}
|
|
19784
19913
|
await this.startLoading();
|
|
19785
19914
|
const { context, params } = this.handlerAbilityParams(args);
|
|
@@ -19810,7 +19939,7 @@ var EditFormController = class extends FormController {
|
|
|
19810
19939
|
async wfSubmit(args) {
|
|
19811
19940
|
const isValid = await this.validate();
|
|
19812
19941
|
if (!isValid) {
|
|
19813
|
-
throw new
|
|
19942
|
+
throw new RuntimeError48("\u8BF7\u68C0\u67E5\u8868\u5355\u586B\u5199\uFF01");
|
|
19814
19943
|
}
|
|
19815
19944
|
await this.startLoading();
|
|
19816
19945
|
const { context, params } = this.handlerAbilityParams(args);
|
|
@@ -20042,7 +20171,7 @@ var FormMDCtrlFormController = class extends FormMDCtrlControlController {
|
|
|
20042
20171
|
};
|
|
20043
20172
|
|
|
20044
20173
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-grid/form-mdctrl-grid.controller.ts
|
|
20045
|
-
import { RuntimeError as
|
|
20174
|
+
import { RuntimeError as RuntimeError49, mergeInLeft as mergeInLeft3 } from "@ibiz-template/core";
|
|
20046
20175
|
var FormMDCtrlGridController = class extends FormMDCtrlControlController {
|
|
20047
20176
|
constructor() {
|
|
20048
20177
|
super(...arguments);
|
|
@@ -20154,7 +20283,7 @@ var FormMDCtrlGridController = class extends FormMDCtrlControlController {
|
|
|
20154
20283
|
const { model } = this.parent;
|
|
20155
20284
|
const { contentControl } = model;
|
|
20156
20285
|
if (!contentControl) {
|
|
20157
|
-
throw new
|
|
20286
|
+
throw new RuntimeError49("\u8868\u5355\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5D4C\u5165\u90E8\u4EF6");
|
|
20158
20287
|
}
|
|
20159
20288
|
mergeInLeft3(contentControl, { enableRowEdit: true, enableRowNew: true });
|
|
20160
20289
|
this.controlModel = contentControl;
|
|
@@ -20948,7 +21077,7 @@ import {
|
|
|
20948
21077
|
debounceAndAsyncMerge as debounceAndAsyncMerge2,
|
|
20949
21078
|
mergeDefaultInLeft as mergeDefaultInLeft3,
|
|
20950
21079
|
recursiveIterate as recursiveIterate5,
|
|
20951
|
-
RuntimeError as
|
|
21080
|
+
RuntimeError as RuntimeError50,
|
|
20952
21081
|
RuntimeModelError as RuntimeModelError54
|
|
20953
21082
|
} from "@ibiz-template/core";
|
|
20954
21083
|
import { clone as clone22 } from "ramda";
|
|
@@ -21332,7 +21461,7 @@ var GridController = class extends MDControlController {
|
|
|
21332
21461
|
if (editShowMode === "row") {
|
|
21333
21462
|
const editingRow = this.state.rows.find((item) => item.showRowEdit);
|
|
21334
21463
|
if (editingRow) {
|
|
21335
|
-
throw new
|
|
21464
|
+
throw new RuntimeError50("\u8BF7\u5148\u5B8C\u6210\u5F53\u524D\u884C\u7F16\u8F91\u4E2D\u7684\u884C\u7684\u64CD\u4F5C");
|
|
21336
21465
|
}
|
|
21337
21466
|
}
|
|
21338
21467
|
const queryParams = { ...this.params };
|
|
@@ -21373,7 +21502,7 @@ var GridController = class extends MDControlController {
|
|
|
21373
21502
|
const isCreate = data.srfuf === 0 /* CREATE */;
|
|
21374
21503
|
const rowState = this.findRowState(data);
|
|
21375
21504
|
if (!rowState) {
|
|
21376
|
-
throw new
|
|
21505
|
+
throw new RuntimeError50("\u884C\u6570\u636E\u4E0D\u5B58\u5728");
|
|
21377
21506
|
}
|
|
21378
21507
|
if (!rowState.modified) {
|
|
21379
21508
|
ibiz.log.debug("\u503C\u6CA1\u6709\u53D1\u751F\u6539\u53D8");
|
|
@@ -21385,7 +21514,7 @@ var GridController = class extends MDControlController {
|
|
|
21385
21514
|
}
|
|
21386
21515
|
const isValid = await this.validate(rowState);
|
|
21387
21516
|
if (!isValid) {
|
|
21388
|
-
throw new
|
|
21517
|
+
throw new RuntimeError50("\u884C\u6570\u636E\u6821\u9A8C\u4E0D\u901A\u8FC7\uFF0C\u4FDD\u5B58\u53D6\u6D88");
|
|
21389
21518
|
}
|
|
21390
21519
|
let res;
|
|
21391
21520
|
const deName = calcDeCodeNameById(this.model.appDataEntityId);
|
|
@@ -21582,7 +21711,7 @@ var GridController = class extends MDControlController {
|
|
|
21582
21711
|
}
|
|
21583
21712
|
async toggleRowEdit() {
|
|
21584
21713
|
if (!this.model.enableRowNew) {
|
|
21585
|
-
throw new
|
|
21714
|
+
throw new RuntimeError50("\u5F53\u524D\u8868\u683C\u4E0D\u652F\u6301\u884C\u7F16\u8F91\uFF0C\u65E0\u6CD5\u5207\u6362\u5F00\u542F\u884C\u7F16\u8F91");
|
|
21586
21715
|
}
|
|
21587
21716
|
this.state.rowEditOpen = !this.state.rowEditOpen;
|
|
21588
21717
|
}
|
|
@@ -21615,7 +21744,7 @@ var GridController = class extends MDControlController {
|
|
|
21615
21744
|
} else {
|
|
21616
21745
|
const editingRow = this.state.rows.find((item) => item.showRowEdit);
|
|
21617
21746
|
if (editingRow) {
|
|
21618
|
-
throw new
|
|
21747
|
+
throw new RuntimeError50("\u540C\u65F6\u53EA\u80FD\u6709\u4E00\u884C\u5F00\u542F\u884C\u7F16\u8F91");
|
|
21619
21748
|
}
|
|
21620
21749
|
if (row.data.srfuf === 1 /* UPDATE */) {
|
|
21621
21750
|
row.cacheData = clone22(row.data);
|
|
@@ -21665,7 +21794,7 @@ var GridController = class extends MDControlController {
|
|
|
21665
21794
|
(item) => item.id === updateId
|
|
21666
21795
|
);
|
|
21667
21796
|
if (!findUpdate) {
|
|
21668
|
-
throw new
|
|
21797
|
+
throw new RuntimeError50("\u6CA1\u627E\u5230".concat(updateId, "\u7F16\u8F91\u5217\u66F4\u65B0"));
|
|
21669
21798
|
}
|
|
21670
21799
|
const { appDEMethodId, degeiupdateDetails, customCode, scriptCode } = findUpdate;
|
|
21671
21800
|
const updateItems = degeiupdateDetails.map((item) => item.id);
|
|
@@ -21820,7 +21949,7 @@ var GridController = class extends MDControlController {
|
|
|
21820
21949
|
data2 = this.getData();
|
|
21821
21950
|
}
|
|
21822
21951
|
if (data2.length === 0) {
|
|
21823
|
-
throw new
|
|
21952
|
+
throw new RuntimeError50("\u65E0\u5BFC\u51FA\u6570\u636E");
|
|
21824
21953
|
}
|
|
21825
21954
|
return formatExcelData(data2);
|
|
21826
21955
|
};
|
|
@@ -22212,7 +22341,7 @@ var GridUAColumnController = class extends GridColumnController {
|
|
|
22212
22341
|
};
|
|
22213
22342
|
|
|
22214
22343
|
// src/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.ts
|
|
22215
|
-
import { RuntimeError as
|
|
22344
|
+
import { RuntimeError as RuntimeError51 } from "@ibiz-template/core";
|
|
22216
22345
|
import Schema2 from "async-validator";
|
|
22217
22346
|
import { isNilOrEmpty as isNilOrEmpty9 } from "qx-util";
|
|
22218
22347
|
var GridFieldEditColumnController = class extends GridFieldColumnController {
|
|
@@ -22349,7 +22478,7 @@ var GridFieldEditColumnController = class extends GridFieldColumnController {
|
|
|
22349
22478
|
if (requiredChanged || names.includes(this.fieldName) || names.includes(this.valueItemName)) {
|
|
22350
22479
|
const result = await this.validate(row);
|
|
22351
22480
|
if (!result) {
|
|
22352
|
-
throw new
|
|
22481
|
+
throw new RuntimeError51(
|
|
22353
22482
|
"".concat(this.editItem.codeName, "\u6821\u9A8C\u62A5\u9519,").concat(row.errors[this.fieldName])
|
|
22354
22483
|
);
|
|
22355
22484
|
}
|
|
@@ -22707,7 +22836,7 @@ var ListController = class extends MDControlController {
|
|
|
22707
22836
|
};
|
|
22708
22837
|
|
|
22709
22838
|
// src/controller/control/panel/panel/panel.controller.ts
|
|
22710
|
-
import { recursiveIterate as recursiveIterate6, RuntimeError as
|
|
22839
|
+
import { recursiveIterate as recursiveIterate6, RuntimeError as RuntimeError52 } from "@ibiz-template/core";
|
|
22711
22840
|
var PanelController = class extends ControlController {
|
|
22712
22841
|
constructor(model, context, params, ctx, container) {
|
|
22713
22842
|
super(model, context, params, ctx);
|
|
@@ -22831,7 +22960,7 @@ var PanelController = class extends ControlController {
|
|
|
22831
22960
|
var _a, _b;
|
|
22832
22961
|
const data = await this.prepareData();
|
|
22833
22962
|
if (!data) {
|
|
22834
|
-
throw new
|
|
22963
|
+
throw new RuntimeError52("\u672A\u83B7\u53D6\u5230\u9762\u677F\u6570\u636E");
|
|
22835
22964
|
}
|
|
22836
22965
|
const panelData = this.convertData(data);
|
|
22837
22966
|
(_b = (_a = this.data).destroy) == null ? void 0 : _b.call(_a);
|
|
@@ -24488,7 +24617,7 @@ var TreeController = class extends MDControlController {
|
|
|
24488
24617
|
};
|
|
24489
24618
|
|
|
24490
24619
|
// src/controller/control/wizard-panel/wizard-panel.controller.ts
|
|
24491
|
-
import { RuntimeError as
|
|
24620
|
+
import { RuntimeError as RuntimeError53 } from "@ibiz-template/core";
|
|
24492
24621
|
|
|
24493
24622
|
// src/controller/control/wizard-panel/wizard-panel.service.ts
|
|
24494
24623
|
var WizardPanelService = class extends ControlService {
|
|
@@ -24647,7 +24776,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24647
24776
|
const { activeFormTag } = this.state;
|
|
24648
24777
|
const controller = this.formControllers.get(activeFormTag);
|
|
24649
24778
|
if (!controller) {
|
|
24650
|
-
throw new
|
|
24779
|
+
throw new RuntimeError53("\u627E\u4E0D\u5230".concat(activeFormTag, "\u7684\u8868\u5355\u63A7\u5236\u5668"));
|
|
24651
24780
|
}
|
|
24652
24781
|
return controller;
|
|
24653
24782
|
}
|
|
@@ -24687,7 +24816,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24687
24816
|
getWizardFormByTag(tag) {
|
|
24688
24817
|
var _a;
|
|
24689
24818
|
if (!((_a = this.model.dewizard) == null ? void 0 : _a.dewizardForms)) {
|
|
24690
|
-
throw new
|
|
24819
|
+
throw new RuntimeError53("\u6CA1\u6709\u914D\u7F6E\u5411\u5BFC\u8868\u5355\u96C6\u5408");
|
|
24691
24820
|
return;
|
|
24692
24821
|
}
|
|
24693
24822
|
const wizardForm = this.model.dewizard.dewizardForms.find(
|
|
@@ -24696,7 +24825,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24696
24825
|
}
|
|
24697
24826
|
);
|
|
24698
24827
|
if (!wizardForm) {
|
|
24699
|
-
throw new
|
|
24828
|
+
throw new RuntimeError53("\u627E\u4E0D\u5230\u6807\u8BC6\u4E3A".concat(tag, "\u7684\u5411\u5BFC\u8868\u5355"));
|
|
24700
24829
|
}
|
|
24701
24830
|
return wizardForm;
|
|
24702
24831
|
}
|
|
@@ -24763,7 +24892,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24763
24892
|
this.tagHistory.pop();
|
|
24764
24893
|
}
|
|
24765
24894
|
if (!prevTag) {
|
|
24766
|
-
throw new
|
|
24895
|
+
throw new RuntimeError53("\u6CA1\u6709\u4E0A\u4E00\u4E2A\u8868\u5355");
|
|
24767
24896
|
}
|
|
24768
24897
|
this.state.activeFormTag = prevTag;
|
|
24769
24898
|
}
|
|
@@ -24799,7 +24928,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24799
24928
|
});
|
|
24800
24929
|
const nextWizardStep = wizardSteps[index + 1];
|
|
24801
24930
|
if (!nextWizardStep) {
|
|
24802
|
-
throw new
|
|
24931
|
+
throw new RuntimeError53("\u627E\u4E0D\u5230\u4E0B\u4E00\u4E2A\u5411\u5BFC\u6B65\u9AA4");
|
|
24803
24932
|
}
|
|
24804
24933
|
const nextWizardForm = this.getWizardFormByTag(nextWizardStep.stepTag);
|
|
24805
24934
|
if (nextWizardForm && nextWizardForm.formTag) {
|
|
@@ -24808,7 +24937,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
24808
24937
|
}
|
|
24809
24938
|
}
|
|
24810
24939
|
if (!nextTag) {
|
|
24811
|
-
throw new
|
|
24940
|
+
throw new RuntimeError53("\u627E\u4E0D\u5230\u4E0B\u4E00\u4E2A\u5411\u5BFC\u8868\u5355");
|
|
24812
24941
|
}
|
|
24813
24942
|
this.state.activeFormTag = nextTag;
|
|
24814
24943
|
this.tagHistory.push(nextTag);
|
|
@@ -25147,7 +25276,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
25147
25276
|
};
|
|
25148
25277
|
|
|
25149
25278
|
// src/controller/control/kanban/kanban.controller.ts
|
|
25150
|
-
import { RuntimeError as
|
|
25279
|
+
import { RuntimeError as RuntimeError54, RuntimeModelError as RuntimeModelError58 } from "@ibiz-template/core";
|
|
25151
25280
|
import { isNil as isNil25 } from "ramda";
|
|
25152
25281
|
|
|
25153
25282
|
// src/controller/control/kanban/kanban.service.ts
|
|
@@ -25235,7 +25364,7 @@ var KanbanController = class extends DataViewControlController {
|
|
|
25235
25364
|
} else {
|
|
25236
25365
|
const toNum = Number(sortValue);
|
|
25237
25366
|
if (Number.isNaN(toNum)) {
|
|
25238
|
-
throw new
|
|
25367
|
+
throw new RuntimeError54(
|
|
25239
25368
|
"".concat(item.srfmajortext, "\u7684\u6392\u5E8F\u5C5E\u6027\u65E0\u6CD5\u8F6C\u6362\u6210\u6570\u503C")
|
|
25240
25369
|
);
|
|
25241
25370
|
}
|
|
@@ -25251,7 +25380,7 @@ var KanbanController = class extends DataViewControlController {
|
|
|
25251
25380
|
}
|
|
25252
25381
|
handleDataGroup() {
|
|
25253
25382
|
if (!this.model.enableGroup || this.model.groupMode === "NONE") {
|
|
25254
|
-
throw new
|
|
25383
|
+
throw new RuntimeError54("\u770B\u677F\u90E8\u4EF6\u5FC5\u987B\u5F00\u542F\u5206\u7EC4");
|
|
25255
25384
|
}
|
|
25256
25385
|
return super.handleDataGroup();
|
|
25257
25386
|
}
|
|
@@ -25745,7 +25874,7 @@ var TreeGridService = class extends GridService {
|
|
|
25745
25874
|
};
|
|
25746
25875
|
|
|
25747
25876
|
// src/controller/control/medit-view-panel/medit-view-panel.controller.ts
|
|
25748
|
-
import { RuntimeError as
|
|
25877
|
+
import { RuntimeError as RuntimeError55 } from "@ibiz-template/core";
|
|
25749
25878
|
import { createUUID as createUUID10 } from "qx-util";
|
|
25750
25879
|
|
|
25751
25880
|
// src/controller/control/medit-view-panel/medit-view-panel.service.ts
|
|
@@ -25960,7 +26089,7 @@ var MEditViewPanelController = class extends MDControlController {
|
|
|
25960
26089
|
(item) => item.id === id
|
|
25961
26090
|
);
|
|
25962
26091
|
if (panelUiItemIndex < 0) {
|
|
25963
|
-
throw new
|
|
26092
|
+
throw new RuntimeError55("\u7F16\u8F91\u89C6\u56FE\u9762\u677F\u90E8\u4EF6UI\u6570\u636E\u4E0D\u5B58\u5728");
|
|
25964
26093
|
}
|
|
25965
26094
|
const tempUiItem = this.state.panelUiItems[panelUiItemIndex];
|
|
25966
26095
|
if (tempUiItem.id.startsWith("mockId:")) {
|
|
@@ -26375,7 +26504,7 @@ var AppHub = class {
|
|
|
26375
26504
|
this.registerAppView(appView);
|
|
26376
26505
|
return appView;
|
|
26377
26506
|
}
|
|
26378
|
-
throw new
|
|
26507
|
+
throw new RuntimeError56("\u89C6\u56FE[".concat(id, "]\u4E0D\u5B58\u5728"));
|
|
26379
26508
|
}
|
|
26380
26509
|
/**
|
|
26381
26510
|
* 根据应用实体代码名称查找应用视图
|
|
@@ -26406,7 +26535,7 @@ var AppHub = class {
|
|
|
26406
26535
|
this.registerAppDataEntity(entity, appId);
|
|
26407
26536
|
return entity;
|
|
26408
26537
|
}
|
|
26409
|
-
throw new
|
|
26538
|
+
throw new RuntimeError56("\u672A\u627E\u5230\u5E94\u7528\u5B9E\u4F53[".concat(id, "]"));
|
|
26410
26539
|
}
|
|
26411
26540
|
/**
|
|
26412
26541
|
* 新建 hub 应用
|
|
@@ -26427,7 +26556,7 @@ var AppHub = class {
|
|
|
26427
26556
|
appModel = await this.modelLoaderProvider.getApp(id);
|
|
26428
26557
|
this.registerApp(appModel);
|
|
26429
26558
|
} else {
|
|
26430
|
-
throw new
|
|
26559
|
+
throw new RuntimeError56("\u672A\u627E\u5230\u5E94\u7528[".concat(id, "]\u6A21\u578B"));
|
|
26431
26560
|
}
|
|
26432
26561
|
const app = new Application(appModel);
|
|
26433
26562
|
this.appMap.set(id, app);
|
|
@@ -26525,7 +26654,7 @@ var EngineFactory = class {
|
|
|
26525
26654
|
};
|
|
26526
26655
|
|
|
26527
26656
|
// src/engine/view-base.engine.ts
|
|
26528
|
-
import { RuntimeError as
|
|
26657
|
+
import { RuntimeError as RuntimeError57 } from "@ibiz-template/core";
|
|
26529
26658
|
var ViewEngineBase = class {
|
|
26530
26659
|
/**
|
|
26531
26660
|
* 构造函数在视图控制器的构造函数逻辑内部执行
|
|
@@ -26713,7 +26842,7 @@ var ViewEngineBase = class {
|
|
|
26713
26842
|
const { appDataEntityId } = this.view.model;
|
|
26714
26843
|
const { evt, context, params } = this.view;
|
|
26715
26844
|
if (!appDataEntityId) {
|
|
26716
|
-
throw new
|
|
26845
|
+
throw new RuntimeError57("\u8BE5\u89C6\u56FE\u6CA1\u6709\u5B9E\u4F53\uFF0C\u65E0\u6CD5\u52A0\u8F7D\u5B9E\u4F53\u6570\u636E");
|
|
26717
26846
|
}
|
|
26718
26847
|
const app = ibiz.hub.getApp(context.srfappid);
|
|
26719
26848
|
const res = await app.deService.exec(
|
|
@@ -27078,7 +27207,7 @@ import {
|
|
|
27078
27207
|
ModelError as ModelError28,
|
|
27079
27208
|
HttpError as HttpError4,
|
|
27080
27209
|
NoticeError as NoticeError2,
|
|
27081
|
-
RuntimeError as
|
|
27210
|
+
RuntimeError as RuntimeError58
|
|
27082
27211
|
} from "@ibiz-template/core";
|
|
27083
27212
|
var DefaultErrorHandler = class {
|
|
27084
27213
|
handle(error) {
|
|
@@ -27096,7 +27225,7 @@ var DefaultErrorHandler = class {
|
|
|
27096
27225
|
}
|
|
27097
27226
|
} else if (error instanceof NoticeError2) {
|
|
27098
27227
|
ibiz.message.error(error.message, error.duration, error.duration === 0);
|
|
27099
|
-
} else if (error instanceof
|
|
27228
|
+
} else if (error instanceof RuntimeError58) {
|
|
27100
27229
|
ibiz.message.error(error.message, 10, true);
|
|
27101
27230
|
}
|
|
27102
27231
|
ibiz.log.error(error);
|
|
@@ -27224,7 +27353,7 @@ var GlobalUtil = class {
|
|
|
27224
27353
|
};
|
|
27225
27354
|
|
|
27226
27355
|
// src/logic-scheduler/executor/logic-executor.ts
|
|
27227
|
-
import { RuntimeError as
|
|
27356
|
+
import { RuntimeError as RuntimeError59 } from "@ibiz-template/core";
|
|
27228
27357
|
var LogicExecutor = class {
|
|
27229
27358
|
/**
|
|
27230
27359
|
* @author lxm
|
|
@@ -27245,7 +27374,7 @@ var LogicExecutor = class {
|
|
|
27245
27374
|
*/
|
|
27246
27375
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
27247
27376
|
execute(_executeParams) {
|
|
27248
|
-
throw new
|
|
27377
|
+
throw new RuntimeError59("Method not implemented.");
|
|
27249
27378
|
}
|
|
27250
27379
|
/**
|
|
27251
27380
|
* 销毁方法
|
|
@@ -27682,7 +27811,7 @@ var LogicSchedulerCenter = class {
|
|
|
27682
27811
|
};
|
|
27683
27812
|
|
|
27684
27813
|
// src/logic-scheduler/trigger/logic-trigger.ts
|
|
27685
|
-
import { RuntimeError as
|
|
27814
|
+
import { RuntimeError as RuntimeError60 } from "@ibiz-template/core";
|
|
27686
27815
|
var LogicTrigger = class {
|
|
27687
27816
|
/**
|
|
27688
27817
|
* @author lxm
|
|
@@ -27742,7 +27871,7 @@ var LogicTrigger = class {
|
|
|
27742
27871
|
if (this.executor) {
|
|
27743
27872
|
return this.executor.execute(executeParams);
|
|
27744
27873
|
}
|
|
27745
|
-
throw new
|
|
27874
|
+
throw new RuntimeError60("".concat(this.logic.id, "\u6CA1\u6709\u7ED1\u5B9Aexecutor"));
|
|
27746
27875
|
}
|
|
27747
27876
|
/**
|
|
27748
27877
|
* 销毁方法
|
|
@@ -27759,12 +27888,12 @@ var CustomTrigger = class extends LogicTrigger {
|
|
|
27759
27888
|
};
|
|
27760
27889
|
|
|
27761
27890
|
// src/logic-scheduler/trigger/item-dyna-logic-trigger.ts
|
|
27762
|
-
import { RuntimeError as
|
|
27891
|
+
import { RuntimeError as RuntimeError61 } from "@ibiz-template/core";
|
|
27763
27892
|
var ItemDynaLogicTrigger = class extends LogicTrigger {
|
|
27764
27893
|
bindExecutor(executor) {
|
|
27765
27894
|
super.bindExecutor(executor);
|
|
27766
27895
|
if (this.executor.type !== "SCRIPT") {
|
|
27767
|
-
throw new
|
|
27896
|
+
throw new RuntimeError61(
|
|
27768
27897
|
"\u9884\u5B9A\u4E49\u903B\u8F91\u7C7B\u578B".concat(this.type, "\u7684\u89E6\u53D1\u5668\u7C7B\u578B\u53EA\u80FD\u662F\u811A\u672C")
|
|
27769
27898
|
);
|
|
27770
27899
|
}
|
|
@@ -27800,7 +27929,7 @@ var ItemDynaLogicTrigger = class extends LogicTrigger {
|
|
|
27800
27929
|
};
|
|
27801
27930
|
|
|
27802
27931
|
// src/logic-scheduler/trigger/timer-trigger.ts
|
|
27803
|
-
import { RuntimeError as
|
|
27932
|
+
import { RuntimeError as RuntimeError62, RuntimeModelError as RuntimeModelError62 } from "@ibiz-template/core";
|
|
27804
27933
|
var TimerTrigger = class extends LogicTrigger {
|
|
27805
27934
|
constructor() {
|
|
27806
27935
|
super(...arguments);
|
|
@@ -27812,7 +27941,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
27812
27941
|
}
|
|
27813
27942
|
this.timer = setInterval(() => {
|
|
27814
27943
|
if (!this.scheduler.defaultParamsCb) {
|
|
27815
|
-
throw new
|
|
27944
|
+
throw new RuntimeError62("\u5B9A\u65F6\u5668\u7F3A\u5C11\u9ED8\u8BA4\u53C2\u6570\u56DE\u8C03");
|
|
27816
27945
|
}
|
|
27817
27946
|
const params = this.scheduler.defaultParamsCb();
|
|
27818
27947
|
this.executor.execute(params);
|
|
@@ -27829,7 +27958,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
27829
27958
|
// src/logic-scheduler/executor/app-ui-logic-executor.ts
|
|
27830
27959
|
import {
|
|
27831
27960
|
ModelError as ModelError31,
|
|
27832
|
-
RuntimeError as
|
|
27961
|
+
RuntimeError as RuntimeError63,
|
|
27833
27962
|
RuntimeModelError as RuntimeModelError63
|
|
27834
27963
|
} from "@ibiz-template/core";
|
|
27835
27964
|
import { notNilEmpty as notNilEmpty9 } from "qx-util";
|
|
@@ -27862,7 +27991,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
27862
27991
|
const { context, params, ...rest } = parameters;
|
|
27863
27992
|
const { data } = parameters;
|
|
27864
27993
|
if (!(data == null ? void 0 : data[0])) {
|
|
27865
|
-
throw new
|
|
27994
|
+
throw new RuntimeError63("opendata\u6CA1\u6709\u53EF\u64CD\u4F5C\u6570\u636E\uFF01");
|
|
27866
27995
|
}
|
|
27867
27996
|
const openViewRefs = appUILogic.openDataAppViews;
|
|
27868
27997
|
let openViewRef;
|
|
@@ -27921,7 +28050,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
27921
28050
|
const openViewRefs = appUILogic.openDataAppViews;
|
|
27922
28051
|
const findView = openViewRefs == null ? void 0 : openViewRefs.find((item) => item.refMode === formTypeValue);
|
|
27923
28052
|
if (!findView) {
|
|
27924
|
-
throw new
|
|
28053
|
+
throw new RuntimeError63(
|
|
27925
28054
|
"\u6CA1\u6709\u627E\u5230\u4E0E\u8868\u5355\u7C7B\u578B".concat(formTypeValue, "\u76F8\u5173\u7684\u5B9E\u4F53\u7684\u7F16\u8F91\u89C6\u56FE")
|
|
27926
28055
|
);
|
|
27927
28056
|
}
|
|
@@ -28039,12 +28168,12 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28039
28168
|
}
|
|
28040
28169
|
const selectData = (_a = result.data) == null ? void 0 : _a[0];
|
|
28041
28170
|
if (!selectData) {
|
|
28042
|
-
throw new
|
|
28171
|
+
throw new RuntimeError63("\u8BF7\u9009\u4E2D\u4E00\u6761\u6570\u636E");
|
|
28043
28172
|
}
|
|
28044
28173
|
const indexType = selectData.srfkey;
|
|
28045
28174
|
const findView = newDataAppViews == null ? void 0 : newDataAppViews.find((item) => item.refMode === indexType);
|
|
28046
28175
|
if (!findView) {
|
|
28047
|
-
throw new
|
|
28176
|
+
throw new RuntimeError63(
|
|
28048
28177
|
"\u6CA1\u6709\u627E\u5230\u4E0E\u7D22\u5F15\u7C7B\u578B".concat(indexType, "\u76F8\u5173\u7684\u5B9E\u4F53\u7684\u7F16\u8F91\u89C6\u56FE")
|
|
28049
28178
|
);
|
|
28050
28179
|
}
|
|
@@ -28238,7 +28367,7 @@ function installLogicSchedule() {
|
|
|
28238
28367
|
}
|
|
28239
28368
|
|
|
28240
28369
|
// src/install.ts
|
|
28241
|
-
function
|
|
28370
|
+
function install2() {
|
|
28242
28371
|
const { ibiz: ibiz2 } = window;
|
|
28243
28372
|
ibiz2.util = new GlobalUtil();
|
|
28244
28373
|
ibiz2.hub = new AppHub();
|
|
@@ -28251,6 +28380,8 @@ function install() {
|
|
|
28251
28380
|
presetUIActionProvider();
|
|
28252
28381
|
presetAppCounterProvider();
|
|
28253
28382
|
installLogicSchedule();
|
|
28383
|
+
install();
|
|
28384
|
+
ibiz2.platform = getPlatformProvider();
|
|
28254
28385
|
}
|
|
28255
28386
|
|
|
28256
28387
|
// src/plugin/plugin-static-resource/plugin-static-resource.ts
|
|
@@ -28355,6 +28486,7 @@ export {
|
|
|
28355
28486
|
AuthorityService,
|
|
28356
28487
|
BackendUIActionProvider,
|
|
28357
28488
|
BaseController,
|
|
28489
|
+
BrowserPlatformProvider,
|
|
28358
28490
|
ButtonContainerState,
|
|
28359
28491
|
CONTROL_PROVIDER_PREFIX,
|
|
28360
28492
|
CTX,
|
|
@@ -28470,6 +28602,7 @@ export {
|
|
|
28470
28602
|
MqttService,
|
|
28471
28603
|
OpenAppViewCommand,
|
|
28472
28604
|
PANELITEM_PROVIDER_PREFIX,
|
|
28605
|
+
PLATFORM_PROVIDER_PREFIX,
|
|
28473
28606
|
PORTLET_PROVIDER_PREFIX,
|
|
28474
28607
|
PSDEDQCondEngine,
|
|
28475
28608
|
PanelController,
|
|
@@ -28479,6 +28612,8 @@ export {
|
|
|
28479
28612
|
PanelItemState,
|
|
28480
28613
|
PanelNotifyState,
|
|
28481
28614
|
PickupViewPanelController,
|
|
28615
|
+
PlatformProviderBase,
|
|
28616
|
+
PlatformType,
|
|
28482
28617
|
PluginStaticResource,
|
|
28483
28618
|
PortletPartController,
|
|
28484
28619
|
PortletPartState,
|
|
@@ -28582,6 +28717,8 @@ export {
|
|
|
28582
28717
|
getOriginData,
|
|
28583
28718
|
getPFPlugin,
|
|
28584
28719
|
getPanelItemProvider,
|
|
28720
|
+
getPlatformProvider,
|
|
28721
|
+
getPlatformType,
|
|
28585
28722
|
getPortletProvider,
|
|
28586
28723
|
getRootNode,
|
|
28587
28724
|
getTreeNode,
|
|
@@ -28597,7 +28734,7 @@ export {
|
|
|
28597
28734
|
hasDeCodeName,
|
|
28598
28735
|
hasSubRoute,
|
|
28599
28736
|
importData,
|
|
28600
|
-
install,
|
|
28737
|
+
install2 as install,
|
|
28601
28738
|
installCommand,
|
|
28602
28739
|
isDataContainer,
|
|
28603
28740
|
isValueChange,
|
|
@@ -28613,6 +28750,7 @@ export {
|
|
|
28613
28750
|
registerFormDetailProvider,
|
|
28614
28751
|
registerGridColumnProvider,
|
|
28615
28752
|
registerPanelItemProvider,
|
|
28753
|
+
registerPlatformProvider,
|
|
28616
28754
|
registerPortletProvider,
|
|
28617
28755
|
registerUIActionProvider,
|
|
28618
28756
|
registerUILogicNodeProvider,
|