adminizer 5.0.0-build.2 → 5.0.0-build.21
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/assets/abnfDiagram-VCTEODGH-CkmsvdDi.js +1 -0
- package/assets/add-CESPH_aI.js +1 -0
- package/assets/add-group-CQ4Xm8Ru.js +1 -0
- package/assets/add-user-B-QNjR4B.js +1 -0
- package/assets/ai-assistant/agent.es.js +28362 -0
- package/assets/app-C5Ju5Zra.css +1 -0
- package/assets/app-Ca5yUSBv.js +138 -0
- package/assets/arc-B-Dt8YNl.js +1 -0
- package/assets/architectureDiagram-5GKGNRK7-Ca58kq-l.js +36 -0
- package/assets/asmcrypto-DZeQH0LC.js +1 -0
- package/assets/blockDiagram-NRAW4CY4-CuqE52IG.js +129 -0
- package/assets/c4Diagram-UCG6FXSJ-Cx8z-0Bw.js +38 -0
- package/assets/catalog-CkSbxvx0.js +6 -0
- package/assets/channel-C9z6Pi_j.js +1 -0
- package/assets/chunk-2Q5K7J3B-CXISVKTC.js +1 -0
- package/assets/chunk-5VM5RSS4-DYGeeVYe.js +15 -0
- package/assets/chunk-F27PBJKO-BeY-dbKj.js +1 -0
- package/assets/chunk-G27WJ6UU-DeX_eH7C.js +231 -0
- package/assets/chunk-JWPE2WC7-DaxI9q0u.js +1 -0
- package/assets/chunk-LCL6LL3I-B7PkaEz_.js +206 -0
- package/assets/chunk-POPQ4Y6H-lwu6ZpsN.js +1 -0
- package/assets/chunk-SVP7TREG-CVFllgl1.js +88 -0
- package/assets/chunk-XXDRQBXY-DDLN0rcg.js +1 -0
- package/assets/classDiagram-DTDB5LWJ-BKtCIC3B.js +1 -0
- package/assets/classDiagram-v2-JRS7N3AN-BKtCIC3B.js +1 -0
- package/assets/controls/ckeditor.es.js +9370 -9306
- package/assets/controls/handsontable.es.js +11971 -11938
- package/assets/controls/jsoneditor.es.js +13104 -13008
- package/assets/controls/leaflet.es.js +1023 -1004
- package/assets/controls/toast-ui.es.js +1843 -1834
- package/assets/cose-bilkent-JH36ORCC-CWRyUkhQ.js +1 -0
- package/assets/cynefin-OW5HDTMX-B1iLDXCC.js +166 -0
- package/assets/cynefinDiagram-5FMLGOSQ-DaXQHr3l.js +62 -0
- package/assets/cytoscape.esm-yzknjiTM.js +321 -0
- package/assets/dagre-3AP2YEHR-DFORa4Hz.js +4 -0
- package/assets/dashboard-Ssa1_Of3.js +3 -0
- package/assets/debounce-B3mXI_sx.js +1 -0
- package/assets/defaultLocale-DX6XiGOO.js +1 -0
- package/assets/diagram-S7CK7UJ4-CgP6KBo0.js +30 -0
- package/assets/diagram-UQ7AKVKN-oYfQe6w0.js +41 -0
- package/assets/diagram-VSXAHHWV-DfCU5wgt.js +3 -0
- package/assets/diagram-VX7I27RA-BITJVrNY.js +24 -0
- package/assets/diagram-Z3DM3KII-D8J9Ssjy.js +24 -0
- package/assets/docs-DHMt_Rq1.js +1 -0
- package/assets/ebnfDiagram-PWID7BFC-qpNmoYgx.js +1 -0
- package/assets/erDiagram-SSCWMZ5O-DDF-Y0zs.js +99 -0
- package/assets/flowDiagram-A5DVABFB-CjKVkR9T.js +168 -0
- package/assets/ganttDiagram-EL5Y4UJY-BXGQ53w6.js +292 -0
- package/assets/gitGraphDiagram-WWUBYQGX-BLMevdLh.js +106 -0
- package/assets/history-tBOo2gd5.js +1 -0
- package/assets/infoDiagram-RXCK75RN-BAnPdnyw.js +2 -0
- package/assets/init-Gi6I4Gst.js +1 -0
- package/assets/init-user-DrNUHa6r.js +1 -0
- package/assets/isObject-DL-BuaBl.js +1 -0
- package/assets/ishikawaDiagram-5VMMS53U-PnL0Z4Li.js +70 -0
- package/assets/journeyDiagram-EYS64GPL-CLcsCSwF.js +139 -0
- package/assets/kanban-definition-3QL26DDD-C2eU3uBE.js +89 -0
- package/assets/katex-HP8lGamR.js +257 -0
- package/assets/layout-BXoYdHdx.js +1 -0
- package/assets/linear-BSzrP0oP.js +1 -0
- package/assets/list-CLg6xeIK.js +4 -0
- package/assets/login-Ce7o3-o_.js +1 -0
- package/assets/manifest.json +834 -58
- package/assets/{media-manager-BDbpSSjH.js → media-manager-D7G1P3fz.js} +3 -3
- package/assets/mermaid.core-aKMJHeEk.js +310 -0
- package/assets/mindmap-definition-FBJOCRG2-Dzbz5ghA.js +96 -0
- package/assets/module-BsXph_pA.js +1 -0
- package/assets/notification-D-Zz1gF_.js +20 -0
- package/assets/ordinal-Cboi1Yqb.js +1 -0
- package/assets/pegDiagram-XKGWAZYB-BTdWkU0Y.js +1 -0
- package/assets/pieDiagram-E7YTZNPT-Dnw8-TB-.js +39 -0
- package/assets/quadrantDiagram-AXDQQJYC-CALzLlg9.js +7 -0
- package/assets/railroadDiagram-O6MQD6OU-CTA1vzcv.js +1 -0
- package/assets/register-CNnBkzej.js +1 -0
- package/assets/requirementDiagram-EFPCY7ZU-UX2CF5HA.js +84 -0
- package/assets/ru-CoNgAwFK.js +1 -0
- package/assets/sankeyDiagram-P5KCCOFB-4aPp3ATV.js +40 -0
- package/assets/sequenceDiagram-WJ2MYXX4--kltkwJw.js +162 -0
- package/assets/sizeCapture-X5ZJPWSS-Ca9-g5QY.js +1 -0
- package/assets/stateDiagram-HBIQ2CUA-Diaf5Q7I.js +1 -0
- package/assets/stateDiagram-v2-4QOOHH4V-C6FlRp7u.js +1 -0
- package/assets/swimlanes-XN3QIQJK-DhqX_myE.js +1 -0
- package/assets/swimlanesDiagram-VK2B7HYN-i_3LTEBk.js +8 -0
- package/assets/timeline-definition-24CTP7MA-CwkJQbhq.js +120 -0
- package/assets/toNumber-DZb-r9sy.js +1 -0
- package/assets/use-appearance-DC-DESKB.js +1 -0
- package/assets/user-filters-list-W47DTBp2.js +1 -0
- package/assets/vennDiagram-4TSXK5OY-BNM3_cVS.js +34 -0
- package/assets/wardleyDiagram-VM6X3IG4-BODb1NP8.js +78 -0
- package/assets/welcome-BeBm6NIi.js +1 -0
- package/assets/with-app-layout-B90DtzYC.js +31 -0
- package/assets/xychartDiagram-S5SC5T6Z-DthqEh3g.js +7 -0
- package/controllers/access-rights/permissionOptions.d.ts +2 -0
- package/controllers/access-rights/permissionOptions.js +23 -0
- package/controllers/add.js +1 -1
- package/controllers/addGroup.js +15 -6
- package/controllers/ai/AiAgentController.d.ts +66 -0
- package/controllers/ai/AiAgentController.js +435 -0
- package/controllers/ai/AiAssistantController.d.ts +0 -4
- package/controllers/ai/AiAssistantController.js +4 -78
- package/controllers/catalog/FrontendCatalogAdapter.d.ts +1 -1
- package/controllers/catalog/FrontentCatalogAdapter.d.ts +1 -1
- package/controllers/docs/index.d.ts +22 -0
- package/controllers/docs/index.js +126 -0
- package/controllers/edit.js +1 -1
- package/controllers/editGroup.js +15 -6
- package/controllers/feedback/feedbackController.d.ts +1 -1
- package/controllers/filter-fields/savedFilters.js +1 -1
- package/controllers/history-actions/HistoryController.d.ts +1 -1
- package/controllers/history-actions/HistoryController.js +6 -6
- package/controllers/list.js +1 -1
- package/controllers/login.js +1 -1
- package/controllers/media-manager/mediaManagerAdapter.d.ts +1 -1
- package/controllers/notifications/NotificationController.js +14 -8
- package/controllers/view.js +2 -2
- package/controllers/widgets/filterInfo.js +1 -1
- package/helpers/accessRightsHelper.d.ts +11 -4
- package/helpers/accessRightsHelper.js +82 -12
- package/helpers/assetVersionHelper.d.ts +14 -0
- package/helpers/assetVersionHelper.js +42 -0
- package/helpers/configHelper.d.ts +3 -3
- package/helpers/configHelper.js +20 -18
- package/helpers/controllerHelper.d.ts +3 -2
- package/helpers/controllerHelper.js +25 -15
- package/helpers/fieldsHelper.d.ts +2 -2
- package/helpers/fieldsHelper.js +3 -3
- package/helpers/filterDatetimeHelper.d.ts +1 -1
- package/helpers/inertiaActionsHelper.d.ts +3 -3
- package/helpers/inertiaActionsHelper.js +4 -5
- package/helpers/inertiaAddHelper.d.ts +5 -5
- package/helpers/inertiaAddHelper.js +7 -6
- package/helpers/inertiaGroupHelper.d.ts +3 -3
- package/helpers/inertiaGroupHelper.js +10 -2
- package/helpers/inertiaListHelper.d.ts +4 -4
- package/helpers/inertiaListHelper.js +7 -8
- package/helpers/inertiaMenuHelper.d.ts +2 -3
- package/helpers/inertiaMenuHelper.js +3 -26
- package/helpers/inertiaUserHelper.d.ts +3 -3
- package/helpers/menuHelper.d.ts +2 -2
- package/helpers/modelResourceHelper.d.ts +9 -0
- package/helpers/modelResourceHelper.js +43 -0
- package/helpers/navigationAccessHelper.d.ts +13 -0
- package/helpers/navigationAccessHelper.js +40 -0
- package/helpers/translationHelper.d.ts +2 -2
- package/index.d.ts +69 -58
- package/index.js +11 -0
- package/interfaces/adminpanelConfig.d.ts +18 -5
- package/interfaces/global.d.ts +6 -6
- package/interfaces/internalModelAccess.d.ts +1 -1
- package/interfaces/listQueryBuilder.d.ts +1 -1
- package/interfaces/types.d.ts +171 -2
- package/lib/Adminizer.d.ts +46 -26
- package/lib/Adminizer.js +37 -1
- package/lib/DataAccessor.d.ts +7 -6
- package/lib/DataAccessor.js +50 -48
- package/lib/MiddlewareManager.d.ts +1 -1
- package/lib/access-rights/AccessRightsHandler.d.ts +2 -2
- package/lib/admin-links/AdminLinkHandler.d.ts +72 -0
- package/lib/admin-links/AdminLinkHandler.js +175 -0
- package/lib/ai-assistant/AbstractAiConversationHistoryService.d.ts +39 -0
- package/lib/ai-assistant/AbstractAiConversationHistoryService.js +98 -0
- package/lib/ai-assistant/AbstractAiModelService.d.ts +140 -3
- package/lib/ai-assistant/AbstractAiModelService.js +154 -1
- package/lib/ai-assistant/AiAgentRunManager.d.ts +35 -0
- package/lib/ai-assistant/AiAgentRunManager.js +109 -0
- package/lib/ai-assistant/AiAssistantAgentSkillHandler.d.ts +58 -0
- package/lib/ai-assistant/AiAssistantAgentSkillHandler.js +87 -0
- package/lib/ai-assistant/AiAssistantHandler.d.ts +16 -5
- package/lib/ai-assistant/AiAssistantHandler.js +35 -1
- package/lib/ai-assistant/AiAssistantUiMethodHandler.d.ts +60 -0
- package/lib/ai-assistant/AiAssistantUiMethodHandler.js +138 -0
- package/lib/ai-assistant/builtinAgentSkills.d.ts +9 -0
- package/lib/ai-assistant/builtinAgentSkills.js +256 -0
- package/lib/ai-assistant/jsonSafe.d.ts +13 -0
- package/lib/ai-assistant/jsonSafe.js +81 -0
- package/lib/app-manager/AdminizerApp.d.ts +40 -11
- package/lib/app-manager/AppManager.d.ts +2 -2
- package/lib/app-manager/AppManager.js +54 -50
- package/lib/app-manager/AssetHandler.d.ts +2 -2
- package/lib/app-manager/ConfigLayerHandler.d.ts +2 -2
- package/lib/app-manager/ControllerHandler.d.ts +2 -2
- package/lib/catalog/AbstractCatalog.d.ts +1 -1
- package/lib/catalog/CatalogHandler.d.ts +1 -1
- package/lib/controls/ControlsHandler.d.ts +1 -1
- package/lib/controls/codeEditor/MonacoEditor.d.ts +1 -1
- package/lib/controls/geojsoneditor/GeoEditor.d.ts +1 -1
- package/lib/controls/jsoneditor/JsonEditor.d.ts +1 -1
- package/lib/controls/markdown/ToastUiEditor.d.ts +1 -1
- package/lib/controls/table/Handsontable.d.ts +1 -1
- package/lib/controls/wysiwyg/CKeditor.d.ts +1 -1
- package/lib/docs/AbstractDocumentation.d.ts +100 -0
- package/lib/docs/AbstractDocumentation.js +108 -0
- package/lib/docs/DocumentationHandler.d.ts +100 -0
- package/lib/docs/DocumentationHandler.js +198 -0
- package/lib/docs/FileDocumentation.d.ts +47 -0
- package/lib/docs/FileDocumentation.js +189 -0
- package/lib/docs/docsAgentSkills.d.ts +10 -0
- package/lib/docs/docsAgentSkills.js +93 -0
- package/lib/feedback/FeedbackHandler.d.ts +2 -2
- package/lib/filters/ConditionValidator.d.ts +1 -1
- package/lib/filters/FilterCustomFieldHandler.d.ts +2 -2
- package/lib/filters/FilterService.d.ts +4 -4
- package/lib/filters/FilterService.js +4 -3
- package/lib/filters/index.d.ts +6 -6
- package/lib/history-actions/AbstractHistoryAdapter.d.ts +6 -6
- package/lib/history-actions/AbstractHistoryAdapter.js +11 -9
- package/lib/history-actions/DefaultHistoryAdapter.d.ts +4 -4
- package/lib/history-actions/HistoryHandler.d.ts +1 -1
- package/lib/list-query-builder/ListQueryBuilder.d.ts +7 -7
- package/lib/media-manager/AbstractMediaManager.d.ts +2 -2
- package/lib/media-manager/MediaManagerHandler.d.ts +1 -1
- package/lib/media-manager/Thumb.d.ts +1 -1
- package/lib/media-manager/helpers/MediaManagerHelper.d.ts +5 -5
- package/lib/model/AbstractModel.d.ts +11 -4
- package/lib/model/InternalModelAccessFactory.d.ts +2 -2
- package/lib/model/ModelHandler.d.ts +50 -5
- package/lib/model/ModelHandler.js +107 -8
- package/lib/model/adapter/sequelize.d.ts +7 -5
- package/lib/model/adapter/sequelize.js +79 -46
- package/lib/model/adapter/typeorm.d.ts +2 -2
- package/lib/model/adapter/typeorm.js +1 -1
- package/lib/model/internalModelRepository.d.ts +2 -2
- package/lib/notifications/AbstractNotificationService.d.ts +4 -4
- package/lib/notifications/GeneralNotificationService.d.ts +2 -2
- package/lib/notifications/GeneralNotificationService.js +6 -5
- package/lib/notifications/NotificationHandler.d.ts +2 -2
- package/lib/notifications/SystemNotificationService.d.ts +2 -2
- package/lib/notifications/SystemNotificationService.js +1 -1
- package/lib/requestProcessor.d.ts +1 -1
- package/lib/ui-i18n/uiTranslationKeys.d.ts +2 -1
- package/lib/ui-i18n/uiTranslationKeys.js +42 -1
- package/lib/widgets/abstractAction.d.ts +1 -1
- package/lib/widgets/abstractCustom.d.ts +2 -2
- package/lib/widgets/abstractInfo.d.ts +1 -1
- package/lib/widgets/abstractLink.d.ts +2 -2
- package/lib/widgets/abstractSwitch.d.ts +1 -1
- package/lib/widgets/abstractWidgetBase.d.ts +1 -1
- package/lib/widgets/widgetHandler.d.ts +9 -9
- package/lib/widgets/widgetHandler.js +5 -1
- package/models/Filter.d.ts +1 -1
- package/models/FilterColumn.d.ts +1 -1
- package/models/Group.d.ts +3 -2
- package/models/HistoryActions.d.ts +1 -1
- package/models/MediaManagerAP.d.ts +2 -2
- package/models/MediaManagerAssociationsAP.d.ts +1 -1
- package/models/MediaManagerMetaAP.d.ts +1 -1
- package/models/User.d.ts +2 -2
- package/models/UserNotification.d.ts +1 -1
- package/package.json +29 -20
- package/policies/authPolicies.js +6 -6
- package/policies/permissionResolvers.d.ts +1 -0
- package/policies/permissionResolvers.js +3 -0
- package/services/FeedService.d.ts +3 -3
- package/system/Router.d.ts +1 -1
- package/system/Router.js +27 -1
- package/system/bindAccessRights.d.ts +1 -1
- package/system/bindAccessRights.js +2 -3
- package/system/bindAuthorization.d.ts +1 -1
- package/system/bindControls.d.ts +1 -1
- package/system/bindCors.d.ts +1 -1
- package/system/bindCustomFilterHandlers.d.ts +1 -1
- package/system/bindDashboardWidgets.d.ts +1 -1
- package/system/bindDev.d.ts +1 -1
- package/system/bindDocs.d.ts +13 -0
- package/system/bindDocs.js +77 -0
- package/system/bindHistory.d.ts +1 -1
- package/system/bindInertia.d.ts +1 -1
- package/system/bindInertia.js +23 -1
- package/system/bindMediaManager.d.ts +1 -1
- package/system/bindNotifications.d.ts +1 -1
- package/system/bindReqFunctions.d.ts +1 -1
- package/system/bindTranslations.d.ts +1 -1
- package/system/buildInternalModelAccess.d.ts +3 -3
- package/system/buildInternalModelAccess.js +5 -2
- package/system/defaults.d.ts +1 -1
- package/system/routePolicies.d.ts +1 -1
- package/system/systemModelContracts.d.ts +1 -1
- package/system/systemModelContracts.js +11 -7
- package/system/validateSystemModels.d.ts +1 -1
- package/system/validateSystemModels.js +29 -9
- package/assets/add-group-BdHFzKng.js +0 -1
- package/assets/add-p6yGCoZ7.js +0 -1
- package/assets/add-user-CDspCLu4.js +0 -1
- package/assets/app-DNXiApCk.css +0 -1
- package/assets/app-layout-DCr_-JY3.js +0 -1
- package/assets/app.js +0 -138
- package/assets/catalog-XN-_p9TB.js +0 -6
- package/assets/dashboard-CHZO2QFY.js +0 -3
- package/assets/debounce-BMmXVQ06.js +0 -1
- package/assets/history-CQd0FojQ.js +0 -1
- package/assets/init-user-8aUohVDq.js +0 -1
- package/assets/list-PHWgTHsg.js +0 -4
- package/assets/login-CO4laf6m.js +0 -1
- package/assets/module-DVyQtIxm.js +0 -1
- package/assets/notification-B87XG8nQ.js +0 -20
- package/assets/register-DBYIMXGQ.js +0 -1
- package/assets/ru-rYKdQbWF.js +0 -1
- package/assets/use-appearance-_EbbjHTh.js +0 -1
- package/assets/user-filters-list-BRzDbPkx.js +0 -1
- package/assets/welcome-DiXmrTgc.js +0 -1
package/index.d.ts
CHANGED
|
@@ -1,58 +1,69 @@
|
|
|
1
|
-
export * from "./helpers/configHelper";
|
|
2
|
-
export * from "./helpers/accessRightsHelper";
|
|
3
|
-
export * from "./lib/widgets/abstractAction";
|
|
4
|
-
export * from "./lib/widgets/abstractInfo";
|
|
5
|
-
export * from "./lib/widgets/abstractCustom";
|
|
6
|
-
export * from "./lib/widgets/abstractLink";
|
|
7
|
-
export * from "./lib/widgets/abstractWidgetBase";
|
|
8
|
-
export * from "./lib/widgets/abstractSwitch";
|
|
9
|
-
export * from "./lib/widgets/widgetHandler";
|
|
10
|
-
export * from "./lib/catalog/AbstractCatalog";
|
|
11
|
-
export * from "./lib/catalog/CatalogHandler";
|
|
12
|
-
export * from "./lib/catalog/CatalogTemplateComponentHandler";
|
|
13
|
-
export * from "./lib/media-manager/MediaManagerHandler";
|
|
14
|
-
export * from "./controllers/media-manager/mediaManagerAdapter";
|
|
15
|
-
export * from "./interfaces/adminpanelConfig";
|
|
16
|
-
export * from "./interfaces/types";
|
|
17
|
-
export * from "./interfaces/queryCriteria";
|
|
18
|
-
export * from "./interfaces/listQueryBuilder";
|
|
19
|
-
export * from "./interfaces/internalModelAccess";
|
|
20
|
-
export * from "./interfaces/MaaterialIcons";
|
|
21
|
-
export * from "./lib/model/AbstractModel";
|
|
22
|
-
export * from "./lib/model/InternalModelAccessFactory";
|
|
23
|
-
export * from "./system/systemModelContracts";
|
|
24
|
-
export * from "./lib/model/adapter/sequelize";
|
|
25
|
-
export * from "./lib/model/adapter/typeorm";
|
|
26
|
-
export * from "./lib/media-manager/AbstractMediaManager";
|
|
27
|
-
export * from "./lib/controls/Control";
|
|
28
|
-
export * from "./lib/controls/ControlsHandler";
|
|
29
|
-
export * from "./lib/Adminizer";
|
|
30
|
-
export * from "./lib/
|
|
31
|
-
export * from "./
|
|
32
|
-
export * from "./
|
|
33
|
-
export * from "./
|
|
34
|
-
export * from "./models/
|
|
35
|
-
export * from "./models/
|
|
36
|
-
export * from "./models/
|
|
37
|
-
export * from "./models/
|
|
38
|
-
export * from "./models/
|
|
39
|
-
export * from "./models/
|
|
40
|
-
export * from "./models/
|
|
41
|
-
export * from "./
|
|
42
|
-
export * from "./
|
|
43
|
-
export * from "./
|
|
44
|
-
export * from "./
|
|
45
|
-
export * from "./lib/
|
|
46
|
-
export * from "./lib/
|
|
47
|
-
export * from "./lib/
|
|
48
|
-
export * from "./lib/
|
|
49
|
-
export * from "./lib/
|
|
50
|
-
export * from "./lib/
|
|
51
|
-
export * from "./lib/
|
|
52
|
-
export * from "./lib/
|
|
53
|
-
export * from "./lib/
|
|
54
|
-
export * from "./lib/
|
|
55
|
-
export * from "./lib/
|
|
56
|
-
export * from "./
|
|
57
|
-
export * from "./
|
|
58
|
-
export * from "./lib/
|
|
1
|
+
export * from "./helpers/configHelper.js";
|
|
2
|
+
export * from "./helpers/accessRightsHelper.js";
|
|
3
|
+
export * from "./lib/widgets/abstractAction.js";
|
|
4
|
+
export * from "./lib/widgets/abstractInfo.js";
|
|
5
|
+
export * from "./lib/widgets/abstractCustom.js";
|
|
6
|
+
export * from "./lib/widgets/abstractLink.js";
|
|
7
|
+
export * from "./lib/widgets/abstractWidgetBase.js";
|
|
8
|
+
export * from "./lib/widgets/abstractSwitch.js";
|
|
9
|
+
export * from "./lib/widgets/widgetHandler.js";
|
|
10
|
+
export * from "./lib/catalog/AbstractCatalog.js";
|
|
11
|
+
export * from "./lib/catalog/CatalogHandler.js";
|
|
12
|
+
export * from "./lib/catalog/CatalogTemplateComponentHandler.js";
|
|
13
|
+
export * from "./lib/media-manager/MediaManagerHandler.js";
|
|
14
|
+
export * from "./controllers/media-manager/mediaManagerAdapter.js";
|
|
15
|
+
export * from "./interfaces/adminpanelConfig.js";
|
|
16
|
+
export * from "./interfaces/types.js";
|
|
17
|
+
export * from "./interfaces/queryCriteria.js";
|
|
18
|
+
export * from "./interfaces/listQueryBuilder.js";
|
|
19
|
+
export * from "./interfaces/internalModelAccess.js";
|
|
20
|
+
export * from "./interfaces/MaaterialIcons.js";
|
|
21
|
+
export * from "./lib/model/AbstractModel.js";
|
|
22
|
+
export * from "./lib/model/InternalModelAccessFactory.js";
|
|
23
|
+
export * from "./system/systemModelContracts.js";
|
|
24
|
+
export * from "./lib/model/adapter/sequelize.js";
|
|
25
|
+
export * from "./lib/model/adapter/typeorm.js";
|
|
26
|
+
export * from "./lib/media-manager/AbstractMediaManager.js";
|
|
27
|
+
export * from "./lib/controls/Control.js";
|
|
28
|
+
export * from "./lib/controls/ControlsHandler.js";
|
|
29
|
+
export * from "./lib/Adminizer.js";
|
|
30
|
+
export * from "./lib/docs/AbstractDocumentation.js";
|
|
31
|
+
export * from "./lib/docs/DocumentationHandler.js";
|
|
32
|
+
export * from "./lib/docs/FileDocumentation.js";
|
|
33
|
+
export * from "./lib/I18n.js";
|
|
34
|
+
export * from "./models/Group.js";
|
|
35
|
+
export * from "./models/User.js";
|
|
36
|
+
export * from "./models/Filter.js";
|
|
37
|
+
export * from "./models/FilterColumn.js";
|
|
38
|
+
export * from "./models/HistoryActions.js";
|
|
39
|
+
export * from "./models/Notification.js";
|
|
40
|
+
export * from "./models/UserNotification.js";
|
|
41
|
+
export * from "./models/MediaManagerAP.js";
|
|
42
|
+
export * from "./models/MediaManagerAssociationsAP.js";
|
|
43
|
+
export * from "./models/MediaManagerMetaAP.js";
|
|
44
|
+
export * from "./policies/authPolicies.js";
|
|
45
|
+
export * from "./lib/helper/jwt.js";
|
|
46
|
+
export * from "./lib/notifications/AbstractNotificationService.js";
|
|
47
|
+
export * from "./lib/POWCaptcha.js";
|
|
48
|
+
export * from "./lib/ai-assistant/AbstractAiModelService.js";
|
|
49
|
+
export * from "./lib/ai-assistant/AbstractAiConversationHistoryService.js";
|
|
50
|
+
export * from "./lib/ai-assistant/AiAssistantHandler.js";
|
|
51
|
+
export * from "./lib/ai-assistant/AiAgentRunManager.js";
|
|
52
|
+
export * from "./lib/ai-assistant/jsonSafe.js";
|
|
53
|
+
export * from "./lib/ai-assistant/AiAssistantUiMethodHandler.js";
|
|
54
|
+
export * from "./lib/ai-assistant/AiAssistantAgentSkillHandler.js";
|
|
55
|
+
export * from "./lib/admin-links/AdminLinkHandler.js";
|
|
56
|
+
export * from "./helpers/modelResourceHelper.js";
|
|
57
|
+
export * from "./helpers/navigationAccessHelper.js";
|
|
58
|
+
export * from "./lib/DataAccessor.js";
|
|
59
|
+
export * from "./lib/history-actions/AbstractHistoryAdapter.js";
|
|
60
|
+
export * from "./lib/filters/CustomFilterHandler.js";
|
|
61
|
+
export * from "./lib/feedback/AbstractFeedbackHandler.js";
|
|
62
|
+
export * from "./lib/feedback/FeedbackHandler.js";
|
|
63
|
+
export * from "./lib/app-manager/AdminizerApp.js";
|
|
64
|
+
export * from "./lib/app-manager/AppManager.js";
|
|
65
|
+
export * from "./lib/app-manager/ControllerHandler.js";
|
|
66
|
+
export * from "./lib/app-manager/AssetHandler.js";
|
|
67
|
+
export * from "./lib/app-manager/ConfigLayerHandler.js";
|
|
68
|
+
export * from "./lib/access-rights/AccessRightsHandler.js";
|
|
69
|
+
export * from "./lib/media-manager/helpers/MediaManagerHelper.js";
|
package/index.js
CHANGED
|
@@ -27,6 +27,9 @@ export * from "./lib/media-manager/AbstractMediaManager.js";
|
|
|
27
27
|
export * from "./lib/controls/Control.js";
|
|
28
28
|
export * from "./lib/controls/ControlsHandler.js";
|
|
29
29
|
export * from "./lib/Adminizer.js";
|
|
30
|
+
export * from "./lib/docs/AbstractDocumentation.js";
|
|
31
|
+
export * from "./lib/docs/DocumentationHandler.js";
|
|
32
|
+
export * from "./lib/docs/FileDocumentation.js";
|
|
30
33
|
export * from "./lib/I18n.js";
|
|
31
34
|
export * from "./models/Group.js";
|
|
32
35
|
export * from "./models/User.js";
|
|
@@ -43,7 +46,15 @@ export * from "./lib/helper/jwt.js";
|
|
|
43
46
|
export * from "./lib/notifications/AbstractNotificationService.js";
|
|
44
47
|
export * from "./lib/POWCaptcha.js";
|
|
45
48
|
export * from "./lib/ai-assistant/AbstractAiModelService.js";
|
|
49
|
+
export * from "./lib/ai-assistant/AbstractAiConversationHistoryService.js";
|
|
46
50
|
export * from "./lib/ai-assistant/AiAssistantHandler.js";
|
|
51
|
+
export * from "./lib/ai-assistant/AiAgentRunManager.js";
|
|
52
|
+
export * from "./lib/ai-assistant/jsonSafe.js";
|
|
53
|
+
export * from "./lib/ai-assistant/AiAssistantUiMethodHandler.js";
|
|
54
|
+
export * from "./lib/ai-assistant/AiAssistantAgentSkillHandler.js";
|
|
55
|
+
export * from "./lib/admin-links/AdminLinkHandler.js";
|
|
56
|
+
export * from "./helpers/modelResourceHelper.js";
|
|
57
|
+
export * from "./helpers/navigationAccessHelper.js";
|
|
47
58
|
export * from "./lib/DataAccessor.js";
|
|
48
59
|
export * from "./lib/history-actions/AbstractHistoryAdapter.js";
|
|
49
60
|
export * from "./lib/filters/CustomFilterHandler.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { MaterialIcon } from "./MaaterialIcons";
|
|
1
|
+
import { MaterialIcon } from "./MaaterialIcons.js";
|
|
2
2
|
import { EditorOptions } from "@toast-ui/editor/types/editor";
|
|
3
3
|
import { GridSettings as HandsontableSettings } from "handsontable/settings";
|
|
4
|
-
import { Group } from "../models/Group";
|
|
5
|
-
import { User } from "../models/User";
|
|
6
|
-
import { InternalModelAccessMap } from "./internalModelAccess";
|
|
4
|
+
import { Group } from "../models/Group.js";
|
|
5
|
+
import { User } from "../models/User.js";
|
|
6
|
+
import { InternalModelAccessMap } from "./internalModelAccess.js";
|
|
7
7
|
/**
|
|
8
8
|
* Controller function type - async function that handles requests and returns a response
|
|
9
9
|
*/
|
|
@@ -223,6 +223,14 @@ export interface AdminpanelConfig {
|
|
|
223
223
|
defaultModel?: string;
|
|
224
224
|
models?: string[];
|
|
225
225
|
};
|
|
226
|
+
/**
|
|
227
|
+
* Knowledge base (built-in documentation). The implementation is
|
|
228
|
+
* registered separately: `adminizer.documentationHandler.register(service)`.
|
|
229
|
+
*/
|
|
230
|
+
documentation?: {
|
|
231
|
+
/** Master switch of the subsystem; nothing is brought up unless `true` */
|
|
232
|
+
enabled?: boolean;
|
|
233
|
+
};
|
|
226
234
|
cors?: {
|
|
227
235
|
enabled: boolean;
|
|
228
236
|
origin: string[] | string;
|
|
@@ -299,9 +307,14 @@ export interface ModelConfig {
|
|
|
299
307
|
adapter?: string;
|
|
300
308
|
title: string;
|
|
301
309
|
/**
|
|
302
|
-
*
|
|
310
|
+
* Physical host ORM model name.
|
|
303
311
|
* */
|
|
304
312
|
model: string;
|
|
313
|
+
/**
|
|
314
|
+
* Required only when two or more Adminizer resources use the same host model.
|
|
315
|
+
* The primary resource is selected for associations that reference the host model.
|
|
316
|
+
*/
|
|
317
|
+
primary?: boolean;
|
|
305
318
|
/**
|
|
306
319
|
* Optional display name for history. Should be a attribute of the model, or a function.
|
|
307
320
|
*/
|
package/interfaces/global.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { Adminizer } from "../lib/Adminizer";
|
|
1
|
+
import { Adminizer } from "../lib/Adminizer.js";
|
|
2
2
|
import { NextFunction, Request, Response } from "express";
|
|
3
3
|
import multer from "multer";
|
|
4
|
-
import { I18n } from "../lib/I18n";
|
|
5
|
-
import { Inertia } from "../lib/inertia/inertiaAdapter";
|
|
6
|
-
import { Flash } from "../lib/inertia/flash";
|
|
7
|
-
import { User } from "../models/User";
|
|
8
|
-
import { AppRuntime } from "../lib/app-manager/AdminizerApp";
|
|
4
|
+
import { I18n } from "../lib/I18n.js";
|
|
5
|
+
import { Inertia } from "../lib/inertia/inertiaAdapter.js";
|
|
6
|
+
import { Flash } from "../lib/inertia/flash.js";
|
|
7
|
+
import { User } from "../models/User.js";
|
|
8
|
+
import { AppRuntime } from "../lib/app-manager/AdminizerApp.js";
|
|
9
9
|
declare global {
|
|
10
10
|
/** @deprecated use import from TS model decalration */
|
|
11
11
|
type ModelsAP = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IsAny, QueryCriteria } from "./queryCriteria";
|
|
1
|
+
import { IsAny, QueryCriteria } from "./queryCriteria.js";
|
|
2
2
|
export type InternalModelAccessScope = string;
|
|
3
3
|
export type InternalModelAccessMap = Record<InternalModelAccessScope, string[]>;
|
|
4
4
|
export type InternalModelRelationId = string | number;
|
package/interfaces/types.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { AbstractModel } from "../lib/model/AbstractModel";
|
|
2
|
-
import { ModelConfig } from "./adminpanelConfig";
|
|
1
|
+
import { AbstractModel } from "../lib/model/AbstractModel.js";
|
|
2
|
+
import { ModelConfig } from "./adminpanelConfig.js";
|
|
3
|
+
import type { User } from "../models/User.js";
|
|
3
4
|
export interface ModelResource {
|
|
4
5
|
name: string;
|
|
5
6
|
config?: ModelConfig;
|
|
@@ -11,7 +12,24 @@ export interface AccessRightsToken {
|
|
|
11
12
|
description: string;
|
|
12
13
|
department: string;
|
|
13
14
|
id: string;
|
|
15
|
+
getOptions?: (user: User) => Promise<PermissionOption[]>;
|
|
16
|
+
check?: (user: User, context?: PermissionContext) => Promise<boolean>;
|
|
14
17
|
}
|
|
18
|
+
export interface PermissionOption {
|
|
19
|
+
id: string;
|
|
20
|
+
name: string;
|
|
21
|
+
description?: string;
|
|
22
|
+
}
|
|
23
|
+
export interface PermissionContext {
|
|
24
|
+
rights?: string[];
|
|
25
|
+
[key: string]: unknown;
|
|
26
|
+
}
|
|
27
|
+
/** Serialized as a JSON string in Group.tokens for a contextual token. */
|
|
28
|
+
export interface GroupPermissionGrant {
|
|
29
|
+
tokenId: string;
|
|
30
|
+
rights: string[];
|
|
31
|
+
}
|
|
32
|
+
export type PermissionGrant = string | GroupPermissionGrant;
|
|
15
33
|
export interface PropsField {
|
|
16
34
|
label: string;
|
|
17
35
|
type: string;
|
|
@@ -70,3 +88,154 @@ export interface AiAssistantModelInfo {
|
|
|
70
88
|
name: string;
|
|
71
89
|
description?: string;
|
|
72
90
|
}
|
|
91
|
+
/**
|
|
92
|
+
* Streaming agent contract.
|
|
93
|
+
*
|
|
94
|
+
* A model service that only implements `generateReply` stays a plain chat
|
|
95
|
+
* model; services that also implement the optional agent members below are
|
|
96
|
+
* driven by the streaming UI (tool calls, reasoning, attachments, per-user
|
|
97
|
+
* server-side session). See AbstractAiModelService.
|
|
98
|
+
*/
|
|
99
|
+
/** One SSE frame of a run. `type` drives how the UI folds it into the thread. */
|
|
100
|
+
export type AiAgentStreamEvent = {
|
|
101
|
+
type: 'text.delta' | 'text.done' | 'reasoning.delta' | 'reasoning.done' | 'tool.start' | 'tool.done' | 'tool.error' | 'step.done' | 'turn.done' | 'done' | 'error' | string;
|
|
102
|
+
[key: string]: unknown;
|
|
103
|
+
};
|
|
104
|
+
export type AiAgentPublish = (event: AiAgentStreamEvent) => void;
|
|
105
|
+
export interface AiAgentTokenUsage {
|
|
106
|
+
inputTokens?: number;
|
|
107
|
+
outputTokens?: number;
|
|
108
|
+
totalTokens?: number;
|
|
109
|
+
}
|
|
110
|
+
/** One selectable LLM inside an agent service. */
|
|
111
|
+
export interface AiAgentModelOption {
|
|
112
|
+
id: string;
|
|
113
|
+
contextWindow: number | null;
|
|
114
|
+
maxOutputTokens: number | null;
|
|
115
|
+
vision: boolean;
|
|
116
|
+
/** Relative spend multiplier (×1 = median-priced model); null if unknown. */
|
|
117
|
+
costCoefficient: number | null;
|
|
118
|
+
[key: string]: unknown;
|
|
119
|
+
}
|
|
120
|
+
/** State of the user's server-side agent session. */
|
|
121
|
+
export interface AiAgentSessionMeta {
|
|
122
|
+
model: string;
|
|
123
|
+
contextWindow: number;
|
|
124
|
+
vision: boolean;
|
|
125
|
+
turns: number;
|
|
126
|
+
contextTokens: number;
|
|
127
|
+
totalUsage: AiAgentTokenUsage;
|
|
128
|
+
[key: string]: unknown;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Whether the service can talk to its LLM yet. Services that need no
|
|
132
|
+
* provisioning simply omit `getConnectionStatus()` and are treated as ready.
|
|
133
|
+
*/
|
|
134
|
+
export interface AiAgentConnectionStatus {
|
|
135
|
+
state: 'ready' | 'registering' | 'waiting_retry' | 'setup_required' | 'error';
|
|
136
|
+
provider?: string;
|
|
137
|
+
baseUrl?: string;
|
|
138
|
+
source?: string | null;
|
|
139
|
+
nextAttemptAt?: string | null;
|
|
140
|
+
lastError?: string | null;
|
|
141
|
+
expiresAt?: string | null;
|
|
142
|
+
[key: string]: unknown;
|
|
143
|
+
}
|
|
144
|
+
/** States for which an agent can describe its connection screen. */
|
|
145
|
+
export type AiAgentConnectionState = Exclude<AiAgentConnectionStatus['state'], 'ready'>;
|
|
146
|
+
/**
|
|
147
|
+
* Declarative connection screen supplied by an agent service. The shared panel
|
|
148
|
+
* owns rendering, while the agent owns its copy, CTA and which status details
|
|
149
|
+
* are useful to expose.
|
|
150
|
+
*/
|
|
151
|
+
export interface AiAgentConnectionScreen {
|
|
152
|
+
title?: string;
|
|
153
|
+
description?: string;
|
|
154
|
+
icon?: 'spinner' | 'bot' | 'error';
|
|
155
|
+
action?: {
|
|
156
|
+
label: string;
|
|
157
|
+
href: string;
|
|
158
|
+
};
|
|
159
|
+
/** Status values the agent wants to render on this screen. */
|
|
160
|
+
details?: Array<{
|
|
161
|
+
field: string;
|
|
162
|
+
label?: string;
|
|
163
|
+
format?: 'text' | 'local-time';
|
|
164
|
+
tone?: 'muted' | 'error';
|
|
165
|
+
}>;
|
|
166
|
+
}
|
|
167
|
+
/** Normalized budget / rate limits of the provider key, when it exposes them. */
|
|
168
|
+
export interface AiAgentLimits {
|
|
169
|
+
provider: string;
|
|
170
|
+
supported: boolean;
|
|
171
|
+
overBudget?: boolean;
|
|
172
|
+
message?: string;
|
|
173
|
+
maxBudgetUsd?: number | null;
|
|
174
|
+
spentUsd?: number | null;
|
|
175
|
+
remainingBudgetUsd?: number | null;
|
|
176
|
+
budgetResetAt?: string | null;
|
|
177
|
+
burstMaxBudgetUsd?: number | null;
|
|
178
|
+
burstSpentUsd?: number | null;
|
|
179
|
+
burstRemainingBudgetUsd?: number | null;
|
|
180
|
+
burstResetAt?: string | null;
|
|
181
|
+
burstDurationLabel?: string | null;
|
|
182
|
+
rpmLimit?: number | null;
|
|
183
|
+
tpmLimit?: number | null;
|
|
184
|
+
fetchedAt?: string;
|
|
185
|
+
[key: string]: unknown;
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* Copy the panel shows instead of its neutral defaults. `getUiHints(locale)`
|
|
189
|
+
* receives the admin user's locale, so agents can return localized copy.
|
|
190
|
+
*/
|
|
191
|
+
export interface AiAgentUiHints {
|
|
192
|
+
title?: string;
|
|
193
|
+
welcomeHint?: string;
|
|
194
|
+
composerPlaceholder?: string;
|
|
195
|
+
suggestions?: string[];
|
|
196
|
+
/** Setting an operator must fill in before the service can connect. */
|
|
197
|
+
setupSetting?: string;
|
|
198
|
+
/** Where to fill it in; rendered as a button on the connection loader. */
|
|
199
|
+
setupUrl?: string;
|
|
200
|
+
/**
|
|
201
|
+
* Per-state pages rendered while this agent is not ready. `default` is
|
|
202
|
+
* used for any state without its own screen.
|
|
203
|
+
*/
|
|
204
|
+
connectionScreens?: Partial<Record<AiAgentConnectionState | 'default', AiAgentConnectionScreen>>;
|
|
205
|
+
[key: string]: unknown;
|
|
206
|
+
}
|
|
207
|
+
/** A browser-side capability which an agent may call through `ui.method`. */
|
|
208
|
+
export interface AiAgentUiMethod {
|
|
209
|
+
id: string;
|
|
210
|
+
title: string;
|
|
211
|
+
description: string;
|
|
212
|
+
inputSchema: Record<string, unknown>;
|
|
213
|
+
action: string;
|
|
214
|
+
accessRightsToken?: string;
|
|
215
|
+
}
|
|
216
|
+
/** Declarative UI contract consumed by the shared assistant panel. */
|
|
217
|
+
export interface AiAgentUiSchema extends AiAgentUiHints {
|
|
218
|
+
commands: Array<{
|
|
219
|
+
id: string;
|
|
220
|
+
description?: string;
|
|
221
|
+
}>;
|
|
222
|
+
uiMethods?: AiAgentUiMethod[];
|
|
223
|
+
panels: {
|
|
224
|
+
history: boolean;
|
|
225
|
+
models: boolean;
|
|
226
|
+
limits: boolean;
|
|
227
|
+
};
|
|
228
|
+
}
|
|
229
|
+
/** An uploaded file as handed to the agent service (multer memory storage). */
|
|
230
|
+
export interface AiAgentUploadedFile {
|
|
231
|
+
originalname: string;
|
|
232
|
+
mimetype: string;
|
|
233
|
+
size: number;
|
|
234
|
+
buffer: Buffer;
|
|
235
|
+
}
|
|
236
|
+
/** What the service reports back about a stored upload, if it stores them. */
|
|
237
|
+
export interface AiAgentSavedFile {
|
|
238
|
+
id?: string;
|
|
239
|
+
name?: string;
|
|
240
|
+
[key: string]: unknown;
|
|
241
|
+
}
|
package/lib/Adminizer.d.ts
CHANGED
|
@@ -1,32 +1,36 @@
|
|
|
1
1
|
import express, { Express } from "express";
|
|
2
2
|
import winston from "winston";
|
|
3
3
|
import EventEmitter from 'events';
|
|
4
|
-
import { AdminpanelConfig } from "../interfaces/adminpanelConfig";
|
|
5
|
-
import MiddlewareManager from "./MiddlewareManager";
|
|
6
|
-
import Router from "./../system/Router";
|
|
7
|
-
import { ModelHandler } from "./model/ModelHandler";
|
|
8
|
-
import { WidgetHandler } from "./widgets/widgetHandler";
|
|
9
|
-
import { AccessRightsHelper } from "../helpers/accessRightsHelper";
|
|
10
|
-
import { ConfigHelper } from "../helpers/configHelper";
|
|
11
|
-
import { I18n } from "./I18n";
|
|
12
|
-
import { AbstractAdapter } from "./model/AbstractModel";
|
|
4
|
+
import { AdminpanelConfig } from "../interfaces/adminpanelConfig.js";
|
|
5
|
+
import MiddlewareManager from "./MiddlewareManager.js";
|
|
6
|
+
import Router from "./../system/Router.js";
|
|
7
|
+
import { ModelHandler } from "./model/ModelHandler.js";
|
|
8
|
+
import { WidgetHandler } from "./widgets/widgetHandler.js";
|
|
9
|
+
import { AccessRightsHelper } from "../helpers/accessRightsHelper.js";
|
|
10
|
+
import { ConfigHelper } from "../helpers/configHelper.js";
|
|
11
|
+
import { I18n } from "./I18n.js";
|
|
12
|
+
import { AbstractAdapter } from "./model/AbstractModel.js";
|
|
13
13
|
import type { ViteDevServer } from 'vite';
|
|
14
|
-
import { MenuHelper } from "../helpers/menuHelper";
|
|
15
|
-
import { ControlsHandler } from "./controls/ControlsHandler";
|
|
16
|
-
import { CatalogHandler } from "./catalog/CatalogHandler";
|
|
17
|
-
import { CatalogTemplateComponentHandler } from "./catalog/CatalogTemplateComponentHandler";
|
|
18
|
-
import { AiAssistantHandler } from './ai-assistant/AiAssistantHandler';
|
|
19
|
-
import { NotificationHandler } from './notifications/NotificationHandler';
|
|
20
|
-
import { INotification } from "../interfaces/types";
|
|
21
|
-
import { MediaManagerHandler } from "./media-manager/MediaManagerHandler";
|
|
22
|
-
import { HistoryHandler } from "./history-actions/HistoryHandler";
|
|
23
|
-
import { CustomFilterHandler } from "./filters/CustomFilterHandler";
|
|
24
|
-
import { FeedbackHandler } from "./feedback/FeedbackHandler";
|
|
25
|
-
import { AppManager } from "./app-manager/AppManager";
|
|
26
|
-
import { ControllerHandler } from "./app-manager/ControllerHandler";
|
|
27
|
-
import { AssetHandler } from "./app-manager/AssetHandler";
|
|
28
|
-
import { ConfigLayerHandler } from "./app-manager/ConfigLayerHandler";
|
|
29
|
-
import { AccessRightsHandler } from "./access-rights/AccessRightsHandler";
|
|
14
|
+
import { MenuHelper } from "../helpers/menuHelper.js";
|
|
15
|
+
import { ControlsHandler } from "./controls/ControlsHandler.js";
|
|
16
|
+
import { CatalogHandler } from "./catalog/CatalogHandler.js";
|
|
17
|
+
import { CatalogTemplateComponentHandler } from "./catalog/CatalogTemplateComponentHandler.js";
|
|
18
|
+
import { AiAssistantHandler } from './ai-assistant/AiAssistantHandler.js';
|
|
19
|
+
import { NotificationHandler } from './notifications/NotificationHandler.js';
|
|
20
|
+
import { INotification } from "../interfaces/types.js";
|
|
21
|
+
import { MediaManagerHandler } from "./media-manager/MediaManagerHandler.js";
|
|
22
|
+
import { HistoryHandler } from "./history-actions/HistoryHandler.js";
|
|
23
|
+
import { CustomFilterHandler } from "./filters/CustomFilterHandler.js";
|
|
24
|
+
import { FeedbackHandler } from "./feedback/FeedbackHandler.js";
|
|
25
|
+
import { AppManager } from "./app-manager/AppManager.js";
|
|
26
|
+
import { ControllerHandler } from "./app-manager/ControllerHandler.js";
|
|
27
|
+
import { AssetHandler } from "./app-manager/AssetHandler.js";
|
|
28
|
+
import { ConfigLayerHandler } from "./app-manager/ConfigLayerHandler.js";
|
|
29
|
+
import { AccessRightsHandler } from "./access-rights/AccessRightsHandler.js";
|
|
30
|
+
import { AiAssistantUiMethodHandler } from './ai-assistant/AiAssistantUiMethodHandler.js';
|
|
31
|
+
import { AdminLinkHandler } from './admin-links/AdminLinkHandler.js';
|
|
32
|
+
import { AiAssistantAgentSkillHandler } from './ai-assistant/AiAssistantAgentSkillHandler.js';
|
|
33
|
+
import { DocumentationHandler } from './docs/DocumentationHandler.js';
|
|
30
34
|
export declare function createAdminizerLogger(): winston.Logger;
|
|
31
35
|
export interface EmitAsyncOptions {
|
|
32
36
|
/**
|
|
@@ -53,7 +57,11 @@ export declare class Adminizer {
|
|
|
53
57
|
router: Router;
|
|
54
58
|
notificationHandler: NotificationHandler;
|
|
55
59
|
historyHandler: HistoryHandler;
|
|
56
|
-
|
|
60
|
+
private _aiAssistantHandler?;
|
|
61
|
+
aiAssistantUiMethodHandler: AiAssistantUiMethodHandler;
|
|
62
|
+
adminLinkHandler: AdminLinkHandler;
|
|
63
|
+
aiAssistantAgentSkillHandler: AiAssistantAgentSkillHandler;
|
|
64
|
+
documentationHandler: DocumentationHandler;
|
|
57
65
|
modelHandler: ModelHandler;
|
|
58
66
|
widgetHandler: WidgetHandler;
|
|
59
67
|
customFilterHandler: CustomFilterHandler;
|
|
@@ -71,6 +79,18 @@ export declare class Adminizer {
|
|
|
71
79
|
jwtSecret: string;
|
|
72
80
|
static logger: winston.Logger;
|
|
73
81
|
constructor(ormAdapters: AbstractAdapter[]);
|
|
82
|
+
/**
|
|
83
|
+
* Shared AI assistant model registry.
|
|
84
|
+
*
|
|
85
|
+
* Created lazily on first access, so host code can register models
|
|
86
|
+
* directly (`adminizer.aiAssistantHandler.registerModel(service)`) without
|
|
87
|
+
* declaring an app. Apps register their models in the same handler through
|
|
88
|
+
* `ctx.aiAssistant()` and own only their entries.
|
|
89
|
+
* `config.aiAssistant.enabled` stays a gate for controllers and the UI, not
|
|
90
|
+
* for the registry itself.
|
|
91
|
+
*/
|
|
92
|
+
get aiAssistantHandler(): AiAssistantHandler;
|
|
93
|
+
set aiAssistantHandler(handler: AiAssistantHandler | undefined);
|
|
74
94
|
getMiddleware(): (req: express.Request, res: express.Response, next: () => void) => void;
|
|
75
95
|
/**
|
|
76
96
|
* Vite middleware
|
package/lib/Adminizer.js
CHANGED
|
@@ -30,6 +30,7 @@ import { ControlsHandler } from "./controls/ControlsHandler.js";
|
|
|
30
30
|
import { CatalogHandler } from "./catalog/CatalogHandler.js";
|
|
31
31
|
import { CatalogTemplateComponentHandler } from "./catalog/CatalogTemplateComponentHandler.js";
|
|
32
32
|
import { v4 as uuid } from "uuid";
|
|
33
|
+
import { AiAssistantHandler } from './ai-assistant/AiAssistantHandler.js';
|
|
33
34
|
import { bindNotifications } from "../system/bindNotifications.js";
|
|
34
35
|
import { MediaManagerHandler } from "./media-manager/MediaManagerHandler.js";
|
|
35
36
|
import { bindCors } from "../system/bindCors.js";
|
|
@@ -42,6 +43,11 @@ import { ControllerHandler } from "./app-manager/ControllerHandler.js";
|
|
|
42
43
|
import { AssetHandler } from "./app-manager/AssetHandler.js";
|
|
43
44
|
import { ConfigLayerHandler } from "./app-manager/ConfigLayerHandler.js";
|
|
44
45
|
import { AccessRightsHandler } from "./access-rights/AccessRightsHandler.js";
|
|
46
|
+
import { AiAssistantUiMethodHandler } from './ai-assistant/AiAssistantUiMethodHandler.js';
|
|
47
|
+
import { AdminLinkHandler } from './admin-links/AdminLinkHandler.js';
|
|
48
|
+
import { AiAssistantAgentSkillHandler } from './ai-assistant/AiAssistantAgentSkillHandler.js';
|
|
49
|
+
import { DocumentationHandler } from './docs/DocumentationHandler.js';
|
|
50
|
+
import bindDocs from '../system/bindDocs.js';
|
|
45
51
|
const logFilePath = "logs/app.log";
|
|
46
52
|
function ensureLogDirectory(filePath) {
|
|
47
53
|
const logDirectory = path.dirname(filePath);
|
|
@@ -107,7 +113,11 @@ export class Adminizer {
|
|
|
107
113
|
router;
|
|
108
114
|
notificationHandler;
|
|
109
115
|
historyHandler;
|
|
110
|
-
|
|
116
|
+
_aiAssistantHandler;
|
|
117
|
+
aiAssistantUiMethodHandler;
|
|
118
|
+
adminLinkHandler;
|
|
119
|
+
aiAssistantAgentSkillHandler;
|
|
120
|
+
documentationHandler;
|
|
111
121
|
modelHandler;
|
|
112
122
|
widgetHandler;
|
|
113
123
|
customFilterHandler;
|
|
@@ -140,11 +150,32 @@ export class Adminizer {
|
|
|
140
150
|
this.catalogTemplateComponentHandler = new CatalogTemplateComponentHandler();
|
|
141
151
|
this.mediaManagerHandler = new MediaManagerHandler();
|
|
142
152
|
this.feedbackHandler = new FeedbackHandler(this);
|
|
153
|
+
this.aiAssistantUiMethodHandler = new AiAssistantUiMethodHandler(this);
|
|
154
|
+
this.adminLinkHandler = new AdminLinkHandler(this);
|
|
155
|
+
this.aiAssistantAgentSkillHandler = new AiAssistantAgentSkillHandler(this);
|
|
156
|
+
this.documentationHandler = new DocumentationHandler(this, () => bindDocs(this));
|
|
143
157
|
this.controllerHandler = new ControllerHandler(this);
|
|
144
158
|
this.assetHandler = new AssetHandler(this);
|
|
145
159
|
this.configLayerHandler = new ConfigLayerHandler(this);
|
|
146
160
|
this.appManager = new AppManager(this);
|
|
147
161
|
}
|
|
162
|
+
/**
|
|
163
|
+
* Shared AI assistant model registry.
|
|
164
|
+
*
|
|
165
|
+
* Created lazily on first access, so host code can register models
|
|
166
|
+
* directly (`adminizer.aiAssistantHandler.registerModel(service)`) without
|
|
167
|
+
* declaring an app. Apps register their models in the same handler through
|
|
168
|
+
* `ctx.aiAssistant()` and own only their entries.
|
|
169
|
+
* `config.aiAssistant.enabled` stays a gate for controllers and the UI, not
|
|
170
|
+
* for the registry itself.
|
|
171
|
+
*/
|
|
172
|
+
get aiAssistantHandler() {
|
|
173
|
+
this._aiAssistantHandler ??= new AiAssistantHandler(this);
|
|
174
|
+
return this._aiAssistantHandler;
|
|
175
|
+
}
|
|
176
|
+
set aiAssistantHandler(handler) {
|
|
177
|
+
this._aiAssistantHandler = handler;
|
|
178
|
+
}
|
|
148
179
|
getMiddleware() {
|
|
149
180
|
return (req, res, next) => {
|
|
150
181
|
try {
|
|
@@ -275,6 +306,11 @@ export class Adminizer {
|
|
|
275
306
|
bindHistory(this);
|
|
276
307
|
this.router = new Router(this);
|
|
277
308
|
await this.router.bind(); // must be after binding policies and req/res functions
|
|
309
|
+
// Documentation (knowledge base) wires itself on register(); this call
|
|
310
|
+
// covers a service registered before the config was read. It runs after
|
|
311
|
+
// the router so those routes sit behind the same middleware stack a
|
|
312
|
+
// service registered after init() gets.
|
|
313
|
+
this.documentationHandler.activate();
|
|
278
314
|
/**
|
|
279
315
|
* Adminizer loaded
|
|
280
316
|
* This call is used so that other apps can know that the admin panel is present in the panel and has been loaded, and can activate their logic.
|
package/lib/DataAccessor.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The class manages the interaction between the user and the database entry, taking into account user permissions and the main config file settings.
|
|
3
3
|
*/
|
|
4
|
-
import { ModelResource } from "../interfaces/types";
|
|
5
|
-
import { ActionType } from "../interfaces/adminpanelConfig";
|
|
6
|
-
import { Fields } from "../helpers/fieldsHelper";
|
|
7
|
-
import { Adminizer } from "./Adminizer";
|
|
8
|
-
import { User } from "../models/User";
|
|
9
|
-
import { QueryCriteria } from "../interfaces/queryCriteria";
|
|
4
|
+
import { ModelResource } from "../interfaces/types.js";
|
|
5
|
+
import { ActionType } from "../interfaces/adminpanelConfig.js";
|
|
6
|
+
import { Fields } from "../helpers/fieldsHelper.js";
|
|
7
|
+
import { Adminizer } from "./Adminizer.js";
|
|
8
|
+
import { User } from "../models/User.js";
|
|
9
|
+
import { QueryCriteria } from "../interfaces/queryCriteria.js";
|
|
10
10
|
export declare class DataAccessor {
|
|
11
11
|
readonly adminizer: Adminizer;
|
|
12
12
|
user: User;
|
|
@@ -18,6 +18,7 @@ export declare class DataAccessor {
|
|
|
18
18
|
private getModelConfig;
|
|
19
19
|
private accessRelationModel;
|
|
20
20
|
private resolveRelationTarget;
|
|
21
|
+
private getRelationModel;
|
|
21
22
|
/**
|
|
22
23
|
* Retrieves the fields for the given ModelResource based on action type,
|
|
23
24
|
* taking into account access rights and configuration settings.
|