@ibiz-template/vue3-components 0.7.41-alpha.33 → 0.7.41-alpha.34
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-y6lsqs4n.js → index-BFGNWF-0.js} +1 -1
- package/dist/{index-BsKD1A4D.js → index-BiFsbM1Y.js} +1 -1
- package/dist/index-Cvz1NuFN.js +11 -0
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/{wang-editor-CYWOJCad.js → wang-editor-B4ClR4_m.js} +1 -1
- package/dist/{xlsx-util-D2V8VJ2T.js → xlsx-util-DIeV3Kl6.js} +1 -1
- package/es/control/app-menu/app-menu.mjs +3 -22
- package/es/control/calendar/calendar.mjs +2 -1
- package/es/control/tree/tree.mjs +3 -16
- package/es/locale/en/index.mjs +10 -0
- package/es/locale/zh-CN/index.mjs +10 -0
- package/es/panel-component/user-message/async-action/async-action-result/async-action-result.css +1 -0
- package/es/panel-component/user-message/async-action/async-action-result/async-action-result.mjs +161 -9
- package/lib/control/app-menu/app-menu.cjs +2 -21
- package/lib/control/calendar/calendar.cjs +2 -1
- package/lib/control/tree/tree.cjs +3 -16
- package/lib/locale/en/index.cjs +10 -0
- package/lib/locale/zh-CN/index.cjs +10 -0
- package/lib/panel-component/user-message/async-action/async-action-result/async-action-result.cjs +160 -8
- package/lib/panel-component/user-message/async-action/async-action-result/async-action-result.css +1 -0
- package/package.json +5 -5
- package/dist/index-BA-hBsSe.js +0 -11
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isVNode, createVNode, resolveComponent, defineComponent, mergeProps, ref, watch,
|
|
1
|
+
import { isVNode, createVNode, resolveComponent, defineComponent, mergeProps, ref, watch, computed, onMounted, nextTick } from 'vue';
|
|
2
2
|
import { RuntimeError, showTitle, findRecursiveChild } from '@ibiz-template/core';
|
|
3
3
|
import { useControlController, useNamespace, route2routePath } from '@ibiz-template/vue3-util';
|
|
4
4
|
import { createUUID } from 'qx-util';
|
|
@@ -288,8 +288,6 @@ const AppMenuControl = /* @__PURE__ */ defineComponent({
|
|
|
288
288
|
const defaultActive = ref("");
|
|
289
289
|
const defaultOpens = ref([]);
|
|
290
290
|
const route = useRoute();
|
|
291
|
-
let counter = null;
|
|
292
|
-
const counterData = ref({});
|
|
293
291
|
const key = ref(createUUID());
|
|
294
292
|
const menuRef = ref();
|
|
295
293
|
const hasScroll = ref(false);
|
|
@@ -338,9 +336,6 @@ const AppMenuControl = /* @__PURE__ */ defineComponent({
|
|
|
338
336
|
}
|
|
339
337
|
});
|
|
340
338
|
}
|
|
341
|
-
const fn = (data) => {
|
|
342
|
-
counterData.value = data;
|
|
343
|
-
};
|
|
344
339
|
c.evt.on("onCreated", async () => {
|
|
345
340
|
saveConfigs.value = c.saveConfigs;
|
|
346
341
|
const defaultActiveMenuItem = c.getDefaultOpenMenuItem();
|
|
@@ -361,19 +356,6 @@ const AppMenuControl = /* @__PURE__ */ defineComponent({
|
|
|
361
356
|
}
|
|
362
357
|
hideSeparator.value = formatSeparator("APPMENU", c.model.appMenuItems, c.state.menuItemsState, saveConfigs.value);
|
|
363
358
|
});
|
|
364
|
-
c.evt.on("onMounted", async () => {
|
|
365
|
-
const counterRefId = c.model.appCounterRefId;
|
|
366
|
-
if (counterRefId) {
|
|
367
|
-
counter = c.getCounter(counterRefId);
|
|
368
|
-
if (counter) {
|
|
369
|
-
counter.onChange(fn);
|
|
370
|
-
}
|
|
371
|
-
}
|
|
372
|
-
});
|
|
373
|
-
onUnmounted(() => {
|
|
374
|
-
counter == null ? void 0 : counter.offChange(fn);
|
|
375
|
-
counter == null ? void 0 : counter.destroy();
|
|
376
|
-
});
|
|
377
359
|
const menuMode = computed(() => {
|
|
378
360
|
const model = c.view.model.mainMenuAlign;
|
|
379
361
|
switch (model) {
|
|
@@ -443,7 +425,6 @@ const AppMenuControl = /* @__PURE__ */ defineComponent({
|
|
|
443
425
|
menuRef,
|
|
444
426
|
menuMode,
|
|
445
427
|
hasScroll,
|
|
446
|
-
counterData,
|
|
447
428
|
saveConfigs,
|
|
448
429
|
defaultOpens,
|
|
449
430
|
defaultActive,
|
|
@@ -484,9 +465,9 @@ const AppMenuControl = /* @__PURE__ */ defineComponent({
|
|
|
484
465
|
return this.menus.map((item) => {
|
|
485
466
|
var _a3;
|
|
486
467
|
if (((_a3 = item.children) == null ? void 0 : _a3.length) > 0) {
|
|
487
|
-
return renderSubmenu(true, item, this.collapse, this.ns, this.c, this.counterData, this.saveConfigs, this.hideSeparator);
|
|
468
|
+
return renderSubmenu(true, item, this.collapse, this.ns, this.c, this.c.state.counterData, this.saveConfigs, this.hideSeparator);
|
|
488
469
|
}
|
|
489
|
-
return renderMenuItem(true, item, this.collapse, this.ns, this.c, this.counterData, this.saveConfigs, this.hideSeparator);
|
|
470
|
+
return renderMenuItem(true, item, this.collapse, this.ns, this.c, this.c.state.counterData, this.saveConfigs, this.hideSeparator);
|
|
490
471
|
});
|
|
491
472
|
}
|
|
492
473
|
}), this.enableCustomized && createVNode(MenuDesign, {
|
|
@@ -655,11 +655,12 @@ const CalendarControl = /* @__PURE__ */ defineComponent({
|
|
|
655
655
|
const model = (_a = this.c.model.sysCalendarItems) == null ? void 0 : _a.find((calendarItems) => {
|
|
656
656
|
return item.itemType === calendarItems.itemType;
|
|
657
657
|
});
|
|
658
|
+
const temptime = item.beginTime ? dayjs(item.beginTime).format(this.c.timelineCaptionFormat) : item.beginTime;
|
|
658
659
|
return createVNode(resolveComponent("el-timeline-item"), {
|
|
659
660
|
"key": item.id,
|
|
660
661
|
"placement": "top",
|
|
661
662
|
"color": item.bkColor,
|
|
662
|
-
"timestamp":
|
|
663
|
+
"timestamp": temptime
|
|
663
664
|
}, {
|
|
664
665
|
default: () => [(model == null ? void 0 : model.layoutPanel) ? renderPanelItem(item, model.layoutPanel) : renderDefaultItem(item)]
|
|
665
666
|
});
|
package/es/control/tree/tree.mjs
CHANGED
|
@@ -4,7 +4,6 @@ import { createUUID } from 'qx-util';
|
|
|
4
4
|
import { cloneDeep, debounce } from 'lodash-es';
|
|
5
5
|
import { TreeController, AppDataEntity, PanelItemEventName } from '@ibiz-template/runtime';
|
|
6
6
|
import { RuntimeError } from '@ibiz-template/core';
|
|
7
|
-
import { isNil } from 'ramda';
|
|
8
7
|
import { getNodeControlPanel, useAppTreeBase, getNewNodeControlPanel, findNodeData, useElTreeUtil, useLoadMoreUtil, findChildItems, formatNodeDropType } from './el-tree-util.mjs';
|
|
9
8
|
import './tree.css';
|
|
10
9
|
|
|
@@ -106,15 +105,8 @@ const TreeControl = /* @__PURE__ */ defineComponent({
|
|
|
106
105
|
const c = useControlController((...args) => new TreeController(...args));
|
|
107
106
|
useAppTreeBase(c, props);
|
|
108
107
|
const cascadeSelect = ref(false);
|
|
109
|
-
const counterData = ref({});
|
|
110
108
|
const menuShowMode = ref("default");
|
|
111
|
-
const fn = (counter) => {
|
|
112
|
-
counterData.value = counter;
|
|
113
|
-
};
|
|
114
109
|
c.evt.on("onCreated", () => {
|
|
115
|
-
if (c.counter) {
|
|
116
|
-
c.counter.onChange(fn, true);
|
|
117
|
-
}
|
|
118
110
|
if (c.controlParams.cascadeselect) {
|
|
119
111
|
cascadeSelect.value = true;
|
|
120
112
|
}
|
|
@@ -685,16 +677,11 @@ const TreeControl = /* @__PURE__ */ defineComponent({
|
|
|
685
677
|
});
|
|
686
678
|
const renderCounter = (nodeModel) => {
|
|
687
679
|
if (nodeModel.counterId) {
|
|
688
|
-
const value = counterData
|
|
689
|
-
if (isNil(value)) {
|
|
690
|
-
return null;
|
|
691
|
-
}
|
|
692
|
-
if (nodeModel.counterMode === 1 && value === 0) {
|
|
693
|
-
return null;
|
|
694
|
-
}
|
|
680
|
+
const value = c.state.counterData[nodeModel.counterId];
|
|
695
681
|
return createVNode(resolveComponent("iBizBadge"), {
|
|
682
|
+
"value": value,
|
|
696
683
|
"class": ns.e("counter"),
|
|
697
|
-
"
|
|
684
|
+
"counterMode": nodeModel.counterMode
|
|
698
685
|
}, null);
|
|
699
686
|
}
|
|
700
687
|
};
|
package/es/locale/en/index.mjs
CHANGED
|
@@ -763,6 +763,16 @@ var index = {
|
|
|
763
763
|
successImport: "Number of successful imports: ",
|
|
764
764
|
ImportFailed: "Number of import failures: "
|
|
765
765
|
},
|
|
766
|
+
asyncActionResult: {
|
|
767
|
+
noMessage: "No content",
|
|
768
|
+
taskName: "Task Name:",
|
|
769
|
+
taskState: "Task Status:",
|
|
770
|
+
finished: "Completed",
|
|
771
|
+
processing: "Processing",
|
|
772
|
+
beginTime: "Start Execution Time:",
|
|
773
|
+
endTime: "End Execution Time:",
|
|
774
|
+
exeResult: "Execution Result:"
|
|
775
|
+
},
|
|
766
776
|
asyncDataExport: {
|
|
767
777
|
exportDetailPrompt: "Export data details-{name}",
|
|
768
778
|
excuteTime: "Execution time",
|
|
@@ -759,6 +759,16 @@ var index = {
|
|
|
759
759
|
successImport: "\u6210\u529F\u5BFC\u5165\u6570: ",
|
|
760
760
|
ImportFailed: "\u5BFC\u5165\u5931\u8D25\u6570: "
|
|
761
761
|
},
|
|
762
|
+
asyncActionResult: {
|
|
763
|
+
noMessage: "\u65E0\u5904\u7406\u5185\u5BB9",
|
|
764
|
+
taskName: "\u4EFB\u52A1\u540D\u79F0:",
|
|
765
|
+
taskState: "\u4EFB\u52A1\u72B6\u6001:",
|
|
766
|
+
finished: "\u5DF2\u5B8C\u6210",
|
|
767
|
+
processing: "\u6267\u884C\u4E2D",
|
|
768
|
+
beginTime: "\u5F00\u59CB\u6267\u884C\u65F6\u95F4:",
|
|
769
|
+
endTime: "\u7ED3\u675F\u6267\u884C\u65F6\u95F4:",
|
|
770
|
+
exeResult: "\u6267\u884C\u7ED3\u679C:"
|
|
771
|
+
},
|
|
762
772
|
asyncDataExport: {
|
|
763
773
|
exportDetailPrompt: "\u5BFC\u51FA\u6570\u636E\u8BE6\u60C5-{name}",
|
|
764
774
|
excuteTime: "\u6267\u884C\u65F6\u95F4",
|
package/es/panel-component/user-message/async-action/async-action-result/async-action-result.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ibiz-async-action-result{height:100%;display:flex;flex-flow:column nowrap;padding:var(--ibiz-spacing-tight)}.ibiz-async-action-result__title{font-size:var(--ibiz-font-size-header-5);font-weight:var(--ibiz-font-weight-bold)}.ibiz-async-action-result-header{display:flex;align-items:center;justify-content:space-between;height:48px;padding:var(--ibiz-spacing-tight);border-bottom:1px solid var(--ibiz-color-border)}.ibiz-async-action-result-content{padding:var(--ibiz-spacing-tight)}.ibiz-async-action-result-content .el-form-item__content,.ibiz-async-action-result-content .el-form-item__label{font-weight:var(--ibiz-font-weight-bold)}.ibiz-async-action-result-content__json-container{width:100%;max-height:400px;padding:12px;overflow-y:auto;font-family:Monaco,Menlo,"Ubuntu Mono",monospace;font-size:13px;line-height:1.5;word-break:break-word;white-space:pre-wrap;background-color:var(--ibiz-color-bg-0);border:1px solid var(--ibiz-color-border);border-radius:4px}.ibiz-async-action-result-content__json-container::-webkit-scrollbar{width:6px;height:6px}.ibiz-async-action-result-content__json-container::-webkit-scrollbar-track{background:#f1f1f1;border-radius:3px}.ibiz-async-action-result-content__json-container::-webkit-scrollbar-thumb{background:#c1c1c1;border-radius:3px}.ibiz-async-action-result-content__json-container::-webkit-scrollbar-thumb:hover{background:#a8a8a8}.ibiz-async-action-result-content__json-key{font-weight:700;color:#d73a49}.ibiz-async-action-result-content__json-string{color:#032f62}.ibiz-async-action-result-content__json-number{color:#005cc5}.ibiz-async-action-result-content__json-boolean{color:#d73a49}.ibiz-async-action-result-content__json-null{color:#d73a49}.ibiz-async-action-result-content__json-array{display:inline-block}.ibiz-async-action-result-content__json-object{display:inline-block}.ibiz-async-action-result-content__json-indent{display:block}
|
package/es/panel-component/user-message/async-action/async-action-result/async-action-result.mjs
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
import { defineComponent, createVNode,
|
|
1
|
+
import { isVNode, defineComponent, createVNode, resolveComponent, reactive, createTextVNode } from 'vue';
|
|
2
2
|
import { useNamespace } from '@ibiz-template/vue3-util';
|
|
3
|
+
import './async-action-result.css';
|
|
3
4
|
import { isObject } from 'lodash-es';
|
|
4
5
|
|
|
5
6
|
"use strict";
|
|
7
|
+
function _isSlot(s) {
|
|
8
|
+
return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
|
|
9
|
+
}
|
|
6
10
|
const AsyncActionResult = /* @__PURE__ */ defineComponent({
|
|
7
11
|
name: "IBizAsyncActionResult",
|
|
8
12
|
props: {
|
|
@@ -16,22 +20,170 @@ const AsyncActionResult = /* @__PURE__ */ defineComponent({
|
|
|
16
20
|
}
|
|
17
21
|
},
|
|
18
22
|
setup(props) {
|
|
19
|
-
const ns = useNamespace("async-action-
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
23
|
+
const ns = useNamespace("async-action-result");
|
|
24
|
+
const finishedStates = [30, 40];
|
|
25
|
+
const info = reactive({
|
|
26
|
+
title: props.asyncAction.asyncacitonname,
|
|
27
|
+
beginTime: props.asyncAction.begintime,
|
|
28
|
+
endTime: props.asyncAction.endtime,
|
|
29
|
+
actionState: finishedStates.includes(props.asyncAction.actionstate),
|
|
30
|
+
message: ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.noMessage"),
|
|
31
|
+
isJSON: false
|
|
25
32
|
});
|
|
33
|
+
const onClose = () => {
|
|
34
|
+
props.modal.dismiss();
|
|
35
|
+
};
|
|
36
|
+
if (isObject(props.asyncAction.actionresult)) {
|
|
37
|
+
info.message = JSON.stringify(props.asyncAction.actionresult, null, 2);
|
|
38
|
+
info.isJSON = true;
|
|
39
|
+
} else if (props.asyncAction.actionresult) {
|
|
40
|
+
info.message = "".concat(props.asyncAction.actionresult);
|
|
41
|
+
}
|
|
42
|
+
const renderJSONObject = (obj, depth) => {
|
|
43
|
+
if (obj === null) {
|
|
44
|
+
return createVNode("span", {
|
|
45
|
+
"class": ns.be("content", "json-null")
|
|
46
|
+
}, [createTextVNode("null")]);
|
|
47
|
+
}
|
|
48
|
+
if (typeof obj === "boolean") {
|
|
49
|
+
return createVNode("span", {
|
|
50
|
+
"class": ns.be("content", "json-boolean")
|
|
51
|
+
}, [obj.toString()]);
|
|
52
|
+
}
|
|
53
|
+
if (typeof obj === "number") {
|
|
54
|
+
return createVNode("span", {
|
|
55
|
+
"class": ns.be("content", "json-number")
|
|
56
|
+
}, [obj.toString()]);
|
|
57
|
+
}
|
|
58
|
+
if (typeof obj === "string") {
|
|
59
|
+
return createVNode("span", {
|
|
60
|
+
"class": ns.be("content", "json-string")
|
|
61
|
+
}, [createTextVNode('"'), obj, createTextVNode('"')]);
|
|
62
|
+
}
|
|
63
|
+
if (Array.isArray(obj)) {
|
|
64
|
+
if (obj.length === 0) {
|
|
65
|
+
return createVNode("span", null, [createTextVNode("[]")]);
|
|
66
|
+
}
|
|
67
|
+
const items2 = obj.map((item, index) => createVNode("div", {
|
|
68
|
+
"key": index,
|
|
69
|
+
"class": ns.be("content", "json-indent"),
|
|
70
|
+
"style": {
|
|
71
|
+
paddingLeft: "".concat((depth + 1) * 20, "px")
|
|
72
|
+
}
|
|
73
|
+
}, [renderJSONObject(item, depth + 1), index < obj.length - 1 ? "," : ""]));
|
|
74
|
+
return createVNode("div", {
|
|
75
|
+
"class": ns.be("content", "json-array")
|
|
76
|
+
}, [createVNode("span", null, [createTextVNode("[")]), items2, createVNode("div", {
|
|
77
|
+
"style": {
|
|
78
|
+
paddingLeft: "".concat(depth * 20, "px")
|
|
79
|
+
}
|
|
80
|
+
}, null), createVNode("span", {
|
|
81
|
+
"style": {
|
|
82
|
+
paddingLeft: "".concat(depth * 20, "px")
|
|
83
|
+
}
|
|
84
|
+
}, [createTextVNode("]")])]);
|
|
85
|
+
}
|
|
86
|
+
const keys = Object.keys(obj);
|
|
87
|
+
if (keys.length === 0) {
|
|
88
|
+
return createVNode("span", null, ["{}"]);
|
|
89
|
+
}
|
|
90
|
+
const items = keys.map((key, index) => createVNode("div", {
|
|
91
|
+
"key": key,
|
|
92
|
+
"class": ns.be("content", "json-indent"),
|
|
93
|
+
"style": {
|
|
94
|
+
paddingLeft: "".concat((depth + 1) * 20, "px")
|
|
95
|
+
}
|
|
96
|
+
}, [createVNode("span", {
|
|
97
|
+
"class": ns.be("content", "json-key")
|
|
98
|
+
}, [createTextVNode('"'), key, createTextVNode('"')]), createTextVNode(":"), " ", renderJSONObject(obj[key], depth + 1), index < keys.length - 1 ? "," : ""]));
|
|
99
|
+
return createVNode("div", {
|
|
100
|
+
"class": ns.be("content", "json-object")
|
|
101
|
+
}, [createVNode("span", null, ["{"]), items, createVNode("div", {
|
|
102
|
+
"style": {
|
|
103
|
+
paddingLeft: "".concat(depth * 20, "px")
|
|
104
|
+
}
|
|
105
|
+
}, null), createVNode("span", {
|
|
106
|
+
"style": {
|
|
107
|
+
paddingLeft: "".concat(depth * 20, "px")
|
|
108
|
+
}
|
|
109
|
+
}, ["}"])]);
|
|
110
|
+
};
|
|
111
|
+
const renderJSON = (jsonStr) => {
|
|
112
|
+
try {
|
|
113
|
+
const obj = JSON.parse(jsonStr);
|
|
114
|
+
return renderJSONObject(obj, 0);
|
|
115
|
+
} catch (e) {
|
|
116
|
+
return createVNode("span", null, [jsonStr]);
|
|
117
|
+
}
|
|
118
|
+
};
|
|
26
119
|
return {
|
|
27
120
|
ns,
|
|
28
|
-
|
|
121
|
+
info,
|
|
122
|
+
onClose,
|
|
123
|
+
renderJSON
|
|
29
124
|
};
|
|
30
125
|
},
|
|
31
126
|
render() {
|
|
127
|
+
let _slot;
|
|
32
128
|
return createVNode("div", {
|
|
33
129
|
"class": [this.ns.b()]
|
|
34
|
-
}, [
|
|
130
|
+
}, [createVNode("div", {
|
|
131
|
+
"class": this.ns.b("header")
|
|
132
|
+
}, [createVNode("div", {
|
|
133
|
+
"class": this.ns.e("title")
|
|
134
|
+
}, [this.info.title]), createVNode("div", {
|
|
135
|
+
"class": this.ns.b("toolbar")
|
|
136
|
+
}, [createVNode(resolveComponent("el-button"), {
|
|
137
|
+
"onClick": this.onClose
|
|
138
|
+
}, _isSlot(_slot = ibiz.i18n.t("app.close")) ? _slot : {
|
|
139
|
+
default: () => [_slot]
|
|
140
|
+
})])]), createVNode("div", {
|
|
141
|
+
"class": this.ns.b("content")
|
|
142
|
+
}, [createVNode(resolveComponent("el-row"), null, {
|
|
143
|
+
default: () => [createVNode(resolveComponent("el-col"), {
|
|
144
|
+
"span": 12
|
|
145
|
+
}, {
|
|
146
|
+
default: () => [createVNode(resolveComponent("el-form-item"), {
|
|
147
|
+
"label": ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.taskName")
|
|
148
|
+
}, {
|
|
149
|
+
default: () => [this.info.title]
|
|
150
|
+
})]
|
|
151
|
+
}), createVNode(resolveComponent("el-col"), {
|
|
152
|
+
"span": 12
|
|
153
|
+
}, {
|
|
154
|
+
default: () => [createVNode(resolveComponent("el-form-item"), {
|
|
155
|
+
"label": ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.taskState")
|
|
156
|
+
}, {
|
|
157
|
+
default: () => [this.info.actionState ? ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.finished") : ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.processing")]
|
|
158
|
+
})]
|
|
159
|
+
}), createVNode(resolveComponent("el-col"), {
|
|
160
|
+
"span": 12
|
|
161
|
+
}, {
|
|
162
|
+
default: () => [createVNode(resolveComponent("el-form-item"), {
|
|
163
|
+
"label": ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.beginTime")
|
|
164
|
+
}, {
|
|
165
|
+
default: () => [this.info.beginTime]
|
|
166
|
+
})]
|
|
167
|
+
}), createVNode(resolveComponent("el-col"), {
|
|
168
|
+
"span": 12
|
|
169
|
+
}, {
|
|
170
|
+
default: () => [createVNode(resolveComponent("el-form-item"), {
|
|
171
|
+
"label": ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.endTime")
|
|
172
|
+
}, {
|
|
173
|
+
default: () => [this.info.endTime]
|
|
174
|
+
})]
|
|
175
|
+
}), createVNode(resolveComponent("el-col"), {
|
|
176
|
+
"span": 24
|
|
177
|
+
}, {
|
|
178
|
+
default: () => [createVNode(resolveComponent("el-form-item"), {
|
|
179
|
+
"label": ibiz.i18n.t("panelComponent.userMessage.asyncActionResult.exeResult")
|
|
180
|
+
}, {
|
|
181
|
+
default: () => [createVNode("div", {
|
|
182
|
+
"class": this.ns.be("content", "json-container")
|
|
183
|
+
}, [this.renderJSON(this.info.message)])]
|
|
184
|
+
})]
|
|
185
|
+
})]
|
|
186
|
+
})])]);
|
|
35
187
|
}
|
|
36
188
|
});
|
|
37
189
|
|
|
@@ -290,8 +290,6 @@ const AppMenuControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
290
290
|
const defaultActive = vue.ref("");
|
|
291
291
|
const defaultOpens = vue.ref([]);
|
|
292
292
|
const route = vueRouter.useRoute();
|
|
293
|
-
let counter = null;
|
|
294
|
-
const counterData = vue.ref({});
|
|
295
293
|
const key = vue.ref(qxUtil.createUUID());
|
|
296
294
|
const menuRef = vue.ref();
|
|
297
295
|
const hasScroll = vue.ref(false);
|
|
@@ -340,9 +338,6 @@ const AppMenuControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
340
338
|
}
|
|
341
339
|
});
|
|
342
340
|
}
|
|
343
|
-
const fn = (data) => {
|
|
344
|
-
counterData.value = data;
|
|
345
|
-
};
|
|
346
341
|
c.evt.on("onCreated", async () => {
|
|
347
342
|
saveConfigs.value = c.saveConfigs;
|
|
348
343
|
const defaultActiveMenuItem = c.getDefaultOpenMenuItem();
|
|
@@ -363,19 +358,6 @@ const AppMenuControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
363
358
|
}
|
|
364
359
|
hideSeparator.value = runtime.formatSeparator("APPMENU", c.model.appMenuItems, c.state.menuItemsState, saveConfigs.value);
|
|
365
360
|
});
|
|
366
|
-
c.evt.on("onMounted", async () => {
|
|
367
|
-
const counterRefId = c.model.appCounterRefId;
|
|
368
|
-
if (counterRefId) {
|
|
369
|
-
counter = c.getCounter(counterRefId);
|
|
370
|
-
if (counter) {
|
|
371
|
-
counter.onChange(fn);
|
|
372
|
-
}
|
|
373
|
-
}
|
|
374
|
-
});
|
|
375
|
-
vue.onUnmounted(() => {
|
|
376
|
-
counter == null ? void 0 : counter.offChange(fn);
|
|
377
|
-
counter == null ? void 0 : counter.destroy();
|
|
378
|
-
});
|
|
379
361
|
const menuMode = vue.computed(() => {
|
|
380
362
|
const model = c.view.model.mainMenuAlign;
|
|
381
363
|
switch (model) {
|
|
@@ -445,7 +427,6 @@ const AppMenuControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
445
427
|
menuRef,
|
|
446
428
|
menuMode,
|
|
447
429
|
hasScroll,
|
|
448
|
-
counterData,
|
|
449
430
|
saveConfigs,
|
|
450
431
|
defaultOpens,
|
|
451
432
|
defaultActive,
|
|
@@ -486,9 +467,9 @@ const AppMenuControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
486
467
|
return this.menus.map((item) => {
|
|
487
468
|
var _a3;
|
|
488
469
|
if (((_a3 = item.children) == null ? void 0 : _a3.length) > 0) {
|
|
489
|
-
return renderSubmenu(true, item, this.collapse, this.ns, this.c, this.counterData, this.saveConfigs, this.hideSeparator);
|
|
470
|
+
return renderSubmenu(true, item, this.collapse, this.ns, this.c, this.c.state.counterData, this.saveConfigs, this.hideSeparator);
|
|
490
471
|
}
|
|
491
|
-
return renderMenuItem(true, item, this.collapse, this.ns, this.c, this.counterData, this.saveConfigs, this.hideSeparator);
|
|
472
|
+
return renderMenuItem(true, item, this.collapse, this.ns, this.c, this.c.state.counterData, this.saveConfigs, this.hideSeparator);
|
|
492
473
|
});
|
|
493
474
|
}
|
|
494
475
|
}), this.enableCustomized && vue.createVNode(customMenuDesign.MenuDesign, {
|
|
@@ -657,11 +657,12 @@ const CalendarControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
657
657
|
const model = (_a = this.c.model.sysCalendarItems) == null ? void 0 : _a.find((calendarItems) => {
|
|
658
658
|
return item.itemType === calendarItems.itemType;
|
|
659
659
|
});
|
|
660
|
+
const temptime = item.beginTime ? dayjs(item.beginTime).format(this.c.timelineCaptionFormat) : item.beginTime;
|
|
660
661
|
return vue.createVNode(vue.resolveComponent("el-timeline-item"), {
|
|
661
662
|
"key": item.id,
|
|
662
663
|
"placement": "top",
|
|
663
664
|
"color": item.bkColor,
|
|
664
|
-
"timestamp":
|
|
665
|
+
"timestamp": temptime
|
|
665
666
|
}, {
|
|
666
667
|
default: () => [(model == null ? void 0 : model.layoutPanel) ? renderPanelItem(item, model.layoutPanel) : renderDefaultItem(item)]
|
|
667
668
|
});
|
|
@@ -6,7 +6,6 @@ var qxUtil = require('qx-util');
|
|
|
6
6
|
var lodashEs = require('lodash-es');
|
|
7
7
|
var runtime = require('@ibiz-template/runtime');
|
|
8
8
|
var core = require('@ibiz-template/core');
|
|
9
|
-
var ramda = require('ramda');
|
|
10
9
|
var elTreeUtil = require('./el-tree-util.cjs');
|
|
11
10
|
require('./tree.css');
|
|
12
11
|
|
|
@@ -108,15 +107,8 @@ const TreeControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
108
107
|
const c = vue3Util.useControlController((...args) => new runtime.TreeController(...args));
|
|
109
108
|
elTreeUtil.useAppTreeBase(c, props);
|
|
110
109
|
const cascadeSelect = vue.ref(false);
|
|
111
|
-
const counterData = vue.ref({});
|
|
112
110
|
const menuShowMode = vue.ref("default");
|
|
113
|
-
const fn = (counter) => {
|
|
114
|
-
counterData.value = counter;
|
|
115
|
-
};
|
|
116
111
|
c.evt.on("onCreated", () => {
|
|
117
|
-
if (c.counter) {
|
|
118
|
-
c.counter.onChange(fn, true);
|
|
119
|
-
}
|
|
120
112
|
if (c.controlParams.cascadeselect) {
|
|
121
113
|
cascadeSelect.value = true;
|
|
122
114
|
}
|
|
@@ -687,16 +679,11 @@ const TreeControl = /* @__PURE__ */ vue.defineComponent({
|
|
|
687
679
|
});
|
|
688
680
|
const renderCounter = (nodeModel) => {
|
|
689
681
|
if (nodeModel.counterId) {
|
|
690
|
-
const value = counterData
|
|
691
|
-
if (ramda.isNil(value)) {
|
|
692
|
-
return null;
|
|
693
|
-
}
|
|
694
|
-
if (nodeModel.counterMode === 1 && value === 0) {
|
|
695
|
-
return null;
|
|
696
|
-
}
|
|
682
|
+
const value = c.state.counterData[nodeModel.counterId];
|
|
697
683
|
return vue.createVNode(vue.resolveComponent("iBizBadge"), {
|
|
684
|
+
"value": value,
|
|
698
685
|
"class": ns.e("counter"),
|
|
699
|
-
"
|
|
686
|
+
"counterMode": nodeModel.counterMode
|
|
700
687
|
}, null);
|
|
701
688
|
}
|
|
702
689
|
};
|
package/lib/locale/en/index.cjs
CHANGED
|
@@ -767,6 +767,16 @@ var index = {
|
|
|
767
767
|
successImport: "Number of successful imports: ",
|
|
768
768
|
ImportFailed: "Number of import failures: "
|
|
769
769
|
},
|
|
770
|
+
asyncActionResult: {
|
|
771
|
+
noMessage: "No content",
|
|
772
|
+
taskName: "Task Name:",
|
|
773
|
+
taskState: "Task Status:",
|
|
774
|
+
finished: "Completed",
|
|
775
|
+
processing: "Processing",
|
|
776
|
+
beginTime: "Start Execution Time:",
|
|
777
|
+
endTime: "End Execution Time:",
|
|
778
|
+
exeResult: "Execution Result:"
|
|
779
|
+
},
|
|
770
780
|
asyncDataExport: {
|
|
771
781
|
exportDetailPrompt: "Export data details-{name}",
|
|
772
782
|
excuteTime: "Execution time",
|
|
@@ -763,6 +763,16 @@ var index = {
|
|
|
763
763
|
successImport: "\u6210\u529F\u5BFC\u5165\u6570: ",
|
|
764
764
|
ImportFailed: "\u5BFC\u5165\u5931\u8D25\u6570: "
|
|
765
765
|
},
|
|
766
|
+
asyncActionResult: {
|
|
767
|
+
noMessage: "\u65E0\u5904\u7406\u5185\u5BB9",
|
|
768
|
+
taskName: "\u4EFB\u52A1\u540D\u79F0:",
|
|
769
|
+
taskState: "\u4EFB\u52A1\u72B6\u6001:",
|
|
770
|
+
finished: "\u5DF2\u5B8C\u6210",
|
|
771
|
+
processing: "\u6267\u884C\u4E2D",
|
|
772
|
+
beginTime: "\u5F00\u59CB\u6267\u884C\u65F6\u95F4:",
|
|
773
|
+
endTime: "\u7ED3\u675F\u6267\u884C\u65F6\u95F4:",
|
|
774
|
+
exeResult: "\u6267\u884C\u7ED3\u679C:"
|
|
775
|
+
},
|
|
766
776
|
asyncDataExport: {
|
|
767
777
|
exportDetailPrompt: "\u5BFC\u51FA\u6570\u636E\u8BE6\u60C5-{name}",
|
|
768
778
|
excuteTime: "\u6267\u884C\u65F6\u95F4",
|