@ibiz-template/vue3-util 0.7.16-alpha.0 → 0.7.17-alpha.0
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.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/es/common/code-list/code-list.mjs +1 -1
- package/es/common/control-shell/control-shell.d.ts.map +1 -1
- package/es/common/control-shell/control-shell.mjs +1 -1
- package/es/common/view-shell/view-shell.d.ts +1 -0
- package/es/common/view-shell/view-shell.d.ts.map +1 -1
- package/es/common/view-shell/view-shell.mjs +55 -4
- package/es/control/panel/panel/panel.d.ts.map +1 -1
- package/es/control/panel/panel/panel.mjs +5 -2
- package/es/control/panel/view-layout-panel/view-layout-panel.d.ts.map +1 -1
- package/es/control/panel/view-layout-panel/view-layout-panel.mjs +5 -2
- package/es/index.d.ts +1 -0
- package/es/index.d.ts.map +1 -1
- package/es/index.mjs +3 -0
- package/es/locale/en/index.d.ts +62 -0
- package/es/locale/en/index.d.ts.map +1 -0
- package/es/locale/en/index.mjs +64 -0
- package/es/locale/index.d.ts +3 -0
- package/es/locale/index.d.ts.map +1 -0
- package/es/locale/index.mjs +4 -0
- package/es/locale/zh-CN/index.d.ts +62 -0
- package/es/locale/zh-CN/index.d.ts.map +1 -0
- package/es/locale/zh-CN/index.mjs +64 -0
- package/es/panel-component/multi-data-container/multi-data-container.controller.d.ts.map +1 -1
- package/es/panel-component/multi-data-container/multi-data-container.controller.mjs +45 -12
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.d.ts.map +1 -1
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.mjs +3 -1
- package/es/panel-component/panel-field/panel-field.controller.d.ts.map +1 -1
- package/es/panel-component/panel-field/panel-field.controller.mjs +3 -1
- package/es/panel-component/scroll-container/scroll-container/scroll-container.d.ts.map +1 -1
- package/es/panel-component/scroll-container/scroll-container/scroll-container.mjs +3 -1
- package/es/panel-component/single-data-container/single-data-container.controller.d.ts.map +1 -1
- package/es/panel-component/single-data-container/single-data-container.controller.mjs +44 -11
- package/es/panel-component/teleport-placeholder/teleport-placeholder.controller.d.ts.map +1 -1
- package/es/panel-component/teleport-placeholder/teleport-placeholder.controller.mjs +4 -1
- package/es/plugin/plugin-factory/plugin-factory.d.ts.map +1 -1
- package/es/plugin/plugin-factory/plugin-factory.mjs +12 -5
- package/es/use/control/use-control-controller/use-control-controller.d.ts.map +1 -1
- package/es/use/control/use-control-controller/use-control-controller.mjs +12 -2
- package/es/use/focus-blur/focus-blur.mjs +1 -1
- package/es/use/view/use-view-controller/use-view-controller.d.ts.map +1 -1
- package/es/use/view/use-view-controller/use-view-controller.mjs +12 -2
- package/es/util/overlay-container/overlay-container.mjs +1 -1
- package/es/util/render/render.mjs +1 -1
- package/es/util/route/route.d.ts.map +1 -1
- package/es/util/route/route.mjs +7 -3
- package/es/view/app-redirect-view/app-redirect-view.mjs +2 -2
- package/es/view/common/view.d.ts.map +1 -1
- package/es/view/common/view.mjs +7 -3
- package/es/view/de-redirect-view/de-redirect-view.d.ts.map +1 -1
- package/es/view/de-redirect-view/de-redirect-view.mjs +1 -1
- package/es/view/todo-redirect/todo-redirect.mjs +3 -3
- package/lib/common/code-list/code-list.cjs +1 -1
- package/lib/common/control-shell/control-shell.cjs +1 -1
- package/lib/common/view-shell/view-shell.cjs +54 -3
- package/lib/control/panel/panel/panel.cjs +4 -1
- package/lib/control/panel/view-layout-panel/view-layout-panel.cjs +4 -1
- package/lib/index.cjs +5 -0
- package/lib/locale/en/index.cjs +66 -0
- package/lib/locale/index.cjs +9 -0
- package/lib/locale/zh-CN/index.cjs +66 -0
- package/lib/panel-component/multi-data-container/multi-data-container.controller.cjs +45 -12
- package/lib/panel-component/panel-ctrl-pos/panel-ctrl-pos.cjs +3 -1
- package/lib/panel-component/panel-field/panel-field.controller.cjs +3 -1
- package/lib/panel-component/scroll-container/scroll-container/scroll-container.cjs +3 -1
- package/lib/panel-component/single-data-container/single-data-container.controller.cjs +44 -11
- package/lib/panel-component/teleport-placeholder/teleport-placeholder.controller.cjs +4 -1
- package/lib/plugin/plugin-factory/plugin-factory.cjs +12 -5
- package/lib/use/control/use-control-controller/use-control-controller.cjs +12 -2
- package/lib/use/focus-blur/focus-blur.cjs +1 -1
- package/lib/use/view/use-view-controller/use-view-controller.cjs +12 -2
- package/lib/util/overlay-container/overlay-container.cjs +1 -1
- package/lib/util/render/render.cjs +1 -1
- package/lib/util/route/route.cjs +7 -3
- package/lib/view/app-redirect-view/app-redirect-view.cjs +1 -1
- package/lib/view/common/view.cjs +6 -2
- package/lib/view/de-redirect-view/de-redirect-view.cjs +1 -1
- package/lib/view/todo-redirect/todo-redirect.cjs +2 -2
- package/package.json +3 -3
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
const en = {
|
|
5
|
+
vue3Util: {
|
|
6
|
+
common: {
|
|
7
|
+
undefined: "undefined",
|
|
8
|
+
onFoundCorrespondingPart: "Undefined adapter with no corresponding part found",
|
|
9
|
+
noFoundViewModel: "View model not found",
|
|
10
|
+
noSupportLoadingDynamic: "{codeName}No entity, do not support loading dynamic models at this time"
|
|
11
|
+
},
|
|
12
|
+
control: {
|
|
13
|
+
unsupportedPanel: "Unsupported panel items: {id} - {itemType}"
|
|
14
|
+
},
|
|
15
|
+
panelComponent: {
|
|
16
|
+
noConfiguardDataObject: "No data object name configured",
|
|
17
|
+
noSupportedDataSourceType: "The data source type {dataSourceType} is not supported yet.",
|
|
18
|
+
noConfiguredEntityLogic: "No entity logic configured",
|
|
19
|
+
noConfiguredEntity: "No entity configured",
|
|
20
|
+
noReturnValue: "The entity logic {appDELogicId} has no return value",
|
|
21
|
+
noAttribute: "There is no {dataName} attribute in the global variable.",
|
|
22
|
+
noConfiguerdEntityBehanior: "No entity behavior configured",
|
|
23
|
+
sessionView: "The session to which the view is bound does not exist {dataName}",
|
|
24
|
+
viewStateAttribute: "There is no {dataName} attribute in the view state",
|
|
25
|
+
noImplementMethod: "Method not implemented.",
|
|
26
|
+
noProvidedSlot: "No {id} slot provided",
|
|
27
|
+
cannotEmpty: "{caption} cannot be empty",
|
|
28
|
+
unadaptedLayout: "Unadapted layout placeholder {layoutPos}",
|
|
29
|
+
placeholderIdentifier: "The placeholder identifier for panel member {id} of view {viewCodeName} is:"
|
|
30
|
+
},
|
|
31
|
+
plugin: {
|
|
32
|
+
failureConfigurationLoad: "Configuration load failure",
|
|
33
|
+
failedRemotePluginLoad: "Remote Plugin failed to load, Remote Plugin did not find [default] Default Export",
|
|
34
|
+
fileContentFormat: "Remote plugin failed to load, file not found or file content format is incorrect"
|
|
35
|
+
},
|
|
36
|
+
use: {
|
|
37
|
+
control: {
|
|
38
|
+
parameterChanges: "Context or view parameter changes for {id}:",
|
|
39
|
+
stateChange: "Part [{name}] state change"
|
|
40
|
+
},
|
|
41
|
+
focusBlur: {
|
|
42
|
+
noFocus: "No focus, no out-of-focus triggering"
|
|
43
|
+
},
|
|
44
|
+
view: {
|
|
45
|
+
stateChange: "View [{{name}] state change"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
util: {
|
|
49
|
+
noInjected: "The createVueApp method is not injected.",
|
|
50
|
+
convertString: "Failed to convert to string",
|
|
51
|
+
viewIdentifiers: "View identifiers do not exist for {depth} level routes",
|
|
52
|
+
noFoundView: "View not found {viewCodeName}",
|
|
53
|
+
routeCorrectly: "Cannot get the route correctly, could be a dependency issue."
|
|
54
|
+
},
|
|
55
|
+
view: {
|
|
56
|
+
redirectionProgress: "Redirection in progress",
|
|
57
|
+
viewType: "View type {viewType} is not supported yet.",
|
|
58
|
+
noTeleportTag: "No teleportTag was found for part {name}.",
|
|
59
|
+
embeddedRedirectionView: "Embedded redirection view does not support url jumping",
|
|
60
|
+
insufficientRedirection: "Insufficient redirection parameters to jump",
|
|
61
|
+
toDoList: "To-Do List Redirection"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
exports.en = en;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
const zhCn = {
|
|
5
|
+
vue3Util: {
|
|
6
|
+
common: {
|
|
7
|
+
undefined: "\u672A\u5B9A\u4E49",
|
|
8
|
+
onFoundCorrespondingPart: "\u672A\u5B9A\u4E49\u672A\u627E\u5230\u5BF9\u5E94\u90E8\u4EF6\u7684\u9002\u914D\u5668",
|
|
9
|
+
noFoundViewModel: "\u672A\u627E\u5230\u89C6\u56FE\u6A21\u578B",
|
|
10
|
+
noSupportLoadingDynamic: "{codeName}\u65E0\u5B9E\u4F53,\u6682\u4E0D\u652F\u6301\u52A0\u8F7D\u52A8\u6001\u6A21\u578B"
|
|
11
|
+
},
|
|
12
|
+
control: {
|
|
13
|
+
unsupportedPanel: "\u6682\u672A\u652F\u6301\u7684\u9762\u677F\u9879: {id} - {itemType}"
|
|
14
|
+
},
|
|
15
|
+
panelComponent: {
|
|
16
|
+
noConfiguardDataObject: "\u6CA1\u6709\u914D\u7F6E\u6570\u636E\u5BF9\u8C61\u540D\u79F0",
|
|
17
|
+
noSupportedDataSourceType: "\u6570\u636E\u6E90\u7C7B\u578B{dataSourceType}\u6682\u672A\u652F\u6301",
|
|
18
|
+
noConfiguredEntityLogic: "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u903B\u8F91",
|
|
19
|
+
noConfiguredEntity: "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53",
|
|
20
|
+
noReturnValue: "\u5B9E\u4F53\u903B\u8F91{appDELogicId}\u6CA1\u6709\u8FD4\u56DE\u503C",
|
|
21
|
+
noAttribute: "\u5168\u5C40\u53D8\u91CF\u91CC\u6CA1\u6709{dataName}\u5C5E\u6027",
|
|
22
|
+
noConfiguerdEntityBehanior: "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u884C\u4E3A",
|
|
23
|
+
sessionView: "\u7ED1\u5B9A\u89C6\u56FE\u7684\u4F1A\u8BDD\u4E0D\u5B58\u5728{dataName}",
|
|
24
|
+
viewStateAttribute: "\u89C6\u56FEstate\u91CC\u6CA1\u6709{dataName}\u5C5E\u6027",
|
|
25
|
+
noImplementMethod: "\u672A\u6267\u884C\u7684\u65B9\u6CD5",
|
|
26
|
+
noProvidedSlot: "\u672A\u63D0\u4F9B{id}\u63D2\u69FD",
|
|
27
|
+
cannotEmpty: "{caption} \u4E0D\u80FD\u4E3A\u7A7A",
|
|
28
|
+
unadaptedLayout: "\u672A\u9002\u914D\u7684\u5E03\u5C40\u5360\u4F4D{layoutPos}",
|
|
29
|
+
placeholderIdentifier: "\u89C6\u56FE{viewCodeName}\u7684\u9762\u677F\u6210\u5458{id}\u7684\u5360\u4F4D\u6807\u8BC6\u662F\uFF1A"
|
|
30
|
+
},
|
|
31
|
+
plugin: {
|
|
32
|
+
failureConfigurationLoad: "\u914D\u7F6E\u52A0\u8F7D\u5931\u8D25",
|
|
33
|
+
failedRemotePluginLoad: "\u8FDC\u7A0B\u63D2\u4EF6\u52A0\u8F7D\u5931\u8D25, \u8FDC\u7A0B\u63D2\u4EF6\u672A\u627E\u5230[default]\u9ED8\u8BA4\u5BFC\u51FA",
|
|
34
|
+
fileContentFormat: "\u8FDC\u7A0B\u63D2\u4EF6\u52A0\u8F7D\u5931\u8D25, \u672A\u627E\u5230\u6587\u4EF6\u6216\u6587\u4EF6\u5185\u5BB9\u683C\u5F0F\u4E0D\u6B63\u786E"
|
|
35
|
+
},
|
|
36
|
+
use: {
|
|
37
|
+
control: {
|
|
38
|
+
parameterChanges: "{id}\u7684\u4E0A\u4E0B\u6587\u6216\u89C6\u56FE\u53C2\u6570\u53D8\u66F4\uFF1A",
|
|
39
|
+
stateChange: "\u90E8\u4EF6 [{name}] state \u53D8\u66F4"
|
|
40
|
+
},
|
|
41
|
+
focusBlur: {
|
|
42
|
+
noFocus: "\u6CA1\u6709\u805A\u7126\uFF0C\u4E0D\u89E6\u53D1\u5931\u7126"
|
|
43
|
+
},
|
|
44
|
+
view: {
|
|
45
|
+
stateChange: "\u89C6\u56FE [{name}] state \u53D8\u66F4"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
util: {
|
|
49
|
+
noInjected: "\u6CA1\u6709\u6CE8\u5165createVueApp\u65B9\u6CD5",
|
|
50
|
+
convertString: "\u8F6C\u6362\u6210\u5B57\u7B26\u4E32\u5931\u8D25",
|
|
51
|
+
viewIdentifiers: "\u7B2C{depth}\u7EA7\u8DEF\u7531\u4E0D\u5B58\u5728\u89C6\u56FE\u6807\u8BC6",
|
|
52
|
+
noFoundView: "\u627E\u4E0D\u5230\u89C6\u56FE{viewCodeName}",
|
|
53
|
+
routeCorrectly: "\u65E0\u6CD5\u6B63\u786E\u83B7\u53D6route,\u53EF\u80FD\u662F\u4F9D\u8D56\u95EE\u9898"
|
|
54
|
+
},
|
|
55
|
+
view: {
|
|
56
|
+
redirectionProgress: "\u91CD\u5B9A\u5411\u8DF3\u8F6C\u4E2D",
|
|
57
|
+
viewType: "\u89C6\u56FE\u7C7B\u578B{viewType}\u6682\u672A\u652F\u6301",
|
|
58
|
+
noTeleportTag: "\u6CA1\u6709\u627E\u5230\u90E8\u4EF6{name}\u7684teleportTag",
|
|
59
|
+
embeddedRedirectionView: "\u5D4C\u5165\u91CD\u5B9A\u5411\u89C6\u56FE\u4E0D\u652F\u6301url\u8DF3\u8F6C",
|
|
60
|
+
insufficientRedirection: "\u91CD\u5B9A\u5411\u53C2\u6570\u4E0D\u8DB3\u65E0\u6CD5\u8DF3\u8F6C",
|
|
61
|
+
toDoList: "\u5F85\u529E\u5217\u8868\u91CD\u5B9A\u5411"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
exports.zhCn = zhCn;
|
|
@@ -103,20 +103,31 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
103
103
|
break;
|
|
104
104
|
case "TOPVIEWSESSIONPARAM": {
|
|
105
105
|
if (!dataName) {
|
|
106
|
-
throw new core.RuntimeModelError(
|
|
106
|
+
throw new core.RuntimeModelError(
|
|
107
|
+
this.model,
|
|
108
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguardDataObject")
|
|
109
|
+
);
|
|
107
110
|
}
|
|
108
111
|
this.bindViewData(this.panel.getTopView(), dataName);
|
|
109
112
|
break;
|
|
110
113
|
}
|
|
111
114
|
case "VIEWSESSIONPARAM": {
|
|
112
115
|
if (!dataName) {
|
|
113
|
-
throw new core.RuntimeModelError(
|
|
116
|
+
throw new core.RuntimeModelError(
|
|
117
|
+
this.model,
|
|
118
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguardDataObject")
|
|
119
|
+
);
|
|
114
120
|
}
|
|
115
121
|
this.bindViewData(this.panel.view, dataName);
|
|
116
122
|
break;
|
|
117
123
|
}
|
|
118
124
|
default:
|
|
119
|
-
throw new core.ModelError(
|
|
125
|
+
throw new core.ModelError(
|
|
126
|
+
this.model,
|
|
127
|
+
ibiz.i18n.t("vue3Util.panelComponent.noSupportedDataSourceType", {
|
|
128
|
+
dataSourceType
|
|
129
|
+
})
|
|
130
|
+
);
|
|
120
131
|
}
|
|
121
132
|
}
|
|
122
133
|
/**
|
|
@@ -179,10 +190,16 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
179
190
|
async setDataByDeLogic() {
|
|
180
191
|
const { appDataEntityId, appDELogicId } = this.model;
|
|
181
192
|
if (!appDELogicId) {
|
|
182
|
-
throw new core.RuntimeModelError(
|
|
193
|
+
throw new core.RuntimeModelError(
|
|
194
|
+
this.model,
|
|
195
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntityLogic")
|
|
196
|
+
);
|
|
183
197
|
}
|
|
184
198
|
if (!appDataEntityId) {
|
|
185
|
-
throw new core.RuntimeModelError(
|
|
199
|
+
throw new core.RuntimeModelError(
|
|
200
|
+
this.model,
|
|
201
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntity")
|
|
202
|
+
);
|
|
186
203
|
}
|
|
187
204
|
const data = await runtime.execDELogicById(
|
|
188
205
|
appDELogicId,
|
|
@@ -192,7 +209,9 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
192
209
|
this.panel.params
|
|
193
210
|
);
|
|
194
211
|
if (!data) {
|
|
195
|
-
throw new core.RuntimeError(
|
|
212
|
+
throw new core.RuntimeError(
|
|
213
|
+
ibiz.i18n.t("vue3Util.panelComponent.noReturnValue", { appDELogicId })
|
|
214
|
+
);
|
|
196
215
|
}
|
|
197
216
|
this.setData(data);
|
|
198
217
|
}
|
|
@@ -208,7 +227,9 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
208
227
|
if (originData) {
|
|
209
228
|
this.setData(originData);
|
|
210
229
|
} else {
|
|
211
|
-
ibiz.log.error(
|
|
230
|
+
ibiz.log.error(
|
|
231
|
+
ibiz.i18n.t("vue3Util.panelComponent.noAttribute", { dataName })
|
|
232
|
+
);
|
|
212
233
|
}
|
|
213
234
|
}
|
|
214
235
|
/**
|
|
@@ -221,10 +242,16 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
221
242
|
async setDataByDeMethod() {
|
|
222
243
|
const { appDEMethodId, appDataEntityId } = this.model;
|
|
223
244
|
if (!appDEMethodId) {
|
|
224
|
-
throw new core.RuntimeModelError(
|
|
245
|
+
throw new core.RuntimeModelError(
|
|
246
|
+
this.model,
|
|
247
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguerdEntityBehanior")
|
|
248
|
+
);
|
|
225
249
|
}
|
|
226
250
|
if (!appDataEntityId) {
|
|
227
|
-
throw new core.RuntimeModelError(
|
|
251
|
+
throw new core.RuntimeModelError(
|
|
252
|
+
this.model,
|
|
253
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntity")
|
|
254
|
+
);
|
|
228
255
|
}
|
|
229
256
|
const app = ibiz.hub.getApp(this.panel.context.srfappid);
|
|
230
257
|
const res = await app.deService.exec(
|
|
@@ -248,7 +275,9 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
248
275
|
*/
|
|
249
276
|
bindViewData(view, dataName) {
|
|
250
277
|
if (!Object.prototype.hasOwnProperty.call(view.state, dataName)) {
|
|
251
|
-
ibiz.log.error(
|
|
278
|
+
ibiz.log.error(
|
|
279
|
+
ibiz.i18n.t("vue3Util.panelComponent.sessionView", { dataName })
|
|
280
|
+
);
|
|
252
281
|
return;
|
|
253
282
|
}
|
|
254
283
|
const updateData = () => {
|
|
@@ -256,7 +285,11 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
256
285
|
if (originData) {
|
|
257
286
|
this.setData(originData);
|
|
258
287
|
} else {
|
|
259
|
-
ibiz.log.error(
|
|
288
|
+
ibiz.log.error(
|
|
289
|
+
ibiz.i18n.t("vue3Util.panelComponent.viewStateAttribute", {
|
|
290
|
+
dataName
|
|
291
|
+
})
|
|
292
|
+
);
|
|
260
293
|
}
|
|
261
294
|
};
|
|
262
295
|
updateData();
|
|
@@ -265,7 +298,7 @@ class MultiDataContainerController extends runtime.PanelItemController {
|
|
|
265
298
|
});
|
|
266
299
|
}
|
|
267
300
|
setDataValue(_name, _value) {
|
|
268
|
-
throw new Error("
|
|
301
|
+
throw new Error(ibiz.i18n.t("vue3Util.panelComponent.noImplementMethod"));
|
|
269
302
|
}
|
|
270
303
|
destroy() {
|
|
271
304
|
super.destroy();
|
|
@@ -40,7 +40,9 @@ const PanelCtrlPos = /* @__PURE__ */ vue.defineComponent({
|
|
|
40
40
|
}
|
|
41
41
|
return vue.createVNode("div", {
|
|
42
42
|
"class": [this.ns.b(), this.ns.m(this.modelData.id), ...this.controller.containerClass, this.ns.is("hidden", !state.visible)]
|
|
43
|
-
}, [content || (ibiz.env.dev ?
|
|
43
|
+
}, [content || (ibiz.env.dev ? ibiz.i18n.t("vue3Util.panelComponent.noProvidedSlot", {
|
|
44
|
+
id: this.modelData.id
|
|
45
|
+
}) : "")]);
|
|
44
46
|
}
|
|
45
47
|
});
|
|
46
48
|
|
|
@@ -59,7 +59,9 @@ class PanelFieldController extends runtime.PanelItemController {
|
|
|
59
59
|
async validate() {
|
|
60
60
|
var _a;
|
|
61
61
|
if (this.state.visible && !this.model.allowEmpty && !this.value) {
|
|
62
|
-
this.state.error = ((_a = this.editor) == null ? void 0 : _a.model.placeHolder) ||
|
|
62
|
+
this.state.error = ((_a = this.editor) == null ? void 0 : _a.model.placeHolder) || ibiz.i18n.t("vue3Util.panelComponent.cannotEmpty", {
|
|
63
|
+
caption: this.model.caption
|
|
64
|
+
});
|
|
63
65
|
return false;
|
|
64
66
|
}
|
|
65
67
|
this.state.error = null;
|
|
@@ -80,7 +80,9 @@ const ScrollContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
80
80
|
center = slot;
|
|
81
81
|
break;
|
|
82
82
|
default:
|
|
83
|
-
ibiz.log.debug(
|
|
83
|
+
ibiz.log.debug(ibiz.i18n.t("vue3Util.panelComponent.unadaptedLayout", {
|
|
84
|
+
layoutPos: props.modelData.layoutPos.layoutPos
|
|
85
|
+
}));
|
|
84
86
|
break;
|
|
85
87
|
}
|
|
86
88
|
});
|
|
@@ -116,20 +116,31 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
116
116
|
break;
|
|
117
117
|
case "TOPVIEWSESSIONPARAM": {
|
|
118
118
|
if (!dataName) {
|
|
119
|
-
throw new core.RuntimeModelError(
|
|
119
|
+
throw new core.RuntimeModelError(
|
|
120
|
+
this.model,
|
|
121
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguardDataObject")
|
|
122
|
+
);
|
|
120
123
|
}
|
|
121
124
|
this.bindViewData(this.panel.getTopView(), dataName);
|
|
122
125
|
break;
|
|
123
126
|
}
|
|
124
127
|
case "VIEWSESSIONPARAM": {
|
|
125
128
|
if (!dataName) {
|
|
126
|
-
throw new core.RuntimeModelError(
|
|
129
|
+
throw new core.RuntimeModelError(
|
|
130
|
+
this.model,
|
|
131
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguardDataObject")
|
|
132
|
+
);
|
|
127
133
|
}
|
|
128
134
|
this.bindViewData(this.panel.view, dataName);
|
|
129
135
|
break;
|
|
130
136
|
}
|
|
131
137
|
default:
|
|
132
|
-
throw new core.ModelError(
|
|
138
|
+
throw new core.ModelError(
|
|
139
|
+
this.model,
|
|
140
|
+
ibiz.i18n.t("vue3Util.panelComponent.noSupportedDataSourceType", {
|
|
141
|
+
dataSourceType
|
|
142
|
+
})
|
|
143
|
+
);
|
|
133
144
|
}
|
|
134
145
|
}
|
|
135
146
|
/**
|
|
@@ -182,10 +193,16 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
182
193
|
async setDataByDeLogic() {
|
|
183
194
|
const { appDataEntityId, appDELogicId } = this.model;
|
|
184
195
|
if (!appDELogicId) {
|
|
185
|
-
throw new core.RuntimeModelError(
|
|
196
|
+
throw new core.RuntimeModelError(
|
|
197
|
+
this.model,
|
|
198
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntityLogic")
|
|
199
|
+
);
|
|
186
200
|
}
|
|
187
201
|
if (!appDataEntityId) {
|
|
188
|
-
throw new core.RuntimeModelError(
|
|
202
|
+
throw new core.RuntimeModelError(
|
|
203
|
+
this.model,
|
|
204
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntity")
|
|
205
|
+
);
|
|
189
206
|
}
|
|
190
207
|
const data = await runtime.execDELogicById(
|
|
191
208
|
appDELogicId,
|
|
@@ -195,7 +212,9 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
195
212
|
this.panel.params
|
|
196
213
|
);
|
|
197
214
|
if (!data) {
|
|
198
|
-
throw new core.RuntimeError(
|
|
215
|
+
throw new core.RuntimeError(
|
|
216
|
+
ibiz.i18n.t("vue3Util.panelComponent.noReturnValue", { appDELogicId })
|
|
217
|
+
);
|
|
199
218
|
}
|
|
200
219
|
this.setData(data);
|
|
201
220
|
}
|
|
@@ -211,7 +230,9 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
211
230
|
if (originData) {
|
|
212
231
|
this.setData(originData);
|
|
213
232
|
} else {
|
|
214
|
-
ibiz.log.error(
|
|
233
|
+
ibiz.log.error(
|
|
234
|
+
ibiz.i18n.t("vue3Util.panelComponent.noAttribute", { dataName })
|
|
235
|
+
);
|
|
215
236
|
}
|
|
216
237
|
}
|
|
217
238
|
/**
|
|
@@ -224,10 +245,16 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
224
245
|
async setDataByDeMethod() {
|
|
225
246
|
const { appDEMethodId, appDataEntityId } = this.model;
|
|
226
247
|
if (!appDEMethodId) {
|
|
227
|
-
throw new core.RuntimeModelError(
|
|
248
|
+
throw new core.RuntimeModelError(
|
|
249
|
+
this.model,
|
|
250
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguerdEntityBehanior")
|
|
251
|
+
);
|
|
228
252
|
}
|
|
229
253
|
if (!appDataEntityId) {
|
|
230
|
-
throw new core.RuntimeModelError(
|
|
254
|
+
throw new core.RuntimeModelError(
|
|
255
|
+
this.model,
|
|
256
|
+
ibiz.i18n.t("vue3Util.panelComponent.noConfiguredEntity")
|
|
257
|
+
);
|
|
231
258
|
}
|
|
232
259
|
const app = ibiz.hub.getApp(this.panel.context.srfappid);
|
|
233
260
|
const res = await app.deService.exec(
|
|
@@ -251,7 +278,9 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
251
278
|
*/
|
|
252
279
|
bindViewData(view, dataName) {
|
|
253
280
|
if (!Object.prototype.hasOwnProperty.call(view.state, dataName)) {
|
|
254
|
-
ibiz.log.error(
|
|
281
|
+
ibiz.log.error(
|
|
282
|
+
ibiz.i18n.t("vue3Util.panelComponent.sessionView", { dataName })
|
|
283
|
+
);
|
|
255
284
|
return;
|
|
256
285
|
}
|
|
257
286
|
const updateData = () => {
|
|
@@ -259,7 +288,11 @@ class SingleDataContainerController extends runtime.PanelItemController {
|
|
|
259
288
|
if (originData) {
|
|
260
289
|
this.setData(originData);
|
|
261
290
|
} else {
|
|
262
|
-
ibiz.log.error(
|
|
291
|
+
ibiz.log.error(
|
|
292
|
+
ibiz.i18n.t("vue3Util.panelComponent.viewStateAttribute", {
|
|
293
|
+
dataName
|
|
294
|
+
})
|
|
295
|
+
);
|
|
263
296
|
}
|
|
264
297
|
};
|
|
265
298
|
updateData();
|
|
@@ -29,7 +29,10 @@ class TeleportPlaceholderController extends runtime.PanelItemController {
|
|
|
29
29
|
teleportTag = paramTag.value;
|
|
30
30
|
}
|
|
31
31
|
ibiz.log.debug(
|
|
32
|
-
|
|
32
|
+
ibiz.i18n.t("vue3Util.panelComponent.placeholderIdentifier", {
|
|
33
|
+
viewCodeName,
|
|
34
|
+
id: this.model.id
|
|
35
|
+
}),
|
|
33
36
|
teleportTag
|
|
34
37
|
);
|
|
35
38
|
this.state.teleportTag = teleportTag;
|
|
@@ -187,7 +187,10 @@ class PluginFactory {
|
|
|
187
187
|
const result = await p;
|
|
188
188
|
return result;
|
|
189
189
|
} catch (error) {
|
|
190
|
-
throw new core.RuntimeModelError(
|
|
190
|
+
throw new core.RuntimeModelError(
|
|
191
|
+
pluginRef,
|
|
192
|
+
ibiz.i18n.t("vue3Util.plugin.failureConfigurationLoad")
|
|
193
|
+
);
|
|
191
194
|
} finally {
|
|
192
195
|
this.loadQueue.delete(rtObjectRepo);
|
|
193
196
|
}
|
|
@@ -220,7 +223,9 @@ class PluginFactory {
|
|
|
220
223
|
url: configUrl
|
|
221
224
|
});
|
|
222
225
|
if (res.status !== 200) {
|
|
223
|
-
throw new Error(
|
|
226
|
+
throw new Error(
|
|
227
|
+
ibiz.i18n.t("vue3Util.plugin.failureConfigurationLoad")
|
|
228
|
+
);
|
|
224
229
|
}
|
|
225
230
|
configData = res.data;
|
|
226
231
|
}
|
|
@@ -279,13 +284,13 @@ class PluginFactory {
|
|
|
279
284
|
this.setPluginCode(data.default);
|
|
280
285
|
} else {
|
|
281
286
|
throw new core.RuntimeError(
|
|
282
|
-
"
|
|
287
|
+
ibiz.i18n.t("vue3Util.plugin.failedRemotePluginLoad")
|
|
283
288
|
);
|
|
284
289
|
}
|
|
285
290
|
this.cache.set(scriptUrl, true);
|
|
286
291
|
} else {
|
|
287
292
|
throw new core.RuntimeError(
|
|
288
|
-
"
|
|
293
|
+
ibiz.i18n.t("vue3Util.plugin.fileContentFormat")
|
|
289
294
|
);
|
|
290
295
|
}
|
|
291
296
|
}
|
|
@@ -347,7 +352,9 @@ class PluginFactory {
|
|
|
347
352
|
url: pkgPath
|
|
348
353
|
});
|
|
349
354
|
if (res.status !== 200) {
|
|
350
|
-
throw new Error(
|
|
355
|
+
throw new Error(
|
|
356
|
+
ibiz.i18n.t("vue3Util.plugin.failureConfigurationLoad")
|
|
357
|
+
);
|
|
351
358
|
}
|
|
352
359
|
await this.loadPluginExternal(res.data);
|
|
353
360
|
}
|
|
@@ -20,7 +20,12 @@ function watchAndUpdateContextParams(props, control) {
|
|
|
20
20
|
delete changedParams.params;
|
|
21
21
|
}
|
|
22
22
|
control.updateContextParams(changedParams);
|
|
23
|
-
ibiz.log.debug(
|
|
23
|
+
ibiz.log.debug(
|
|
24
|
+
ibiz.i18n.t("vue3Util.use.control.parameterChanges", {
|
|
25
|
+
id: control.model.id
|
|
26
|
+
}),
|
|
27
|
+
newVal
|
|
28
|
+
);
|
|
24
29
|
}
|
|
25
30
|
);
|
|
26
31
|
}
|
|
@@ -43,7 +48,12 @@ function watchAndUpdateState(props, control, excludeFields = []) {
|
|
|
43
48
|
changeProps[key] = newVal[key];
|
|
44
49
|
}
|
|
45
50
|
});
|
|
46
|
-
ibiz.log.debug(
|
|
51
|
+
ibiz.log.debug(
|
|
52
|
+
ibiz.i18n.t("vue3Util.use.control.stateChange", {
|
|
53
|
+
name: control.model.name
|
|
54
|
+
}),
|
|
55
|
+
changeProps
|
|
56
|
+
);
|
|
47
57
|
Object.keys(changeProps).forEach((key) => {
|
|
48
58
|
if (changeProps[key] !== void 0) {
|
|
49
59
|
control.state[key] = changeProps[key];
|
|
@@ -11,7 +11,7 @@ function useFocusAndBlur(focus, blur) {
|
|
|
11
11
|
let outsideFuns;
|
|
12
12
|
const doBlur = () => {
|
|
13
13
|
if (!isFocus.value) {
|
|
14
|
-
ibiz.log.debug("
|
|
14
|
+
ibiz.log.debug(ibiz.i18n.t("vue3Util.use.focusBlur.noFocus"));
|
|
15
15
|
}
|
|
16
16
|
blur();
|
|
17
17
|
outsideFuns.stop();
|
|
@@ -13,7 +13,12 @@ function watchAndUpdateContextParams(props, view) {
|
|
|
13
13
|
qxUtil.clearAll(view.params);
|
|
14
14
|
Object.assign(view.params, newVal.params);
|
|
15
15
|
view.handleContextParams();
|
|
16
|
-
ibiz.log.debug(
|
|
16
|
+
ibiz.log.debug(
|
|
17
|
+
ibiz.i18n.t("vue3Util.use.control.parameterChanges", {
|
|
18
|
+
id: view.model.id
|
|
19
|
+
}),
|
|
20
|
+
newVal
|
|
21
|
+
);
|
|
17
22
|
}
|
|
18
23
|
);
|
|
19
24
|
}
|
|
@@ -29,7 +34,12 @@ function watchAndUpdateState(props, view) {
|
|
|
29
34
|
changeProps[key] = newVal[key];
|
|
30
35
|
}
|
|
31
36
|
});
|
|
32
|
-
ibiz.log.debug(
|
|
37
|
+
ibiz.log.debug(
|
|
38
|
+
ibiz.i18n.t("vue3Util.use.view.stateChange", {
|
|
39
|
+
name: view.model.name
|
|
40
|
+
}),
|
|
41
|
+
changeProps
|
|
42
|
+
);
|
|
33
43
|
Object.keys(changeProps).forEach((key) => {
|
|
34
44
|
view.state[key] = changeProps[key];
|
|
35
45
|
});
|
|
@@ -30,7 +30,7 @@ class OverlayContainer {
|
|
|
30
30
|
this.init();
|
|
31
31
|
}
|
|
32
32
|
static createVueApp(_rootComponent, _rootProps) {
|
|
33
|
-
throw new core.RuntimeError("
|
|
33
|
+
throw new core.RuntimeError(ibiz.i18n.t("vue3Util.util.noInjected"));
|
|
34
34
|
}
|
|
35
35
|
/**
|
|
36
36
|
* 初始化飘窗
|
|
@@ -17,7 +17,7 @@ function renderString(value) {
|
|
|
17
17
|
const str = value.toString();
|
|
18
18
|
return str;
|
|
19
19
|
} catch (error) {
|
|
20
|
-
ibiz.log.error(value, "
|
|
20
|
+
ibiz.log.error(value, ibiz.i18n.t("vue3Util.util.convertString"), error);
|
|
21
21
|
}
|
|
22
22
|
return "";
|
|
23
23
|
}
|
package/lib/util/route/route.cjs
CHANGED
|
@@ -235,7 +235,9 @@ async function parseRouteViewData(route, depth, isRouteModal = false) {
|
|
|
235
235
|
const routePath = route2routePath(route, isRouteModal);
|
|
236
236
|
let viewCodeName = routePath.pathNodes[depth - 1].viewName;
|
|
237
237
|
if (!viewCodeName) {
|
|
238
|
-
throw new core.RuntimeError(
|
|
238
|
+
throw new core.RuntimeError(
|
|
239
|
+
ibiz.i18n.t("vue3Util.util.viewIdentifiers", { depth })
|
|
240
|
+
);
|
|
239
241
|
}
|
|
240
242
|
if (viewCodeName === runtime.RouteConst.ROUTE_MODAL_TAG) {
|
|
241
243
|
viewCodeName = routePath.pathNodes[depth].viewName;
|
|
@@ -245,7 +247,9 @@ async function parseRouteViewData(route, depth, isRouteModal = false) {
|
|
|
245
247
|
}
|
|
246
248
|
const viewConfig = await ibiz.hub.config.view.get(viewCodeName);
|
|
247
249
|
if (!viewConfig) {
|
|
248
|
-
throw new core.RuntimeError(
|
|
250
|
+
throw new core.RuntimeError(
|
|
251
|
+
ibiz.i18n.t("vue3Util.util.noFoundView", { viewCodeName })
|
|
252
|
+
);
|
|
249
253
|
}
|
|
250
254
|
const context = {};
|
|
251
255
|
if ((_a = ibiz.appData) == null ? void 0 : _a.context) {
|
|
@@ -296,7 +300,7 @@ function getNestedRoutePath(route, depth, noSrfNav = true) {
|
|
|
296
300
|
function onRouteChange(callback, depth) {
|
|
297
301
|
const route = vueRouter.useRoute();
|
|
298
302
|
if (!route) {
|
|
299
|
-
throw new core.RuntimeError("
|
|
303
|
+
throw new core.RuntimeError(ibiz.i18n.t("vue3Util.util.routeCorrectly"));
|
|
300
304
|
}
|
|
301
305
|
vue.watch(
|
|
302
306
|
() => route == null ? void 0 : route.path,
|
|
@@ -22,7 +22,7 @@ const AppRedirectView = /* @__PURE__ */ vue.defineComponent({
|
|
|
22
22
|
toRedirect();
|
|
23
23
|
},
|
|
24
24
|
render() {
|
|
25
|
-
return vue.createVNode("div", null, [
|
|
25
|
+
return vue.createVNode("div", null, [ibiz.i18n.t("vue3Util.view.redirectionProgress")]);
|
|
26
26
|
}
|
|
27
27
|
});
|
|
28
28
|
|
package/lib/view/common/view.cjs
CHANGED
|
@@ -125,7 +125,9 @@ const View = /* @__PURE__ */ vue.defineComponent({
|
|
|
125
125
|
if (this.c.engines.length === 0) {
|
|
126
126
|
layoutPanel = vue.createVNode("span", {
|
|
127
127
|
"style": "color:red;"
|
|
128
|
-
}, [
|
|
128
|
+
}, [ibiz.i18n.t("vue3Util.view.viewType", {
|
|
129
|
+
viewType: this.modelData.viewType
|
|
130
|
+
})]);
|
|
129
131
|
} else {
|
|
130
132
|
const slots = {
|
|
131
133
|
...this.$slots
|
|
@@ -157,7 +159,9 @@ const View = /* @__PURE__ */ vue.defineComponent({
|
|
|
157
159
|
let _slot;
|
|
158
160
|
const tag = this.getCtrlTeleportTag(ctrl);
|
|
159
161
|
if (!tag) {
|
|
160
|
-
ibiz.log.error(
|
|
162
|
+
ibiz.log.error(ibiz.i18n.t("vue3Util.view.noTeleportTag", {
|
|
163
|
+
name: ctrl.name
|
|
164
|
+
}));
|
|
161
165
|
return null;
|
|
162
166
|
}
|
|
163
167
|
return vue.createVNode("div", {
|
|
@@ -35,7 +35,7 @@ const DeRedirectView = /* @__PURE__ */ vue.defineComponent({
|
|
|
35
35
|
toViewContext.value = result.context;
|
|
36
36
|
toViewParams.value = result.params;
|
|
37
37
|
} else {
|
|
38
|
-
throw new core.RuntimeError("
|
|
38
|
+
throw new core.RuntimeError(ibiz.i18n.t("vue3Util.view.embeddedRedirectionView"));
|
|
39
39
|
}
|
|
40
40
|
});
|
|
41
41
|
});
|