@epxing/business 5.3.0-beta.2 → 5.3.0-beta.3
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/API.md +8 -4
- package/README.md +44 -44
- package/dist/src/base/AiSkillEditor.js +1 -1
- package/dist/src/base/AiSkillEditor.vue.js +2 -0
- package/dist/src/base/AppConfigFormItem.js +1 -3
- package/dist/src/base/AppConfigFormItem.vue.js +210 -85
- package/dist/src/base/CommonFieldList.js +1 -1
- package/dist/src/base/CommonFieldList.vue.js +2 -1
- package/dist/src/base/ConfigModuleIndex.js +38 -1
- package/dist/src/base/ManageAppNav.js +1 -1
- package/dist/src/base/ManageMenu.js +1 -1
- package/dist/src/base/RoleBindTrace.js +253 -0
- package/dist/src/base/RoleGroupManage.js +1037 -0
- package/dist/src/base/ServiceMenu.js +7 -6
- package/dist/src/components/AiList.js +1278 -3
- package/dist/src/components/EntityCheckboxFind.vue.js +14 -10
- package/dist/src/components/EntityRightFormItem.js +1 -5
- package/dist/src/components/EntityRightFormItem.vue.js +3 -1
- package/dist/src/components/EntitySystemEr.js +492 -0
- package/dist/src/components/HallNav.vue.js +7 -36
- package/dist/src/components/IconFontLibrary.js +22 -1
- package/dist/src/components/IconFontList.js +21 -1
- package/dist/src/components/PrintFormList.js +2 -1
- package/dist/src/components/PrintFormList.vue.js +3 -1
- package/dist/src/components/WikiWorkbench.js +153 -129
- package/dist/src/components/authorization/AuthorizationInterface.js +3 -1
- package/dist/src/components/custom-bpmn/PropertiesView.js +1991 -1942
- package/dist/src/components/icon-gallery/IconGallery.js +193 -0
- package/dist/src/components/icon-gallery/mixin.js +150 -0
- package/dist/src/components/wiki-workbench/WikiIntake.js +86 -93
- package/dist/src/components/wiki-workbench/WikiIntake.vue.js +153 -73
- package/dist/src/index.js +26 -20
- package/dist/src/public-components.js +16 -14
- package/dist/src/route-components.js +5 -5
- package/dist/src/system.component.index.js +1 -1
- package/dist/src/system.component.js +8 -3
- package/dist/src/system.component.lazy.js +1 -1
- package/dist/src/views/Add.js +1 -1
- package/dist/src/views/Add.vue.js +8 -3
- package/dist/src/views/AiToolManager.js +792 -317
- package/dist/src/views/App.js +3 -45
- package/dist/src/views/AppRoleSelect.js +3 -230
- package/dist/src/views/Error.js +3 -207
- package/dist/src/views/ExcelDesign.js +326 -316
- package/dist/src/views/JvmMemoryMonitor.js +463 -0
- package/dist/src/views/Module.js +3 -170
- package/dist/src/views/WikiBinding.js +88 -25
- package/dist/style.css +2867 -1487
- package/package.json +12 -6
- package/src/base/AiSkillEditor.vue +2 -0
- package/src/base/AppConfigFormItem.vue +211 -145
- package/src/base/CommonFieldList.vue +9 -6
- package/src/base/ConfigModuleIndex.vue +37 -1
- package/src/base/ManageAppNav.vue +1188 -1188
- package/src/base/ManageMenu.vue +933 -933
- package/src/base/RoleBindTrace.vue +364 -0
- package/src/base/RoleGroupManage.vue +1160 -0
- package/src/base/ServiceMenu.vue +6 -5
- package/src/components/AiList.vue +439 -113
- package/src/components/EntityCheckboxFind.vue +12 -8
- package/src/components/EntityRightFormItem.vue +9 -10
- package/src/components/EntitySystemEr.vue +517 -0
- package/src/components/HallNav.vue +6 -33
- package/src/components/IconFontLibrary.vue +27 -60
- package/src/components/IconFontList.vue +13 -64
- package/src/components/PrintFormList.vue +33 -27
- package/src/components/WikiWorkbench.vue +90 -60
- package/src/components/authorization/AuthorizationInterface.vue +2 -0
- package/src/components/custom-bpmn/CustomPalette.js +1 -1
- package/src/components/custom-bpmn/CustomRenderer.js +1 -1
- package/src/components/custom-bpmn/PropertiesView.vue +35 -4
- package/src/components/custom-bpmn/index.js +1 -1
- package/src/components/icon-gallery/IconGallery.vue +130 -0
- package/src/components/icon-gallery/mixin.jsx +109 -0
- package/src/components/wiki-workbench/WikiIntake.vue +178 -104
- package/src/index.js +24 -20
- package/src/public-components.js +1 -0
- package/src/route-components.js +4 -4
- package/src/system.component.index.js +1 -1
- package/src/views/Add.vue +8 -5
- package/src/views/AiToolManager.vue +326 -4
- package/src/views/App.vue +4 -53
- package/src/views/AppRoleSelect.vue +4 -334
- package/src/views/Error.vue +4 -63
- package/src/views/ExcelDesign.vue +24 -7
- package/src/views/JvmMemoryMonitor.vue +284 -0
- package/src/views/Module.vue +4 -210
- package/src/views/WikiBinding.vue +42 -0
- package/types/app.d.ts +1 -0
- package/types/dept-find.d.ts +1 -1
- package/types/index.d.ts +15 -14
- package/types/popup.d.ts +2 -2
- package/types/route-components.d.ts +1 -1
- package/types/user-find.d.ts +1 -1
- package/dist/assets/role_select-DTqRlFNz.webp +0 -0
- package/dist/src/components/AiList.vue.js +0 -93
- package/dist/src/components/IconFontLibrary.vue.js +0 -67
- package/dist/src/components/IconFontList.vue.js +0 -79
package/API.md
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
系统业务页面、人员/部门选择器、页面目录和报表组件。
|
|
4
4
|
|
|
5
|
-
本页对应包版本 `5.3.0-beta.
|
|
5
|
+
本页对应包版本 `5.3.0-beta.3`。导出名、子路径和签名从当前源码、package.json 与类型声明生成。
|
|
6
6
|
|
|
7
7
|
## 安装与使用
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
```sh
|
|
11
|
-
pnpm add @epxing/business@5.3.0-beta.
|
|
11
|
+
pnpm add @epxing/business@5.3.0-beta.3
|
|
12
12
|
```
|
|
13
13
|
|
|
14
14
|
|
|
@@ -22,7 +22,7 @@ app.component('ProductUserFind', UserFind)
|
|
|
22
22
|
|
|
23
23
|
## 接入约定
|
|
24
24
|
|
|
25
|
-
业务组件依赖核心服务、基础组件和服务端元数据/权限。根 default
|
|
25
|
+
业务组件依赖核心服务、基础组件和服务端元数据/权限。根 default 插件负责系统业务组件、弹层和路由映射注册。平台系统入口使用 createApp({ router: createFrameRouter() }) 并安装 Components、Business 和产品插件;其中 App 可从本包根入口或 @epxing/business/app 导入,用于系统视图定制,不直接作为最外层根组件。只使用具名组件时,产品仍需准备该组件实际使用的服务与子组件。远程产品的共享入口支持公开组件;宿主负责安装业务插件。
|
|
26
26
|
|
|
27
27
|
本版 JS 入口自动加载本包聚合样式,根导入和稳定子路径均无需手动 import style.css;保留显式样式入口以兼容旧代码。样式按包加载,产品覆盖样式放在框架导入之后。
|
|
28
28
|
|
|
@@ -31,6 +31,7 @@ app.component('ProductUserFind', UserFind)
|
|
|
31
31
|
| 导出名 | 形态 | 用途 | 参数 / 配置 / 事件 |
|
|
32
32
|
| --- | --- | --- | --- |
|
|
33
33
|
| `UserFind` | Vue 组件 | 人员选择器,用于选择用户并按组件协议回填标识和显示标签。 | [详细参考](../../docs/revision/business/components/UserFind.md) |
|
|
34
|
+
| `App` | Vue 组件 | 平台系统路由视图,在应用配置加载后读取 FIRST_PAGE / MOBILE_FIRST_PAGE 并显示首页。由 Business 注册给平台路由,不是最外层路由根组件。 | [详细参考](../../docs/revision/business/views/App.md) |
|
|
34
35
|
| `DeptFind` | Vue 组件 | 部门选择器,用于组织部门的查找、选择和回填。 | [详细参考](../../docs/revision/business/components/DeptFind.md) |
|
|
35
36
|
| `HeaderNav` | Vue 组件 | 应用顶部导航组件,展示应用和菜单导航入口。 | [详细参考](../../docs/revision/business/components/HeaderNav.md) |
|
|
36
37
|
| `EntityTreeManage` | Vue 组件 | 实体树管理组件,组合分类树、实体查询和管理操作。 | [详细参考](../../docs/revision/business/components/EntityTreeManage.md) |
|
|
@@ -49,6 +50,8 @@ app.component('ProductUserFind', UserFind)
|
|
|
49
50
|
|
|
50
51
|
### routeComponents
|
|
51
52
|
|
|
53
|
+
基础页面 App、Module、AppRoleSelect、Error 由 core 提供;此处保留映射兼容,并补充 QyWechat、Task、HelpDocSet。未使用这些业务页面时无需安装 business。
|
|
54
|
+
|
|
52
55
|
业务层路由页面映射,供核心路由解析使用。
|
|
53
56
|
|
|
54
57
|
通过 `routeComponents.成员名` 访问,下面的成员不是额外的根具名导出。
|
|
@@ -56,7 +59,7 @@ app.component('ProductUserFind', UserFind)
|
|
|
56
59
|
| 成员名 | 用途 | 配置参考 |
|
|
57
60
|
| --- | --- | --- |
|
|
58
61
|
| `QyWechat` | 企业微信接入页面,承载对应客户端的认证与跳转流程。 | [详细参考](../../docs/revision/business/views/QyWechat.md) |
|
|
59
|
-
| `App` |
|
|
62
|
+
| `App` | 平台系统路由视图,在应用配置加载后读取 FIRST_PAGE / MOBILE_FIRST_PAGE 并显示首页。由 Business 注册给平台路由,不是最外层路由根组件。 | [详细参考](../../docs/revision/business/views/App.md) |
|
|
60
63
|
| `Module` | 平台模块容器页面,承载模块中的业务内容。 | [详细参考](../../docs/revision/business/views/Module.md) |
|
|
61
64
|
| `AppRoleSelect` | 应用角色选择页面,供用户选择进入应用时使用的角色。 | [详细参考](../../docs/revision/business/views/AppRoleSelect.md) |
|
|
62
65
|
| `Task` | 平台任务页面,展示和处理任务相关内容。 | [详细参考](../../docs/revision/business/views/TaskPage.md) |
|
|
@@ -69,6 +72,7 @@ app.component('ProductUserFind', UserFind)
|
|
|
69
72
|
|
|
70
73
|
| 导入路径 | 完整导出名 | 用途 / 详细说明 |
|
|
71
74
|
| --- | --- | --- |
|
|
75
|
+
| `@epxing/business/app` | `default` | 平台系统路由视图,在应用配置加载后读取 FIRST_PAGE / MOBILE_FIRST_PAGE 并显示首页。由 Business 注册给平台路由,不是最外层路由根组件。 [详细参考](../../docs/revision/business/views/App.md) |
|
|
72
76
|
| `@epxing/business/user-find` | `default` | 人员选择器,用于选择用户并按组件协议回填标识和显示标签。 [详细参考](../../docs/revision/business/components/UserFind.md) |
|
|
73
77
|
| `@epxing/business/dept-find` | `default` | 部门选择器,用于组织部门的查找、选择和回填。 [详细参考](../../docs/revision/business/components/DeptFind.md) |
|
|
74
78
|
| `@epxing/business/popup` | `default` | 默认导出弹层安装函数 (app),用 app.use(PopupInstall) 安装 $popup;与主应用共享上下文。 [详细参考](../../docs/revision/business/api/popup.md) |
|
package/README.md
CHANGED
|
@@ -1,44 +1,44 @@
|
|
|
1
|
-
# @epxing/business
|
|
2
|
-
|
|
3
|
-
[完整公开 API、导入方式与示例](./API.md)
|
|
4
|
-
|
|
5
|
-
从 5.3.0-beta.2 起,导入本包 JS 时自动加载包级样式,根入口和稳定子路径均无需手动引入 style.css。显式样式入口继续兼容旧代码;产品覆盖样式放在框架导入之后。
|
|
6
|
-
|
|
7
|
-
平台业务组件包。产品可继承 UserFind、EntityTreeManage 等业务组件,整包安装时补充平台业务视图与 popup。
|
|
8
|
-
|
|
9
|
-
## 范围
|
|
10
|
-
|
|
11
|
-
- `src/frame/components/` 业务组件(authorization / permiss / UserManage 等)
|
|
12
|
-
- `src/frame/base/` 平台基础组件(AppMarket / ClientApplication / 角色权限 等)
|
|
13
|
-
- `src/frame/views/` 运行时业务页面(App / Module / Container / Login / Error / EntityListPage 等)
|
|
14
|
-
- `src/frame/views/client/` / `src/frame/views/layout/`
|
|
15
|
-
|
|
16
|
-
## 依赖
|
|
17
|
-
|
|
18
|
-
- `@epxing/utils`
|
|
19
|
-
- `@epxing/theme`
|
|
20
|
-
- `@epxing/core`
|
|
21
|
-
- `@epxing/components`
|
|
22
|
-
|
|
23
|
-
## 状态
|
|
24
|
-
|
|
25
|
-
已提供公共根入口、稳定组件子路径和类型声明。
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
## 独立包公共入口(2026-10-22)
|
|
29
|
-
|
|
30
|
-
根入口及稳定子路径提供类型声明。先安装 core 与需要的 component,再按需安装本包。
|
|
31
|
-
|
|
32
|
-
```js
|
|
33
|
-
import { UserFind, DeptFind, EntityTreeManage, HeaderNav } from '@epxing/business'
|
|
34
|
-
import EntityTreeManageDefault from '@epxing/business/entity-tree-manage'
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
还提供 PageCatalog、ReportFormList、ReportFormListPage、ExcelPreviewPage。远程产品可共享这些单件,整包安装由宿主负责。使用与迁移说明见 `docs/guide/getting-started/packages.md`。
|
|
38
|
-
|
|
39
|
-
```js
|
|
40
|
-
import plugin from '@epxing/business'
|
|
41
|
-
app.use(plugin)
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
工作区构建:`pnpm --filter @epxing/business build`。pack/publish 的 prepack 会重建;版本由 Changesets 独立管理。旧 `/src/*` 入口保留。完整初始化、打包与远程共享流程见 docs/build-and-publish.md。
|
|
1
|
+
# @epxing/business
|
|
2
|
+
|
|
3
|
+
[完整公开 API、导入方式与示例](./API.md)
|
|
4
|
+
|
|
5
|
+
从 5.3.0-beta.2 起,导入本包 JS 时自动加载包级样式,根入口和稳定子路径均无需手动引入 style.css。显式样式入口继续兼容旧代码;产品覆盖样式放在框架导入之后。
|
|
6
|
+
|
|
7
|
+
平台业务组件包。产品可继承 UserFind、EntityTreeManage 等业务组件,整包安装时补充平台业务视图与 popup。
|
|
8
|
+
|
|
9
|
+
## 范围
|
|
10
|
+
|
|
11
|
+
- `src/frame/components/` 业务组件(authorization / permiss / UserManage 等)
|
|
12
|
+
- `src/frame/base/` 平台基础组件(AppMarket / ClientApplication / 角色权限 等)
|
|
13
|
+
- `src/frame/views/` 运行时业务页面(App / Module / Container / Login / Error / EntityListPage 等)
|
|
14
|
+
- `src/frame/views/client/` / `src/frame/views/layout/`
|
|
15
|
+
|
|
16
|
+
## 依赖
|
|
17
|
+
|
|
18
|
+
- `@epxing/utils`
|
|
19
|
+
- `@epxing/theme`
|
|
20
|
+
- `@epxing/core`
|
|
21
|
+
- `@epxing/components`
|
|
22
|
+
|
|
23
|
+
## 状态
|
|
24
|
+
|
|
25
|
+
已提供公共根入口、稳定组件子路径和类型声明。
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
## 独立包公共入口(2026-10-22)
|
|
29
|
+
|
|
30
|
+
根入口及稳定子路径提供类型声明。先安装 core 与需要的 component,再按需安装本包。
|
|
31
|
+
|
|
32
|
+
```js
|
|
33
|
+
import { UserFind, DeptFind, EntityTreeManage, HeaderNav } from '@epxing/business'
|
|
34
|
+
import EntityTreeManageDefault from '@epxing/business/entity-tree-manage'
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
还提供 PageCatalog、ReportFormList、ReportFormListPage、ExcelPreviewPage。远程产品可共享这些单件,整包安装由宿主负责。使用与迁移说明见 `docs/guide/getting-started/packages.md`。
|
|
38
|
+
|
|
39
|
+
```js
|
|
40
|
+
import plugin from '@epxing/business'
|
|
41
|
+
app.use(plugin)
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
工作区构建:`pnpm --filter @epxing/business build`。pack/publish 的 prepack 会重建;版本由 Changesets 独立管理。旧 `/src/*` 入口保留。完整初始化、打包与远程共享流程见 docs/build-and-publish.md。
|
|
@@ -1023,7 +1023,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1023
1023
|
}, 8, ["model-value", "onUpdate:modelValue", "functionList", "extendVariable"])) : createCommentVNode("", true)
|
|
1024
1024
|
]);
|
|
1025
1025
|
}
|
|
1026
|
-
const AiSkillEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
1026
|
+
const AiSkillEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-148f13cb"]]);
|
|
1027
1027
|
export {
|
|
1028
1028
|
AiSkillEditor as default
|
|
1029
1029
|
};
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import '../../style.css';
|
|
2
2
|
import _sfc_main from "./AppConfigFormItem.vue.js";
|
|
3
3
|
/* empty css */
|
|
4
|
-
import _export_sfc from "../../_virtual/_plugin-vue_export-helper.js";
|
|
5
|
-
const AppConfigFormItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-7e3ef531"]]);
|
|
6
4
|
export {
|
|
7
|
-
|
|
5
|
+
_sfc_main as default
|
|
8
6
|
};
|
|
@@ -2,23 +2,61 @@ import __cjsReq7 from "../assets/images/nav/0.png.js";
|
|
|
2
2
|
import __cjsReq6 from "../assets/images/nav/1.png.js";
|
|
3
3
|
import __cjsReq8 from "../assets/images/nav/2.png.js";
|
|
4
4
|
import __cjsReq9 from "../assets/images/nav/3.svg.js";
|
|
5
|
-
import { createVNode, resolveComponent, isVNode } from "vue";
|
|
5
|
+
import { createVNode, resolveComponent, createTextVNode, isVNode } from "vue";
|
|
6
6
|
import AddFormItem from "@epxing/components/src/add-form-item";
|
|
7
|
+
import TableForm from "@epxing/components/src/form";
|
|
8
|
+
import AppSettings from "@epxing/components/src/app-settings/AppSettings.vue";
|
|
9
|
+
import AppAppearancePreview from "@epxing/components/src/app-settings/AppAppearancePreview.vue";
|
|
10
|
+
import { createAppUiDraft } from "@epxing/core/src/app-ui-settings";
|
|
11
|
+
import { captureRef } from "@epxing/core/src/capture-ref";
|
|
7
12
|
function _isSlot(s) {
|
|
8
13
|
return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
|
|
9
14
|
}
|
|
10
15
|
const _sfc_main = {
|
|
11
16
|
name: "epx-base-app-config-form-item",
|
|
12
17
|
extends: AddFormItem,
|
|
18
|
+
components: {
|
|
19
|
+
AppSettings,
|
|
20
|
+
AppAppearancePreview,
|
|
21
|
+
TableForm
|
|
22
|
+
},
|
|
13
23
|
data() {
|
|
14
24
|
return {
|
|
15
25
|
config: {},
|
|
16
|
-
fieldsConfigs: []
|
|
26
|
+
fieldsConfigs: [],
|
|
27
|
+
layoutFieldsConfigs: [],
|
|
28
|
+
activeGroup: "theme",
|
|
29
|
+
uiDraft: {},
|
|
30
|
+
initialConfig: "{}",
|
|
31
|
+
syncingDraft: true,
|
|
32
|
+
settingsGroups: [{
|
|
33
|
+
key: "theme",
|
|
34
|
+
label: "主题与配色"
|
|
35
|
+
}, {
|
|
36
|
+
key: "layout",
|
|
37
|
+
label: "导航与布局"
|
|
38
|
+
}, {
|
|
39
|
+
key: "style",
|
|
40
|
+
label: "界面风格"
|
|
41
|
+
}, {
|
|
42
|
+
key: "tabs",
|
|
43
|
+
label: "页签设置"
|
|
44
|
+
}, {
|
|
45
|
+
key: "page",
|
|
46
|
+
label: "页面与效果"
|
|
47
|
+
}]
|
|
17
48
|
};
|
|
18
49
|
},
|
|
19
50
|
computed: {
|
|
51
|
+
readOnly() {
|
|
52
|
+
return ["DETAIL", "READONLY"].includes(this.componentType);
|
|
53
|
+
},
|
|
20
54
|
showFieldsConfigs() {
|
|
21
|
-
return this.
|
|
55
|
+
return this.layoutFieldsConfigs.filter((item) => {
|
|
56
|
+
const themeKeys = ["navBackgroundColorType", "navBackgroundColor"];
|
|
57
|
+
const pageKeys = ["pageBackgroundType", "pageBackgroundColor", "pageBackgroundGradient", "pageBackgroundImage", "pageBackgroundSize"];
|
|
58
|
+
const group = themeKeys.includes(item.key) ? "theme" : pageKeys.includes(item.key) ? "page" : "layout";
|
|
59
|
+
if (group !== this.activeGroup) return false;
|
|
22
60
|
let flag = true;
|
|
23
61
|
if (item.showFlag) {
|
|
24
62
|
for (const key in item.showFlag) {
|
|
@@ -35,6 +73,7 @@ const _sfc_main = {
|
|
|
35
73
|
watch: {
|
|
36
74
|
config: {
|
|
37
75
|
handler(v) {
|
|
76
|
+
if (this.syncingDraft || this.readOnly) return;
|
|
38
77
|
const APP_CONFIG = JSON.stringify(v);
|
|
39
78
|
this.$emit("change", {
|
|
40
79
|
...this.data,
|
|
@@ -42,6 +81,15 @@ const _sfc_main = {
|
|
|
42
81
|
});
|
|
43
82
|
},
|
|
44
83
|
deep: true
|
|
84
|
+
},
|
|
85
|
+
uiDraft: {
|
|
86
|
+
deep: true,
|
|
87
|
+
handler(value) {
|
|
88
|
+
if (!this.syncingDraft && !this.readOnly) this.config.uiDefaults = JSON.parse(JSON.stringify(value));
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
"formData.APP_CONFIG"(value) {
|
|
92
|
+
if (value !== JSON.stringify(this.config)) this.loadConfig(value);
|
|
45
93
|
}
|
|
46
94
|
},
|
|
47
95
|
methods: {
|
|
@@ -122,6 +170,9 @@ const _sfc_main = {
|
|
|
122
170
|
key: "navBackgroundColor",
|
|
123
171
|
label: "自定义导航背景色",
|
|
124
172
|
type: "color",
|
|
173
|
+
showFlag: {
|
|
174
|
+
navBackgroundColorType: "custom"
|
|
175
|
+
},
|
|
125
176
|
predefineColors: []
|
|
126
177
|
}, {
|
|
127
178
|
key: "navOperates",
|
|
@@ -218,42 +269,6 @@ const _sfc_main = {
|
|
|
218
269
|
type: "number",
|
|
219
270
|
defaultValue: 992
|
|
220
271
|
}];
|
|
221
|
-
if (this.appConfig["SYSTEM|TYPE"] === "hall") {
|
|
222
|
-
fieldsConfigs.splice(9, 0, {
|
|
223
|
-
key: "componentMargin",
|
|
224
|
-
label: "页面组件间距",
|
|
225
|
-
type: "radio",
|
|
226
|
-
options: [{
|
|
227
|
-
label: "小",
|
|
228
|
-
value: "small"
|
|
229
|
-
}, {
|
|
230
|
-
label: "中",
|
|
231
|
-
value: "medium"
|
|
232
|
-
}, {
|
|
233
|
-
label: "默认",
|
|
234
|
-
value: "base"
|
|
235
|
-
}],
|
|
236
|
-
defaultValue: "base"
|
|
237
|
-
}, {
|
|
238
|
-
key: "borderRadius",
|
|
239
|
-
label: "圆角",
|
|
240
|
-
type: "radio",
|
|
241
|
-
options: [{
|
|
242
|
-
label: "无",
|
|
243
|
-
value: "zero"
|
|
244
|
-
}, {
|
|
245
|
-
label: "默认",
|
|
246
|
-
value: "base"
|
|
247
|
-
}, {
|
|
248
|
-
label: "中",
|
|
249
|
-
value: "medium"
|
|
250
|
-
}, {
|
|
251
|
-
label: "大",
|
|
252
|
-
value: "large"
|
|
253
|
-
}],
|
|
254
|
-
defaultValue: "base"
|
|
255
|
-
});
|
|
256
|
-
}
|
|
257
272
|
for (const item of fieldsConfigs) {
|
|
258
273
|
item.state = pageType;
|
|
259
274
|
if (item.options) item.options = item.options.map((item2) => ({
|
|
@@ -263,12 +278,23 @@ const _sfc_main = {
|
|
|
263
278
|
preview: item2.preview
|
|
264
279
|
}));
|
|
265
280
|
}
|
|
266
|
-
this.
|
|
281
|
+
this.layoutFieldsConfigs = fieldsConfigs;
|
|
282
|
+
this.fieldsConfigs = [{
|
|
283
|
+
attriName: "APP_CONFIG",
|
|
284
|
+
state: "HIDDEN"
|
|
285
|
+
}];
|
|
267
286
|
},
|
|
268
287
|
changeConfigItem(key, value) {
|
|
288
|
+
if (this.readOnly) return;
|
|
269
289
|
this.config[key] = value;
|
|
270
290
|
},
|
|
271
291
|
save() {
|
|
292
|
+
var _a;
|
|
293
|
+
if (this.readOnly) return;
|
|
294
|
+
if (((_a = this.form) == null ? void 0 : _a.submitForm) && !this.isEdit) {
|
|
295
|
+
this.$nextTick(() => this.form.submitForm());
|
|
296
|
+
return;
|
|
297
|
+
}
|
|
272
298
|
const params = {};
|
|
273
299
|
const {
|
|
274
300
|
submitParams: querySumitParams = {}
|
|
@@ -276,7 +302,12 @@ const _sfc_main = {
|
|
|
276
302
|
if (this.formData[this.$metaKey]) {
|
|
277
303
|
params[`bean.${this.$metaKey}`] = this.formData[this.$metaKey];
|
|
278
304
|
}
|
|
279
|
-
|
|
305
|
+
Object.entries({
|
|
306
|
+
...this.formData,
|
|
307
|
+
APP_CONFIG: JSON.stringify(this.config)
|
|
308
|
+
}).forEach(([key, value]) => {
|
|
309
|
+
params[`bean.${key}`] = value;
|
|
310
|
+
});
|
|
280
311
|
const {
|
|
281
312
|
componentEvents = {}
|
|
282
313
|
} = this.$configs;
|
|
@@ -298,47 +329,150 @@ const _sfc_main = {
|
|
|
298
329
|
});
|
|
299
330
|
},
|
|
300
331
|
switchNav(value, item) {
|
|
301
|
-
if (item.state
|
|
332
|
+
if (!["DETAIL", "READONLY"].includes(item.state)) {
|
|
302
333
|
this.config[item.key] = value;
|
|
303
334
|
}
|
|
304
335
|
},
|
|
336
|
+
loadConfig(value = "{}") {
|
|
337
|
+
this.syncingDraft = true;
|
|
338
|
+
const config = JSON.parse(value || "{}");
|
|
339
|
+
this.initialConfig = JSON.stringify(config);
|
|
340
|
+
for (const item of this.layoutFieldsConfigs) {
|
|
341
|
+
if (config[item.key] === void 0 && item.defaultValue !== void 0) config[item.key] = item.defaultValue;
|
|
342
|
+
}
|
|
343
|
+
this.config = config;
|
|
344
|
+
this.uiDraft = createAppUiDraft(config);
|
|
345
|
+
this.$nextTick(() => {
|
|
346
|
+
this.syncingDraft = false;
|
|
347
|
+
});
|
|
348
|
+
},
|
|
349
|
+
restorePlatform() {
|
|
350
|
+
if (this.readOnly) return;
|
|
351
|
+
this.uiDraft = createAppUiDraft();
|
|
352
|
+
const businessKeys = ["appPageType", "pageId", "navComponent", "navOperates", "mobileSize"];
|
|
353
|
+
for (const field of this.layoutFieldsConfigs) {
|
|
354
|
+
if (businessKeys.includes(field.key)) continue;
|
|
355
|
+
if (field.defaultValue !== void 0) this.config[field.key] = field.defaultValue;
|
|
356
|
+
else delete this.config[field.key];
|
|
357
|
+
}
|
|
358
|
+
},
|
|
359
|
+
discardDraft() {
|
|
360
|
+
const initial = this.initialConfig;
|
|
361
|
+
this.loadConfig(initial);
|
|
362
|
+
this.$emit("change", {
|
|
363
|
+
...this.data,
|
|
364
|
+
APP_CONFIG: initial
|
|
365
|
+
});
|
|
366
|
+
},
|
|
305
367
|
renderForm() {
|
|
306
|
-
|
|
307
|
-
return createVNode(
|
|
308
|
-
"class": "app-
|
|
309
|
-
|
|
310
|
-
"
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
"
|
|
314
|
-
"
|
|
315
|
-
|
|
316
|
-
|
|
368
|
+
var _a;
|
|
369
|
+
return createVNode("section", {
|
|
370
|
+
"class": "epx-app-interface-settings"
|
|
371
|
+
}, [createVNode("div", {
|
|
372
|
+
"hidden": true
|
|
373
|
+
}, [createVNode(TableForm, {
|
|
374
|
+
"ref": captureRef(this, "form"),
|
|
375
|
+
"fieldsConfigs": this.fieldsConfigs,
|
|
376
|
+
"modelValue": {
|
|
377
|
+
...this.data,
|
|
378
|
+
APP_CONFIG: JSON.stringify(this.config)
|
|
379
|
+
},
|
|
380
|
+
"type": "auto",
|
|
381
|
+
"showRelyFlag": false,
|
|
382
|
+
"valueRelyFlag": false,
|
|
383
|
+
"requiredRelyFlag": false
|
|
384
|
+
}, null)]), createVNode("div", {
|
|
385
|
+
"class": "epx-app-interface-settings__heading"
|
|
386
|
+
}, [createVNode("p", null, [createTextVNode("设置当前应用的默认外观;用户的个人选择优先。右侧预览不会改变当前界面。")])]), createVNode("div", {
|
|
387
|
+
"class": "epx-app-interface-settings__workspace"
|
|
388
|
+
}, [createVNode("nav", {
|
|
389
|
+
"class": "epx-app-interface-settings__nav",
|
|
390
|
+
"aria-label": "界面设置分组"
|
|
391
|
+
}, [this.settingsGroups.map((group) => createVNode("button", {
|
|
392
|
+
"type": "button",
|
|
393
|
+
"key": group.key,
|
|
394
|
+
"class": {
|
|
395
|
+
"is-active": this.activeGroup === group.key
|
|
396
|
+
},
|
|
397
|
+
"aria-current": this.activeGroup === group.key ? "page" : void 0,
|
|
398
|
+
"onClick": () => {
|
|
399
|
+
this.activeGroup = group.key;
|
|
400
|
+
}
|
|
401
|
+
}, [group.label]))]), createVNode("div", {
|
|
402
|
+
"class": "epx-app-interface-settings__editor"
|
|
403
|
+
}, [createVNode("h4", null, [(_a = this.settingsGroups.find((group) => group.key === this.activeGroup)) == null ? void 0 : _a.label]), createVNode(AppSettings, {
|
|
404
|
+
"embedded": true,
|
|
405
|
+
"settings": this.uiDraft,
|
|
406
|
+
"sections": [this.activeGroup],
|
|
407
|
+
"disabled": this.readOnly
|
|
408
|
+
}, null), this.renderLayoutFields()]), createVNode(AppAppearancePreview, {
|
|
409
|
+
"config": this.config,
|
|
410
|
+
"settings": this.uiDraft,
|
|
411
|
+
"title": this.data.NAME || "应用名称"
|
|
412
|
+
}, null)]), !this.readOnly && createVNode("div", {
|
|
413
|
+
"class": "epx-app-interface-settings__actions"
|
|
414
|
+
}, [createVNode(resolveComponent("el-button"), {
|
|
415
|
+
"onClick": this.restorePlatform
|
|
317
416
|
}, {
|
|
318
|
-
default: () => [
|
|
319
|
-
|
|
320
|
-
|
|
417
|
+
default: () => [createTextVNode("恢复平台默认")]
|
|
418
|
+
}), createVNode(resolveComponent("el-button"), {
|
|
419
|
+
"onClick": this.discardDraft
|
|
420
|
+
}, {
|
|
421
|
+
default: () => [createTextVNode("撤销本次修改")]
|
|
422
|
+
}), createVNode(resolveComponent("el-button"), {
|
|
423
|
+
"type": "primary",
|
|
424
|
+
"onClick": this.save
|
|
425
|
+
}, {
|
|
426
|
+
default: () => [createTextVNode("保存")]
|
|
427
|
+
})])]);
|
|
428
|
+
},
|
|
429
|
+
renderLayoutFields() {
|
|
430
|
+
let _slot2;
|
|
431
|
+
return createVNode(resolveComponent("el-form"), {
|
|
432
|
+
"disabled": this.readOnly,
|
|
433
|
+
"class": "epx-base-app-config-form-item__form"
|
|
434
|
+
}, _isSlot(_slot2 = this.showFieldsConfigs.map((item) => {
|
|
435
|
+
let _slot;
|
|
436
|
+
return createVNode("div", {
|
|
437
|
+
"key": item.key,
|
|
438
|
+
"class": ["epx-app-interface-settings__field", {
|
|
439
|
+
"epx-app-interface-settings__field--block": item.block || item.type === "radio"
|
|
321
440
|
}]
|
|
322
|
-
}, [
|
|
441
|
+
}, [createVNode("span", {
|
|
442
|
+
"class": "epx-app-interface-settings__label"
|
|
443
|
+
}, [item.label]), createVNode("div", {
|
|
444
|
+
"class": "epx-app-interface-settings__control"
|
|
445
|
+
}, [item.key === "navType" ? createVNode("div", {
|
|
446
|
+
"class": "nav-type",
|
|
447
|
+
"role": "group",
|
|
448
|
+
"aria-label": item.label
|
|
449
|
+
}, [item.options.map((option) => createVNode("button", {
|
|
450
|
+
"type": "button",
|
|
323
451
|
"class": ["nav-type__item", {
|
|
324
452
|
"is-active": this.config[item.key] === option.id
|
|
325
453
|
}],
|
|
326
454
|
"key": option.id,
|
|
455
|
+
"disabled": this.readOnly,
|
|
456
|
+
"aria-pressed": this.config[item.key] === option.id,
|
|
327
457
|
"onClick": this.switchNav.bind(this, option.id, item)
|
|
328
|
-
}, [createVNode("
|
|
329
|
-
"src": option.preview
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
333
|
-
"fieldConfigs": {
|
|
334
|
-
state: item.state,
|
|
335
|
-
attriName: item.key,
|
|
336
|
-
attriLabel: item.label,
|
|
337
|
-
options: item.options
|
|
338
|
-
}
|
|
339
|
-
}, null) : item.type === "object" ? createVNode(resolveComponent("epx-visual-config-object"), {
|
|
458
|
+
}, [createVNode("img", {
|
|
459
|
+
"src": option.preview,
|
|
460
|
+
"alt": ""
|
|
461
|
+
}, null), createVNode("span", null, [option.name])]))]) : item.type === "radio" ? createVNode(resolveComponent("el-radio-group"), {
|
|
340
462
|
"modelValue": this.config[item.key],
|
|
341
463
|
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
464
|
+
"size": "small",
|
|
465
|
+
"aria-label": item.label
|
|
466
|
+
}, _isSlot(_slot = item.options.map((option) => createVNode(resolveComponent("el-radio-button"), {
|
|
467
|
+
"key": option.id,
|
|
468
|
+
"value": option.id
|
|
469
|
+
}, {
|
|
470
|
+
default: () => [option.name]
|
|
471
|
+
}))) ? _slot : {
|
|
472
|
+
default: () => [_slot]
|
|
473
|
+
}) : item.type === "object" ? createVNode(resolveComponent("epx-visual-config-object"), {
|
|
474
|
+
"value": this.config[item.key],
|
|
475
|
+
"onChangeConfigs": this.changeConfigItem.bind(this, item.key),
|
|
342
476
|
"label": item.label,
|
|
343
477
|
"object": item.object,
|
|
344
478
|
"flag": item.flag,
|
|
@@ -348,11 +482,11 @@ const _sfc_main = {
|
|
|
348
482
|
"modelValue": this.config[item.key],
|
|
349
483
|
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
350
484
|
"predefine": item.predefineColors,
|
|
351
|
-
"disabled":
|
|
485
|
+
"disabled": this.readOnly
|
|
352
486
|
}, null) : item.type === "gradient" ? createVNode(resolveComponent("epx-color-picker"), {
|
|
353
487
|
"modelValue": this.config[item.key],
|
|
354
488
|
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
355
|
-
"disabled":
|
|
489
|
+
"disabled": this.readOnly
|
|
356
490
|
}, null) : item.type === "photo" ? createVNode(resolveComponent("epx-photo"), {
|
|
357
491
|
"modelValue": this.config[item.key],
|
|
358
492
|
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
@@ -361,7 +495,7 @@ const _sfc_main = {
|
|
|
361
495
|
attriName: item.key,
|
|
362
496
|
attriLabel: item.label
|
|
363
497
|
}
|
|
364
|
-
}, null) : item.type
|
|
498
|
+
}, null) : ["num", "number"].includes(item.type) ? createVNode(resolveComponent("epx-number"), {
|
|
365
499
|
"modelValue": this.config[item.key],
|
|
366
500
|
"onUpdate:modelValue": ($event) => this.config[item.key] = $event,
|
|
367
501
|
"fieldConfigs": {
|
|
@@ -383,23 +517,14 @@ const _sfc_main = {
|
|
|
383
517
|
attriName: item.key,
|
|
384
518
|
attriLabel: item.label
|
|
385
519
|
}
|
|
386
|
-
}, null)]
|
|
387
|
-
}))
|
|
388
|
-
default: () => [
|
|
520
|
+
}, null)])]);
|
|
521
|
+
})) ? _slot2 : {
|
|
522
|
+
default: () => [_slot2]
|
|
389
523
|
});
|
|
390
524
|
}
|
|
391
525
|
},
|
|
392
526
|
created() {
|
|
393
|
-
|
|
394
|
-
APP_CONFIG = "{}"
|
|
395
|
-
} = this.data;
|
|
396
|
-
const appConfig = JSON.parse(APP_CONFIG);
|
|
397
|
-
for (const item of this.fieldsConfigs) {
|
|
398
|
-
if (!appConfig[item.key] && item.defaultValue) {
|
|
399
|
-
appConfig[item.key] = item.defaultValue;
|
|
400
|
-
}
|
|
401
|
-
}
|
|
402
|
-
this.config = appConfig;
|
|
527
|
+
this.loadConfig(this.data.APP_CONFIG);
|
|
403
528
|
}
|
|
404
529
|
};
|
|
405
530
|
export {
|
|
@@ -5,7 +5,7 @@ import _sfc_main from "./CommonFieldList.vue.js";
|
|
|
5
5
|
/* empty css */
|
|
6
6
|
/* empty css */
|
|
7
7
|
import _export_sfc from "../../_virtual/_plugin-vue_export-helper.js";
|
|
8
|
-
const CommonFieldList = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
8
|
+
const CommonFieldList = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-2c565e21"]]);
|
|
9
9
|
export {
|
|
10
10
|
CommonFieldList as default
|
|
11
11
|
};
|
|
@@ -376,7 +376,7 @@ const _sfc_main = {
|
|
|
376
376
|
}
|
|
377
377
|
}, {
|
|
378
378
|
"append-to-body": true,
|
|
379
|
-
"class": "show-field-dialog",
|
|
379
|
+
"class": "show-field-dialog epx-common-field-dialog",
|
|
380
380
|
"destroy-on-close": true,
|
|
381
381
|
"width": "800px",
|
|
382
382
|
"top": "10vh"
|
|
@@ -476,6 +476,7 @@ const _sfc_main = {
|
|
|
476
476
|
},
|
|
477
477
|
renderNameDialog() {
|
|
478
478
|
return createVNode(resolveComponent("el-dialog"), mergeProps({
|
|
479
|
+
"class": "epx-common-field-dialog",
|
|
479
480
|
"modelValue": this.addCommonFieldDialod
|
|
480
481
|
}, {
|
|
481
482
|
"onUpdate:modelValue": (v) => {
|