@arkxos/arkos-system 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -0
- package/ark_dist/664d11f069eab128.css +2 -0
- package/ark_dist/ArkOsConfig.js +136 -0
- package/ark_dist/ark-meta.json +92 -0
- package/ark_dist/ark_userChunk_1.js +3 -0
- package/ark_dist/ark_userChunk_2.js +5 -0
- package/ark_dist/ark_userChunk_3.js +49 -0
- package/ark_dist/config.js +75 -0
- package/ark_dist/css/views/views-flow-flow.ca26b106.css +5784 -0
- package/ark_dist/favicon.ico +0 -0
- package/ark_dist/fonts/bpmn.5d33bee4.eot +0 -0
- package/ark_dist/fonts/bpmn.67058807.woff2 +0 -0
- package/ark_dist/fonts/bpmn.b5c9250d.ttf +0 -0
- package/ark_dist/fonts/bpmn.e9e7d076.woff +0 -0
- package/ark_dist/img/404.png +0 -0
- package/ark_dist/img/auth_banner.jpg +0 -0
- package/ark_dist/img/avatar.jpg +0 -0
- package/ark_dist/img/avatar2.gif +0 -0
- package/ark_dist/img/avatar3.gif +0 -0
- package/ark_dist/img/bpmn.74eea12b.svg +224 -0
- package/ark_dist/img/loginbg.svg +1 -0
- package/ark_dist/img/logo-r.png +0 -0
- package/ark_dist/img/logo.png +0 -0
- package/ark_dist/img/mobile-bg.d055fadc.png +0 -0
- package/ark_dist/img/no-widgets.svg +57 -0
- package/ark_dist/img/tasks-example.png +0 -0
- package/ark_dist/img/ver.svg +236 -0
- package/ark_dist/index.html +118 -0
- package/ark_dist/js/app.e39a548a.js +1 -0
- package/ark_dist/js/views/views-flow-flow.84dc5300.js +3 -0
- package/ark_dist/js/views/views-flow-flow.84dc5300.js.LICENSE.txt +182 -0
- package/ark_dist/js/views/views-flow-flow.84dc5300.js.map +1 -0
- package/ark_proxy/entry.js +28 -0
- package/ark_proxy_es/entry.js +16 -0
- package/package.json +173 -0
- package/scripts/check.js +13 -0
- package/scripts/meta.js +21 -0
- package/scripts/prepublishOnly.js +28 -0
- package/src/admin/App.vue +13 -0
- package/src/admin/bpmn/custom/context-pad.js +405 -0
- package/src/admin/bpmn/custom/index.js +8 -0
- package/src/admin/bpmn/custom/palette.js +159 -0
- package/src/admin/bpmn/properties-panel/PropertiesView.vue +620 -0
- package/src/admin/bpmn/translate.js +23 -0
- package/src/admin/bpmn/translations.js +211 -0
- package/src/admin/components/affix/index.vue +385 -0
- package/src/admin/components/area-select/index.vue +52 -0
- package/src/admin/components/buttons/index.vue +47 -0
- package/src/admin/components/checkbox/index.vue +83 -0
- package/src/admin/components/code/code.js +149 -0
- package/src/admin/components/code/index.vue +450 -0
- package/src/admin/components/color/index.vue +30 -0
- package/src/admin/components/color-picker/index.vue +57 -0
- package/src/admin/components/color-scheme/index.vue +234 -0
- package/src/admin/components/condition-list/index.vue +170 -0
- package/src/admin/components/date/index.vue +29 -0
- package/src/admin/components/datetime/index.vue +45 -0
- package/src/admin/components/default-value-tips/index.vue +44 -0
- package/src/admin/components/dict-buttons/index.vue +53 -0
- package/src/admin/components/dict-checkbox/index.vue +45 -0
- package/src/admin/components/dict-radio/index.vue +68 -0
- package/src/admin/components/dict-select/index.vue +93 -0
- package/src/admin/components/dict-selects/index.vue +105 -0
- package/src/admin/components/dict-switch/index.vue +64 -0
- package/src/admin/components/dict-tree/index.vue +17 -0
- package/src/admin/components/dm-tree/index.vue +224 -0
- package/src/admin/components/edit-table/index.vue +171 -0
- package/src/admin/components/employee-tree/index.vue +247 -0
- package/src/admin/components/employees-tree/index.vue +80 -0
- package/src/admin/components/entp-tree/index.vue +266 -0
- package/src/admin/components/file/index.vue +310 -0
- package/src/admin/components/form/index.vue +141 -0
- package/src/admin/components/icon/index.vue +77 -0
- package/src/admin/components/icon-buttons/index.vue +52 -0
- package/src/admin/components/icon-select/index.vue +140 -0
- package/src/admin/components/image/index.vue +207 -0
- package/src/admin/components/index.js +16 -0
- package/src/admin/components/input/index.vue +41 -0
- package/src/admin/components/local-img/index.vue +49 -0
- package/src/admin/components/multiple-input/index.vue +64 -0
- package/src/admin/components/multiple-number/index.vue +70 -0
- package/src/admin/components/number/index.vue +134 -0
- package/src/admin/components/organization/index.vue +303 -0
- package/src/admin/components/organization-tree/index.vue +269 -0
- package/src/admin/components/page/index.vue +149 -0
- package/src/admin/components/password/index.vue +21 -0
- package/src/admin/components/radio/index.vue +46 -0
- package/src/admin/components/region-tree/index.vue +269 -0
- package/src/admin/components/remote-select/index.vue +315 -0
- package/src/admin/components/rich-editor/index.vue +152 -0
- package/src/admin/components/role-select/index.vue +58 -0
- package/src/admin/components/script-input/index.vue +97 -0
- package/src/admin/components/select/index.vue +105 -0
- package/src/admin/components/selects/index.vue +100 -0
- package/src/admin/components/style-list/index.vue +500 -0
- package/src/admin/components/switch/index.vue +54 -0
- package/src/admin/components/table/index.vue +920 -0
- package/src/admin/components/textarea/index.vue +28 -0
- package/src/admin/components/tree/index.vue +247 -0
- package/src/admin/components/tree-selects/index.vue +66 -0
- package/src/admin/components/unit-tree/index.vue +269 -0
- package/src/admin/console/index.vue +122 -0
- package/src/admin/layout/console/index.vue +15 -0
- package/src/admin/layout/fullscreen/index.vue +32 -0
- package/src/admin/layout/home/index.vue +11 -0
- package/src/admin/layout/index.vue +139 -0
- package/src/admin/layout/menu/index.vue +102 -0
- package/src/admin/layout/personnel/index.vue +166 -0
- package/src/admin/layout/search/index.vue +78 -0
- package/src/admin/main.js +30 -0
- package/src/admin/pinia/router.js +179 -0
- package/src/admin/router.js +91 -0
- package/src/admin/visual/comp-data.vue +1107 -0
- package/src/admin/visual/comp-event.vue +1677 -0
- package/src/admin/visual/components/app/list/goods/double.vue +184 -0
- package/src/admin/visual/components/app/list/nav/image.vue +114 -0
- package/src/admin/visual/components/app/list/nav/text.vue +130 -0
- package/src/admin/visual/components/button/index.vue +58 -0
- package/src/admin/visual/components/container/index.vue +37 -0
- package/src/admin/visual/components/custom-list/index.vue +127 -0
- package/src/admin/visual/components/data/index.vue +46 -0
- package/src/admin/visual/components/data-table/index.vue +203 -0
- package/src/admin/visual/components/echarts/annular.vue +140 -0
- package/src/admin/visual/components/echarts/bar.vue +115 -0
- package/src/admin/visual/components/echarts/funnel.vue +115 -0
- package/src/admin/visual/components/echarts/gauge.vue +158 -0
- package/src/admin/visual/components/echarts/line.vue +110 -0
- package/src/admin/visual/components/echarts/map.vue +150 -0
- package/src/admin/visual/components/echarts/pie.vue +114 -0
- package/src/admin/visual/components/echarts/radar.vue +145 -0
- package/src/admin/visual/components/echarts/scatter.vue +106 -0
- package/src/admin/visual/components/edit-table/index.vue +71 -0
- package/src/admin/visual/components/form/affix.vue +107 -0
- package/src/admin/visual/components/form/area.vue +76 -0
- package/src/admin/visual/components/form/buttons.vue +90 -0
- package/src/admin/visual/components/form/checkbox.vue +85 -0
- package/src/admin/visual/components/form/date-range.vue +61 -0
- package/src/admin/visual/components/form/date.vue +59 -0
- package/src/admin/visual/components/form/datetime.vue +59 -0
- package/src/admin/visual/components/form/employee-tree.vue +88 -0
- package/src/admin/visual/components/form/employees-tree.vue +6 -0
- package/src/admin/visual/components/form/image.vue +103 -0
- package/src/admin/visual/components/form/index.vue +59 -0
- package/src/admin/visual/components/form/input.vue +84 -0
- package/src/admin/visual/components/form/item.vue +68 -0
- package/src/admin/visual/components/form/number.vue +130 -0
- package/src/admin/visual/components/form/organization-tree.vue +88 -0
- package/src/admin/visual/components/form/password.vue +74 -0
- package/src/admin/visual/components/form/radio.vue +87 -0
- package/src/admin/visual/components/form/rate.vue +66 -0
- package/src/admin/visual/components/form/region-tree.vue +88 -0
- package/src/admin/visual/components/form/rich-editor.vue +94 -0
- package/src/admin/visual/components/form/select.vue +156 -0
- package/src/admin/visual/components/form/switch.vue +85 -0
- package/src/admin/visual/components/form/textarea.vue +62 -0
- package/src/admin/visual/components/form/unit-tree.vue +88 -0
- package/src/admin/visual/components/icon/index.vue +65 -0
- package/src/admin/visual/components/image/index.vue +170 -0
- package/src/admin/visual/components/index.js +44 -0
- package/src/admin/visual/components/list/block.vue +160 -0
- package/src/admin/visual/components/list/button.vue +80 -0
- package/src/admin/visual/components/list/card.vue +101 -0
- package/src/admin/visual/components/list/custom.vue +150 -0
- package/src/admin/visual/components/list/image.vue +116 -0
- package/src/admin/visual/components/list/news.vue +138 -0
- package/src/admin/visual/components/page/index.vue +88 -0
- package/src/admin/visual/components/page-comp/index.vue +110 -0
- package/src/admin/visual/components/portal-menu/index.vue +92 -0
- package/src/admin/visual/components/qrcode/index.vue +77 -0
- package/src/admin/visual/components/router-view/index.vue +12 -0
- package/src/admin/visual/components/row/index.vue +139 -0
- package/src/admin/visual/components/search/index.vue +40 -0
- package/src/admin/visual/components/tabs/index.vue +125 -0
- package/src/admin/visual/components/text/index.vue +64 -0
- package/src/admin/visual/components/video/index.vue +41 -0
- package/src/admin/visual/draggable.vue +49 -0
- package/src/admin/visual/editor.vue +602 -0
- package/src/admin/visual/js/app-form.config.js +1301 -0
- package/src/admin/visual/js/app.config.js +86 -0
- package/src/admin/visual/js/common.config.js +687 -0
- package/src/admin/visual/js/component.config.js +741 -0
- package/src/admin/visual/js/echarts.config.js +2440 -0
- package/src/admin/visual/js/form.config.js +2837 -0
- package/src/admin/visual/js/list.config.js +578 -0
- package/src/admin/visual/js/menu.config.js +62 -0
- package/src/admin/visual/js/visual-comp.js +48 -0
- package/src/admin/visual/tool.vue +1223 -0
- package/src/assets/images/background.jpg +0 -0
- package/src/assets/images/login-bg.jpg +0 -0
- package/src/assets/images/mobile-bg.png +0 -0
- package/src/assets/images/no-data.png +0 -0
- package/src/assets/style/base.css +48 -0
- package/src/assets/style/business.css +5 -0
- package/src/assets/style/code.css +36 -0
- package/src/assets/style/codeless.css +195 -0
- package/src/assets/style/flow.css +12 -0
- package/src/assets/style/global/blue.css +83 -0
- package/src/assets/style/global/default.css +71 -0
- package/src/assets/style/global/green.css +83 -0
- package/src/assets/style/global/purple.css +83 -0
- package/src/assets/style/global/red.css +83 -0
- package/src/assets/style/main.css +608 -0
- package/src/assets/style/menu/black.css +9 -0
- package/src/assets/style/menu/default.css +9 -0
- package/src/assets/style/menu/grey.css +9 -0
- package/src/assets/style/visual.css +204 -0
- package/src/auto-imports.d.ts +307 -0
- package/src/business/App.vue +131 -0
- package/src/business/components/dict-select/index.vue +88 -0
- package/src/business/components/index.js +13 -0
- package/src/business/components/input/index.vue +38 -0
- package/src/business/components/table/index.vue +928 -0
- package/src/business/home/index.vue +45 -0
- package/src/business/iframe/index.vue +63 -0
- package/src/business/layout/aside/history/history.vue +518 -0
- package/src/business/layout/aside/index.vue +116 -0
- package/src/business/layout/aside/menu/index.vue +47 -0
- package/src/business/layout/aside/menu/menuItem.vue +83 -0
- package/src/business/layout/aside/menu/submenu.vue +88 -0
- package/src/business/layout/fullscreen/index.vue +41 -0
- package/src/business/layout/header/index.vue +81 -0
- package/src/business/layout/header/menu/index.vue +47 -0
- package/src/business/layout/header/menu/menuItem.vue +43 -0
- package/src/business/layout/header/menu/submenu.vue +34 -0
- package/src/business/layout/home/index.vue +20 -0
- package/src/business/layout/index.vue +330 -0
- package/src/business/layout/message/index.vue +250 -0
- package/src/business/layout/personnel/index.vue +549 -0
- package/src/business/layout/search/index.vue +75 -0
- package/src/business/layout/subsystem/index.vue +124 -0
- package/src/business/main.js +36 -0
- package/src/business/pinia/menuBadge.js +58 -0
- package/src/business/pinia/router.js +190 -0
- package/src/business/router.js +98 -0
- package/src/choose/App.vue +203 -0
- package/src/choose/main.js +22 -0
- package/src/choose/router.js +33 -0
- package/src/codeless/components/affix/index.vue +393 -0
- package/src/codeless/components/affix-view/index.vue +244 -0
- package/src/codeless/components/buttons/index.vue +59 -0
- package/src/codeless/components/checkbox/index.vue +107 -0
- package/src/codeless/components/date/index.vue +105 -0
- package/src/codeless/components/datetime/index.vue +65 -0
- package/src/codeless/components/dialog-select/index.vue +170 -0
- package/src/codeless/components/dict-buttons/index.vue +97 -0
- package/src/codeless/components/dict-radio/index.vue +94 -0
- package/src/codeless/components/dict-select/index.vue +181 -0
- package/src/codeless/components/dict-selects/index.vue +145 -0
- package/src/codeless/components/dict-switch/index.vue +94 -0
- package/src/codeless/components/dict-tree/index.vue +116 -0
- package/src/codeless/components/edit-table/index.vue +160 -0
- package/src/codeless/components/employee-tree/index.vue +254 -0
- package/src/codeless/components/employees-tree/index.vue +87 -0
- package/src/codeless/components/entp-tree/index.vue +261 -0
- package/src/codeless/components/entps-tree/index.vue +93 -0
- package/src/codeless/components/icon/index.vue +65 -0
- package/src/codeless/components/image/index.vue +298 -0
- package/src/codeless/components/index.js +16 -0
- package/src/codeless/components/input/index.vue +63 -0
- package/src/codeless/components/number/index.vue +150 -0
- package/src/codeless/components/organization-tree/index.vue +262 -0
- package/src/codeless/components/organizations-tree/index.vue +79 -0
- package/src/codeless/components/password/index.vue +42 -0
- package/src/codeless/components/radio/index.vue +57 -0
- package/src/codeless/components/region-tree/index.vue +262 -0
- package/src/codeless/components/remote-distinct/index.vue +354 -0
- package/src/codeless/components/remote-select/index.vue +363 -0
- package/src/codeless/components/rich-editor/index.vue +159 -0
- package/src/codeless/components/roles/index.vue +68 -0
- package/src/codeless/components/select/index.vue +95 -0
- package/src/codeless/components/selects/index.vue +116 -0
- package/src/codeless/components/show-dict/index.vue +52 -0
- package/src/codeless/components/show-employees/index.vue +29 -0
- package/src/codeless/components/show-organizations/index.vue +29 -0
- package/src/codeless/components/show-roles/index.vue +45 -0
- package/src/codeless/components/signature-pad/index.vue +224 -0
- package/src/codeless/components/switch/index.vue +56 -0
- package/src/codeless/components/textarea/index.vue +37 -0
- package/src/codeless/components/tree/index.vue +244 -0
- package/src/codeless/components/unit-tree/index.vue +262 -0
- package/src/codeless/components/units-tree/index.vue +93 -0
- package/src/codeless/components/video/index.vue +255 -0
- package/src/codeless/components/video-view/index.vue +130 -0
- package/src/codeless/js/codeless.js +47 -0
- package/src/codeless/view/form-auto.vue +192 -0
- package/src/codeless/view/form-custom.vue +10 -0
- package/src/codeless/view/form-model.vue +421 -0
- package/src/codeless/view/form-query.vue +171 -0
- package/src/codeless/view/form.vue +575 -0
- package/src/codeless/view/page-comp.vue +1318 -0
- package/src/codeless/view/page.vue +280 -0
- package/src/codeless/view/table-edit-item.vue +184 -0
- package/src/codeless/view/table-edit.vue +490 -0
- package/src/codeless/view/table.vue +1606 -0
- package/src/codeless/view/tree.vue +431 -0
- package/src/configs/subApp.ts +9 -0
- package/src/directives/collapse/index.js +123 -0
- package/src/directives/drag/index.js +43 -0
- package/src/directives/index.js +9 -0
- package/src/directives/resize/index.js +23 -0
- package/src/entrance/libProperties.ts +24 -0
- package/src/entrance/libTypes.ts +26 -0
- package/src/error/404.vue +23 -0
- package/src/flow/chart.vue +130 -0
- package/src/flow/deal.vue +776 -0
- package/src/flow/signature.vue +216 -0
- package/src/flow/start.vue +18 -0
- package/src/http/api.js +192 -0
- package/src/http/request.js +81 -0
- package/src/login/App.vue +421 -0
- package/src/login/main.js +30 -0
- package/src/login/router.js +33 -0
- package/src/main.ts +20 -0
- package/src/mobile/App.vue +51 -0
- package/src/mobile/home/index.vue +34 -0
- package/src/mobile/main.js +26 -0
- package/src/mobile/router.js +101 -0
- package/src/mobile/view/page.vue +99 -0
- package/src/pinia/index.js +5 -0
- package/src/pinia/modules/dataField.js +77 -0
- package/src/pinia/modules/dataForm.js +46 -0
- package/src/pinia/modules/dataTable.js +46 -0
- package/src/pinia/modules/dictionary.js +66 -0
- package/src/pinia/modules/employee.js +46 -0
- package/src/pinia/modules/icon.js +46 -0
- package/src/pinia/modules/keepAlive.js +35 -0
- package/src/pinia/modules/organization.js +189 -0
- package/src/pinia/modules/page.js +46 -0
- package/src/pinia/modules/pageButton.js +44 -0
- package/src/pinia/modules/pageComp.js +46 -0
- package/src/pinia/modules/role.js +46 -0
- package/src/pinia/modules/setting.js +56 -0
- package/src/pinia/modules/subsystem.js +64 -0
- package/src/pinia/modules/user.js +177 -0
- package/src/plugins/index.ts +24 -0
- package/src/portal/App.vue +27 -0
- package/src/portal/home/index.vue +52 -0
- package/src/portal/main.js +31 -0
- package/src/portal/page/index.vue +39 -0
- package/src/portal/pinia/router.js +176 -0
- package/src/portal/router.js +86 -0
- package/src/router/constantRoutes.ts +13 -0
- package/src/router/loadComponent.ts +29 -0
- package/src/router/readme.txt +21 -0
- package/src/sso/sso.js +19 -0
- package/src/sso/sso.vue +138 -0
- package/src/types/axios.d.ts +13 -0
- package/src/types/func.ts +14 -0
- package/src/types/global.d.ts +108 -0
- package/src/types/layout.d.ts +59 -0
- package/src/types/mitt.d.ts +40 -0
- package/src/types/pinia.d.ts +93 -0
- package/src/types/views.d.ts +27 -0
- package/src/types/window.d.ts +8 -0
- package/src/utils/aes.js +75 -0
- package/src/utils/browser.js +13 -0
- package/src/utils/bus.js +4 -0
- package/src/utils/cache.js +6 -0
- package/src/utils/codeless.js +92 -0
- package/src/utils/color.js +274 -0
- package/src/utils/date.js +180 -0
- package/src/utils/loading.js +22 -0
- package/src/utils/page.js +36 -0
- package/src/utils/progress.js +19 -0
- package/src/utils/system.js +92 -0
- package/src/utils/theme.js +79 -0
- package/src/utils/tool.js +431 -0
- package/src/utils/websocket.js +124 -0
- package/src/views/codeless/appVersion.vue +593 -0
- package/src/views/codeless/dataFormEdit.vue +1463 -0
- package/src/views/codeless/dataModel.vue +2584 -0
- package/src/views/codeless/dataModelPage.vue +535 -0
- package/src/views/codeless/dataTableEdit.vue +1678 -0
- package/src/views/codeless/datasource.vue +308 -0
- package/src/views/codeless/interface.vue +833 -0
- package/src/views/codeless/interfaceToken.vue +255 -0
- package/src/views/codeless/page.vue +752 -0
- package/src/views/codeless/pageButton.vue +255 -0
- package/src/views/codeless/pageCompEdit.vue +2330 -0
- package/src/views/codeless/pageEdit.vue +661 -0
- package/src/views/codeless/relationPage.vue +349 -0
- package/src/views/codeless/scriptGroovy.vue +736 -0
- package/src/views/codeless/scriptGroovyEdit.vue +248 -0
- package/src/views/codeless/scriptGroovyExecute.vue +212 -0
- package/src/views/codeless/scriptGroovySimple.vue +1057 -0
- package/src/views/codeless/scriptTool.vue +563 -0
- package/src/views/codeless/subsystem.vue +309 -0
- package/src/views/codeless/template.vue +739 -0
- package/src/views/codeless/variable.vue +727 -0
- package/src/views/codeless/view.vue +738 -0
- package/src/views/codeless/viewEdit.vue +244 -0
- package/src/views/codeless/viewSimple.vue +1034 -0
- package/src/views/collect/task.vue +898 -0
- package/src/views/collect/taskLog.vue +238 -0
- package/src/views/dictionary/dictionary.vue +866 -0
- package/src/views/employee/employee.vue +355 -0
- package/src/views/flow/flow.vue +369 -0
- package/src/views/flow/flowInst.vue +73 -0
- package/src/views/flow/flowLineBranch.vue +406 -0
- package/src/views/flow/flowNodeMan.vue +426 -0
- package/src/views/flow/flowOpinion.vue +188 -0
- package/src/views/icon/icon.vue +242 -0
- package/src/views/log/loginLog.vue +41 -0
- package/src/views/log/operatorLog.vue +176 -0
- package/src/views/menu/menu.vue +883 -0
- package/src/views/menu/menuList.vue +858 -0
- package/src/views/message/message.vue +299 -0
- package/src/views/mobile/editor.vue +1100 -0
- package/src/views/mobile/mobile.vue +568 -0
- package/src/views/mobile/tool.vue +1258 -0
- package/src/views/monitor/database.vue +11 -0
- package/src/views/monitor/details-diskspace.vue +56 -0
- package/src/views/monitor/details-gc.vue +93 -0
- package/src/views/monitor/details-memory.vue +143 -0
- package/src/views/monitor/details-process.vue +132 -0
- package/src/views/monitor/details-threads.vue +106 -0
- package/src/views/monitor/line-chart.vue +93 -0
- package/src/views/monitor/mem-chart.vue +22 -0
- package/src/views/monitor/panel.vue +90 -0
- package/src/views/monitor/performance.vue +36 -0
- package/src/views/monitor/threads-chart.vue +16 -0
- package/src/views/operation/backup.vue +593 -0
- package/src/views/operation/center.vue +420 -0
- package/src/views/operation/restore.vue +94 -0
- package/src/views/organization/organization.vue +366 -0
- package/src/views/role/role.vue +502 -0
- package/src/views/schedule/schedule.vue +338 -0
- package/src/views/schedule/scheduleLog.vue +40 -0
- package/src/views/sequence/sequence.vue +283 -0
- package/src/views/setting/setting.vue +371 -0
- package/src/visual/components/app/list/goods/double.vue +241 -0
- package/src/visual/components/app/list/nav/image.vue +135 -0
- package/src/visual/components/app/list/nav/text.vue +159 -0
- package/src/visual/components/button/index.vue +95 -0
- package/src/visual/components/container/index.vue +128 -0
- package/src/visual/components/data/index.vue +60 -0
- package/src/visual/components/data-table/index.vue +260 -0
- package/src/visual/components/echarts/annular.vue +173 -0
- package/src/visual/components/echarts/bar.vue +172 -0
- package/src/visual/components/echarts/funnel.vue +167 -0
- package/src/visual/components/echarts/gauge.vue +186 -0
- package/src/visual/components/echarts/line.vue +172 -0
- package/src/visual/components/echarts/map.vue +206 -0
- package/src/visual/components/echarts/pie.vue +158 -0
- package/src/visual/components/echarts/radar.vue +196 -0
- package/src/visual/components/echarts/scatter.vue +153 -0
- package/src/visual/components/edit-table/index.vue +71 -0
- package/src/visual/components/form/affix.vue +440 -0
- package/src/visual/components/form/area.vue +134 -0
- package/src/visual/components/form/buttons.vue +120 -0
- package/src/visual/components/form/checkbox.vue +126 -0
- package/src/visual/components/form/date-range.vue +97 -0
- package/src/visual/components/form/date.vue +88 -0
- package/src/visual/components/form/datetime.vue +87 -0
- package/src/visual/components/form/employee-tree.vue +300 -0
- package/src/visual/components/form/employees-tree.vue +91 -0
- package/src/visual/components/form/image.vue +440 -0
- package/src/visual/components/form/index.vue +85 -0
- package/src/visual/components/form/input.vue +116 -0
- package/src/visual/components/form/item.vue +68 -0
- package/src/visual/components/form/number.vue +157 -0
- package/src/visual/components/form/organization-tree.vue +300 -0
- package/src/visual/components/form/password.vue +103 -0
- package/src/visual/components/form/radio.vue +122 -0
- package/src/visual/components/form/rate.vue +93 -0
- package/src/visual/components/form/region-tree.vue +300 -0
- package/src/visual/components/form/rich-editor.vue +114 -0
- package/src/visual/components/form/select.vue +172 -0
- package/src/visual/components/form/switch.vue +105 -0
- package/src/visual/components/form/textarea.vue +91 -0
- package/src/visual/components/form/unit-tree.vue +300 -0
- package/src/visual/components/icon/index.vue +73 -0
- package/src/visual/components/image/index.vue +445 -0
- package/src/visual/components/index.js +26 -0
- package/src/visual/components/list/block.vue +234 -0
- package/src/visual/components/list/button.vue +123 -0
- package/src/visual/components/list/card.vue +129 -0
- package/src/visual/components/list/custom.vue +214 -0
- package/src/visual/components/list/image.vue +182 -0
- package/src/visual/components/list/news.vue +174 -0
- package/src/visual/components/page-comp/index.vue +67 -0
- package/src/visual/components/portal-menu/index.vue +191 -0
- package/src/visual/components/qrcode/index.vue +98 -0
- package/src/visual/components/router-view/index.vue +51 -0
- package/src/visual/components/row/index.vue +175 -0
- package/src/visual/components/search/index.vue +96 -0
- package/src/visual/components/tabs/index.vue +103 -0
- package/src/visual/components/text/index.vue +111 -0
- package/src/visual/components/video/index.vue +93 -0
- package/src/visual/js/echarts.js +220 -0
- package/src/visual/js/event.js +476 -0
- package/src/visual/js/visual-comp.js +48 -0
- package/src/visual/js/visual.js +508 -0
- package/src/visual/view/page.vue +357 -0
|
@@ -0,0 +1,1107 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
v-if="activatedNode.compData.inputData"
|
|
4
|
+
class="data-box"
|
|
5
|
+
>
|
|
6
|
+
<el-collapse v-model="collapseNames">
|
|
7
|
+
<el-collapse-item title="输入参数" name="param">
|
|
8
|
+
<div
|
|
9
|
+
v-if="activatedNode.compData.inputParamList && activatedNode.compData.inputParamList.length > 0"
|
|
10
|
+
class="data-list"
|
|
11
|
+
>
|
|
12
|
+
<div
|
|
13
|
+
class="data-item"
|
|
14
|
+
v-for="(param, index) in activatedNode.compData.inputParamList || []"
|
|
15
|
+
:key="index"
|
|
16
|
+
>
|
|
17
|
+
<div class="label" style="margin-right: 5px;">
|
|
18
|
+
<el-input
|
|
19
|
+
v-model="param.name"
|
|
20
|
+
@change="initNodeOptions()"
|
|
21
|
+
size="small"
|
|
22
|
+
title="参数名"
|
|
23
|
+
/>
|
|
24
|
+
</div>
|
|
25
|
+
<div v-if="param.input" style="flex-grow: 1">
|
|
26
|
+
<el-input v-model="param.value" title="默认值" size="small" />
|
|
27
|
+
</div>
|
|
28
|
+
<div v-else style="flex-grow: 1">
|
|
29
|
+
<ac-select
|
|
30
|
+
v-model="param.value"
|
|
31
|
+
:options="globalParamOptions"
|
|
32
|
+
title="默认值"
|
|
33
|
+
size="small"
|
|
34
|
+
/>
|
|
35
|
+
</div>
|
|
36
|
+
<div style="margin-left: 5px;flex-shrink: 0">
|
|
37
|
+
<ac-switch
|
|
38
|
+
v-model="param.input"
|
|
39
|
+
:options="[{key: true, value: ''}, {key: false, value: ''}]"
|
|
40
|
+
title="手动输入"
|
|
41
|
+
size="small"
|
|
42
|
+
/>
|
|
43
|
+
</div>
|
|
44
|
+
<ac-icon
|
|
45
|
+
iconId="018dc9c3efd3a0502886"
|
|
46
|
+
title="删除"
|
|
47
|
+
color="red"
|
|
48
|
+
@click="deleteInputParam(index)"
|
|
49
|
+
/>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
<div class="data-add-box">
|
|
53
|
+
<div class="data-add" @click="addInputParam">
|
|
54
|
+
<ac-icon iconId="018dca3b4707c4c43a2f" />
|
|
55
|
+
<span style="margin-left: 5px;font-size: 13px;">添加参数</span>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
</el-collapse-item>
|
|
59
|
+
<el-collapse-item title="数据源" name="dataSource">
|
|
60
|
+
<div class="data-list">
|
|
61
|
+
<div class="data-item">
|
|
62
|
+
<div class="label">数据类型:</div>
|
|
63
|
+
<div class="content">
|
|
64
|
+
<ac-select
|
|
65
|
+
v-model="activatedNode.compData.dataSourceType"
|
|
66
|
+
options="静态数据,输入参数,数据模型,视图,脚本"
|
|
67
|
+
size="small"
|
|
68
|
+
@change="changeDataSourceType"
|
|
69
|
+
/>
|
|
70
|
+
<ac-icon
|
|
71
|
+
v-if="activatedNode.compData.dataSourceType === '静态数据'"
|
|
72
|
+
iconId="018ece4f695f6947a2a8"
|
|
73
|
+
@click.stop="editDataList(activatedNode.compData.dataJson)"
|
|
74
|
+
/>
|
|
75
|
+
</div>
|
|
76
|
+
</div>
|
|
77
|
+
<div class="data-item" v-if="activatedNode.compData.dataSourceType === '静态数据'">
|
|
78
|
+
<div class="content">
|
|
79
|
+
<ac-textarea
|
|
80
|
+
v-model="activatedNode.compData.dataJson"
|
|
81
|
+
:rows="10"
|
|
82
|
+
size="small"
|
|
83
|
+
@change="changeDataJson"
|
|
84
|
+
/>
|
|
85
|
+
</div>
|
|
86
|
+
</div>
|
|
87
|
+
<div class="data-item" v-if="activatedNode.compData.dataSourceType === '输入参数'">
|
|
88
|
+
<div class="label">输入参数:</div>
|
|
89
|
+
<div class="content">
|
|
90
|
+
<ac-select
|
|
91
|
+
v-model="activatedNode.compData.inputParamId"
|
|
92
|
+
size="small"
|
|
93
|
+
:options="inputParamOptions"
|
|
94
|
+
/>
|
|
95
|
+
</div>
|
|
96
|
+
</div>
|
|
97
|
+
<div class="data-item" v-if="activatedNode.compData.dataSourceType === '数据模型'">
|
|
98
|
+
<div class="label">数据模型:</div>
|
|
99
|
+
<div class="content">
|
|
100
|
+
<ac-tree
|
|
101
|
+
v-model="activatedNode.compData.dataModelId"
|
|
102
|
+
data-url="/system/dataModel/queryTree"
|
|
103
|
+
typeSelect="model"
|
|
104
|
+
size="small"
|
|
105
|
+
@change="changeDataModel"
|
|
106
|
+
/>
|
|
107
|
+
</div>
|
|
108
|
+
</div>
|
|
109
|
+
<div class="data-item" v-if="activatedNode.compData.dataSourceType === '视图'">
|
|
110
|
+
<div class="label">视图:</div>
|
|
111
|
+
<div class="content">
|
|
112
|
+
<ac-tree
|
|
113
|
+
v-model="activatedNode.compData.viewId"
|
|
114
|
+
data-url="/system/view/queryTree"
|
|
115
|
+
typeSelect="view"
|
|
116
|
+
size="small"
|
|
117
|
+
@change="changeView"
|
|
118
|
+
/>
|
|
119
|
+
</div>
|
|
120
|
+
</div>
|
|
121
|
+
<div class="data-item" v-if="activatedNode.compData.dataSourceType === '脚本'">
|
|
122
|
+
<div class="label">脚本:</div>
|
|
123
|
+
<div class="content">
|
|
124
|
+
<ac-tree
|
|
125
|
+
v-model="activatedNode.compData.scriptId"
|
|
126
|
+
data-url="/system/scriptGroovy/queryTree"
|
|
127
|
+
type-select="script"
|
|
128
|
+
size="small"
|
|
129
|
+
@change="changeScript"
|
|
130
|
+
/>
|
|
131
|
+
</div>
|
|
132
|
+
</div>
|
|
133
|
+
</div>
|
|
134
|
+
</el-collapse-item>
|
|
135
|
+
<el-collapse-item
|
|
136
|
+
v-if="activatedNode.compData.dataSourceType === '输入参数'
|
|
137
|
+
|| activatedNode.compData.dataSourceType === '数据模型'
|
|
138
|
+
|| activatedNode.compData.dataSourceType === '视图'
|
|
139
|
+
|| activatedNode.compData.dataSourceType === '脚本'"
|
|
140
|
+
:title="(activatedNode.compData.dataSourceType === '输入参数'
|
|
141
|
+
|| activatedNode.compData.dataSourceType === '脚本') ? '输入参数' : '数据过滤'"
|
|
142
|
+
name="dataFilter"
|
|
143
|
+
>
|
|
144
|
+
<div
|
|
145
|
+
v-if="activatedNode.compData.dataSourceType === '脚本'
|
|
146
|
+
|| activatedNode.compData.dataSourceType === '输入参数'"
|
|
147
|
+
class="data-list"
|
|
148
|
+
>
|
|
149
|
+
<div
|
|
150
|
+
class="data-item"
|
|
151
|
+
v-for="(filter, index) in activatedNode.compData.filterList || []"
|
|
152
|
+
:key="index"
|
|
153
|
+
>
|
|
154
|
+
<div class="label" style="margin-right: 5px;">
|
|
155
|
+
<ac-input
|
|
156
|
+
v-model="filter.fieldId"
|
|
157
|
+
placeholder="参数名"
|
|
158
|
+
size="small"
|
|
159
|
+
title="参数名"
|
|
160
|
+
/>
|
|
161
|
+
</div>
|
|
162
|
+
<div v-if="filter.manually" style="flex-grow: 1">
|
|
163
|
+
<el-input v-model="filter.compareValue" title="参数值" size="small" />
|
|
164
|
+
</div>
|
|
165
|
+
<div v-else style="flex-grow: 1">
|
|
166
|
+
<ac-select
|
|
167
|
+
v-model="filter.compareValue"
|
|
168
|
+
:options="nodeOptions"
|
|
169
|
+
title="参数值"
|
|
170
|
+
size="small"
|
|
171
|
+
/>
|
|
172
|
+
</div>
|
|
173
|
+
<div style="margin-left: 5px;flex-shrink: 0">
|
|
174
|
+
<ac-switch
|
|
175
|
+
v-model="filter.manually"
|
|
176
|
+
:options="[{key: true, value: ''}, {key: false, value: ''}]"
|
|
177
|
+
title="手动输入"
|
|
178
|
+
size="small"
|
|
179
|
+
/>
|
|
180
|
+
</div>
|
|
181
|
+
<ac-icon
|
|
182
|
+
iconId="018dc9c3efd3a0502886"
|
|
183
|
+
title="删除过滤"
|
|
184
|
+
color="red"
|
|
185
|
+
@click="deleteFilter(index)"
|
|
186
|
+
/>
|
|
187
|
+
</div>
|
|
188
|
+
<div class="data-add-box">
|
|
189
|
+
<div class="data-add">
|
|
190
|
+
<ac-icon iconId="018dca3b4707c4c43a2f" />
|
|
191
|
+
<span style="font-size: 13px;" @click="addFilter">添加参数</span>
|
|
192
|
+
<ac-icon style="margin-left: 15px" iconId="018ece4f72d1bf69178b" />
|
|
193
|
+
<span style="font-size: 13px" @click="addAllFilter">一键添加</span>
|
|
194
|
+
</div>
|
|
195
|
+
</div>
|
|
196
|
+
</div>
|
|
197
|
+
<div class="filter" v-else>
|
|
198
|
+
<div
|
|
199
|
+
class="data-list"
|
|
200
|
+
v-for="(filter, index) in activatedNode.compData.filterList || []"
|
|
201
|
+
:key="index"
|
|
202
|
+
>
|
|
203
|
+
<div class="data-item">
|
|
204
|
+
<span class="label">拼接方式:</span>
|
|
205
|
+
<ac-select v-model="filter.connectSymbol" options="and,or" size="small" />
|
|
206
|
+
<ac-icon
|
|
207
|
+
v-if="index > 0 && index < (activatedNode.compData.filterList || []).length"
|
|
208
|
+
iconId="018fa3973ded010d7ef2"
|
|
209
|
+
title="上移"
|
|
210
|
+
style="margin-left: 10px"
|
|
211
|
+
@click="moveFilterUp(index)"
|
|
212
|
+
/>
|
|
213
|
+
<ac-icon
|
|
214
|
+
v-if="index < (activatedNode.compData.filterList || []).length - 1"
|
|
215
|
+
iconId="018fa397630c01052d7e"
|
|
216
|
+
title="下移"
|
|
217
|
+
@click="moveFilterDown(index)"
|
|
218
|
+
/>
|
|
219
|
+
<ac-icon
|
|
220
|
+
iconId="018dc9c3efd3a0502886"
|
|
221
|
+
title="删除过滤"
|
|
222
|
+
color="red"
|
|
223
|
+
@click="deleteFilter(index)"
|
|
224
|
+
/>
|
|
225
|
+
</div>
|
|
226
|
+
<div class="data-item">
|
|
227
|
+
<span class="label">前置括号:</span>
|
|
228
|
+
<span class="content">
|
|
229
|
+
<ac-select v-model="filter.frontBracket" options="(,((,(((,((((" size="small" />
|
|
230
|
+
</span>
|
|
231
|
+
</div>
|
|
232
|
+
<div class="data-item">
|
|
233
|
+
<span class="label">过滤字段:</span>
|
|
234
|
+
<span class="content">
|
|
235
|
+
<ac-select v-model="filter.fieldId" :options="fieldIdList" size="small" />
|
|
236
|
+
</span>
|
|
237
|
+
</div>
|
|
238
|
+
<div class="data-item">
|
|
239
|
+
<span class="label">比较符:</span>
|
|
240
|
+
<span class="content">
|
|
241
|
+
<ac-select
|
|
242
|
+
v-model="filter.compareSymbol"
|
|
243
|
+
options="大于,大于等于,等于,小于,小于等于,不等于,模糊"
|
|
244
|
+
size="small"
|
|
245
|
+
/>
|
|
246
|
+
</span>
|
|
247
|
+
</div>
|
|
248
|
+
<div class="data-item">
|
|
249
|
+
<span class="label">比较值:</span>
|
|
250
|
+
<div v-if="filter.manually" style="flex-grow: 1;">
|
|
251
|
+
<el-input v-model="filter.compareValue" size="small" />
|
|
252
|
+
</div>
|
|
253
|
+
<div v-else style="flex-grow: 1">
|
|
254
|
+
<ac-select
|
|
255
|
+
v-model="filter.compareValue"
|
|
256
|
+
:options="nodeOptions"
|
|
257
|
+
title="比较值"
|
|
258
|
+
size="small"
|
|
259
|
+
/>
|
|
260
|
+
</div>
|
|
261
|
+
<div style="margin-left: 5px;flex-shrink: 0">
|
|
262
|
+
<ac-switch
|
|
263
|
+
v-model="filter.manually"
|
|
264
|
+
:options="[{key: true, value: ''}, {key: false, value: ''}]"
|
|
265
|
+
title="手动输入"
|
|
266
|
+
size="small"
|
|
267
|
+
/>
|
|
268
|
+
</div>
|
|
269
|
+
</div>
|
|
270
|
+
<div class="data-item">
|
|
271
|
+
<span class="label">后置括号:</span>
|
|
272
|
+
<span class="content">
|
|
273
|
+
<ac-select v-model="filter.behindBracket" options="),)),))),))))" size="small" />
|
|
274
|
+
</span>
|
|
275
|
+
</div>
|
|
276
|
+
</div>
|
|
277
|
+
<div class="data-add-box">
|
|
278
|
+
<div class="data-add" @click="addFilter">
|
|
279
|
+
<ac-icon iconId="018dca3b4707c4c43a2f" />
|
|
280
|
+
<span style="margin-left: 5px;font-size: 13px;">添加过滤</span>
|
|
281
|
+
</div>
|
|
282
|
+
</div>
|
|
283
|
+
</div>
|
|
284
|
+
</el-collapse-item>
|
|
285
|
+
<el-collapse-item
|
|
286
|
+
v-if="activatedNode.compData.dataSourceType === '数据模型'
|
|
287
|
+
|| activatedNode.compData.dataSourceType === '视图'"
|
|
288
|
+
title="数据排序"
|
|
289
|
+
name="dataOrdinal"
|
|
290
|
+
>
|
|
291
|
+
<div class="filter">
|
|
292
|
+
<div
|
|
293
|
+
class="data-list"
|
|
294
|
+
v-for="(ordinal, index) in activatedNode.compData.ordinalList || []"
|
|
295
|
+
:key="index"
|
|
296
|
+
>
|
|
297
|
+
<div class="data-item" style="justify-content: start">
|
|
298
|
+
<div style="flex-shrink: 0;margin-right: 5px;width:130px;">
|
|
299
|
+
<ac-select v-model="ordinal.fieldId" :options="fieldIdList" size="small" />
|
|
300
|
+
</div>
|
|
301
|
+
<div style="flex-shrink: 0;width:100px;">
|
|
302
|
+
<ac-select v-model="ordinal.ordinalMode" options="升序,降序" size="small" />
|
|
303
|
+
</div>
|
|
304
|
+
<ac-icon
|
|
305
|
+
v-if="index > 0 && index < (activatedNode.compData.ordinalList || []).length"
|
|
306
|
+
iconId="018fa3973ded010d7ef2"
|
|
307
|
+
title="上移"
|
|
308
|
+
style="margin-left: 10px"
|
|
309
|
+
@click="moveOrdinalUp(index)"
|
|
310
|
+
/>
|
|
311
|
+
<ac-icon
|
|
312
|
+
v-if="index < (activatedNode.compData.ordinalList || []).length - 1"
|
|
313
|
+
iconId="018fa397630c01052d7e"
|
|
314
|
+
title="下移"
|
|
315
|
+
style="margin-left: 10px"
|
|
316
|
+
@click="moveOrdinalDown(index)"
|
|
317
|
+
/>
|
|
318
|
+
<ac-icon
|
|
319
|
+
iconId="018dc9c3efd3a0502886"
|
|
320
|
+
title="删除过滤"
|
|
321
|
+
color="red"
|
|
322
|
+
@click="deleteOrdinal(index)"
|
|
323
|
+
/>
|
|
324
|
+
</div>
|
|
325
|
+
</div>
|
|
326
|
+
<div class="data-add-box">
|
|
327
|
+
<div class="data-add" @click="addOrdinal">
|
|
328
|
+
<ac-icon iconId="018dca3b4707c4c43a2f" />
|
|
329
|
+
<span style="margin-left: 5px;font-size: 13px;">添加排序</span>
|
|
330
|
+
</div>
|
|
331
|
+
</div>
|
|
332
|
+
</div>
|
|
333
|
+
</el-collapse-item>
|
|
334
|
+
<el-collapse-item
|
|
335
|
+
v-if="activatedNode.compData.dataSourceType === '数据模型'
|
|
336
|
+
|| activatedNode.compData.dataSourceType === '视图'"
|
|
337
|
+
title="数据查询"
|
|
338
|
+
name="dataQuery"
|
|
339
|
+
>
|
|
340
|
+
<div class="data-list">
|
|
341
|
+
<div class="data-item">
|
|
342
|
+
<div class="label">自动更新:</div>
|
|
343
|
+
<div class="content">
|
|
344
|
+
<ac-switch
|
|
345
|
+
v-model="activatedNode.compData.autoload"
|
|
346
|
+
:options="[{key: true, value: ''}, {key: false, value: ''}]"
|
|
347
|
+
size="small"
|
|
348
|
+
/>
|
|
349
|
+
</div>
|
|
350
|
+
</div>
|
|
351
|
+
<div class="data-item" v-if="activatedNode.compData.autoload">
|
|
352
|
+
<div class="label">
|
|
353
|
+
<el-tooltip content="单位:秒">
|
|
354
|
+
<span>更新间隔<ac-icon iconId="018dca8ec9890493be26" style="margin-left: 5px"/>:</span>
|
|
355
|
+
</el-tooltip>
|
|
356
|
+
</div>
|
|
357
|
+
<div class="content">
|
|
358
|
+
<ac-number
|
|
359
|
+
v-model="activatedNode.compData.autoInterval"
|
|
360
|
+
size="small"
|
|
361
|
+
point="0"
|
|
362
|
+
/>
|
|
363
|
+
</div>
|
|
364
|
+
</div>
|
|
365
|
+
<div class="data-item">
|
|
366
|
+
<div class="label">开启分页:</div>
|
|
367
|
+
<div class="content">
|
|
368
|
+
<ac-switch
|
|
369
|
+
v-model="activatedNode.compData.dataPage"
|
|
370
|
+
:options="[{key: true, value: ''}, {key: false, value: ''}]"
|
|
371
|
+
size="small"
|
|
372
|
+
/>
|
|
373
|
+
</div>
|
|
374
|
+
</div>
|
|
375
|
+
<div class="data-item" v-if="activatedNode.compData.dataPage">
|
|
376
|
+
<div class="label">每页数量:</div>
|
|
377
|
+
<div class="content">
|
|
378
|
+
<ac-number
|
|
379
|
+
v-model="activatedNode.compData.dataPageSize"
|
|
380
|
+
size="small"
|
|
381
|
+
point="0"
|
|
382
|
+
/>
|
|
383
|
+
</div>
|
|
384
|
+
</div>
|
|
385
|
+
<div class="data-item" v-if="activatedNode.compData.dataPage">
|
|
386
|
+
<div class="label">分页加载方式:</div>
|
|
387
|
+
<div class="content">
|
|
388
|
+
<ac-buttons
|
|
389
|
+
v-model="activatedNode.compData.dataLoadMode"
|
|
390
|
+
size="small"
|
|
391
|
+
:options="[
|
|
392
|
+
{key: 'pagination', value: '分页导航'},
|
|
393
|
+
{key: 'bottom', value: '滚动到底部加载'}
|
|
394
|
+
]"
|
|
395
|
+
/>
|
|
396
|
+
</div>
|
|
397
|
+
</div>
|
|
398
|
+
<div
|
|
399
|
+
v-if="activatedNode.compData.dataPage
|
|
400
|
+
&& activatedNode.compData.dataLoadMode === 'pagination'"
|
|
401
|
+
class="data-item"
|
|
402
|
+
>
|
|
403
|
+
<div class="label">显示跳转:</div>
|
|
404
|
+
<div class="content">
|
|
405
|
+
<ac-switch
|
|
406
|
+
v-model="activatedNode.compData.showJumper"
|
|
407
|
+
size="small"
|
|
408
|
+
:options="[
|
|
409
|
+
{key: true, value: ''},
|
|
410
|
+
{key: false, value: ''}
|
|
411
|
+
]"
|
|
412
|
+
/>
|
|
413
|
+
</div>
|
|
414
|
+
</div>
|
|
415
|
+
<div
|
|
416
|
+
v-if="activatedNode.compData.dataPage
|
|
417
|
+
&& activatedNode.compData.dataLoadMode === 'pagination'"
|
|
418
|
+
class="data-item"
|
|
419
|
+
>
|
|
420
|
+
<div class="label">每页数量选择:</div>
|
|
421
|
+
<div class="content">
|
|
422
|
+
<ac-switch
|
|
423
|
+
v-model="activatedNode.compData.showSizes"
|
|
424
|
+
size="small"
|
|
425
|
+
:options="[
|
|
426
|
+
{key: true, value: ''},
|
|
427
|
+
{key: false, value: ''}
|
|
428
|
+
]"
|
|
429
|
+
/>
|
|
430
|
+
</div>
|
|
431
|
+
</div>
|
|
432
|
+
<div
|
|
433
|
+
v-if="activatedNode.compData.dataPage
|
|
434
|
+
&& activatedNode.compData.dataLoadMode === 'pagination'"
|
|
435
|
+
class="data-item"
|
|
436
|
+
>
|
|
437
|
+
<div class="label">页码按钮数:</div>
|
|
438
|
+
<div class="content">
|
|
439
|
+
<ac-number
|
|
440
|
+
v-model="activatedNode.compData.pagerCount"
|
|
441
|
+
size="small"
|
|
442
|
+
point="0"
|
|
443
|
+
/>
|
|
444
|
+
</div>
|
|
445
|
+
</div>
|
|
446
|
+
<div class="data-item" v-if="!activatedNode.compData.dataPage">
|
|
447
|
+
<div class="label">查询总数:</div>
|
|
448
|
+
<div class="content">
|
|
449
|
+
<ac-number
|
|
450
|
+
v-model="activatedNode.compData.dataQueryTotal"
|
|
451
|
+
size="small"
|
|
452
|
+
point="0"
|
|
453
|
+
/>
|
|
454
|
+
</div>
|
|
455
|
+
</div>
|
|
456
|
+
</div>
|
|
457
|
+
</el-collapse-item>
|
|
458
|
+
<el-collapse-item
|
|
459
|
+
v-if="activatedNode.compData.dataSourceType
|
|
460
|
+
&& activatedNode.compData.dataSourceType !== '输入参数'"
|
|
461
|
+
title="数据映射"
|
|
462
|
+
name="mapping"
|
|
463
|
+
>
|
|
464
|
+
<div class="data-list">
|
|
465
|
+
<div
|
|
466
|
+
class="data-item"
|
|
467
|
+
v-for="(field, index) in activatedNode.compData.fieldList || []"
|
|
468
|
+
:key="index"
|
|
469
|
+
>
|
|
470
|
+
<div class="label">
|
|
471
|
+
<span v-if="field.builtin">{{field.name}}:</span>
|
|
472
|
+
<el-input
|
|
473
|
+
v-else
|
|
474
|
+
v-model="field.name"
|
|
475
|
+
style="padding-right: 5px"
|
|
476
|
+
placeholder="字段名"
|
|
477
|
+
size="small"
|
|
478
|
+
/>
|
|
479
|
+
</div>
|
|
480
|
+
<ac-select
|
|
481
|
+
v-model="field.value"
|
|
482
|
+
:options="fieldNameList"
|
|
483
|
+
allowCreate
|
|
484
|
+
size="small"
|
|
485
|
+
/>
|
|
486
|
+
<ac-select
|
|
487
|
+
v-if="activatedNode.compData.dataSourceType === '脚本'"
|
|
488
|
+
v-model="field.type"
|
|
489
|
+
:options="[
|
|
490
|
+
{key: '日期', value: '日期'},
|
|
491
|
+
{key: '时间', value: '时间'}
|
|
492
|
+
]"
|
|
493
|
+
style="width: 170px;padding-left: 5px;"
|
|
494
|
+
size="small"
|
|
495
|
+
title="数据类型"
|
|
496
|
+
/>
|
|
497
|
+
<ac-icon
|
|
498
|
+
iconId="018dc9c3efd3a0502886"
|
|
499
|
+
title="删除"
|
|
500
|
+
color="red"
|
|
501
|
+
size="small"
|
|
502
|
+
@click="deleteDataField(index)"
|
|
503
|
+
/>
|
|
504
|
+
</div>
|
|
505
|
+
</div>
|
|
506
|
+
<div class="data-add-box">
|
|
507
|
+
<div class="data-add">
|
|
508
|
+
<ac-icon iconId="018dca3b4707c4c43a2f" />
|
|
509
|
+
<span style="font-size: 13px;" @click="addDataField">添加映射</span>
|
|
510
|
+
<ac-icon style="margin-left: 15px" iconId="018ece4f72d1bf69178b" />
|
|
511
|
+
<span style="font-size: 13px" @click="addAllDataField">一键添加</span>
|
|
512
|
+
</div>
|
|
513
|
+
</div>
|
|
514
|
+
</el-collapse-item>
|
|
515
|
+
<el-collapse-item
|
|
516
|
+
v-if="activatedNode.compData.dataSourceType"
|
|
517
|
+
title="数据响应结果"
|
|
518
|
+
name="dataList"
|
|
519
|
+
>
|
|
520
|
+
<template #title>
|
|
521
|
+
<span style="margin-right: 10px">数据响应结果</span>
|
|
522
|
+
<ac-icon
|
|
523
|
+
iconId="018dc9c3efd289739df0"
|
|
524
|
+
@click.stop="activatedNode.compData.refresh = !activatedNode.compData.refresh"
|
|
525
|
+
/>
|
|
526
|
+
</template>
|
|
527
|
+
<div class="data-list">
|
|
528
|
+
<div class="data-item">
|
|
529
|
+
<div class="content">
|
|
530
|
+
<ac-textarea
|
|
531
|
+
v-model="activatedNode.compData.dataList"
|
|
532
|
+
:rows="10"
|
|
533
|
+
size="small"
|
|
534
|
+
/>
|
|
535
|
+
</div>
|
|
536
|
+
</div>
|
|
537
|
+
</div>
|
|
538
|
+
</el-collapse-item>
|
|
539
|
+
</el-collapse>
|
|
540
|
+
</div>
|
|
541
|
+
<div v-else class="not-support">此组件不支持数据</div>
|
|
542
|
+
|
|
543
|
+
<!--新增编辑界面-->
|
|
544
|
+
<el-dialog
|
|
545
|
+
:title="dialogTitle"
|
|
546
|
+
v-model="dialogVisible"
|
|
547
|
+
:close-on-click-modal="false"
|
|
548
|
+
destroy-on-close
|
|
549
|
+
fullscreen
|
|
550
|
+
append-to-body
|
|
551
|
+
>
|
|
552
|
+
<div class="page-container">
|
|
553
|
+
<div v-if="dialogEdit" style="margin-bottom: 5px">
|
|
554
|
+
<el-button
|
|
555
|
+
size="default"
|
|
556
|
+
type="success"
|
|
557
|
+
@click="addDialogData"
|
|
558
|
+
>添加1行</el-button>
|
|
559
|
+
<el-button
|
|
560
|
+
size="default"
|
|
561
|
+
type="success"
|
|
562
|
+
@click="addDialogColumn"
|
|
563
|
+
>添加1列</el-button>
|
|
564
|
+
</div>
|
|
565
|
+
<el-table
|
|
566
|
+
:show-overflow-tooltip="true"
|
|
567
|
+
:class="['data-table', dialogEdit ? 'edit-table' : '']"
|
|
568
|
+
width="100%"
|
|
569
|
+
:data="dialogDataList"
|
|
570
|
+
:border="true"
|
|
571
|
+
:stripe="true"
|
|
572
|
+
>
|
|
573
|
+
<template #empty>
|
|
574
|
+
<div class="el-table__empty-block">
|
|
575
|
+
<img src="@/assets/images/no-data.png" style="width: 100px" alt />
|
|
576
|
+
<span style="min-width: 100px">暂无数据</span>
|
|
577
|
+
</div>
|
|
578
|
+
</template>
|
|
579
|
+
<el-table-column
|
|
580
|
+
v-for="column in dialogColumns"
|
|
581
|
+
header-align="center"
|
|
582
|
+
align="center"
|
|
583
|
+
:label="column.prop"
|
|
584
|
+
:min-width="120"
|
|
585
|
+
:key="column.prop"
|
|
586
|
+
:show-overflow-tooltip="dialogEdit ? false : {
|
|
587
|
+
'effect': 'light',
|
|
588
|
+
'raw-content': false,
|
|
589
|
+
'placement': 'bottom',
|
|
590
|
+
'popper-class': 'padding-10-15'
|
|
591
|
+
}"
|
|
592
|
+
>
|
|
593
|
+
<template #header>
|
|
594
|
+
<div
|
|
595
|
+
v-if="dialogEdit"
|
|
596
|
+
style="width: 100%;display: flex;flex-direction: row"
|
|
597
|
+
>
|
|
598
|
+
<el-input v-model="dialogMapping[column.prop]" />
|
|
599
|
+
<el-button
|
|
600
|
+
type="danger"
|
|
601
|
+
@click="delDialogColumn(column)"
|
|
602
|
+
link
|
|
603
|
+
>删除</el-button>
|
|
604
|
+
</div>
|
|
605
|
+
<div v-else>{{dialogMapping[column.prop]}}</div>
|
|
606
|
+
</template>
|
|
607
|
+
<template v-slot="scope">
|
|
608
|
+
<div v-if="dialogEdit" style="width: 100%;">
|
|
609
|
+
<el-input
|
|
610
|
+
v-model="scope.row[column.prop]"
|
|
611
|
+
/>
|
|
612
|
+
</div>
|
|
613
|
+
<div v-else>{{scope.row[column.prop]}}</div>
|
|
614
|
+
</template>
|
|
615
|
+
</el-table-column>
|
|
616
|
+
<el-table-column
|
|
617
|
+
header-align="center"
|
|
618
|
+
align="center"
|
|
619
|
+
label="操作"
|
|
620
|
+
width="50"
|
|
621
|
+
>
|
|
622
|
+
<template #default="scope">
|
|
623
|
+
<el-button
|
|
624
|
+
type="danger"
|
|
625
|
+
@click="delDialogData(scope.row)"
|
|
626
|
+
link
|
|
627
|
+
>删除</el-button>
|
|
628
|
+
</template>
|
|
629
|
+
</el-table-column>
|
|
630
|
+
</el-table>
|
|
631
|
+
</div>
|
|
632
|
+
<template #footer>
|
|
633
|
+
<el-button
|
|
634
|
+
v-if="dialogEdit"
|
|
635
|
+
size="default"
|
|
636
|
+
type="info"
|
|
637
|
+
@click="dialogVisible = false"
|
|
638
|
+
>取消</el-button>
|
|
639
|
+
<el-button
|
|
640
|
+
v-if="dialogEdit"
|
|
641
|
+
size="default"
|
|
642
|
+
type="primary"
|
|
643
|
+
@click="submitDialog"
|
|
644
|
+
>确定</el-button>
|
|
645
|
+
<el-button
|
|
646
|
+
v-if="!dialogEdit"
|
|
647
|
+
size="default"
|
|
648
|
+
type="info"
|
|
649
|
+
@click="dialogVisible = false"
|
|
650
|
+
>关闭</el-button>
|
|
651
|
+
</template>
|
|
652
|
+
</el-dialog>
|
|
653
|
+
</template>
|
|
654
|
+
|
|
655
|
+
<script setup>
|
|
656
|
+
import { ref, watch, onMounted, inject, nextTick, computed } from 'vue';
|
|
657
|
+
import tool from '@/utils/tool';
|
|
658
|
+
import api from '@/http/api';
|
|
659
|
+
import { ElMessageBox } from 'element-plus';
|
|
660
|
+
|
|
661
|
+
const rootNode = inject('rootNode');
|
|
662
|
+
const activatedNode = inject('activatedNode');
|
|
663
|
+
const collapseNames = ref(['param', 'dataSource', 'dataFilter', 'dataOrdinal', 'dataQuery', 'mapping', 'dataList'])
|
|
664
|
+
const dialogTitle = ref('');
|
|
665
|
+
const dialogVisible = ref(false);
|
|
666
|
+
const dialogEdit = ref(false);
|
|
667
|
+
const dialogMapping = ref({});
|
|
668
|
+
const dialogColumns = ref([]);
|
|
669
|
+
const dialogDataList = ref([]);
|
|
670
|
+
const fieldIdList = ref();
|
|
671
|
+
const fieldNameList = ref();
|
|
672
|
+
const nodeOptions = ref();
|
|
673
|
+
const pageParamList = inject('pageParamList');
|
|
674
|
+
|
|
675
|
+
const addInputParam = () => {
|
|
676
|
+
if (!activatedNode.value.compData.inputParamList) {
|
|
677
|
+
activatedNode.value.compData.inputParamList = [];
|
|
678
|
+
}
|
|
679
|
+
activatedNode.value.compData.inputParamList.push({ id: tool.uuids(), name: '' });
|
|
680
|
+
initNodeOptions();
|
|
681
|
+
};
|
|
682
|
+
|
|
683
|
+
const deleteInputParam = (index) => {
|
|
684
|
+
ElMessageBox.confirm('请确认是否删除?', '提示', { type: 'warning' }).then(() => {
|
|
685
|
+
activatedNode.value.compData.inputParamList.splice(index, 1);
|
|
686
|
+
initNodeOptions();
|
|
687
|
+
}).catch(() => {});
|
|
688
|
+
};
|
|
689
|
+
|
|
690
|
+
const globalParamOptions = computed(() => {
|
|
691
|
+
const options = [];
|
|
692
|
+
(pageParamList.value || []).forEach(param => {
|
|
693
|
+
options.push({ key: param.id || '', value: '[全局参数].' + (param.name || '参数名') });
|
|
694
|
+
});
|
|
695
|
+
|
|
696
|
+
const nodes = tool.getParentNodes(rootNode.value, activatedNode.value.id);
|
|
697
|
+
for (const node of nodes) {
|
|
698
|
+
const dataNode = tool.findNodeById(rootNode.value, node.id);
|
|
699
|
+
if (dataNode?.compData?.fieldList?.length > 0) {
|
|
700
|
+
options.push({ key: 'list.' + node.id + '.row', value: node.name + '.行.值' });
|
|
701
|
+
}
|
|
702
|
+
(dataNode?.compData?.fieldList || []).forEach(field => {
|
|
703
|
+
options.push({ key: 'list.' + node.id + '.row.' + field.name, value: node.name + '.行.' + field.name + '.值' });
|
|
704
|
+
});
|
|
705
|
+
}
|
|
706
|
+
return options;
|
|
707
|
+
});
|
|
708
|
+
|
|
709
|
+
const inputParamOptions = computed(() => {
|
|
710
|
+
const options = [];
|
|
711
|
+
(activatedNode.value.compData?.inputParamList || []).forEach(param => {
|
|
712
|
+
options.push({ key: param.id || '', value: '[组件入参].' + (param.name || '参数名') });
|
|
713
|
+
});
|
|
714
|
+
return options;
|
|
715
|
+
});
|
|
716
|
+
|
|
717
|
+
const addDataField = () => {
|
|
718
|
+
if (!activatedNode.value.compData.fieldList) {
|
|
719
|
+
activatedNode.value.compData.fieldList = [];
|
|
720
|
+
}
|
|
721
|
+
activatedNode.value.compData.fieldList.push({ id: tool.uuids(), name: '', value: '' });
|
|
722
|
+
};
|
|
723
|
+
|
|
724
|
+
const addAllDataField = () => {
|
|
725
|
+
if (!activatedNode.value.compData.fieldList) {
|
|
726
|
+
activatedNode.value.compData.fieldList = [];
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
if (Array.isArray(fieldNameList.value)) {
|
|
730
|
+
fieldNameList.value.forEach(item => {
|
|
731
|
+
activatedNode.value.compData.fieldList.push({ id: tool.uuids(), name: item.value, value: item.key });
|
|
732
|
+
});
|
|
733
|
+
} else {
|
|
734
|
+
(fieldNameList.value || '').split(',').forEach(item => {
|
|
735
|
+
activatedNode.value.compData.fieldList.push({ id: tool.uuids(), name: item, value: item });
|
|
736
|
+
});
|
|
737
|
+
}
|
|
738
|
+
};
|
|
739
|
+
|
|
740
|
+
const deleteDataField = (index) => {
|
|
741
|
+
activatedNode.value.compData.fieldList.splice(index, 1);
|
|
742
|
+
};
|
|
743
|
+
|
|
744
|
+
const addFilter = () => {
|
|
745
|
+
if (!activatedNode.value.compData.filterList) {
|
|
746
|
+
activatedNode.value.compData.filterList = [];
|
|
747
|
+
}
|
|
748
|
+
activatedNode.value.compData.filterList.push({ name: '', value: '' });
|
|
749
|
+
};
|
|
750
|
+
|
|
751
|
+
const addAllFilter = () => {
|
|
752
|
+
if (!activatedNode.value.compData.filterList) {
|
|
753
|
+
activatedNode.value.compData.filterList = [];
|
|
754
|
+
}
|
|
755
|
+
|
|
756
|
+
(nodeOptions.value || []).forEach(option => {
|
|
757
|
+
activatedNode.value.compData.filterList.push({
|
|
758
|
+
manually: false,
|
|
759
|
+
fieldId: option.value && option.value.indexOf('.') ? option.value.split('.')[0] : option.value,
|
|
760
|
+
compareValue: option.key
|
|
761
|
+
});
|
|
762
|
+
});
|
|
763
|
+
};
|
|
764
|
+
|
|
765
|
+
const moveFilterUp = (index) => {
|
|
766
|
+
const curr = activatedNode.value.compData.filterList[index];
|
|
767
|
+
activatedNode.value.compData.filterList[index] = activatedNode.value.compData.filterList[index - 1];
|
|
768
|
+
activatedNode.value.compData.filterList[index - 1] = curr;
|
|
769
|
+
};
|
|
770
|
+
|
|
771
|
+
const moveFilterDown = (index) => {
|
|
772
|
+
const curr = activatedNode.value.compData.filterList[index];
|
|
773
|
+
activatedNode.value.compData.filterList[index] = activatedNode.value.compData.filterList[index + 1];
|
|
774
|
+
activatedNode.value.compData.filterList[index + 1] = curr;
|
|
775
|
+
};
|
|
776
|
+
|
|
777
|
+
const deleteFilter = (index) => {
|
|
778
|
+
ElMessageBox.confirm('请确认是否删除?', '提示', { type: 'warning' }).then(() => {
|
|
779
|
+
activatedNode.value.compData.filterList.splice(index, 1);
|
|
780
|
+
}).catch(() => {});
|
|
781
|
+
};
|
|
782
|
+
|
|
783
|
+
const addOrdinal = () => {
|
|
784
|
+
if (!activatedNode.value.compData.ordinalList) {
|
|
785
|
+
activatedNode.value.compData.ordinalList = [];
|
|
786
|
+
}
|
|
787
|
+
activatedNode.value.compData.ordinalList.push({ name: '', value: '' });
|
|
788
|
+
};
|
|
789
|
+
|
|
790
|
+
const moveOrdinalUp = (index) => {
|
|
791
|
+
const curr = activatedNode.value.compData.ordinalList[index];
|
|
792
|
+
activatedNode.value.compData.ordinalList[index] = activatedNode.value.compData.ordinalList[index - 1];
|
|
793
|
+
activatedNode.value.compData.ordinalList[index - 1] = curr;
|
|
794
|
+
};
|
|
795
|
+
|
|
796
|
+
const moveOrdinalDown = (index) => {
|
|
797
|
+
const curr = activatedNode.value.compData.ordinalList[index];
|
|
798
|
+
activatedNode.value.compData.ordinalList[index] = activatedNode.value.compData.ordinalList[index + 1];
|
|
799
|
+
activatedNode.value.compData.ordinalList[index + 1] = curr;
|
|
800
|
+
};
|
|
801
|
+
|
|
802
|
+
const deleteOrdinal = (index) => {
|
|
803
|
+
ElMessageBox.confirm('请确认是否删除?', '提示', { type: 'warning' }).then(() => {
|
|
804
|
+
activatedNode.value.compData.ordinalList.splice(index, 1);
|
|
805
|
+
}).catch(() => {});
|
|
806
|
+
};
|
|
807
|
+
|
|
808
|
+
const changeDataSourceType = () => {
|
|
809
|
+
if (activatedNode.value.compData.dataSourceType === '静态数据') {
|
|
810
|
+
changeDataJson();
|
|
811
|
+
} else if (activatedNode.value.compData.dataSourceType === '数据模型') {
|
|
812
|
+
changeDataModel();
|
|
813
|
+
}
|
|
814
|
+
};
|
|
815
|
+
|
|
816
|
+
const changeDataJson = () => {
|
|
817
|
+
fieldIdList.value = [];
|
|
818
|
+
fieldNameList.value = [];
|
|
819
|
+
if (!activatedNode.value.compData.dataJson) return;
|
|
820
|
+
|
|
821
|
+
try {
|
|
822
|
+
const fieldNames = [];
|
|
823
|
+
const json = JSON.parse(activatedNode.value.compData.dataJson);
|
|
824
|
+
for (const p in (json && json[0]) || {}) {
|
|
825
|
+
if (fieldNames.indexOf(p) < 0) {
|
|
826
|
+
fieldNames.push(p);
|
|
827
|
+
}
|
|
828
|
+
}
|
|
829
|
+
fieldIdList.value = fieldNames.join(',');
|
|
830
|
+
fieldNameList.value = fieldNames.join(',');
|
|
831
|
+
} catch (e) {
|
|
832
|
+
console.log('解释静态数据出错!', e)
|
|
833
|
+
}
|
|
834
|
+
};
|
|
835
|
+
|
|
836
|
+
const changeDataModel = () => {
|
|
837
|
+
fieldIdList.value = [];
|
|
838
|
+
fieldNameList.value = [];
|
|
839
|
+
if (!activatedNode.value.compData.dataModelId) return;
|
|
840
|
+
|
|
841
|
+
const data = { modelId: activatedNode.value.compData.dataModelId };
|
|
842
|
+
api.post('/system/dataField/queryList', data).then(res => {
|
|
843
|
+
fieldIdList.value = (res.data || []).map(item => ({ key: item.id, value: item.showName }));
|
|
844
|
+
fieldNameList.value = (res.data || []).map(item => ({ key: item.fieldName, value: item.showName }));
|
|
845
|
+
});
|
|
846
|
+
};
|
|
847
|
+
|
|
848
|
+
const changeView = () => {
|
|
849
|
+
fieldIdList.value = [];
|
|
850
|
+
fieldNameList.value = [];
|
|
851
|
+
if (!activatedNode.value.compData.viewId) return;
|
|
852
|
+
|
|
853
|
+
const data = { id: activatedNode.value.compData.viewId };
|
|
854
|
+
api.post('/system/view/queryColumn', { id: data }).then(res => {
|
|
855
|
+
fieldIdList.value = (res.data && res.data.columnList || []).map(item => item.columnName).join(',');
|
|
856
|
+
fieldNameList.value = (res.data && res.data.columnList || []).map(item => item.columnName).join(',');
|
|
857
|
+
});
|
|
858
|
+
};
|
|
859
|
+
|
|
860
|
+
const changeScript = () => {
|
|
861
|
+
fieldIdList.value = [];
|
|
862
|
+
fieldNameList.value = [];
|
|
863
|
+
if (!activatedNode.value.compData.scriptId) return;
|
|
864
|
+
|
|
865
|
+
const data = {};
|
|
866
|
+
api.runScript(activatedNode.value.compData.scriptId, data).then(res => {
|
|
867
|
+
const fieldNames = [];
|
|
868
|
+
Object.keys((res && res.data && res.data[0]) || {}).forEach(key => {
|
|
869
|
+
if (fieldNames.indexOf(key) < 0) {
|
|
870
|
+
fieldNames.push(key);
|
|
871
|
+
}
|
|
872
|
+
});
|
|
873
|
+
fieldIdList.value = fieldNames.join(',');
|
|
874
|
+
fieldNameList.value = fieldNames.join(',');
|
|
875
|
+
});
|
|
876
|
+
};
|
|
877
|
+
|
|
878
|
+
const initNodeOptions = () => {
|
|
879
|
+
let options = [];
|
|
880
|
+
tool.walkTree(rootNode.value, (node) => {
|
|
881
|
+
if (!node.type || node.type === 'form-item' || !node.type.startsWith('form-')) return;
|
|
882
|
+
options.push({ key: node.id + '.value', value: node.name + '.值' });
|
|
883
|
+
});
|
|
884
|
+
|
|
885
|
+
options = options.sort((a, b) => a.value.localeCompare(b.value));
|
|
886
|
+
|
|
887
|
+
const inputParamList = [];
|
|
888
|
+
(activatedNode.value.compData.inputParamList || []).forEach(inputParam => {
|
|
889
|
+
inputParamList.push({
|
|
890
|
+
key: 'inputParam.' + inputParam.id,
|
|
891
|
+
value: '[组件入参].' + inputParam.name
|
|
892
|
+
}
|
|
893
|
+
);
|
|
894
|
+
});
|
|
895
|
+
options.unshift(...inputParamList);
|
|
896
|
+
nodeOptions.value = options;
|
|
897
|
+
};
|
|
898
|
+
|
|
899
|
+
const init = async() => {
|
|
900
|
+
if (!activatedNode.value.compData.dataSourceType ||
|
|
901
|
+
activatedNode.value.compData.dataSourceType === '静态数据') {
|
|
902
|
+
changeDataJson();
|
|
903
|
+
} else if (activatedNode.value.compData.dataSourceType === '数据模型') {
|
|
904
|
+
changeDataModel();
|
|
905
|
+
} else if (activatedNode.value.compData.dataSourceType === '视图') {
|
|
906
|
+
changeView();
|
|
907
|
+
} else if (activatedNode.value.compData.dataSourceType === '脚本') {
|
|
908
|
+
changeScript();
|
|
909
|
+
}
|
|
910
|
+
initNodeOptions();
|
|
911
|
+
|
|
912
|
+
if (!fieldNameList.value) {
|
|
913
|
+
fieldNameList.value = 'clear.options';
|
|
914
|
+
}
|
|
915
|
+
};
|
|
916
|
+
|
|
917
|
+
const editDataList = (json) => {
|
|
918
|
+
const dataList = json ? (JSON.parse(json) || []) : [];
|
|
919
|
+
const columnList = [];
|
|
920
|
+
const dataMap = {};
|
|
921
|
+
const resultList = [];
|
|
922
|
+
dataList.forEach(data => {
|
|
923
|
+
const result = { rowFlag: tool.uuid() };
|
|
924
|
+
for (const p in data) {
|
|
925
|
+
let id = null;
|
|
926
|
+
for (const key in dataMap) {
|
|
927
|
+
if (dataMap[key] === p) {
|
|
928
|
+
id = key;
|
|
929
|
+
break;
|
|
930
|
+
}
|
|
931
|
+
}
|
|
932
|
+
|
|
933
|
+
if (!id) {
|
|
934
|
+
id = tool.uuid();
|
|
935
|
+
dataMap[id] = p;
|
|
936
|
+
columnList.push({ prop: id });
|
|
937
|
+
}
|
|
938
|
+
result[id] = data[p];
|
|
939
|
+
}
|
|
940
|
+
resultList.push(result);
|
|
941
|
+
});
|
|
942
|
+
|
|
943
|
+
if (Object.keys(dataMap).length === 0 &&
|
|
944
|
+
activatedNode.value.compData?.fieldList?.length > 0) {
|
|
945
|
+
activatedNode.value.compData?.fieldList.forEach(field => {
|
|
946
|
+
const id = tool.uuid();
|
|
947
|
+
dataMap[id] = field.name;
|
|
948
|
+
columnList.push({ prop: id });
|
|
949
|
+
});
|
|
950
|
+
}
|
|
951
|
+
dialogMapping.value = dataMap;
|
|
952
|
+
dialogColumns.value = columnList;
|
|
953
|
+
dialogDataList.value = resultList;
|
|
954
|
+
dialogVisible.value = true;
|
|
955
|
+
dialogEdit.value = true;
|
|
956
|
+
dialogTitle.value = '数据编辑';
|
|
957
|
+
};
|
|
958
|
+
|
|
959
|
+
const addDialogColumn = () => {
|
|
960
|
+
dialogColumns.value.push({ prop: tool.uuid() });
|
|
961
|
+
};
|
|
962
|
+
|
|
963
|
+
const delDialogColumn = (column) => {
|
|
964
|
+
const index = dialogColumns.value.findIndex(item => item.prop === column.prop);
|
|
965
|
+
dialogColumns.value.splice(index, 1);
|
|
966
|
+
};
|
|
967
|
+
|
|
968
|
+
const addDialogData = () => {
|
|
969
|
+
dialogDataList.value.push({ rowFlag: tool.uuid() });
|
|
970
|
+
};
|
|
971
|
+
|
|
972
|
+
const delDialogData = (row) => {
|
|
973
|
+
const index = dialogDataList.value.findIndex(item => item.rowFlag === row.rowFlag);
|
|
974
|
+
dialogDataList.value.splice(index, 1);
|
|
975
|
+
};
|
|
976
|
+
|
|
977
|
+
const submitDialog = () => {
|
|
978
|
+
const resultList = [];
|
|
979
|
+
dialogDataList.value.forEach(data => {
|
|
980
|
+
const result = {};
|
|
981
|
+
for (const key in dialogMapping.value) {
|
|
982
|
+
result[dialogMapping.value[key]] = data[key];
|
|
983
|
+
}
|
|
984
|
+
resultList.push(result);
|
|
985
|
+
});
|
|
986
|
+
activatedNode.value.compData.dataJson = JSON.stringify(resultList);
|
|
987
|
+
dialogVisible.value = false;
|
|
988
|
+
changeDataJson();
|
|
989
|
+
};
|
|
990
|
+
|
|
991
|
+
watch(() => activatedNode.value.id, async() => {
|
|
992
|
+
await nextTick(() => init());
|
|
993
|
+
});
|
|
994
|
+
|
|
995
|
+
watch(() => activatedNode.value.compData, () => {
|
|
996
|
+
rootNode.value.unSave = true;
|
|
997
|
+
}, { deep: true });
|
|
998
|
+
|
|
999
|
+
onMounted(() => {
|
|
1000
|
+
init();
|
|
1001
|
+
});
|
|
1002
|
+
</script>
|
|
1003
|
+
|
|
1004
|
+
<style scoped lang="scss">
|
|
1005
|
+
.not-support {
|
|
1006
|
+
color: #dcdcdc;
|
|
1007
|
+
padding: 8px;
|
|
1008
|
+
text-align: center;
|
|
1009
|
+
width: 100%;
|
|
1010
|
+
}
|
|
1011
|
+
.data-box {
|
|
1012
|
+
display: flex;
|
|
1013
|
+
flex-direction: column;
|
|
1014
|
+
.data-list {
|
|
1015
|
+
margin: 5px;
|
|
1016
|
+
display: flex;
|
|
1017
|
+
flex-direction: column;
|
|
1018
|
+
.data-item {
|
|
1019
|
+
display: flex;
|
|
1020
|
+
flex-direction: row;
|
|
1021
|
+
justify-content: space-between;
|
|
1022
|
+
align-items: center;
|
|
1023
|
+
margin-bottom: 5px;
|
|
1024
|
+
color: #dcdcdc;
|
|
1025
|
+
border-radius: 5px;
|
|
1026
|
+
font-size: 14px !important;
|
|
1027
|
+
|
|
1028
|
+
.label {
|
|
1029
|
+
width: 100px;
|
|
1030
|
+
padding-left: 5px;
|
|
1031
|
+
text-align: right;
|
|
1032
|
+
white-space: nowrap;
|
|
1033
|
+
font-size: 13px;
|
|
1034
|
+
overflow: hidden;
|
|
1035
|
+
text-overflow: ellipsis;
|
|
1036
|
+
flex-shrink: 0;
|
|
1037
|
+
:deep(.el-tooltip__trigger) {
|
|
1038
|
+
display: flex;
|
|
1039
|
+
flex-direction: row;
|
|
1040
|
+
justify-content: end;
|
|
1041
|
+
align-items: center;
|
|
1042
|
+
}
|
|
1043
|
+
}
|
|
1044
|
+
|
|
1045
|
+
.content {
|
|
1046
|
+
width: 1px;
|
|
1047
|
+
flex-grow: 1;
|
|
1048
|
+
display: flex;
|
|
1049
|
+
flex-direction: row;
|
|
1050
|
+
}
|
|
1051
|
+
|
|
1052
|
+
.ac-icon {
|
|
1053
|
+
flex-shrink: 0;
|
|
1054
|
+
margin-left: 5px;
|
|
1055
|
+
cursor: pointer;
|
|
1056
|
+
}
|
|
1057
|
+
}
|
|
1058
|
+
.data-item:last-child {
|
|
1059
|
+
margin-bottom: 0;
|
|
1060
|
+
}
|
|
1061
|
+
}
|
|
1062
|
+
.filter {
|
|
1063
|
+
.data-list {
|
|
1064
|
+
&:nth-last-child(2) {
|
|
1065
|
+
padding-bottom: 0;
|
|
1066
|
+
border-bottom: none!important;
|
|
1067
|
+
}
|
|
1068
|
+
}
|
|
1069
|
+
}
|
|
1070
|
+
}
|
|
1071
|
+
.data-add-box {
|
|
1072
|
+
display: flex;
|
|
1073
|
+
flex-direction: row;
|
|
1074
|
+
justify-content: center;
|
|
1075
|
+
align-items: center;
|
|
1076
|
+
padding: 5px 8px;
|
|
1077
|
+
color: #dcdcdc;
|
|
1078
|
+
height: 30px;
|
|
1079
|
+
.data-add {
|
|
1080
|
+
display: flex;
|
|
1081
|
+
flex-direction: row;
|
|
1082
|
+
justify-content: center;
|
|
1083
|
+
align-items: center;
|
|
1084
|
+
cursor: pointer;
|
|
1085
|
+
}
|
|
1086
|
+
}
|
|
1087
|
+
:deep(.el-radio-button) {
|
|
1088
|
+
--el-radio-button-checked-bg-color: #555;
|
|
1089
|
+
--el-radio-button-checked-text-color: #dcdcdc;
|
|
1090
|
+
--el-radio-button-checked-border-color: #333;
|
|
1091
|
+
--el-radio-button-disabled-checked-fill: #333;
|
|
1092
|
+
}
|
|
1093
|
+
:deep(.el-radio-button) .el-radio-button__inner {
|
|
1094
|
+
color: #dcdcdc;
|
|
1095
|
+
background: #555555;
|
|
1096
|
+
border-right: 1px solid #333;
|
|
1097
|
+
border-top: 1px solid #333;
|
|
1098
|
+
border-bottom: 1px solid #333;
|
|
1099
|
+
padding: 5px 6px;
|
|
1100
|
+
}
|
|
1101
|
+
:deep(.el-radio-button:first-child) .el-radio-button__inner {
|
|
1102
|
+
border-left: 1px solid #333;
|
|
1103
|
+
}
|
|
1104
|
+
:deep(.el-radio-button).is-active .el-radio-button__inner {
|
|
1105
|
+
background: #333!important;
|
|
1106
|
+
}
|
|
1107
|
+
</style>
|