@sankhyalabs/sankhyablocks 8.15.0-dev.6 → 8.15.0-dev.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{ConfigStorage-8009ecb2.js → ConfigStorage-7df9d3bb.js} +102 -30
- package/dist/cjs/IExporterProvider-1ed8e92a.js +187 -0
- package/dist/cjs/{ISave-d68ce3cd.js → ISave-e91b70a7.js} +1 -0
- package/dist/cjs/RecordIDUtils-3735135c.js +43 -0
- package/dist/cjs/{SnkFormConfigManager-7d850fbc.js → SnkFormConfigManager-4259edbe.js} +21 -13
- package/dist/cjs/{SnkMessageBuilder-7293d0ad.js → SnkMessageBuilder-66aa2557.js} +19 -1
- package/dist/cjs/{auth-fetcher-c8467c07.js → auth-fetcher-e6112be7.js} +1 -1
- package/dist/cjs/{DataFetcher-ba94ed5b.js → form-config-fetcher-3c4daeb5.js} +258 -4
- package/dist/cjs/index-f9e81701.js +2 -10
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{dataunit-fetcher-bd4c52da.js → pesquisa-fetcher-cb768be1.js} +520 -86
- package/dist/cjs/sankhyablocks.cjs.js +1 -1
- package/dist/cjs/{snk-actions-button_2.cjs.entry.js → snk-actions-button_4.cjs.entry.js} +529 -13
- package/dist/cjs/snk-application.cjs.entry.js +62 -28
- package/dist/cjs/snk-attach.cjs.entry.js +422 -62
- package/dist/cjs/snk-crud.cjs.entry.js +17 -12
- package/dist/cjs/snk-data-exporter.cjs.entry.js +204 -82
- package/dist/cjs/{snk-data-unit-1bc69073.js → snk-data-unit-abd2113f.js} +3 -38
- package/dist/cjs/snk-data-unit.cjs.entry.js +3 -2
- package/dist/cjs/snk-detail-view.cjs.entry.js +10 -12
- package/dist/cjs/snk-entity-list.cjs.entry.js +5 -3
- package/dist/cjs/snk-filter-bar.cjs.entry.js +65 -10
- package/dist/cjs/snk-filter-detail.cjs.entry.js +4 -1
- package/dist/cjs/snk-filter-item.cjs.entry.js +13 -6
- package/dist/cjs/snk-filter-modal-item.cjs.entry.js +2 -3
- package/dist/cjs/snk-filter-modal.cjs.entry.js +2 -1
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +2 -1
- package/dist/cjs/snk-form-config.cjs.entry.js +46 -27
- package/dist/cjs/snk-form.cjs.entry.js +10 -4
- package/dist/cjs/snk-grid.cjs.entry.js +95 -116
- package/dist/cjs/{snk-guides-viewer-cb176c4d.js → snk-guides-viewer-bec9c1a5.js} +15 -11
- package/dist/cjs/snk-guides-viewer.cjs.entry.js +8 -10
- package/dist/cjs/snk-personalized-filter-editor.cjs.entry.js +3 -1
- package/dist/cjs/snk-personalized-filter.cjs.entry.js +2 -3
- package/dist/cjs/snk-pesquisa.cjs.entry.js +1 -1
- package/dist/cjs/snk-simple-crud.cjs.entry.js +367 -38
- package/dist/cjs/snk-taskbar.cjs.entry.js +124 -15
- package/dist/cjs/{taskbar-elements-01b85b99.js → taskbar-elements-d9392685.js} +11 -11
- package/dist/collection/collection-manifest.json +7 -7
- package/dist/collection/components/snk-application/__mocks__/snk-application.js +7 -0
- package/dist/collection/components/snk-application/snk-application.js +85 -2
- package/dist/collection/components/snk-attach/snk-attach.js +212 -39
- package/dist/collection/components/snk-attach/structure/{crud-config-builder.js → builder/anexo-sistema-crud-config.builder.js} +1 -1
- package/dist/collection/components/snk-attach/structure/builder/attach-crud-config.builder.js +62 -0
- package/dist/collection/components/snk-attach/structure/{taskbar-builder.js → builder/taskbar-builder.js} +1 -1
- package/dist/collection/components/snk-attach/structure/fetcher/facade/fetcher.facade.js +1 -0
- package/dist/collection/components/snk-attach/structure/{data-unit-builder.js → fetcher/factory/anexo-sistema-data-unit.factory.js} +14 -11
- package/dist/collection/components/snk-attach/structure/fetcher/factory/attach-fetcher-data-unit.factory.js +118 -0
- package/dist/collection/components/snk-attach/structure/index.js +6 -3
- package/dist/collection/components/snk-crud/snk-crud.js +95 -3
- package/dist/collection/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.js +2 -2
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.css +11 -2
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +27 -3
- package/dist/collection/components/snk-data-exporter/exporter-strategy/ClientSideExporterStrategy.js +90 -0
- package/dist/collection/components/snk-data-exporter/exporter-strategy/ServerSideExporterStrategy.js +68 -0
- package/dist/collection/components/snk-data-exporter/interfaces/IExporterProvider.js +48 -1
- package/dist/collection/components/snk-data-exporter/interfaces/IExporterStrategy.js +1 -0
- package/dist/collection/components/snk-data-exporter/providers/ClientSideExporterProvider.js +53 -0
- package/dist/collection/components/snk-data-exporter/providers/ServerSideExporterProvider.js +55 -0
- package/dist/collection/components/snk-data-exporter/snk-data-exporter.js +42 -48
- package/dist/collection/components/snk-data-exporter/test/resources/ClientSideExporterStrategyResources.js +88 -0
- package/dist/collection/components/snk-data-exporter/utils/RecordIDUtils.js +38 -0
- package/dist/collection/components/snk-data-unit/snk-data-unit.js +3 -42
- package/dist/collection/components/snk-entity-list/snk-entity-list.js +5 -3
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-multi-select.js +2 -1
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-personalized-filter-editor/snk-personalized-filter-editor.js +3 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-detail.js +22 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-item.js +31 -6
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +19 -1
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.css +24 -1
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.js +159 -5
- package/dist/collection/components/snk-filter-bar/utils/SnkFilterModalFactory.js +3 -1
- package/dist/collection/components/snk-form/snk-form.js +25 -1
- package/dist/collection/components/{snk-form → snk-form-config}/SnkFormConfigManager.js +20 -12
- package/dist/collection/components/{snk-form/subcomponents/snk-form-config → snk-form-config}/snk-form-config.js +50 -30
- package/dist/collection/components/snk-grid/snk-grid.js +102 -109
- package/dist/collection/components/{snk-grid/subcomponents/snk-grid-config → snk-grid-config}/snk-grid-config.js +130 -123
- package/dist/collection/components/{snk-grid/subcomponents → snk-grid-config}/snk-select-box/snk-select-box.js +1 -1
- package/dist/collection/components/snk-pesquisa/snk-pesquisa.css +2 -4
- package/dist/collection/components/snk-simple-crud/regular-buttons.js +3 -0
- package/dist/collection/components/snk-simple-crud/snk-simple-crud.css +10 -2
- package/dist/collection/components/snk-simple-crud/snk-simple-crud.js +548 -20
- package/dist/collection/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.js +4 -2
- package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +11 -11
- package/dist/collection/components/snk-taskbar/snk-taskbar.css +17 -0
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +167 -14
- package/dist/collection/lib/configs/ConfigStorage.js +86 -16
- package/dist/collection/lib/dataUnit/InMemoryLoader.js +9 -40
- package/dist/collection/lib/dataUnit/dataUnitInMemoryUtils.js +33 -0
- package/dist/collection/lib/http/data-fetcher/DataFetcher.js +7 -4
- package/dist/collection/lib/http/data-fetcher/fetchers/{attach-fetcher.js → AttachFetcher/anexo-sistema-fetcher.js} +16 -15
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/attach-fetcher.js +90 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/facade/attach-fetcher.facade.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/index.js +2 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/interfaces/IDelete.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/interfaces/IDownloadKey.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/ISave.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/DataUnitDataLoader.js +3 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/cache/ArrayRepository.js +4 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/cache/PreloadManager.js +11 -13
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.js +32 -3
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/loadstrategy/DatasetStrategy.js +36 -23
- package/dist/collection/lib/http/data-fetcher/fetchers/form-config-fetcher.js +12 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/parameters-fecher.js +21 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/personalized-filter-fetcher.js +6 -3
- package/dist/collection/lib/http/data-fetcher/fetchers/pesquisa-fetcher.js +12 -13
- package/dist/collection/lib/index.js +1 -1
- package/dist/collection/lib/message/resources/snk-attach.msg.js +13 -0
- package/dist/collection/lib/message/resources/snk-data-exporter.msg.js +2 -1
- package/dist/collection/lib/message/resources/snk-simple-crud.msg.js +4 -0
- package/dist/collection/lib/utils/CrudUtils.js +13 -1
- package/dist/components/ConfigStorage.js +93 -21
- package/dist/components/IExporterProvider.js +256 -0
- package/dist/components/ISave.js +42 -0
- package/dist/components/SnkFormConfigManager.js +19 -11
- package/dist/components/SnkMessageBuilder.js +19 -1
- package/dist/components/dataunit-fetcher.js +138 -91
- package/dist/components/form-config-fetcher.js +7035 -3
- package/dist/components/index.d.ts +6 -6
- package/dist/components/index2.js +198 -33
- package/dist/components/snk-actions-button2.js +3 -11
- package/dist/components/snk-application2.js +42 -3
- package/dist/components/snk-attach2.js +478 -70
- package/dist/components/snk-crud.js +18 -7
- package/dist/components/snk-data-exporter2.js +199 -82
- package/dist/components/snk-data-unit2.js +41 -39
- package/dist/components/snk-detail-view2.js +44 -12
- package/dist/components/snk-entity-list.js +5 -3
- package/dist/components/snk-expression-item2.js +1 -1
- package/dist/components/snk-filter-bar2.js +69 -8
- package/dist/components/snk-filter-detail2.js +5 -1
- package/dist/components/snk-filter-item2.js +14 -6
- package/dist/components/snk-filter-modal.js +4 -2
- package/dist/components/snk-filter-multi-select.js +2 -1
- package/dist/components/snk-form-config2.js +47 -27
- package/dist/components/snk-form.js +8 -0
- package/dist/components/snk-grid-config2.js +128 -102
- package/dist/components/snk-grid2.js +96 -112
- package/dist/components/snk-personalized-filter-editor.js +3 -1
- package/dist/components/snk-personalized-filter2.js +1 -1
- package/dist/components/snk-pesquisa2.js +1 -1
- package/dist/components/snk-simple-crud2.js +421 -34
- package/dist/components/snk-taskbar2.js +144 -29
- package/dist/components/taskbar-actions-button2.js +4 -2
- package/dist/esm/{ConfigStorage-1244b8b0.js → ConfigStorage-928c3bf4.js} +93 -21
- package/dist/esm/IExporterProvider-ceabfb7e.js +179 -0
- package/dist/esm/{ISave-4412b20c.js → ISave-d8c8bc59.js} +1 -0
- package/dist/esm/RecordIDUtils-87d02110.js +41 -0
- package/dist/esm/{SnkFormConfigManager-9be0e7d4.js → SnkFormConfigManager-a87ade7a.js} +21 -13
- package/dist/esm/{SnkMessageBuilder-ca843d1b.js → SnkMessageBuilder-0a4becdd.js} +19 -1
- package/dist/esm/{auth-fetcher-c05dc474.js → auth-fetcher-e1cb288f.js} +1 -1
- package/dist/esm/{DataFetcher-aa159c5a.js → form-config-fetcher-e3094014.js} +257 -5
- package/dist/esm/index-a7d3d3f1.js +2 -10
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{dataunit-fetcher-65714f21.js → pesquisa-fetcher-72125b13.js} +494 -69
- package/dist/esm/sankhyablocks.js +1 -1
- package/dist/esm/{snk-actions-button_2.entry.js → snk-actions-button_4.entry.js} +523 -9
- package/dist/esm/snk-application.entry.js +43 -9
- package/dist/esm/snk-attach.entry.js +422 -62
- package/dist/esm/snk-crud.entry.js +17 -12
- package/dist/esm/snk-data-exporter.entry.js +204 -82
- package/dist/esm/{snk-data-unit-6208ebf0.js → snk-data-unit-29eba11a.js} +4 -39
- package/dist/esm/snk-data-unit.entry.js +3 -2
- package/dist/esm/snk-detail-view.entry.js +10 -12
- package/dist/esm/snk-entity-list.entry.js +5 -3
- package/dist/esm/snk-filter-bar.entry.js +65 -10
- package/dist/esm/snk-filter-detail.entry.js +4 -1
- package/dist/esm/snk-filter-item.entry.js +13 -6
- package/dist/esm/snk-filter-modal-item.entry.js +2 -3
- package/dist/esm/snk-filter-modal.entry.js +2 -1
- package/dist/esm/snk-filter-multi-select.entry.js +2 -1
- package/dist/esm/snk-form-config.entry.js +47 -28
- package/dist/esm/snk-form.entry.js +10 -4
- package/dist/esm/snk-grid.entry.js +95 -116
- package/dist/esm/{snk-guides-viewer-eeb8f354.js → snk-guides-viewer-303aafb4.js} +15 -11
- package/dist/esm/snk-guides-viewer.entry.js +8 -10
- package/dist/esm/snk-personalized-filter-editor.entry.js +3 -1
- package/dist/esm/snk-personalized-filter.entry.js +2 -3
- package/dist/esm/snk-pesquisa.entry.js +1 -1
- package/dist/esm/snk-simple-crud.entry.js +359 -30
- package/dist/esm/snk-taskbar.entry.js +125 -16
- package/dist/esm/{taskbar-elements-d4d0b424.js → taskbar-elements-ad766858.js} +11 -11
- package/dist/sankhyablocks/p-029bfc09.js +1 -0
- package/dist/sankhyablocks/p-07825198.js +1 -0
- package/dist/sankhyablocks/p-0e8702f0.js +1 -0
- package/dist/sankhyablocks/p-13ea113d.entry.js +1 -0
- package/dist/sankhyablocks/p-1fa244c0.entry.js +1 -0
- package/dist/sankhyablocks/{p-9e7d65a4.js → p-21749402.js} +1 -1
- package/dist/sankhyablocks/p-2d972c2e.entry.js +1 -0
- package/dist/sankhyablocks/p-314e2d1a.entry.js +1 -0
- package/dist/sankhyablocks/p-32556aa6.js +1 -0
- package/dist/sankhyablocks/p-33718dfc.entry.js +1 -0
- package/dist/sankhyablocks/p-3494a28e.entry.js +1 -0
- package/dist/sankhyablocks/p-35bd4df7.entry.js +1 -0
- package/dist/sankhyablocks/p-536eeb16.js +26 -0
- package/dist/sankhyablocks/p-54a5d52a.entry.js +1 -0
- package/dist/sankhyablocks/p-563701f3.js +1 -0
- package/dist/sankhyablocks/p-61984566.entry.js +1 -0
- package/dist/sankhyablocks/p-61dd89eb.js +1 -0
- package/dist/sankhyablocks/p-64977b22.entry.js +1 -0
- package/dist/sankhyablocks/p-65b6dba3.entry.js +1 -0
- package/dist/sankhyablocks/p-6bc64fb0.entry.js +1 -0
- package/dist/sankhyablocks/p-70a4af56.entry.js +1 -0
- package/dist/sankhyablocks/p-9863d682.js +1 -0
- package/dist/sankhyablocks/p-aedf37fb.js +65 -0
- package/dist/sankhyablocks/p-b11aa1e0.entry.js +1 -0
- package/dist/sankhyablocks/p-b233f5aa.entry.js +1 -0
- package/dist/sankhyablocks/p-b86ea293.entry.js +1 -0
- package/dist/sankhyablocks/p-bf2acf72.entry.js +1 -0
- package/dist/sankhyablocks/p-c73482cf.js +1 -0
- package/dist/sankhyablocks/p-cb3c7b4a.entry.js +11 -0
- package/dist/sankhyablocks/p-cfb98f51.entry.js +1 -0
- package/dist/sankhyablocks/{p-247a8b36.entry.js → p-d1791da2.entry.js} +1 -1
- package/dist/sankhyablocks/p-d911a023.entry.js +1 -0
- package/dist/sankhyablocks/p-e27496ed.js +56 -0
- package/dist/sankhyablocks/p-e8763234.entry.js +1 -0
- package/dist/sankhyablocks/p-fa84e72f.entry.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-application/__mocks__/snk-application.d.ts +3 -0
- package/dist/types/components/snk-application/snk-application.d.ts +15 -0
- package/dist/types/components/snk-attach/{structure/crud-config-builder.d.ts → interfaces/ICrudConfig.d.ts} +1 -2
- package/dist/types/components/snk-attach/interfaces/TFetcherType.d.ts +1 -0
- package/dist/types/components/snk-attach/snk-attach.d.ts +29 -6
- package/dist/types/components/snk-attach/structure/builder/anexo-sistema-crud-config.builder.d.ts +2 -0
- package/dist/types/components/snk-attach/structure/builder/attach-crud-config.builder.d.ts +40 -0
- package/dist/types/components/snk-attach/structure/{taskbar-builder.d.ts → builder/taskbar-builder.d.ts} +1 -1
- package/dist/types/components/snk-attach/structure/fetcher/facade/fetcher.facade.d.ts +11 -0
- package/dist/types/components/snk-attach/structure/fetcher/factory/anexo-sistema-data-unit.factory.d.ts +17 -0
- package/dist/types/components/snk-attach/structure/fetcher/factory/attach-fetcher-data-unit.factory.d.ts +16 -0
- package/dist/types/components/snk-attach/structure/index.d.ts +6 -3
- package/dist/types/components/snk-crud/snk-crud.d.ts +21 -0
- package/dist/types/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.d.ts +1 -1
- package/dist/types/components/snk-crud/subcomponents/snk-guides-viewer.d.ts +6 -1
- package/dist/types/components/snk-data-exporter/exporter-strategy/ClientSideExporterStrategy.d.ts +13 -0
- package/dist/types/components/snk-data-exporter/exporter-strategy/ServerSideExporterStrategy.d.ts +11 -0
- package/dist/types/components/snk-data-exporter/interfaces/IExporterProvider.d.ts +21 -4
- package/dist/types/components/snk-data-exporter/interfaces/IExporterStrategy.d.ts +5 -0
- package/dist/types/components/snk-data-exporter/providers/ClientSideExporterProvider.d.ts +17 -0
- package/dist/types/components/snk-data-exporter/providers/ServerSideExporterProvider.d.ts +17 -0
- package/dist/types/components/snk-data-exporter/snk-data-exporter.d.ts +3 -1
- package/dist/types/components/snk-data-exporter/test/resources/ClientSideExporterStrategyResources.d.ts +77 -0
- package/dist/types/components/snk-data-exporter/utils/RecordIDUtils.d.ts +3 -0
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-detail.d.ts +4 -0
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-item.d.ts +7 -3
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +5 -0
- package/dist/types/components/snk-filter-bar/snk-filter-bar.d.ts +27 -1
- package/dist/types/components/snk-filter-bar/utils/SnkFilterModalFactory.d.ts +3 -1
- package/dist/types/components/snk-form/snk-form.d.ts +6 -1
- package/dist/types/components/{snk-form → snk-form-config}/SnkFormConfigManager.d.ts +2 -1
- package/dist/types/components/{snk-form/subcomponents/snk-form-config → snk-form-config}/snk-form-config.d.ts +5 -3
- package/dist/types/components/snk-grid/snk-grid.d.ts +19 -4
- package/dist/types/components/{snk-grid/subcomponents/snk-grid-config → snk-grid-config}/snk-grid-config.d.ts +11 -6
- package/dist/types/components/{snk-grid/subcomponents → snk-grid-config}/snk-select-box/snk-select-box.d.ts +1 -1
- package/dist/types/components/snk-simple-crud/regular-buttons.d.ts +3 -0
- package/dist/types/components/snk-simple-crud/snk-simple-crud.d.ts +98 -4
- package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +1 -1
- package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +34 -1
- package/dist/types/components.d.ts +314 -12
- package/dist/types/lib/configs/ConfigStorage.d.ts +25 -1
- package/dist/types/lib/dataUnit/InMemoryLoader.d.ts +0 -2
- package/dist/types/lib/dataUnit/dataUnitInMemoryUtils.d.ts +4 -0
- package/dist/types/lib/http/data-fetcher/DataFetcher.d.ts +1 -1
- package/dist/types/lib/http/data-fetcher/fetchers/{attach-fetcher.d.ts → AttachFetcher/anexo-sistema-fetcher.d.ts} +3 -2
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/attach-fetcher.d.ts +11 -0
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/facade/attach-fetcher.facade.d.ts +8 -0
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/index.d.ts +3 -0
- package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/ISave.d.ts +2 -1
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/DataUnitDataLoader.d.ts +2 -1
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/cache/ArrayRepository.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/cache/PreloadManager.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.d.ts +2 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/loadstrategy/DatasetStrategy.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IExporterColumnMetadata.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/form-config-fetcher.d.ts +2 -0
- package/dist/types/lib/http/data-fetcher/fetchers/parameters-fecher.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/personalized-filter-fetcher.d.ts +2 -1
- package/dist/types/lib/index.d.ts +1 -1
- package/dist/types/lib/utils/CrudUtils.d.ts +3 -0
- package/package.json +15 -6
- package/dist/cjs/PreloadManager-84466da6.js +0 -224
- package/dist/cjs/SnkMultiSelectionListDataSource-ba5838c2.js +0 -49
- package/dist/cjs/form-config-fetcher-df043d3d.js +0 -244
- package/dist/cjs/pesquisa-fetcher-ef050a47.js +0 -167
- package/dist/cjs/snk-grid-config.cjs.entry.js +0 -483
- package/dist/cjs/snk-select-box.cjs.entry.js +0 -25
- package/dist/collection/lib/http/data-fetcher/fetchers/fetchDataExporter/index.js +0 -34
- package/dist/components/DataFetcher.js +0 -7021
- package/dist/components/field-search.js +0 -121
- package/dist/components/index3.js +0 -199
- package/dist/esm/PreloadManager-c1c2f2b4.js +0 -222
- package/dist/esm/SnkMultiSelectionListDataSource-44494b0e.js +0 -43
- package/dist/esm/form-config-fetcher-36219cd3.js +0 -241
- package/dist/esm/pesquisa-fetcher-dd3ca0a5.js +0 -165
- package/dist/esm/snk-grid-config.entry.js +0 -479
- package/dist/esm/snk-select-box.entry.js +0 -21
- package/dist/sankhyablocks/p-0874adb5.entry.js +0 -1
- package/dist/sankhyablocks/p-094c30cb.js +0 -1
- package/dist/sankhyablocks/p-0d7863ed.js +0 -26
- package/dist/sankhyablocks/p-0dca29cb.entry.js +0 -1
- package/dist/sankhyablocks/p-11081798.entry.js +0 -1
- package/dist/sankhyablocks/p-20726710.entry.js +0 -1
- package/dist/sankhyablocks/p-29804fc5.js +0 -60
- package/dist/sankhyablocks/p-32f0935f.js +0 -1
- package/dist/sankhyablocks/p-3520c088.entry.js +0 -1
- package/dist/sankhyablocks/p-374d03f6.js +0 -1
- package/dist/sankhyablocks/p-4775a293.entry.js +0 -1
- package/dist/sankhyablocks/p-585294ee.js +0 -56
- package/dist/sankhyablocks/p-6977a26c.entry.js +0 -1
- package/dist/sankhyablocks/p-69efa80d.entry.js +0 -1
- package/dist/sankhyablocks/p-6d20d38c.entry.js +0 -1
- package/dist/sankhyablocks/p-776ee8e3.js +0 -1
- package/dist/sankhyablocks/p-7d51d949.entry.js +0 -11
- package/dist/sankhyablocks/p-809f367d.entry.js +0 -1
- package/dist/sankhyablocks/p-95a3778f.entry.js +0 -1
- package/dist/sankhyablocks/p-9695f78b.js +0 -1
- package/dist/sankhyablocks/p-98674137.entry.js +0 -1
- package/dist/sankhyablocks/p-a9e5b094.entry.js +0 -1
- package/dist/sankhyablocks/p-b146a9f0.entry.js +0 -1
- package/dist/sankhyablocks/p-bedb8ad6.entry.js +0 -1
- package/dist/sankhyablocks/p-c22c1d8e.js +0 -1
- package/dist/sankhyablocks/p-c758265f.entry.js +0 -1
- package/dist/sankhyablocks/p-ca4d337a.entry.js +0 -1
- package/dist/sankhyablocks/p-cb7419e0.entry.js +0 -1
- package/dist/sankhyablocks/p-d1f5bc50.js +0 -1
- package/dist/sankhyablocks/p-d4f9ee17.entry.js +0 -1
- package/dist/sankhyablocks/p-d6317851.entry.js +0 -1
- package/dist/sankhyablocks/p-d9bb09b3.js +0 -6
- package/dist/sankhyablocks/p-e6380c60.js +0 -1
- package/dist/sankhyablocks/p-f2056f66.entry.js +0 -1
- package/dist/sankhyablocks/p-f514913b.entry.js +0 -1
- package/dist/sankhyablocks/p-fd8814b9.entry.js +0 -1
- package/dist/sankhyablocks/p-ff6064e7.js +0 -1
- package/dist/types/components/snk-attach/structure/data-unit-builder.d.ts +0 -15
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/index.d.ts +0 -3
- /package/dist/collection/{lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDelete.js → components/snk-attach/interfaces/ICrudConfig.js} +0 -0
- /package/dist/collection/{lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDownloadKey.js → components/snk-attach/interfaces/TFetcherType.js} +0 -0
- /package/dist/collection/components/{snk-form/subcomponents/snk-form-config → snk-form-config}/snk-form-config.css +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-config-options/snk-config-options.css +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-config-options/snk-config-options.js +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-field-config/snk-field-config.css +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-field-config/snk-field-config.js +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-tab-config/snk-tab-config.css +0 -0
- /package/dist/collection/components/{snk-form → snk-form-config}/subcomponents/snk-tab-config/snk-tab-config.js +0 -0
- /package/dist/collection/components/{snk-grid/subcomponents/snk-grid-config → snk-grid-config}/snk-grid-config.css +0 -0
- /package/dist/collection/components/{snk-grid/subcomponents → snk-grid-config}/snk-select-box/snk-select-box.css +0 -0
- /package/dist/collection/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/index.js +0 -0
- /package/dist/types/components/{snk-form → snk-form-config}/subcomponents/snk-config-options/snk-config-options.d.ts +0 -0
- /package/dist/types/components/{snk-form → snk-form-config}/subcomponents/snk-field-config/snk-field-config.d.ts +0 -0
- /package/dist/types/components/{snk-form → snk-form-config}/subcomponents/snk-tab-config/snk-tab-config.d.ts +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/IDelete.d.ts +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/IDownloadKey.d.ts +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/index.d.ts +0 -0
@@ -20,6 +20,7 @@ export class SnkCrud {
|
|
20
20
|
this._canEdit = undefined;
|
21
21
|
this._resourceID = undefined;
|
22
22
|
this.configName = undefined;
|
23
|
+
this.filterBarTitle = undefined;
|
23
24
|
this.selectionToastConfig = undefined;
|
24
25
|
this.showActionButtons = false;
|
25
26
|
this.actionsList = undefined;
|
@@ -30,6 +31,10 @@ export class SnkCrud {
|
|
30
31
|
this.presentationMode = PresentationMode.PRIMARY;
|
31
32
|
this.messagesBuilder = undefined;
|
32
33
|
this.useEnterLikeTab = false;
|
34
|
+
this.gridLegacyConfigName = undefined;
|
35
|
+
this.filterBarLegacyConfigName = undefined;
|
36
|
+
this.formLegacyConfigName = undefined;
|
37
|
+
this.disablePersonalizedFilter = undefined;
|
33
38
|
this.customContainerId = `SNK-CRUD-CUSTOM-CONTAINER-${StringUtils.generateUUID()}`;
|
34
39
|
}
|
35
40
|
/**
|
@@ -162,7 +167,8 @@ export class SnkCrud {
|
|
162
167
|
window.removeEventListener("keydown", this._keyDownHandler);
|
163
168
|
}
|
164
169
|
async initKeyboardManager() {
|
165
|
-
|
170
|
+
var _a;
|
171
|
+
const keyboardManager = await ((_a = this._application) === null || _a === void 0 ? void 0 : _a.getKeyboardManager());
|
166
172
|
if (keyboardManager) {
|
167
173
|
const dataUnit = this._dataUnit || await this._snkDataUnit.getDataUnit();
|
168
174
|
async function saveDataUnitHandlingFocus() {
|
@@ -211,7 +217,8 @@ export class SnkCrud {
|
|
211
217
|
}
|
212
218
|
}
|
213
219
|
async removeShortcuts() {
|
214
|
-
|
220
|
+
var _a;
|
221
|
+
const keyboardManager = await ((_a = this._application) === null || _a === void 0 ? void 0 : _a.getKeyboardManager());
|
215
222
|
if (keyboardManager) {
|
216
223
|
keyboardManager
|
217
224
|
.unbind("F6")
|
@@ -278,7 +285,7 @@ export class SnkCrud {
|
|
278
285
|
return;
|
279
286
|
}
|
280
287
|
this._snkDataUnit.ignoreSaveMessage = this._currentViewMode === VIEW_MODE.GRID;
|
281
|
-
return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", null, h("snk-grid", { ref: (ref) => this._snkGrid = ref, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", null, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
|
288
|
+
return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", null, h("snk-grid", { ref: (ref) => this._snkGrid = ref, filterBarTitle: this.filterBarTitle, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, recordsValidator: this.recordsValidator, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID, disablePersonalizedFilter: this.disablePersonalizedFilter, gridLegacyConfigName: this.gridLegacyConfigName, filterBarLegacyConfigName: this.filterBarLegacyConfigName }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, recordsValidator: this.recordsValidator, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId, formLegacyConfigName: this.formLegacyConfigName }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", null, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
|
282
289
|
}
|
283
290
|
static get is() { return "snk-crud"; }
|
284
291
|
static get encapsulation() { return "scoped"; }
|
@@ -311,6 +318,23 @@ export class SnkCrud {
|
|
311
318
|
"attribute": "config-name",
|
312
319
|
"reflect": false
|
313
320
|
},
|
321
|
+
"filterBarTitle": {
|
322
|
+
"type": "string",
|
323
|
+
"mutable": false,
|
324
|
+
"complexType": {
|
325
|
+
"original": "string",
|
326
|
+
"resolved": "string",
|
327
|
+
"references": {}
|
328
|
+
},
|
329
|
+
"required": false,
|
330
|
+
"optional": false,
|
331
|
+
"docs": {
|
332
|
+
"tags": [],
|
333
|
+
"text": "T\u00EDtulo que ser\u00E1 apresentado na barra de filtros"
|
334
|
+
},
|
335
|
+
"attribute": "filter-bar-title",
|
336
|
+
"reflect": false
|
337
|
+
},
|
314
338
|
"selectionToastConfig": {
|
315
339
|
"type": "unknown",
|
316
340
|
"mutable": false,
|
@@ -514,6 +538,74 @@ export class SnkCrud {
|
|
514
538
|
"attribute": "use-enter-like-tab",
|
515
539
|
"reflect": false,
|
516
540
|
"defaultValue": "false"
|
541
|
+
},
|
542
|
+
"gridLegacyConfigName": {
|
543
|
+
"type": "string",
|
544
|
+
"mutable": false,
|
545
|
+
"complexType": {
|
546
|
+
"original": "string",
|
547
|
+
"resolved": "string",
|
548
|
+
"references": {}
|
549
|
+
},
|
550
|
+
"required": false,
|
551
|
+
"optional": false,
|
552
|
+
"docs": {
|
553
|
+
"tags": [],
|
554
|
+
"text": "Chave da configura\u00E7\u00E3o legado da grade."
|
555
|
+
},
|
556
|
+
"attribute": "grid-legacy-config-name",
|
557
|
+
"reflect": false
|
558
|
+
},
|
559
|
+
"filterBarLegacyConfigName": {
|
560
|
+
"type": "string",
|
561
|
+
"mutable": false,
|
562
|
+
"complexType": {
|
563
|
+
"original": "string",
|
564
|
+
"resolved": "string",
|
565
|
+
"references": {}
|
566
|
+
},
|
567
|
+
"required": false,
|
568
|
+
"optional": false,
|
569
|
+
"docs": {
|
570
|
+
"tags": [],
|
571
|
+
"text": "Chave da configura\u00E7\u00E3o legado da barra de filtros."
|
572
|
+
},
|
573
|
+
"attribute": "filter-bar-legacy-config-name",
|
574
|
+
"reflect": false
|
575
|
+
},
|
576
|
+
"formLegacyConfigName": {
|
577
|
+
"type": "string",
|
578
|
+
"mutable": false,
|
579
|
+
"complexType": {
|
580
|
+
"original": "string",
|
581
|
+
"resolved": "string",
|
582
|
+
"references": {}
|
583
|
+
},
|
584
|
+
"required": false,
|
585
|
+
"optional": false,
|
586
|
+
"docs": {
|
587
|
+
"tags": [],
|
588
|
+
"text": "Chave da configura\u00E7\u00E3o legado do formul\u00E1rio."
|
589
|
+
},
|
590
|
+
"attribute": "form-legacy-config-name",
|
591
|
+
"reflect": false
|
592
|
+
},
|
593
|
+
"disablePersonalizedFilter": {
|
594
|
+
"type": "boolean",
|
595
|
+
"mutable": false,
|
596
|
+
"complexType": {
|
597
|
+
"original": "boolean",
|
598
|
+
"resolved": "boolean",
|
599
|
+
"references": {}
|
600
|
+
},
|
601
|
+
"required": false,
|
602
|
+
"optional": false,
|
603
|
+
"docs": {
|
604
|
+
"tags": [],
|
605
|
+
"text": "Desabilita a apresenta\u00E7\u00E3o da op\u00E7\u00E3o de filtros personalizados na filter bar (chip de filtros)\ne no modal lateral de filtros (container de filtros personalizados)."
|
606
|
+
},
|
607
|
+
"attribute": "disable-personalized-filter",
|
608
|
+
"reflect": false
|
517
609
|
}
|
518
610
|
};
|
519
611
|
}
|
package/dist/collection/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { Action } from '@sankhyalabs/core';
|
2
2
|
import { Host, forceUpdate, h } from '@stencil/core';
|
3
|
-
import { SnkFormConfigManager } from '../../../snk-form/SnkFormConfigManager';
|
3
|
+
import { SnkFormConfigManager } from '../../../snk-form-config/SnkFormConfigManager';
|
4
4
|
import { buildFormMetadata } from "@sankhyalabs/ezui/dist/collection/utils/form";
|
5
5
|
import { PresentationMode } from '../../../../lib';
|
6
6
|
import { TaskbarElement } from '../../../snk-taskbar/elements/taskbar-elements';
|
@@ -236,7 +236,7 @@ export class SnkDetailView {
|
|
236
236
|
"references": {
|
237
237
|
"SnkFormConfigManager": {
|
238
238
|
"location": "import",
|
239
|
-
"path": "../../../snk-form/SnkFormConfigManager"
|
239
|
+
"path": "../../../snk-form-config/SnkFormConfigManager"
|
240
240
|
}
|
241
241
|
}
|
242
242
|
},
|
@@ -25,7 +25,7 @@ snk-form-view {
|
|
25
25
|
position: relative;
|
26
26
|
padding-left: 0px;
|
27
27
|
padding-top: 0px;
|
28
|
-
|
28
|
+
|
29
29
|
/*public*/
|
30
30
|
padding-right: var(--snk-guides-viewer--space-large);
|
31
31
|
padding-bottom: var(--snk-guides-viewer--space-large);
|
@@ -57,6 +57,15 @@ snk-form-view {
|
|
57
57
|
margin-bottom: var(--snk-guides-viewer--space-medium);
|
58
58
|
}
|
59
59
|
|
60
|
+
.snk-guides-viewer__header-breadcrumb{
|
61
|
+
width: 25%;
|
62
|
+
display: flex;
|
63
|
+
}
|
64
|
+
|
65
|
+
.snk-guides-viewer__header-taskbar{
|
66
|
+
width: 75%;
|
67
|
+
}
|
68
|
+
|
60
69
|
.snk-guides-viewer__container {
|
61
70
|
/*private*/
|
62
71
|
display: grid;
|
@@ -88,4 +97,4 @@ snk-form-view {
|
|
88
97
|
min-height: 100%;
|
89
98
|
align-items: flex-start;
|
90
99
|
align-content: flex-start;
|
91
|
-
}
|
100
|
+
}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { Action as DUAction, ElementIDUtils } from '@sankhyalabs/core';
|
2
2
|
import { Fragment, h } from '@stencil/core';
|
3
|
-
import { SnkFormConfigManager } from '../../snk-form/SnkFormConfigManager';
|
3
|
+
import { SnkFormConfigManager } from '../../snk-form-config/SnkFormConfigManager';
|
4
4
|
import { buildFormMetadata, FormMetadata } from '@sankhyalabs/ezui/dist/collection/utils/form';
|
5
5
|
import TaskbarProcessor from '../../snk-taskbar/processor/taskbar-processor';
|
6
6
|
import { TaskbarElement } from '../../snk-taskbar/elements/taskbar-elements';
|
@@ -26,6 +26,7 @@ export class SnkGuidesViewer {
|
|
26
26
|
this.presentationMode = undefined;
|
27
27
|
this.resourceID = undefined;
|
28
28
|
this.detailTaskbarCustomContainerId = undefined;
|
29
|
+
this.formLegacyConfigName = undefined;
|
29
30
|
this._hasToCreateFieldSearch = true;
|
30
31
|
this._breadcrumbItems = [];
|
31
32
|
this._guides = undefined;
|
@@ -323,11 +324,17 @@ export class SnkGuidesViewer {
|
|
323
324
|
var _a;
|
324
325
|
return this.selectedGuide === undefined || '__main' === ((_a = this.selectedGuide) === null || _a === void 0 ? void 0 : _a.id);
|
325
326
|
}
|
327
|
+
addFormLegacyConfigName() {
|
328
|
+
if (this.formLegacyConfigName) {
|
329
|
+
this._configManager.addFormLegacyConfig(this.formLegacyConfigName);
|
330
|
+
}
|
331
|
+
}
|
326
332
|
componentWillLoad() {
|
327
333
|
if (this.resourceID == undefined) {
|
328
334
|
throw new Error("Erro interno: resourceID não informado");
|
329
335
|
}
|
330
336
|
this._configManager = new SnkFormConfigManager(this.configName, this.resourceID, config => this.masterFormConfig = config);
|
337
|
+
this.addFormLegacyConfigName();
|
331
338
|
this._configManager.loadConfig();
|
332
339
|
}
|
333
340
|
componentDidRender() {
|
@@ -383,7 +390,7 @@ export class SnkGuidesViewer {
|
|
383
390
|
}
|
384
391
|
buildTaskBar() {
|
385
392
|
var _a;
|
386
|
-
return h("div", { class: `
|
393
|
+
return h("div", { class: `snk-guides-viewer__header-taskbar ${this.presentationMode != PresentationMode.SECONDARY ? 'ez-align--right' : 'ez-padding-bottom--medium'}` }, h("snk-taskbar", { key: "guideViewerTaskbar", "data-element-id": "guideViewer", configName: this.configName, buttons: this._taskbarProcessor.buttons, disabledButtons: this._taskbarProcessor.disabledButtons, customButtons: this._taskbarProcessor.customButtons, actionsList: this.getActionsList(), messagesBuilder: this.messagesBuilder, presentationMode: this.presentationMode, primaryButton: ((_a = this.dataState) === null || _a === void 0 ? void 0 : _a.isDirty) ? "SAVE" : "INSERT", "data-taskbar-owner": "master", dataUnit: this.dataUnit, resourceID: this.resourceID, customSlotId: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS", alignRigth: true }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" })));
|
387
394
|
}
|
388
395
|
async dataUnitActionHandler(action) {
|
389
396
|
var _a;
|
@@ -442,7 +449,7 @@ export class SnkGuidesViewer {
|
|
442
449
|
}
|
443
450
|
this.loadTaskbarProcessor();
|
444
451
|
const showGuides = this._guides && (this._guides.length > 1);
|
445
|
-
return (h("section", { class: "snk-guides-viewer" }, h("div", { class: "ez-row snk-guides-viewer__header" }, h("div", { class: "
|
452
|
+
return (h("section", { class: "snk-guides-viewer" }, h("div", { class: "ez-row snk-guides-viewer__header" }, h("div", { class: "snk-guides-viewer__header-breadcrumb ez-flex--align-items-center ez-flex-item--align-center ez-padding-left--large", key: "header" }, h("ez-button", { onClick: () => this.exitViewer(), title: this.getMessage("snkCrud.goBackTitle"), mode: "icon", iconName: "arrow_back", class: "ez-padding-right--medium", size: "small" }), h("div", { class: "ez-flex ez-flex--column ez-flex-item--auto" }, h("h1", { class: "ez-title ez-title--primary ez-title--xlarge" }, this.getMessage("snkCrud.title")), ((_a = this._breadcrumbItems) === null || _a === void 0 ? void 0 : _a.length) > 1 &&
|
446
453
|
h("div", { class: "ez-margin-top--extra-small" }, h("ez-breadcrumb", Object.assign({ items: this._breadcrumbItems, onSelectedItem: (evt) => this.onBreadcrumbClickHandler(evt === null || evt === void 0 ? void 0 : evt.detail) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("breadcrumb")}` }))))), this.presentationMode != PresentationMode.SECONDARY && this.buildTaskBar()), h("div", { class: "snk-guides-viewer__container" }, showGuides ?
|
447
454
|
h("ez-guide-navigator", { ref: (ref) => this._guideNavigator = ref, class: "snk-guides-viewer__guide-navigator", items: this._guides, selectedId: this.selectedGuide ? this.selectedGuide.id : undefined, onEzSelectionChange: evt => this.updateSelectedGuideHandler(evt.detail) })
|
448
455
|
:
|
@@ -740,6 +747,23 @@ export class SnkGuidesViewer {
|
|
740
747
|
},
|
741
748
|
"attribute": "detail-taskbar-custom-container-id",
|
742
749
|
"reflect": false
|
750
|
+
},
|
751
|
+
"formLegacyConfigName": {
|
752
|
+
"type": "string",
|
753
|
+
"mutable": false,
|
754
|
+
"complexType": {
|
755
|
+
"original": "string",
|
756
|
+
"resolved": "string",
|
757
|
+
"references": {}
|
758
|
+
},
|
759
|
+
"required": false,
|
760
|
+
"optional": false,
|
761
|
+
"docs": {
|
762
|
+
"tags": [],
|
763
|
+
"text": "Chave da configura\u00E7\u00E3o legado do formul\u00E1rio."
|
764
|
+
},
|
765
|
+
"attribute": "form-legacy-config-name",
|
766
|
+
"reflect": false
|
743
767
|
}
|
744
768
|
};
|
745
769
|
}
|
package/dist/collection/components/snk-data-exporter/exporter-strategy/ClientSideExporterStrategy.js
ADDED
@@ -0,0 +1,90 @@
|
|
1
|
+
import { UserInterface } from "@sankhyalabs/core";
|
2
|
+
import { DataFetcher } from "../../../lib";
|
3
|
+
export default class ClientSideExporterStrategy {
|
4
|
+
constructor(provider) {
|
5
|
+
this._provider = provider;
|
6
|
+
}
|
7
|
+
async executeExport(resolveProps) {
|
8
|
+
const { methodName, titleGrid } = resolveProps;
|
9
|
+
const records = await this._provider.getRecords();
|
10
|
+
const columns = await this._provider.getColumnsMetadata();
|
11
|
+
const [serviceName, processor] = this.getExecutor(methodName);
|
12
|
+
const payload = {
|
13
|
+
serviceName,
|
14
|
+
requestBody: {
|
15
|
+
grid: {
|
16
|
+
titleGrid,
|
17
|
+
columns: this.buildColumnsObject(columns),
|
18
|
+
rows: this.buildRowsObject(columns, records),
|
19
|
+
customOptions: { xlsxExtension: false }
|
20
|
+
}
|
21
|
+
}
|
22
|
+
};
|
23
|
+
return new Promise((resolve, reject) => {
|
24
|
+
DataFetcher.get()
|
25
|
+
.callServiceBroker(serviceName, payload)
|
26
|
+
.then(result => resolve(processor(result)))
|
27
|
+
.catch(error => reject(error));
|
28
|
+
});
|
29
|
+
}
|
30
|
+
getExecutor(methodName) {
|
31
|
+
if (methodName === "exportToPDF") {
|
32
|
+
return [
|
33
|
+
"GridPDFBuilderSP.buildPDFFromJson",
|
34
|
+
responseBody => ({
|
35
|
+
fileSessionKey: responseBody.chavePDF.valor,
|
36
|
+
canPrint: responseBody.permiteImprimir.valor === "S",
|
37
|
+
canExport: responseBody.permiteExportar.valor === "S",
|
38
|
+
canSendEmail: responseBody.canSendEmail.valor === "S",
|
39
|
+
useAppPrint: true
|
40
|
+
})
|
41
|
+
];
|
42
|
+
}
|
43
|
+
return [
|
44
|
+
"GridXLSBuilderSP.buildXLSFromJson",
|
45
|
+
responseBody => ({
|
46
|
+
fileSessionKey: responseBody.chaveXLS.valor,
|
47
|
+
canPrint: false,
|
48
|
+
canExport: false,
|
49
|
+
useAppPrint: false,
|
50
|
+
canSendEmail: false
|
51
|
+
})
|
52
|
+
];
|
53
|
+
}
|
54
|
+
buildColumnsObject(columns) {
|
55
|
+
return {
|
56
|
+
column: columns.map((column, index) => {
|
57
|
+
const { label, id, width, userInterface } = column;
|
58
|
+
return Object.assign({ index: index + 1, id,
|
59
|
+
label,
|
60
|
+
width, presentationType: "P" }, (TYPE_MAP[userInterface] || { type: "S", align: "left" }));
|
61
|
+
})
|
62
|
+
};
|
63
|
+
}
|
64
|
+
buildRowsObject(columns, records) {
|
65
|
+
return {
|
66
|
+
row: records.map(rawRecord => {
|
67
|
+
const record = {};
|
68
|
+
columns.forEach((column, index) => record["c" + (index + 1)] = { $: this.formatValue(rawRecord, column) });
|
69
|
+
return record;
|
70
|
+
})
|
71
|
+
};
|
72
|
+
}
|
73
|
+
formatValue(record, column) {
|
74
|
+
if (this._provider.formatValue != undefined) {
|
75
|
+
return this._provider.formatValue(record, column);
|
76
|
+
}
|
77
|
+
return record[column.id] || "";
|
78
|
+
}
|
79
|
+
}
|
80
|
+
class FormatedRecord {
|
81
|
+
}
|
82
|
+
const TYPE_MAP = {
|
83
|
+
[UserInterface.DATE]: { type: "D", align: "center" },
|
84
|
+
[UserInterface.DATETIME]: { type: "H", align: "center" },
|
85
|
+
[UserInterface.TIME]: { type: "I", align: "right" },
|
86
|
+
[UserInterface.ELAPSEDTIME]: { type: "I", align: "right" },
|
87
|
+
[UserInterface.DECIMALNUMBER]: { type: "F", align: "right" },
|
88
|
+
[UserInterface.INTEGERNUMBER]: { type: "I", align: "right" },
|
89
|
+
[UserInterface.SEARCH]: { type: "S", align: "right" }
|
90
|
+
};
|
package/dist/collection/components/snk-data-exporter/exporter-strategy/ServerSideExporterStrategy.js
ADDED
@@ -0,0 +1,68 @@
|
|
1
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
2
|
+
var t = {};
|
3
|
+
for (var p in s)
|
4
|
+
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
5
|
+
t[p] = s[p];
|
6
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
7
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
8
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
9
|
+
t[p[i]] = s[p[i]];
|
10
|
+
}
|
11
|
+
return t;
|
12
|
+
};
|
13
|
+
import { ApplicationContext, ObjectUtils } from "@sankhyalabs/core";
|
14
|
+
import { DataFetcher } from '../../../lib/http/data-fetcher/DataFetcher';
|
15
|
+
import { DataExporterOption } from "../../../lib/@types";
|
16
|
+
export default class ServerSideExporterStrategy {
|
17
|
+
constructor(provider) {
|
18
|
+
this._provider = provider;
|
19
|
+
}
|
20
|
+
async getParams(resolveProps) {
|
21
|
+
var _a, _b, _c, _d, _e, _f;
|
22
|
+
const filters = (_b = (_a = this._provider).getFilters) === null || _b === void 0 ? void 0 : _b.call(_a);
|
23
|
+
const columns = await this._provider.getColumnsMetadata();
|
24
|
+
const sort = (_d = (_c = this._provider).getOrders) === null || _d === void 0 ? void 0 : _d.call(_c);
|
25
|
+
const resourceURI = (_f = (_e = this._provider).getResourceURI) === null || _f === void 0 ? void 0 : _f.call(_e);
|
26
|
+
const selectedIDs = this._provider.getSelectedIDs();
|
27
|
+
const option = resolveProps.exportOption;
|
28
|
+
const currentPageOptions = [
|
29
|
+
DataExporterOption.EXPORT_PAGE_TO_PDF,
|
30
|
+
DataExporterOption.EXPORT_PAGE_TO_XLS
|
31
|
+
];
|
32
|
+
delete resolveProps.exportOption;
|
33
|
+
let params = Object.assign({ filters,
|
34
|
+
columns,
|
35
|
+
sort,
|
36
|
+
resourceURI, selectedIDs: selectedIDs.slice(0, this._provider.getExportLimit()) }, resolveProps);
|
37
|
+
if (currentPageOptions.includes(option) || resolveProps.type == "page") {
|
38
|
+
const offset = this._provider.getOffset();
|
39
|
+
const limit = this._provider.getPageSize();
|
40
|
+
params = Object.assign(Object.assign({}, params), { offset,
|
41
|
+
limit, selectedIDs: [] });
|
42
|
+
}
|
43
|
+
else if (resolveProps.type == "all") {
|
44
|
+
params = Object.assign(Object.assign({}, params), { offset: 0, limit: this._provider.getExportLimit(), selectedIDs: [] });
|
45
|
+
}
|
46
|
+
return Promise.resolve(params);
|
47
|
+
}
|
48
|
+
async executeExport(resolveProps) {
|
49
|
+
const _a = await this.getParams(resolveProps), { methodName } = _a, requestBody = __rest(_a, ["methodName"]);
|
50
|
+
const application = ApplicationContext.getContextValue("__SNK__APPLICATION__");
|
51
|
+
const serviceName = `${application.getModuleName()}@DataExporterSPBean.${methodName}`;
|
52
|
+
const payload = { serviceName, requestBody };
|
53
|
+
return new Promise((resolve, reject) => {
|
54
|
+
DataFetcher.get()
|
55
|
+
.callServiceBroker(serviceName, ObjectUtils.objectToString(payload))
|
56
|
+
.then(result => resolve(this.getFormatResponse(result)))
|
57
|
+
.catch(error => reject(error));
|
58
|
+
});
|
59
|
+
}
|
60
|
+
getFormatResponse(result) {
|
61
|
+
var _a;
|
62
|
+
const response = (_a = result === null || result === void 0 ? void 0 : result.json) === null || _a === void 0 ? void 0 : _a.$;
|
63
|
+
if (response == undefined) {
|
64
|
+
return;
|
65
|
+
}
|
66
|
+
return ObjectUtils.stringToObject(response);
|
67
|
+
}
|
68
|
+
}
|
@@ -1 +1,48 @@
|
|
1
|
-
|
1
|
+
import { UserInterface } from '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
|
2
|
+
import { DataType } from '@sankhyalabs/core';
|
3
|
+
export class CommonsExporter {
|
4
|
+
constructor(dataUnit, grid) {
|
5
|
+
this.dataUnit = dataUnit;
|
6
|
+
this.grid = grid;
|
7
|
+
}
|
8
|
+
async getColumnsMetadata() {
|
9
|
+
var _a;
|
10
|
+
const columnsState = await ((_a = this.grid) === null || _a === void 0 ? void 0 : _a.getColumnsState());
|
11
|
+
return this.buildColumnsMetadata(columnsState);
|
12
|
+
}
|
13
|
+
buildColumnsMetadata(gridColumns) {
|
14
|
+
const columnsMetadata = [];
|
15
|
+
gridColumns === null || gridColumns === void 0 ? void 0 : gridColumns.forEach((column) => {
|
16
|
+
var _a, _b;
|
17
|
+
/**
|
18
|
+
* TODO: Analisar e criar uma melhor forma de tratar essa validação do "RECDESP".
|
19
|
+
*/
|
20
|
+
if (column.hidden && column.name !== "RECDESP") {
|
21
|
+
return;
|
22
|
+
}
|
23
|
+
const fieldData = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField(column.name);
|
24
|
+
const columnData = {
|
25
|
+
label: column.label,
|
26
|
+
id: column.name,
|
27
|
+
width: (fieldData === null || fieldData === void 0 ? void 0 : fieldData.userInterface) === UserInterface.SEARCH ? 30 : column.width,
|
28
|
+
type: fieldData === null || fieldData === void 0 ? void 0 : fieldData.dataType,
|
29
|
+
userInterface: fieldData === null || fieldData === void 0 ? void 0 : fieldData.userInterface
|
30
|
+
};
|
31
|
+
columnsMetadata.push(columnData);
|
32
|
+
if (((_b = fieldData === null || fieldData === void 0 ? void 0 : fieldData.properties) === null || _b === void 0 ? void 0 : _b.DESCRIPTIONFIELD) != undefined) {
|
33
|
+
const mergedFrom = fieldData.properties.mergedFrom;
|
34
|
+
const descriptionField = `${fieldData.properties.ENTITYNAME}.${fieldData.properties.DESCRIPTIONFIELD}`;
|
35
|
+
const descriptionColumn = {
|
36
|
+
label: fieldData.properties.DESCRIPTIONENTITY,
|
37
|
+
id: `${mergedFrom ? (mergedFrom + ".") : ""}${descriptionField}`,
|
38
|
+
width: 200,
|
39
|
+
type: DataType.TEXT,
|
40
|
+
userInterface: UserInterface.LONGTEXT,
|
41
|
+
descriptionFrom: fieldData.name
|
42
|
+
};
|
43
|
+
columnsMetadata.push(descriptionColumn);
|
44
|
+
}
|
45
|
+
});
|
46
|
+
return columnsMetadata || [];
|
47
|
+
}
|
48
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,53 @@
|
|
1
|
+
import { CommonsExporter } from "../interfaces/IExporterProvider";
|
2
|
+
import { UserInterface } from "@sankhyalabs/core";
|
3
|
+
import { getSelectedIDs } from "../utils/RecordIDUtils";
|
4
|
+
import { DataExporterOption } from "../../../lib/@types";
|
5
|
+
export default class ClientSideExporterProvider extends CommonsExporter {
|
6
|
+
getSelectedNumber() {
|
7
|
+
return this.dataUnit.getSelectionInfo().length;
|
8
|
+
}
|
9
|
+
getTotalRecords() {
|
10
|
+
var _a, _b, _c;
|
11
|
+
const { total } = ((_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getPaginationInfo()) || {};
|
12
|
+
return total !== null && total !== void 0 ? total : (_c = (_b = this.dataUnit) === null || _b === void 0 ? void 0 : _b.records) === null || _c === void 0 ? void 0 : _c.length;
|
13
|
+
}
|
14
|
+
getSelectedIDs() {
|
15
|
+
return getSelectedIDs(this.dataUnit);
|
16
|
+
}
|
17
|
+
getRecordID() {
|
18
|
+
var _a, _b, _c;
|
19
|
+
return (_c = (_b = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.records) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.__record__id__;
|
20
|
+
}
|
21
|
+
async getRecords() {
|
22
|
+
if (this.dataUnit.records.length === 0) {
|
23
|
+
return Promise.resolve([]);
|
24
|
+
}
|
25
|
+
const selectionInfo = this.dataUnit.getSelectionInfo();
|
26
|
+
const records = selectionInfo.isEmpty() || selectionInfo.isAllRecords() ? await selectionInfo.getAllRecords() : selectionInfo.records;
|
27
|
+
return Promise.resolve(records == undefined ? [] : records);
|
28
|
+
}
|
29
|
+
getHiddenOptions() {
|
30
|
+
return [
|
31
|
+
DataExporterOption.EXPORT_BY_EMAIL,
|
32
|
+
DataExporterOption.EXPORT_PDF_TO_EMAIL,
|
33
|
+
DataExporterOption.EXPORT_XLS_TO_EMAIL,
|
34
|
+
DataExporterOption.EXPORT_PAGE_TO_PDF,
|
35
|
+
DataExporterOption.EXPORT_PAGE_TO_XLS
|
36
|
+
];
|
37
|
+
}
|
38
|
+
formatValue(record, column) {
|
39
|
+
const { id, descriptionFrom } = column;
|
40
|
+
const value = record[descriptionFrom || id];
|
41
|
+
if (value == undefined) {
|
42
|
+
return "";
|
43
|
+
}
|
44
|
+
if (descriptionFrom != undefined) {
|
45
|
+
return value.label;
|
46
|
+
}
|
47
|
+
const fieldDescriptor = this.dataUnit.getField(id);
|
48
|
+
if (fieldDescriptor.userInterface === UserInterface.SEARCH) {
|
49
|
+
return value.value;
|
50
|
+
}
|
51
|
+
return this.dataUnit.getFormattedValue(id, value);
|
52
|
+
}
|
53
|
+
}
|
@@ -0,0 +1,55 @@
|
|
1
|
+
import { CommonsExporter } from "../interfaces/IExporterProvider";
|
2
|
+
import { getSelectedIDs } from "../utils/RecordIDUtils";
|
3
|
+
export default class ServerSideExporterProvider extends CommonsExporter {
|
4
|
+
getFilters() {
|
5
|
+
var _a;
|
6
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getAppliedFilters();
|
7
|
+
}
|
8
|
+
getOrders() {
|
9
|
+
var _a;
|
10
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getSort();
|
11
|
+
}
|
12
|
+
getResourceURI() {
|
13
|
+
var _a;
|
14
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.name;
|
15
|
+
}
|
16
|
+
getSelectedNumber() {
|
17
|
+
return this.dataUnit.getSelectionInfo().length;
|
18
|
+
}
|
19
|
+
getTotalRecords() {
|
20
|
+
var _a, _b, _c;
|
21
|
+
const { total } = ((_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getPaginationInfo()) || {};
|
22
|
+
return total !== null && total !== void 0 ? total : (_c = (_b = this.dataUnit) === null || _b === void 0 ? void 0 : _b.records) === null || _c === void 0 ? void 0 : _c.length;
|
23
|
+
}
|
24
|
+
getSelectedIDs() {
|
25
|
+
return getSelectedIDs(this.dataUnit);
|
26
|
+
}
|
27
|
+
getOffset() {
|
28
|
+
return this.getExporterOffset(this.getPaginationInfo());
|
29
|
+
}
|
30
|
+
getPageSize() {
|
31
|
+
var _a;
|
32
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.pageSize;
|
33
|
+
}
|
34
|
+
getExportLimit() {
|
35
|
+
return 5000;
|
36
|
+
}
|
37
|
+
getRecordID() {
|
38
|
+
var _a, _b, _c;
|
39
|
+
return (_c = (_b = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.records) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.__record__id__;
|
40
|
+
}
|
41
|
+
getPaginationInfo() {
|
42
|
+
var _a;
|
43
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getPaginationInfo();
|
44
|
+
}
|
45
|
+
getExporterOffset(paginationInfo) {
|
46
|
+
if (paginationInfo == undefined) {
|
47
|
+
return;
|
48
|
+
}
|
49
|
+
const offset = paginationInfo.firstRecord;
|
50
|
+
if (offset > 0) {
|
51
|
+
return (offset - 1);
|
52
|
+
}
|
53
|
+
return offset;
|
54
|
+
}
|
55
|
+
}
|