@ibiz-template/vue3-components 0.7.41-alpha.147 → 0.7.41-alpha.149
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-BRBBeU_2.js +339 -0
- package/dist/{index.es-CSMb33DK.js → index.es-BezvNJVH.js} +1 -1
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/{wang-editor-LyrHDNOt.js → wang-editor-9d2x6WBQ.js} +1 -1
- package/dist/{xlsx-util-DcIFyyjA.js → xlsx-util-Dr9uwITS.js} +1 -1
- package/es/common/back-top/back-top.css +1 -1
- package/es/common/control-navigation/control-navigation.css +1 -1
- package/es/common/no-data/no-data.css +1 -1
- package/es/common/no-data/no-data.mjs +1 -1
- package/es/control/dashboard/portlet/portlet-layout/portlet-layout.mjs +8 -5
- package/es/control/data-view/data-view.mjs +7 -6
- package/es/control/drtab/drtab-control.util.mjs +1 -1
- package/es/control/exp-bar/index.mjs +1 -0
- package/es/control/index.mjs +1 -0
- package/es/control/tree/el-tree-util.mjs +4 -16
- package/es/editor/ai-chat/embed-ai-chat/embed-ai-chat.mjs +0 -11
- package/es/index.mjs +1 -0
- package/es/panel-component/panel-app-title/panel-app-title.controller.mjs +2 -0
- package/es/util/ai-chat-util/ai-chat-util.mjs +17 -0
- package/es/util/fullscreen/fullscreen-util.mjs +1 -1
- package/lib/common/back-top/back-top.css +1 -1
- package/lib/common/control-navigation/control-navigation.css +1 -1
- package/lib/common/no-data/no-data.cjs +1 -1
- package/lib/common/no-data/no-data.css +1 -1
- package/lib/control/dashboard/portlet/portlet-layout/portlet-layout.cjs +8 -5
- package/lib/control/data-view/data-view.cjs +7 -6
- package/lib/control/drtab/drtab-control.util.cjs +1 -1
- package/lib/control/exp-bar/index.cjs +3 -0
- package/lib/control/index.cjs +3 -0
- package/lib/control/tree/el-tree-util.cjs +3 -15
- package/lib/editor/ai-chat/embed-ai-chat/embed-ai-chat.cjs +0 -11
- package/lib/index.cjs +5 -2
- package/lib/panel-component/panel-app-title/panel-app-title.controller.cjs +2 -0
- package/lib/util/ai-chat-util/ai-chat-util.cjs +17 -0
- package/lib/util/fullscreen/fullscreen-util.cjs +1 -1
- package/package.json +6 -6
- package/src/common/back-top/back-top.scss +3 -3
- package/src/common/control-navigation/control-navigation.scss +2 -1
- package/src/common/no-data/no-data.scss +1 -1
- package/src/common/no-data/no-data.tsx +2 -1
- package/src/control/dashboard/portlet/portlet-layout/portlet-layout.tsx +16 -4
- package/src/control/data-view/data-view.tsx +7 -7
- package/src/control/exp-bar/index.ts +1 -0
- package/src/control/tree/el-tree-util.ts +7 -24
- package/src/editor/ai-chat/embed-ai-chat/embed-ai-chat.tsx +0 -13
- package/src/panel-component/panel-app-title/panel-app-title.controller.ts +1 -0
- package/src/util/ai-chat-util/ai-chat-util.ts +20 -0
- package/dist/index-BAfdAw1V.js +0 -339
- /package/es/node_modules/.pnpm/{@ibiz-template_core@0.7.41-alpha.147_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.41-alpha.150_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.mjs +0 -0
- /package/lib/node_modules/.pnpm/{@ibiz-template_core@0.7.41-alpha.147_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.41-alpha.150_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.cjs +0 -0
|
@@ -70,24 +70,33 @@ export const PortletLayout = defineComponent({
|
|
|
70
70
|
// 部件绘制器
|
|
71
71
|
const controlRenders = c.dashboard.model.controlRenders;
|
|
72
72
|
|
|
73
|
+
// 有dashboard_前缀的为实体数据看板门户部件,没有前缀的为应用数据看板门户部件
|
|
73
74
|
// 头部绘制器
|
|
74
75
|
const header = controlRenders?.find(
|
|
75
|
-
item =>
|
|
76
|
+
item =>
|
|
77
|
+
`dashboard_${item.id}` === `${c.model.name}_header` ||
|
|
78
|
+
`${item.id}` === `${c.model.name}_header`,
|
|
76
79
|
);
|
|
77
80
|
|
|
78
81
|
// 头部标题绘制器
|
|
79
82
|
const headerCaption = controlRenders?.find(
|
|
80
|
-
item =>
|
|
83
|
+
item =>
|
|
84
|
+
`dashboard_${item.id}` === `${c.model.name}_header_caption` ||
|
|
85
|
+
`${item.id}` === `${c.model.name}_header_caption`,
|
|
81
86
|
);
|
|
82
87
|
|
|
83
88
|
// 头部背景绘制器
|
|
84
89
|
const headerBg = controlRenders?.find(
|
|
85
|
-
item =>
|
|
90
|
+
item =>
|
|
91
|
+
`dashboard_${item.id}` === `${c.model.name}_header_bg` ||
|
|
92
|
+
`${item.id}` === `${c.model.name}_header_bg`,
|
|
86
93
|
);
|
|
87
94
|
|
|
88
95
|
// 头部行为组绘制器
|
|
89
96
|
const headerAction = controlRenders?.find(
|
|
90
|
-
item =>
|
|
97
|
+
item =>
|
|
98
|
+
`dashboard_${item.id}` === `${c.model.name}_header_action` ||
|
|
99
|
+
`${item.id}` === `${c.model.name}_header_action`,
|
|
91
100
|
);
|
|
92
101
|
|
|
93
102
|
// 渲染绘制器内容
|
|
@@ -97,6 +106,9 @@ export const PortletLayout = defineComponent({
|
|
|
97
106
|
{
|
|
98
107
|
params: c.params,
|
|
99
108
|
context: c.context,
|
|
109
|
+
controller: props.controller,
|
|
110
|
+
ctrl: props.controller.dashboard,
|
|
111
|
+
view: props.controller.dashboard.view,
|
|
100
112
|
},
|
|
101
113
|
model.layoutPanelModel,
|
|
102
114
|
{ isAsync: false },
|
|
@@ -1087,14 +1087,14 @@ export const DataViewControl = defineComponent({
|
|
|
1087
1087
|
controller={this.c}
|
|
1088
1088
|
>
|
|
1089
1089
|
{this.renderLayoutByStyle()}
|
|
1090
|
-
{this.c.state.isLoaded && this.c.showScrollTo !== 'none' && (
|
|
1091
|
-
<iBizBackTop
|
|
1092
|
-
target={this.infiniteScroll}
|
|
1093
|
-
mode={this.c.showScrollTo}
|
|
1094
|
-
{...this.renderAttrs()}
|
|
1095
|
-
/>
|
|
1096
|
-
)}
|
|
1097
1090
|
</iBizControlBase>
|
|
1091
|
+
{this.c.state.isLoaded && this.c.showScrollTo !== 'none' && (
|
|
1092
|
+
<iBizBackTop
|
|
1093
|
+
target={this.infiniteScroll}
|
|
1094
|
+
mode={this.c.showScrollTo}
|
|
1095
|
+
{...this.renderAttrs()}
|
|
1096
|
+
/>
|
|
1097
|
+
)}
|
|
1098
1098
|
</iBizControlNavigation>
|
|
1099
1099
|
);
|
|
1100
1100
|
},
|
|
@@ -4,7 +4,6 @@ import {
|
|
|
4
4
|
IControlProvider,
|
|
5
5
|
ITreeController,
|
|
6
6
|
ITreeNodeData,
|
|
7
|
-
ScriptFactory,
|
|
8
7
|
TreeController,
|
|
9
8
|
} from '@ibiz-template/runtime';
|
|
10
9
|
import { IControlRender, IDETree, IPanel } from '@ibiz/model-core';
|
|
@@ -266,6 +265,7 @@ export function findChildItems(
|
|
|
266
265
|
* @return {*} {(IPanel | undefined)}
|
|
267
266
|
*/
|
|
268
267
|
export function getNodeControlPanel(control: {
|
|
268
|
+
appId: string;
|
|
269
269
|
controlRenders?: IControlRender[];
|
|
270
270
|
}): IPanel | undefined {
|
|
271
271
|
if (control.controlRenders) {
|
|
@@ -273,7 +273,7 @@ export function getNodeControlPanel(control: {
|
|
|
273
273
|
const controlRenders = control.controlRenders.filter(
|
|
274
274
|
item => (item.id || '').split('_')[0] !== 'newnoderender',
|
|
275
275
|
);
|
|
276
|
-
return getControlPanel({ controlRenders });
|
|
276
|
+
return getControlPanel({ controlRenders, appId: control.appId });
|
|
277
277
|
}
|
|
278
278
|
}
|
|
279
279
|
|
|
@@ -289,30 +289,13 @@ export function getNewNodeControlPanel(control: {
|
|
|
289
289
|
controlRenders?: IControlRender[];
|
|
290
290
|
}): IPanel | undefined {
|
|
291
291
|
if (control.controlRenders) {
|
|
292
|
-
//
|
|
292
|
+
// 查找新建节点内容绘制器
|
|
293
293
|
const controlRender = control.controlRenders.find(
|
|
294
|
-
item =>
|
|
294
|
+
item =>
|
|
295
|
+
(item.id || '').split('_')[0] === 'newnoderender' &&
|
|
296
|
+
item.renderType === 'LAYOUTPANEL',
|
|
295
297
|
);
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
if (
|
|
299
|
-
controlRender.renderType === 'LAYOUTPANEL_MODEL' &&
|
|
300
|
-
controlRender.layoutPanelModel
|
|
301
|
-
) {
|
|
302
|
-
const layoutPanelModel = ScriptFactory.execScriptFn(
|
|
303
|
-
{},
|
|
304
|
-
controlRender.layoutPanelModel,
|
|
305
|
-
{ isAsync: false },
|
|
306
|
-
) as IPanel;
|
|
307
|
-
return layoutPanelModel;
|
|
308
|
-
}
|
|
309
|
-
|
|
310
|
-
if (
|
|
311
|
-
controlRender.renderType === 'LAYOUTPANEL' &&
|
|
312
|
-
controlRender.layoutPanel
|
|
313
|
-
) {
|
|
314
|
-
return controlRender.layoutPanel;
|
|
315
|
-
}
|
|
298
|
+
return controlRender?.layoutPanel;
|
|
316
299
|
}
|
|
317
300
|
}
|
|
318
301
|
|
|
@@ -36,7 +36,6 @@ export const IBizEmbedAIChat = defineComponent({
|
|
|
36
36
|
const ctrl = c.ctrl as EditFormController;
|
|
37
37
|
const agentMap: Map<string | undefined, IData[]> = new Map();
|
|
38
38
|
const knowledgeMap: Map<string | undefined, IData[]> = new Map();
|
|
39
|
-
const projectMap: Map<string | undefined, IData[]> = new Map();
|
|
40
39
|
// AI聊天框挂载元素
|
|
41
40
|
const aiChatElementRef: Ref<HTMLElement | null> = ref(null);
|
|
42
41
|
let mountedFlag: boolean = false;
|
|
@@ -173,18 +172,6 @@ export const IBizEmbedAIChat = defineComponent({
|
|
|
173
172
|
if (knowledge) knowledgeMap.set(key, knowledge);
|
|
174
173
|
return knowledge;
|
|
175
174
|
},
|
|
176
|
-
fetchProject: async (
|
|
177
|
-
ctx: IContext,
|
|
178
|
-
param: IParams,
|
|
179
|
-
other: IParams,
|
|
180
|
-
) => {
|
|
181
|
-
const key = JSON.stringify(other);
|
|
182
|
-
let projects = projectMap.get(key);
|
|
183
|
-
if (projects?.length) return projects;
|
|
184
|
-
projects = await chatOptions.fetchProject(ctx, param, other);
|
|
185
|
-
if (projects) projectMap.set(key, projects);
|
|
186
|
-
return projects;
|
|
187
|
-
},
|
|
188
175
|
action: (action: string, message: IData) => {
|
|
189
176
|
if (action === 'send')
|
|
190
177
|
ctrl.evt.emit('onFormDetailEvent', {
|
|
@@ -107,6 +107,7 @@ export class PanelAppTitleController extends PanelItemController<IPanelRawItem>
|
|
|
107
107
|
if (defaultApp.model.appId === indexViewModel.appId) {
|
|
108
108
|
// 环境变量中的系统标题权重最大
|
|
109
109
|
if (ibiz.env.AppTitle) this.state.caption = ibiz.env.AppTitle;
|
|
110
|
+
if (ibiz.env.AppSubTitle) this.state.subCaption = ibiz.env.AppSubTitle;
|
|
110
111
|
}
|
|
111
112
|
}
|
|
112
113
|
|
|
@@ -125,6 +125,12 @@ export class AIChatUtil implements IApiAIChatUtil {
|
|
|
125
125
|
if (editorParams.srfworkmode) {
|
|
126
126
|
topicOptions.workMode = editorParams.srfworkmode;
|
|
127
127
|
}
|
|
128
|
+
// 编辑器参数srfdisableselectscope,禁用会话域选择,仅适用于工作模式为'WORKSPACE'
|
|
129
|
+
topicOptions.disableSelectScope = ibiz.config.common.aiDisableSelectScope;
|
|
130
|
+
if (editorParams.srfdisableselectscope) {
|
|
131
|
+
topicOptions.disableSelectScope =
|
|
132
|
+
editorParams.srfdisableselectscope === 'true';
|
|
133
|
+
}
|
|
128
134
|
// 编辑器参数srfscopecodelistid,用于修正会话域源数据(代码表标识)
|
|
129
135
|
let scopeCodeListId = editorParams.srfscopecodelistid;
|
|
130
136
|
if (!scopeCodeListId) {
|
|
@@ -760,6 +766,10 @@ export class AIChatUtil implements IApiAIChatUtil {
|
|
|
760
766
|
...headers,
|
|
761
767
|
'Content-Type': 'multipart/form-data',
|
|
762
768
|
},
|
|
769
|
+
params: {
|
|
770
|
+
// 时间戳加随机数,防止请求合并
|
|
771
|
+
timestamp: `${Date.now()}-${Math.floor(Math.random() * 10000)}`,
|
|
772
|
+
},
|
|
763
773
|
data: formData,
|
|
764
774
|
onUploadProgress: (progressEvent: AxiosProgressEvent) => {
|
|
765
775
|
const percent = (progressEvent.loaded / progressEvent.total!) * 100;
|
|
@@ -964,6 +974,12 @@ export class AIChatUtil implements IApiAIChatUtil {
|
|
|
964
974
|
topicOptions.workMode = params.srfworkmode;
|
|
965
975
|
delete params.srfworkmode;
|
|
966
976
|
}
|
|
977
|
+
// 视图参数srfdisableselectscope,禁用会话域选择,仅适用于工作模式为'WORKSPACE'
|
|
978
|
+
topicOptions.disableSelectScope = ibiz.config.common.aiDisableSelectScope;
|
|
979
|
+
if (params.srfdisableselectscope) {
|
|
980
|
+
topicOptions.disableSelectScope = params.srfdisableselectscope === 'true';
|
|
981
|
+
delete params.srfdisableselectscope;
|
|
982
|
+
}
|
|
967
983
|
// 视图参数srfscopecodelistid,用于修正会话域源数据(代码表标识)
|
|
968
984
|
let scopeCodeListId = params.srfscopecodelistid;
|
|
969
985
|
if (!scopeCodeListId) {
|
|
@@ -1628,6 +1644,10 @@ export class AIChatUtil implements IApiAIChatUtil {
|
|
|
1628
1644
|
...headers,
|
|
1629
1645
|
'Content-Type': 'multipart/form-data',
|
|
1630
1646
|
},
|
|
1647
|
+
params: {
|
|
1648
|
+
// 时间戳加随机数,防止请求合并
|
|
1649
|
+
timestamp: `${Date.now()}-${Math.floor(Math.random() * 10000)}`,
|
|
1650
|
+
},
|
|
1631
1651
|
data: formData,
|
|
1632
1652
|
onUploadProgress: (progressEvent: AxiosProgressEvent) => {
|
|
1633
1653
|
const percent = (progressEvent.loaded / progressEvent.total!) * 100;
|