@sankhyalabs/sankhyablocks 8.16.0-dev.113 → 8.16.0-dev.115
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/{ClientSideExporterProvider-a2753c93.js → ClientSideExporterProvider-0ce2bcd9.js} +2 -2
- package/dist/cjs/{ConfigStorage-df09fb78.js → ConfigStorage-48ba265b.js} +45 -17
- package/dist/cjs/FormConfigHelper-c664dbae.js +260 -0
- package/dist/cjs/{PersonalizedFilterUtils-0184ffbb.js → PersonalizedFilterUtils-7259cf65.js} +1 -1
- package/dist/cjs/{SnkFormConfigManager-45a8d7b7.js → SnkFormConfigManager-aa4631bd.js} +3 -4
- package/dist/cjs/{SnkMessageBuilder-9deeae08.js → SnkMessageBuilder-e3b7850b.js} +28 -3
- package/dist/cjs/config-header.cjs.entry.js +79 -0
- package/dist/cjs/configs-button.cjs.entry.js +61 -0
- package/dist/cjs/{constants-77c1b8bd.js → constants-6d82e405.js} +8 -38
- package/dist/cjs/default-filters-a09bf82b.js +8 -0
- package/dist/cjs/field-config_2.cjs.entry.js +324 -0
- package/dist/cjs/fields-layout.cjs.entry.js +341 -0
- package/dist/cjs/fields-selector.cjs.entry.js +74 -0
- package/dist/cjs/{filter-type.enum-b14ce507.js → filter-type.enum-2bb46d2a.js} +1 -0
- package/dist/cjs/guides-configurator.cjs.entry.js +164 -0
- package/dist/cjs/{index-102ba62d.js → index-0ad2baeb.js} +4 -5
- package/dist/cjs/{index-f9e81701.js → index-1cf293c1.js} +32 -10
- package/dist/cjs/{index-c5771aba.js → index-62760a9c.js} +5 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/pesquisa-grid_2.cjs.entry.js +2 -2
- package/dist/cjs/sankhyablocks.cjs.js +2 -2
- package/dist/cjs/snk-actions-button_8.cjs.entry.js +3 -3
- package/dist/cjs/snk-actions-form.cjs.entry.js +1 -1
- package/dist/cjs/snk-application.cjs.entry.js +4 -4
- package/dist/cjs/snk-attach.cjs.entry.js +4 -4
- package/dist/cjs/snk-client-confirm.cjs.entry.js +1 -1
- package/dist/cjs/snk-configurator.cjs.entry.js +2 -2
- package/dist/cjs/snk-crud.cjs.entry.js +4 -4
- package/dist/cjs/snk-custom-slot-elements.cjs.entry.js +1 -1
- package/dist/cjs/snk-data-exporter.cjs.entry.js +4 -4
- package/dist/cjs/{snk-data-unit-57916de4.js → snk-data-unit-3684c96e.js} +2 -2
- package/dist/cjs/snk-data-unit.cjs.entry.js +3 -3
- package/dist/cjs/snk-default-filter.cjs.entry.js +77 -0
- package/dist/cjs/snk-detail-view.cjs.entry.js +8 -8
- package/dist/cjs/snk-entity-list.cjs.entry.js +1 -1
- package/dist/cjs/snk-exporter-email-sender.cjs.entry.js +1 -1
- package/dist/cjs/snk-expression-group_2.cjs.entry.js +10 -8
- package/dist/cjs/snk-filter-advanced-mode_2.cjs.entry.js +5 -4
- package/dist/cjs/snk-filter-bar_4.cjs.entry.js +82 -28
- package/dist/cjs/snk-filter-binary-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-checkbox-list.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-detail.cjs.entry.js +3 -3
- package/dist/cjs/snk-filter-field-search_2.cjs.entry.js +3 -3
- package/dist/cjs/snk-filter-modal-item.cjs.entry.js +3 -3
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-number.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-period.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-search.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-text.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-summary.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-view.cjs.entry.js +1 -1
- package/dist/cjs/snk-form_2.cjs.entry.js +433 -0
- package/dist/cjs/snk-grid.cjs.entry.js +6 -6
- package/dist/cjs/{snk-guides-viewer-d33379cd.js → snk-guides-viewer-edc0a00a.js} +5 -5
- package/dist/cjs/snk-guides-viewer.cjs.entry.js +7 -7
- package/dist/cjs/snk-personalized-filter-editor.cjs.entry.js +1 -1
- package/dist/cjs/snk-personalized-filter.cjs.entry.js +53 -18
- package/dist/cjs/snk-pesquisa.cjs.entry.js +2 -2
- package/dist/cjs/snk-print-selector.cjs.entry.js +1 -1
- package/dist/cjs/snk-simple-bar.cjs.entry.js +1 -1
- package/dist/cjs/snk-simple-crud.cjs.entry.js +7 -7
- package/dist/cjs/snk-taskbar.cjs.entry.js +3 -3
- package/dist/cjs/sortable.esm-9a110bb7.js +2668 -0
- package/dist/cjs/{taskbar-elements-6f4e06af.js → taskbar-elements-3b74cd21.js} +2 -2
- package/dist/cjs/teste-pesquisa.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +8 -14
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +1 -1
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +80 -12
- package/dist/collection/components/snk-filter-bar/filter-modal/subcomponents/snk-default-filter/snk-default-filter.css +34 -0
- package/dist/collection/components/snk-filter-bar/filter-modal/subcomponents/snk-default-filter/snk-default-filter.js +142 -0
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.js +24 -15
- package/dist/collection/components/snk-filter-bar/types/default-filters.js +6 -0
- package/dist/collection/components/snk-filter-bar/types/filter-type.enum.js +1 -0
- package/dist/collection/components/snk-filter-bar/utils/SnkFilterModalFactory.js +4 -4
- package/dist/collection/components/snk-form-config/FormConfigHelper.js +245 -0
- package/dist/collection/components/snk-form-config/SnkFormConfigManager.js +4 -5
- package/dist/collection/components/snk-form-config/config-header/config-header.css +18 -0
- package/dist/collection/components/snk-form-config/config-header/config-header.js +236 -0
- package/dist/collection/components/snk-form-config/config-header/configs-button/configs-button.css +41 -0
- package/dist/collection/components/snk-form-config/config-header/configs-button/configs-button.js +170 -0
- package/dist/collection/components/snk-form-config/field-item/field-config/field-config.css +21 -0
- package/dist/collection/components/snk-form-config/field-item/field-config/field-config.js +408 -0
- package/dist/collection/components/snk-form-config/field-item/field-item.css +108 -0
- package/dist/collection/components/snk-form-config/field-item/field-item.js +206 -0
- package/dist/collection/components/snk-form-config/fields-layout/fields-layout.css +133 -0
- package/dist/collection/components/snk-form-config/fields-layout/fields-layout.js +578 -0
- package/dist/collection/components/snk-form-config/fields-selector/fields-selector.css +38 -0
- package/dist/collection/components/snk-form-config/fields-selector/fields-selector.js +146 -0
- package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.css +132 -0
- package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.js +317 -0
- package/dist/collection/components/snk-form-config/snk-form-config.css +16 -229
- package/dist/collection/components/snk-form-config/snk-form-config.js +288 -980
- package/dist/collection/components/snk-personalized-filter/interfaces/index.js +5 -0
- package/dist/collection/components/snk-personalized-filter/snk-personalized-filter.js +67 -13
- package/dist/collection/components/snk-personalized-filter/subcomponents/snk-expression-group/snk-expression-group.css +3 -0
- package/dist/collection/components/snk-personalized-filter/subcomponents/snk-expression-group/snk-expression-group.js +20 -1
- package/dist/collection/components/snk-personalized-filter/subcomponents/snk-expression-item/snk-expression-item.js +22 -3
- package/dist/collection/components/snk-personalized-filter/subcomponents/snk-filter-assistent-mode/snk-filter-assistent-mode.js +20 -1
- package/dist/collection/lib/configs/ConfigStorage.js +16 -8
- package/dist/collection/lib/http/data-fetcher/fetchers/personalized-filter-fetcher.js +29 -9
- package/dist/collection/lib/message/resources/snk-filter-bar.msg.js +6 -0
- package/dist/collection/lib/message/resources/snk-form.msg.js +16 -2
- package/dist/collection/lib/message/resources/snk-personalized-filter.msg.js +6 -1
- package/dist/collection/lib/utils/constants.js +7 -1
- package/dist/components/ConfigStorage.js +45 -17
- package/dist/components/PersonalizedFilterUtils.js +6 -1
- package/dist/components/SnkFormConfigManager.js +2 -3
- package/dist/components/SnkMessageBuilder.js +28 -3
- package/dist/components/{snk-tab-config.d.ts → config-header.d.ts} +4 -4
- package/dist/components/config-header.js +6 -0
- package/dist/components/config-header2.js +103 -0
- package/dist/components/configs-button.d.ts +11 -0
- package/dist/components/configs-button.js +6 -0
- package/dist/components/configs-button2.js +76 -0
- package/dist/components/constants.js +8 -34
- package/dist/components/field-config.d.ts +11 -0
- package/dist/components/field-config.js +6 -0
- package/dist/components/field-config2.js +525 -0
- package/dist/components/field-item.d.ts +11 -0
- package/dist/components/field-item.js +6 -0
- package/dist/components/field-item2.js +93 -0
- package/dist/components/fields-layout.d.ts +11 -0
- package/dist/components/fields-layout.js +6 -0
- package/dist/components/fields-layout2.js +370 -0
- package/dist/components/{snk-field-config.d.ts → fields-selector.d.ts} +4 -4
- package/dist/components/fields-selector.js +6 -0
- package/dist/components/fields-selector2.js +98 -0
- package/dist/components/guides-configurator.d.ts +11 -0
- package/dist/components/guides-configurator.js +6 -0
- package/dist/components/guides-configurator2.js +182 -0
- package/dist/components/index.d.ts +8 -3
- package/dist/components/index.js +8 -3
- package/dist/components/index2.js +3 -4
- package/dist/components/snk-application2.js +1 -1
- package/dist/components/snk-crud.js +86 -62
- package/dist/components/{snk-config-options.d.ts → snk-default-filter.d.ts} +4 -4
- package/dist/components/snk-default-filter.js +6 -0
- package/dist/components/snk-default-filter2.js +97 -0
- package/dist/components/snk-detail-view2.js +113 -89
- package/dist/components/snk-expression-group2.js +4 -2
- package/dist/components/snk-expression-item2.js +5 -3
- package/dist/components/snk-filter-assistent-mode2.js +4 -2
- package/dist/components/snk-filter-bar2.js +28 -19
- package/dist/components/snk-filter-modal-item2.js +1 -0
- package/dist/components/snk-filter-modal.js +59 -8
- package/dist/components/snk-form-config2.js +253 -953
- package/dist/components/snk-form.js +33 -9
- package/dist/components/snk-personalized-filter2.js +50 -14
- package/dist/components/sortable.esm.js +2666 -0
- package/dist/esm/{ClientSideExporterProvider-b3871edb.js → ClientSideExporterProvider-3ed744fd.js} +2 -2
- package/dist/esm/{ConfigStorage-71e6766f.js → ConfigStorage-79b9e180.js} +45 -17
- package/dist/esm/FormConfigHelper-49fe72ca.js +248 -0
- package/dist/esm/{PersonalizedFilterUtils-e2b38ef7.js → PersonalizedFilterUtils-2db38ff2.js} +1 -1
- package/dist/esm/{SnkFormConfigManager-be490a33.js → SnkFormConfigManager-b4b93298.js} +3 -4
- package/dist/esm/{SnkMessageBuilder-2dbd8fa2.js → SnkMessageBuilder-9c269caf.js} +28 -3
- package/dist/esm/config-header.entry.js +75 -0
- package/dist/esm/configs-button.entry.js +57 -0
- package/dist/esm/{constants-7db1128a.js → constants-7b422de0.js} +8 -34
- package/dist/esm/default-filters-50105e43.js +8 -0
- package/dist/esm/field-config_2.entry.js +319 -0
- package/dist/esm/fields-layout.entry.js +337 -0
- package/dist/esm/fields-selector.entry.js +70 -0
- package/dist/esm/{filter-type.enum-a80c1b6b.js → filter-type.enum-f6a8fe23.js} +1 -0
- package/dist/esm/guides-configurator.entry.js +160 -0
- package/dist/esm/{index-a7d3d3f1.js → index-479e1293.js} +32 -10
- package/dist/esm/{index-ae591a44.js → index-8acbae97.js} +6 -1
- package/dist/esm/{index-bdf75557.js → index-b72af127.js} +4 -5
- package/dist/esm/loader.js +3 -3
- package/dist/esm/pesquisa-grid_2.entry.js +2 -2
- package/dist/esm/sankhyablocks.js +3 -3
- package/dist/esm/snk-actions-button_8.entry.js +3 -3
- package/dist/esm/snk-actions-form.entry.js +1 -1
- package/dist/esm/snk-application.entry.js +4 -4
- package/dist/esm/snk-attach.entry.js +4 -4
- package/dist/esm/snk-client-confirm.entry.js +1 -1
- package/dist/esm/snk-configurator.entry.js +2 -2
- package/dist/esm/snk-crud.entry.js +4 -4
- package/dist/esm/snk-custom-slot-elements.entry.js +1 -1
- package/dist/esm/snk-data-exporter.entry.js +4 -4
- package/dist/esm/{snk-data-unit-65c9dd1a.js → snk-data-unit-027bca56.js} +2 -2
- package/dist/esm/snk-data-unit.entry.js +3 -3
- package/dist/esm/snk-default-filter.entry.js +73 -0
- package/dist/esm/snk-detail-view.entry.js +8 -8
- package/dist/esm/snk-entity-list.entry.js +1 -1
- package/dist/esm/snk-exporter-email-sender.entry.js +1 -1
- package/dist/esm/snk-expression-group_2.entry.js +10 -8
- package/dist/esm/snk-filter-advanced-mode_2.entry.js +5 -4
- package/dist/esm/snk-filter-bar_4.entry.js +82 -28
- package/dist/esm/snk-filter-binary-select.entry.js +1 -1
- package/dist/esm/snk-filter-checkbox-list.entry.js +1 -1
- package/dist/esm/snk-filter-detail.entry.js +3 -3
- package/dist/esm/snk-filter-field-search_2.entry.js +3 -3
- package/dist/esm/snk-filter-modal-item.entry.js +3 -3
- package/dist/esm/snk-filter-multi-select.entry.js +1 -1
- package/dist/esm/snk-filter-number.entry.js +1 -1
- package/dist/esm/snk-filter-period.entry.js +1 -1
- package/dist/esm/snk-filter-search.entry.js +1 -1
- package/dist/esm/snk-filter-text.entry.js +1 -1
- package/dist/esm/snk-form-summary.entry.js +1 -1
- package/dist/esm/snk-form-view.entry.js +1 -1
- package/dist/esm/snk-form_2.entry.js +428 -0
- package/dist/esm/snk-grid.entry.js +6 -6
- package/dist/esm/{snk-guides-viewer-72953334.js → snk-guides-viewer-32f3d3ab.js} +5 -5
- package/dist/esm/snk-guides-viewer.entry.js +7 -7
- package/dist/esm/snk-personalized-filter-editor.entry.js +1 -1
- package/dist/esm/snk-personalized-filter.entry.js +53 -18
- package/dist/esm/snk-pesquisa.entry.js +2 -2
- package/dist/esm/snk-print-selector.entry.js +1 -1
- package/dist/esm/snk-simple-bar.entry.js +1 -1
- package/dist/esm/snk-simple-crud.entry.js +7 -7
- package/dist/esm/snk-taskbar.entry.js +3 -3
- package/dist/esm/sortable.esm-842f85a3.js +2666 -0
- package/dist/esm/{taskbar-elements-f2cb4922.js → taskbar-elements-171476d4.js} +2 -2
- package/dist/esm/teste-pesquisa.entry.js +1 -1
- package/dist/sankhyablocks/{p-24a0dbd2.entry.js → p-0024d3fd.entry.js} +1 -1
- package/dist/sankhyablocks/{p-b8d649dd.entry.js → p-09e60995.entry.js} +1 -1
- package/dist/sankhyablocks/{p-bc101064.entry.js → p-0cb295c1.entry.js} +1 -1
- package/dist/sankhyablocks/{p-b0ab5066.entry.js → p-1456d7cb.entry.js} +1 -1
- package/dist/sankhyablocks/{p-9531fd46.entry.js → p-180716b2.entry.js} +1 -1
- package/dist/sankhyablocks/{p-6a03b190.entry.js → p-1ea34488.entry.js} +1 -1
- package/dist/sankhyablocks/p-21107f0d.entry.js +1 -0
- package/dist/sankhyablocks/{p-118e769b.entry.js → p-27482793.entry.js} +1 -1
- package/dist/sankhyablocks/p-290fea5f.entry.js +1 -0
- package/dist/sankhyablocks/{p-08ea6c86.entry.js → p-295aa209.entry.js} +1 -1
- package/dist/sankhyablocks/{p-c9675d64.js → p-2bde486e.js} +1 -1
- package/dist/sankhyablocks/{p-26b0ce3e.entry.js → p-2fdac5e6.entry.js} +1 -1
- package/dist/sankhyablocks/p-349d1968.entry.js +1 -0
- package/dist/sankhyablocks/p-35e73c5d.js +1 -0
- package/dist/sankhyablocks/{p-89c92727.entry.js → p-398cdd67.entry.js} +1 -1
- package/dist/sankhyablocks/{p-ddf93f36.entry.js → p-3a48bff3.entry.js} +1 -1
- package/dist/sankhyablocks/{p-434817f0.entry.js → p-3d41f5a8.entry.js} +1 -1
- package/dist/sankhyablocks/p-3f24c9b2.js +1 -0
- package/dist/sankhyablocks/{p-8002dcd0.entry.js → p-471b34f4.entry.js} +1 -1
- package/dist/sankhyablocks/{p-7e2ded86.entry.js → p-49d968e2.entry.js} +1 -1
- package/dist/sankhyablocks/p-4d2ff2fb.entry.js +1 -0
- package/dist/sankhyablocks/p-51833248.js +7 -0
- package/dist/sankhyablocks/p-60dd1d27.entry.js +1 -0
- package/dist/sankhyablocks/p-6416975c.js +56 -0
- package/dist/sankhyablocks/{p-7beeabc1.entry.js → p-65c5d430.entry.js} +1 -1
- package/dist/sankhyablocks/{p-21a81901.entry.js → p-667cab42.entry.js} +1 -1
- package/dist/sankhyablocks/p-6a4b21dd.js +1 -0
- package/dist/sankhyablocks/p-71a05822.entry.js +1 -0
- package/dist/sankhyablocks/{p-ac8d1cd6.entry.js → p-7345782c.entry.js} +1 -1
- package/dist/sankhyablocks/{p-885802c3.js → p-763b04fa.js} +1 -1
- package/dist/sankhyablocks/{p-d07b18a4.js → p-7de79adf.js} +1 -1
- package/dist/sankhyablocks/p-7e250432.entry.js +1 -0
- package/dist/sankhyablocks/{p-47178038.entry.js → p-83c100f2.entry.js} +1 -1
- package/dist/sankhyablocks/p-84345e7a.js +1 -0
- package/dist/sankhyablocks/p-86bd4478.entry.js +1 -0
- package/dist/sankhyablocks/p-9019a32f.js +1 -0
- package/dist/sankhyablocks/{p-54a5d52a.entry.js → p-90805683.entry.js} +1 -1
- package/dist/sankhyablocks/{p-c2e468c9.entry.js → p-91a9abb6.entry.js} +1 -1
- package/dist/sankhyablocks/p-9751c42f.entry.js +1 -0
- package/dist/sankhyablocks/{p-057fad05.js → p-988afe78.js} +1 -1
- package/dist/sankhyablocks/{p-16a1dd18.entry.js → p-9a63f3f7.entry.js} +1 -1
- package/dist/sankhyablocks/{p-90684a75.entry.js → p-9ad3557c.entry.js} +1 -1
- package/dist/sankhyablocks/{p-b6200d32.entry.js → p-9fd87bfd.entry.js} +1 -1
- package/dist/sankhyablocks/p-a06bf7b9.entry.js +1 -0
- package/dist/sankhyablocks/{p-33718dfc.entry.js → p-a227b650.entry.js} +1 -1
- package/dist/sankhyablocks/p-a349689a.js +1 -0
- package/dist/sankhyablocks/p-a5bb2f93.entry.js +1 -0
- package/dist/sankhyablocks/{p-ebdb9d89.js → p-a6513fcb.js} +1 -1
- package/dist/sankhyablocks/{p-8c235d4c.entry.js → p-a76e6d51.entry.js} +1 -1
- package/dist/sankhyablocks/p-b568c1d4.js +1 -0
- package/dist/sankhyablocks/{p-ce94e6c4.entry.js → p-bd665460.entry.js} +1 -1
- package/dist/sankhyablocks/p-c3324d79.entry.js +1 -0
- package/dist/sankhyablocks/{p-bf2acf72.entry.js → p-c6a8a8bc.entry.js} +1 -1
- package/dist/sankhyablocks/{p-165cde3b.entry.js → p-c926cf6b.entry.js} +1 -1
- package/dist/sankhyablocks/{p-79f823f3.entry.js → p-d67526b6.entry.js} +1 -1
- package/dist/sankhyablocks/{p-d2d301a6.js → p-d8d8169b.js} +1 -1
- package/dist/sankhyablocks/{p-5f157b09.entry.js → p-dff65083.entry.js} +1 -1
- package/dist/sankhyablocks/{p-3372178e.entry.js → p-e2988bb1.entry.js} +1 -1
- package/dist/sankhyablocks/{p-a4ebeec4.entry.js → p-e3521eae.entry.js} +1 -1
- package/dist/sankhyablocks/p-e7cccc45.entry.js +1 -0
- package/dist/sankhyablocks/{p-1f80174b.entry.js → p-f4e31122.entry.js} +1 -1
- package/dist/sankhyablocks/{p-0fadb620.js → p-fc0b609e.js} +1 -1
- package/dist/sankhyablocks/{p-a14a09c3.entry.js → p-ff7060bc.entry.js} +1 -1
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +16 -4
- package/dist/types/components/snk-filter-bar/filter-modal/subcomponents/snk-default-filter/snk-default-filter.d.ts +27 -0
- package/dist/types/components/snk-filter-bar/snk-filter-bar.d.ts +4 -3
- package/dist/types/components/snk-filter-bar/types/default-filters.d.ts +5 -0
- package/dist/types/components/snk-filter-bar/types/filter-type.enum.d.ts +2 -1
- package/dist/types/components/snk-filter-bar/utils/SnkFilterModalFactory.d.ts +3 -3
- package/dist/types/components/snk-form-config/FormConfigHelper.d.ts +31 -0
- package/dist/types/components/snk-form-config/SnkFormConfigManager.d.ts +3 -3
- package/dist/types/components/snk-form-config/config-header/config-header.d.ts +23 -0
- package/dist/types/components/snk-form-config/config-header/configs-button/configs-button.d.ts +19 -0
- package/dist/types/components/snk-form-config/field-item/field-config/field-config.d.ts +56 -0
- package/dist/types/components/snk-form-config/fields-layout/fields-layout.d.ts +63 -0
- package/dist/types/components/snk-form-config/fields-selector/fields-selector.d.ts +18 -0
- package/dist/types/components/snk-form-config/guides-configurator/guides-configurator.d.ts +42 -0
- package/dist/types/components/snk-form-config/snk-form-config.d.ts +51 -120
- package/dist/types/components/snk-personalized-filter/interfaces/index.d.ts +4 -0
- package/dist/types/components/snk-personalized-filter/snk-personalized-filter.d.ts +7 -1
- package/dist/types/components/snk-personalized-filter/subcomponents/snk-expression-group/snk-expression-group.d.ts +4 -0
- package/dist/types/components/snk-personalized-filter/subcomponents/snk-expression-item/snk-expression-item.d.ts +4 -0
- package/dist/types/components/snk-personalized-filter/subcomponents/snk-filter-assistent-mode/snk-filter-assistent-mode.d.ts +4 -0
- package/dist/types/components.d.ts +276 -203
- package/dist/types/lib/configs/ConfigStorage.d.ts +4 -2
- package/dist/types/lib/http/data-fetcher/fetchers/personalized-filter-fetcher.d.ts +8 -4
- package/dist/types/lib/utils/constants.d.ts +6 -0
- package/package.json +4 -2
- package/react/components.d.ts +8 -3
- package/react/components.js +8 -3
- package/react/components.js.map +1 -1
- package/dist/cjs/Sortable-fb1c4cbb.js +0 -2853
- package/dist/cjs/snk-config-options_3.cjs.entry.js +0 -1390
- package/dist/cjs/snk-field-config.cjs.entry.js +0 -60
- package/dist/cjs/snk-tab-config.cjs.entry.js +0 -332
- package/dist/collection/components/snk-form-config/subcomponents/snk-config-options/snk-config-options.css +0 -16
- package/dist/collection/components/snk-form-config/subcomponents/snk-config-options/snk-config-options.js +0 -346
- package/dist/collection/components/snk-form-config/subcomponents/snk-field-config/snk-field-config.css +0 -219
- package/dist/collection/components/snk-form-config/subcomponents/snk-field-config/snk-field-config.js +0 -184
- package/dist/collection/components/snk-form-config/subcomponents/snk-tab-config/snk-tab-config.css +0 -323
- package/dist/collection/components/snk-form-config/subcomponents/snk-tab-config/snk-tab-config.js +0 -527
- package/dist/components/snk-config-options.js +0 -6
- package/dist/components/snk-config-options2.js +0 -257
- package/dist/components/snk-field-config.js +0 -6
- package/dist/components/snk-field-config2.js +0 -76
- package/dist/components/snk-tab-config.js +0 -6
- package/dist/components/snk-tab-config2.js +0 -3202
- package/dist/esm/Sortable-83960219.js +0 -2851
- package/dist/esm/snk-config-options_3.entry.js +0 -1384
- package/dist/esm/snk-field-config.entry.js +0 -56
- package/dist/esm/snk-tab-config.entry.js +0 -328
- package/dist/sankhyablocks/p-03b68a74.js +0 -56
- package/dist/sankhyablocks/p-3749dffb.entry.js +0 -1
- package/dist/sankhyablocks/p-3ab6df3d.entry.js +0 -1
- package/dist/sankhyablocks/p-4689c2e6.js +0 -1
- package/dist/sankhyablocks/p-490b75b5.entry.js +0 -1
- package/dist/sankhyablocks/p-52d10014.entry.js +0 -1
- package/dist/sankhyablocks/p-5ffa0493.entry.js +0 -1
- package/dist/sankhyablocks/p-60137b7a.entry.js +0 -1
- package/dist/sankhyablocks/p-6dc031de.js +0 -1
- package/dist/sankhyablocks/p-9261d8a0.js +0 -1
- package/dist/sankhyablocks/p-933c0c0b.js +0 -1
- package/dist/sankhyablocks/p-9d3a025a.entry.js +0 -1
- package/dist/sankhyablocks/p-c0eb761b.entry.js +0 -1
- package/dist/sankhyablocks/p-d9804798.js +0 -1
- package/dist/sankhyablocks/p-fa816fb2.js +0 -1
- package/dist/types/components/snk-form-config/subcomponents/snk-config-options/snk-config-options.d.ts +0 -57
- package/dist/types/components/snk-form-config/subcomponents/snk-field-config/snk-field-config.d.ts +0 -43
- package/dist/types/components/snk-form-config/subcomponents/snk-tab-config/snk-tab-config.d.ts +0 -105
@@ -37,3 +37,8 @@ export var FilterEntities;
|
|
37
37
|
FilterEntities["FIELD"] = "Campo";
|
38
38
|
FilterEntities["INSTANCE"] = "Instancia";
|
39
39
|
})(FilterEntities || (FilterEntities = {}));
|
40
|
+
export var DefaultFilter;
|
41
|
+
(function (DefaultFilter) {
|
42
|
+
DefaultFilter["name"] = "Filtro padr\u00E3o";
|
43
|
+
DefaultFilter["id"] = "DEFAULT_FILTER";
|
44
|
+
})(DefaultFilter || (DefaultFilter = {}));
|
@@ -7,6 +7,7 @@ import { ObjectUtils, ElementIDUtils } from "@sankhyalabs/core";
|
|
7
7
|
import { FilterGroupCondition } from './interfaces/IExpressionItem';
|
8
8
|
import store from '../../lib/store';
|
9
9
|
import PersonalizedFilterFetcher from "../../lib/http/data-fetcher/fetchers/personalized-filter-fetcher";
|
10
|
+
import { DefaultFilter } from './interfaces';
|
10
11
|
export class SnkPersonalizedFilter {
|
11
12
|
constructor() {
|
12
13
|
this._personalizedFilterFetcher = new PersonalizedFilterFetcher();
|
@@ -31,6 +32,7 @@ export class SnkPersonalizedFilter {
|
|
31
32
|
this.filterId = undefined;
|
32
33
|
this.configName = undefined;
|
33
34
|
this.resourceID = undefined;
|
35
|
+
this.isDefaultFilter = false;
|
34
36
|
}
|
35
37
|
/*
|
36
38
|
* Cria um novo filtro se não houver nenhum filtro existente
|
@@ -63,6 +65,9 @@ export class SnkPersonalizedFilter {
|
|
63
65
|
operand: FilterGroupCondition.AND
|
64
66
|
}
|
65
67
|
};
|
68
|
+
if (this.isDefaultFilter) {
|
69
|
+
this.buildDataDefaultFilter(newPersonalizedFilter);
|
70
|
+
}
|
66
71
|
this._originalFilterAssistent = ObjectUtils.copy(newPersonalizedFilter);
|
67
72
|
this._filterAssistent = ObjectUtils.copy(newPersonalizedFilter);
|
68
73
|
}
|
@@ -70,6 +75,16 @@ export class SnkPersonalizedFilter {
|
|
70
75
|
if (newValue == null || oldValue == newValue || this.resourceID == undefined) {
|
71
76
|
return;
|
72
77
|
}
|
78
|
+
if (newValue === DefaultFilter.id) {
|
79
|
+
ConfigStorage.loadDefaultFilter(newValue, this.resourceID, this.configName)
|
80
|
+
.then((resp) => {
|
81
|
+
const personalizedFilter = this.applyDefaultValues(resp);
|
82
|
+
this._filterAssistent = personalizedFilter;
|
83
|
+
this._originalFilterAssistent = ObjectUtils.copy(personalizedFilter);
|
84
|
+
this._filterAssistentMode = this._filterAssistent.hasOwnProperty("assistent") && this._filterAssistent.assistent != undefined;
|
85
|
+
});
|
86
|
+
return;
|
87
|
+
}
|
73
88
|
ConfigStorage.loadPersonalizedFilter(newValue, this.resourceID, this.configName)
|
74
89
|
.then((resp) => {
|
75
90
|
const personalizedFilter = this.applyDefaultValues(resp);
|
@@ -96,20 +111,29 @@ export class SnkPersonalizedFilter {
|
|
96
111
|
this._elButtonMode.setAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME, ElementIDUtils.getInternalIDInfo(`${this._filterAssistentMode ? "advancedMode_ezButton" : "assistentMode_ezButton"}`));
|
97
112
|
}
|
98
113
|
}
|
114
|
+
buildDataDefaultFilter(data) {
|
115
|
+
data.name = DefaultFilter.name;
|
116
|
+
data.id = DefaultFilter.id;
|
117
|
+
}
|
99
118
|
getMessage(key, params) {
|
100
119
|
return this._application.messagesBuilder.getMessage(key, params);
|
101
120
|
}
|
102
|
-
saveFilter() {
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
});
|
121
|
+
async saveFilter() {
|
122
|
+
let response;
|
123
|
+
if (this.isDefaultFilter) {
|
124
|
+
response = await ConfigStorage.saveDefaultFilter(this._filterAssistent, this.resourceID, this.configName);
|
125
|
+
}
|
126
|
+
else {
|
127
|
+
response = await ConfigStorage.savePersonalizedFilter(this._filterAssistent, this.resourceID, this.configName);
|
128
|
+
}
|
129
|
+
this._elButtonSave.enabled = false;
|
130
|
+
const messageToken = !!this._filterAssistent.id ? 'confirmEdit' : 'confirmSave';
|
131
|
+
ApplicationUtils.info(this.getMessage(`snkPersonalizedFilter.${messageToken}.title`), { iconName: "check" });
|
132
|
+
const updatedFilterAssistent = Object.assign(Object.assign({}, response), this._filterAssistent);
|
133
|
+
updatedFilterAssistent.parameters = PersonalizedFilterUtils.buildVariableParameters(this._filterAssistent.assistent);
|
134
|
+
this._originalFilterAssistent = ObjectUtils.copy(updatedFilterAssistent);
|
135
|
+
this._filterAssistent = ObjectUtils.copy(updatedFilterAssistent);
|
136
|
+
this.ezAfterSave.emit();
|
113
137
|
}
|
114
138
|
removeFilter() {
|
115
139
|
ConfigStorage.removePersonalizedFilter(this._filterAssistent, this.resourceID, this.configName);
|
@@ -245,7 +269,7 @@ export class SnkPersonalizedFilter {
|
|
245
269
|
}
|
246
270
|
buildContainerPersonalizedFilter() {
|
247
271
|
return (h("ez-view-stack", { ref: (ref) => this._viewStackRef = ref }, h("stack-item", null, this._filterAssistentMode &&
|
248
|
-
h("snk-filter-assistent-mode", { filterAssistent: this._filterAssistent, messagesBuilder: this.messagesBuilder, filterId: this.filterId, entityUri: this.entityUri, application: this._application, onEzChangeFilter: (ev) => this.handleChangeFilterAssistentMode(ev.detail) })), h("stack-item", null, h("snk-filter-advanced-mode", { ref: (ref) => this._elAdvancedMode = ref, filterAssistent: this._filterAssistent, application: this._application, onEzExpressionChange: (ev) => this.handleExpressionChangeAdvancedMode(ev.detail) }))));
|
272
|
+
h("snk-filter-assistent-mode", { filterAssistent: this._filterAssistent, messagesBuilder: this.messagesBuilder, filterId: this.filterId, entityUri: this.entityUri, application: this._application, onEzChangeFilter: (ev) => this.handleChangeFilterAssistentMode(ev.detail), isDefaultFilter: this.isDefaultFilter })), h("stack-item", null, h("snk-filter-advanced-mode", { ref: (ref) => this._elAdvancedMode = ref, filterAssistent: this._filterAssistent, application: this._application, onEzExpressionChange: (ev) => this.handleExpressionChangeAdvancedMode(ev.detail) }))));
|
249
273
|
}
|
250
274
|
handleModeChange() {
|
251
275
|
var _a, _b;
|
@@ -284,12 +308,24 @@ export class SnkPersonalizedFilter {
|
|
284
308
|
}
|
285
309
|
}
|
286
310
|
}
|
311
|
+
buildTitle() {
|
312
|
+
if (this.isDefaultFilter && !this.filterId) {
|
313
|
+
return this.getMessage("snkPersonalizedFilter.info.titleCreateDefault");
|
314
|
+
}
|
315
|
+
if (this.isDefaultFilter && this.filterId) {
|
316
|
+
return this.getMessage("snkPersonalizedFilter.info.titleEditDefault");
|
317
|
+
}
|
318
|
+
if (this.filterId) {
|
319
|
+
return this.getMessage("snkPersonalizedFilter.info.titleEdit");
|
320
|
+
}
|
321
|
+
return this.getMessage("snkPersonalizedFilter.info.titleAdd");
|
322
|
+
}
|
287
323
|
render() {
|
288
324
|
var _a, _b, _c, _d;
|
289
325
|
if (!((_a = this._filterAssistent) === null || _a === void 0 ? void 0 : _a.assistent) && this._filterAssistentMode) {
|
290
326
|
return;
|
291
327
|
}
|
292
|
-
return (h(Host, null, h("div", { class: "snk-personalized-filter" }, h("div", null, h("snk-simple-bar", { label: this.
|
328
|
+
return (h(Host, null, h("div", { class: "snk-personalized-filter" }, h("div", null, h("snk-simple-bar", { label: this.buildTitle(), onExit: () => this.handleCancel() }, h("div", { class: "snk-personalized-filter__header-actions", slot: "rightSlot" }, h("ez-button", { size: "small", label: this.getMessage("snkPersonalizedFilter.info.labelCancel"), onClick: () => this.handleCancel() }), h("ez-button", { size: "small", ref: (el) => this._elButtonSave = el, enabled: false, class: "ez-button--primary", label: this.getMessage("snkPersonalizedFilter.info.labelSave"), onClick: this.handleSave.bind(this) })))), h("div", { class: "ez-box ez-margin-bottom--medium ez-box__main" }, h("div", { class: "ez-box__container" }, h("div", { class: "ez-flex ez-flex--column ez-size-width--full" }, h("div", { class: "ez-flex" }, h("ez-tooltip", { message: this.getMessage("snkPersonalizedFilter.info.textInputDisabled"), active: this.isDefaultFilter }, h("ez-text-input", { class: "ez-padding-right--medium", label: this.getMessage("snkPersonalizedFilter.info.labelNameFilter"), value: (_b = this._filterAssistent) === null || _b === void 0 ? void 0 : _b.name, onEzChange: (evt) => this.handleTitleChange(evt.detail), enabled: !this.isDefaultFilter })), this.renderButtonAddField(), h("ez-button", { ref: (el) => this._elButtonMode = el, class: "snk-personalized-filter__button-mode", label: this._filterAssistentMode ? this.getMessage("snkPersonalizedFilter.info.activeModeAdvanced") : this.getMessage("snkPersonalizedFilter.info.activeModeAssistent"), onClick: () => this.handleModeChange(), "data-tooltip": !(this._filterAssistentMode || ((_c = this._filterAssistent) === null || _c === void 0 ? void 0 : _c.assistent)) ? this.getMessage("snkPersonalizedFilter.info.tooltipDisabledAssistentMode") : undefined, "data-flow": "bottom", enabled: (!this._filterAssistent.name || Boolean(this._filterAssistentMode || ((_d = this._filterAssistent) === null || _d === void 0 ? void 0 : _d.assistent))) })), this.buildContainerPersonalizedFilter()))))));
|
293
329
|
}
|
294
330
|
static get is() { return "snk-personalized-filter"; }
|
295
331
|
static get encapsulation() { return "scoped"; }
|
@@ -392,6 +428,24 @@ export class SnkPersonalizedFilter {
|
|
392
428
|
},
|
393
429
|
"attribute": "resource-i-d",
|
394
430
|
"reflect": false
|
431
|
+
},
|
432
|
+
"isDefaultFilter": {
|
433
|
+
"type": "boolean",
|
434
|
+
"mutable": false,
|
435
|
+
"complexType": {
|
436
|
+
"original": "boolean",
|
437
|
+
"resolved": "boolean",
|
438
|
+
"references": {}
|
439
|
+
},
|
440
|
+
"required": false,
|
441
|
+
"optional": false,
|
442
|
+
"docs": {
|
443
|
+
"tags": [],
|
444
|
+
"text": "Define se o filtro em quest\u00E3o \u00E9 um filtro padr\u00E3o."
|
445
|
+
},
|
446
|
+
"attribute": "is-default-filter",
|
447
|
+
"reflect": false,
|
448
|
+
"defaultValue": "false"
|
395
449
|
}
|
396
450
|
};
|
397
451
|
}
|
@@ -20,6 +20,8 @@
|
|
20
20
|
|
21
21
|
/*@doc Define a cor de efeito de tracejado.*/
|
22
22
|
--snk-expression-group__background-color-dashed: var(--background--body, #fafcff);
|
23
|
+
|
24
|
+
--ez-text-input__margin-bottom: 0px;
|
23
25
|
}
|
24
26
|
|
25
27
|
.snk-expression-group__container-condition {
|
@@ -27,6 +29,7 @@
|
|
27
29
|
height: var(--snk-expression-group--container-condition--height);
|
28
30
|
border-radius: var(--snk-expression-group--container-condition--border-radius);
|
29
31
|
z-index: var(--more-visible--2x, 3);
|
32
|
+
padding: var(--space--nano, 2px);
|
30
33
|
}
|
31
34
|
|
32
35
|
.snk-expression-group__container-option {
|
@@ -17,6 +17,7 @@ export class SnkExpressionGroup {
|
|
17
17
|
this.messagesBuilder = undefined;
|
18
18
|
this.filterId = undefined;
|
19
19
|
this.entityURI = undefined;
|
20
|
+
this.isDefaultFilter = false;
|
20
21
|
}
|
21
22
|
/**
|
22
23
|
* Listener para capturar adição e remoção de grupos e items de expressão.
|
@@ -73,7 +74,7 @@ export class SnkExpressionGroup {
|
|
73
74
|
}
|
74
75
|
renderExpressionItems() {
|
75
76
|
var _a;
|
76
|
-
return (_a = this._group.items) === null || _a === void 0 ? void 0 : _a.map((item) => (h("snk-expression-item", { key: item.id, class: "ez-padding-top--small snk-expression-group__item", expression: item, canRemove: this._group.items.length > 1, onEzFilterItemChange: () => this.handleFilterItemChange(), onEzFilterItemRemove: (evt) => this.handleFilterItemRemove(evt, item.id), messagesBuilder: this.messagesBuilder, entityURI: this.entityURI })));
|
77
|
+
return (_a = this._group.items) === null || _a === void 0 ? void 0 : _a.map((item) => (h("snk-expression-item", { key: item.id, class: "ez-padding-top--small snk-expression-group__item", expression: item, canRemove: this._group.items.length > 1, onEzFilterItemChange: () => this.handleFilterItemChange(), onEzFilterItemRemove: (evt) => this.handleFilterItemRemove(evt, item.id), messagesBuilder: this.messagesBuilder, entityURI: this.entityURI, isDefaultFilter: this.isDefaultFilter })));
|
77
78
|
}
|
78
79
|
renderGroups() {
|
79
80
|
var _a;
|
@@ -335,6 +336,24 @@ export class SnkExpressionGroup {
|
|
335
336
|
},
|
336
337
|
"attribute": "entity-u-r-i",
|
337
338
|
"reflect": false
|
339
|
+
},
|
340
|
+
"isDefaultFilter": {
|
341
|
+
"type": "boolean",
|
342
|
+
"mutable": false,
|
343
|
+
"complexType": {
|
344
|
+
"original": "boolean",
|
345
|
+
"resolved": "boolean",
|
346
|
+
"references": {}
|
347
|
+
},
|
348
|
+
"required": false,
|
349
|
+
"optional": false,
|
350
|
+
"docs": {
|
351
|
+
"tags": [],
|
352
|
+
"text": "Define se o filtro em quest\u00E3o \u00E9 um filtro padr\u00E3o."
|
353
|
+
},
|
354
|
+
"attribute": "is-default-filter",
|
355
|
+
"reflect": false,
|
356
|
+
"defaultValue": "false"
|
338
357
|
}
|
339
358
|
};
|
340
359
|
}
|
@@ -19,6 +19,7 @@ export class SnkExpressionItem {
|
|
19
19
|
this.expression = undefined;
|
20
20
|
this.canRemove = true;
|
21
21
|
this.messagesBuilder = undefined;
|
22
|
+
this.isDefaultFilter = false;
|
22
23
|
this.entityURI = undefined;
|
23
24
|
}
|
24
25
|
expressionChanged(newValue, oldValue) {
|
@@ -240,14 +241,14 @@ export class SnkExpressionItem {
|
|
240
241
|
return field;
|
241
242
|
}
|
242
243
|
setCriteriaSearch({ mode, argument }, application) {
|
243
|
-
var _a, _b;
|
244
|
+
var _a, _b, _c;
|
244
245
|
if (application == undefined)
|
245
246
|
return;
|
246
247
|
const searchOptions = {
|
247
248
|
showInactives: false
|
248
249
|
};
|
249
250
|
const options = {
|
250
|
-
entity: (_b = (_a = this._fieldSelected) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.ENTITYNAME,
|
251
|
+
entity: (_c = (_b = (_a = this._fieldSelected) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.ENTITYNAME) !== null && _c !== void 0 ? _c : this._fieldSelected.entityName,
|
251
252
|
searchOptions,
|
252
253
|
entityDescription: this._fieldSelected.description
|
253
254
|
};
|
@@ -258,7 +259,7 @@ export class SnkExpressionItem {
|
|
258
259
|
return (h(Host, null, h("div", { class: "dashes" }), h("div", { class: "box" }, h("div", { class: "box__container" }, h("div", { class: "box__container--input-filter" }, h("ez-filter-input", Object.assign({ ref: ref => this._elFilterInput = ref, value: (_a = this._fieldSelected) === null || _a === void 0 ? void 0 : _a.path, label: this.getMessage("snkPersonalizedFilter.info.labelSearchField"), canShowError: false, onEzChange: (evt) => this.handleChangeFilterInput(evt), onFocus: () => this.handleFocus() }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `expressionFilterInput_${this.expression.fieldName || this.DEFAULT_FIELD_NAME}` })), h("snk-filter-field-search", { ref: ref => this._elFilterFieldSearch = ref, searchable: false, onEzSelectFilterItem: (ev) => this.handleSelectItem(ev.detail), fieldsDataSource: this._dataSourceFetcher })), h("div", { class: "box__container--input-operator" }, h("ez-combo-box", Object.assign({ label: this.getMessage("snkPersonalizedFilter.info.labelOperator"), value: this.expression.operand, canShowError: false, options: this.buildOptionsOperator(), onEzChange: (evt) => { var _a; return this.handleChangeOperator((_a = evt.detail) === null || _a === void 0 ? void 0 : _a.value); }, suppressEmptyOption: true }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `comboBoxOperand_${this.expression.fieldName || this.DEFAULT_FIELD_NAME}` }))), h("div", { class: "box__container--input-value" }, !this._fieldSelected ?
|
259
260
|
h("ez-number-input", { label: "Valor", canShowError: false, enabled: (!this._showValueVariable && !this._optionNotNull) }) :
|
260
261
|
this.buildFieldByType()), h("div", { class: "box__container--input-value-variable" }, !this._optionNotNull &&
|
261
|
-
h("ez-check", { ref: ref => this._elValueVariable = ref, value: this.expression.paramVariable, label: this.getMessage("snkPersonalizedFilter.info.labelValueVarible"), mode: CheckMode.SWITCH, onEzChange: (evt) => this.handleChangeValueVariable(evt.detail) }), (this._showValueVariable && !this._optionNotNull) &&
|
262
|
+
h("ez-tooltip", { message: this.getMessage("snkPersonalizedFilter.info.checkVariableDisabled"), active: this.isDefaultFilter }, h("ez-check", { ref: ref => this._elValueVariable = ref, value: this.expression.paramVariable, label: this.getMessage("snkPersonalizedFilter.info.labelValueVarible"), mode: CheckMode.SWITCH, onEzChange: (evt) => this.handleChangeValueVariable(evt.detail), enabled: !this.isDefaultFilter })), (this._showValueVariable && !this._optionNotNull) &&
|
262
263
|
h("ez-icon", Object.assign({ class: "box__container--input-value-variable--icon", size: "large", iconName: "settings-inverted" }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: 'iconConfig' }, { title: this.getMessage("snkPersonalizedFilter.info.titleTooltip"), onClick: () => this.openSnkFilterParamConfig() })), h("snk-filter-param-config", { ref: (el) => this._elFilterParamConfigRef = el, messagesBuilder: this.messagesBuilder })), h("div", { class: "box__container--button-delete" }, h("div", { class: "box__container--button-delete--icon" }, h("ez-button", { mode: "icon", iconName: "delete", enabled: this.canRemove, label: this.getMessage("snkPersonalizedFilter.info.labelDeleteItem"), onClick: (evt) => this.confirmRemove(evt) })))))));
|
263
264
|
}
|
264
265
|
static get is() { return "snk-expression-item"; }
|
@@ -334,6 +335,24 @@ export class SnkExpressionItem {
|
|
334
335
|
"text": "Respons\u00E1vel por flexibilizar e padronizar o uso de mensagens nos blocos de constru\u00E7\u00E3o."
|
335
336
|
}
|
336
337
|
},
|
338
|
+
"isDefaultFilter": {
|
339
|
+
"type": "boolean",
|
340
|
+
"mutable": false,
|
341
|
+
"complexType": {
|
342
|
+
"original": "boolean",
|
343
|
+
"resolved": "boolean",
|
344
|
+
"references": {}
|
345
|
+
},
|
346
|
+
"required": false,
|
347
|
+
"optional": false,
|
348
|
+
"docs": {
|
349
|
+
"tags": [],
|
350
|
+
"text": "Define se o filtro em quest\u00E3o \u00E9 um filtro padr\u00E3o."
|
351
|
+
},
|
352
|
+
"attribute": "is-default-filter",
|
353
|
+
"reflect": false,
|
354
|
+
"defaultValue": "false"
|
355
|
+
},
|
337
356
|
"entityURI": {
|
338
357
|
"type": "string",
|
339
358
|
"mutable": true,
|
@@ -7,6 +7,7 @@ export class SnkFilterAssistentMode {
|
|
7
7
|
this.filterId = undefined;
|
8
8
|
this.entityUri = undefined;
|
9
9
|
this.application = undefined;
|
10
|
+
this.isDefaultFilter = false;
|
10
11
|
}
|
11
12
|
getMessage(key, params) {
|
12
13
|
return this.application.messagesBuilder.getMessage(key, params);
|
@@ -20,7 +21,7 @@ export class SnkFilterAssistentMode {
|
|
20
21
|
}
|
21
22
|
render() {
|
22
23
|
var _a, _b;
|
23
|
-
return (h(Host, null, h("div", { class: "ez-padding-top--small snk-personalized-filter__group" }, h("snk-expression-group", { ref: (el) => this._mainExpressionGroup = el, group: (_a = this.filterAssistent) === null || _a === void 0 ? void 0 : _a.assistent, messagesBuilder: this.messagesBuilder, onEzFilterGroupChange: this.handleFilterGroupChange.bind(this), filterId: this.filterId, entityURI: this.entityUri })), h("div", { class: "ez-margin-top--auto" }, h("div", { class: "snk-personalized-filter__expression-input--line" }), h("ez-collapsible-box", { label: this.getMessage("snkPersonalizedFilter.info.titleCollapsible"), headerSize: "medium", value: true }, h("div", { class: "ez-box" }, h("div", { class: "ez-box__container--external" }, h("div", { class: "ez-box__container--internal" }, h("span", { class: "ez-box__container--title" }, this.getMessage("snkPersonalizedFilter.info.labelExpression")), h("span", { class: "ez-box__container--expression" }, (_b = this.filterAssistent) === null || _b === void 0 ? void 0 : _b.expression))))))));
|
24
|
+
return (h(Host, null, h("div", { class: "ez-padding-top--small snk-personalized-filter__group" }, h("snk-expression-group", { ref: (el) => this._mainExpressionGroup = el, group: (_a = this.filterAssistent) === null || _a === void 0 ? void 0 : _a.assistent, messagesBuilder: this.messagesBuilder, onEzFilterGroupChange: this.handleFilterGroupChange.bind(this), filterId: this.filterId, entityURI: this.entityUri, isDefaultFilter: this.isDefaultFilter })), h("div", { class: "ez-margin-top--auto" }, h("div", { class: "snk-personalized-filter__expression-input--line" }), h("ez-collapsible-box", { label: this.getMessage("snkPersonalizedFilter.info.titleCollapsible"), headerSize: "medium", value: true }, h("div", { class: "ez-box" }, h("div", { class: "ez-box__container--external" }, h("div", { class: "ez-box__container--internal" }, h("span", { class: "ez-box__container--title" }, this.getMessage("snkPersonalizedFilter.info.labelExpression")), h("span", { class: "ez-box__container--expression" }, (_b = this.filterAssistent) === null || _b === void 0 ? void 0 : _b.expression))))))));
|
24
25
|
}
|
25
26
|
static get is() { return "snk-filter-assistent-mode"; }
|
26
27
|
static get encapsulation() { return "scoped"; }
|
@@ -129,6 +130,24 @@ export class SnkFilterAssistentMode {
|
|
129
130
|
"tags": [],
|
130
131
|
"text": "Propriedade que mant\u00E9m informa\u00E7\u00F5es relacionadas ao SnkApplication."
|
131
132
|
}
|
133
|
+
},
|
134
|
+
"isDefaultFilter": {
|
135
|
+
"type": "boolean",
|
136
|
+
"mutable": false,
|
137
|
+
"complexType": {
|
138
|
+
"original": "boolean",
|
139
|
+
"resolved": "boolean",
|
140
|
+
"references": {}
|
141
|
+
},
|
142
|
+
"required": false,
|
143
|
+
"optional": false,
|
144
|
+
"docs": {
|
145
|
+
"tags": [],
|
146
|
+
"text": "Define se o filtro em quest\u00E3o \u00E9 um filtro padr\u00E3o."
|
147
|
+
},
|
148
|
+
"attribute": "is-default-filter",
|
149
|
+
"reflect": false,
|
150
|
+
"defaultValue": "false"
|
132
151
|
}
|
133
152
|
};
|
134
153
|
}
|
@@ -10,15 +10,15 @@ export var CONFIG_SOURCE;
|
|
10
10
|
})(CONFIG_SOURCE || (CONFIG_SOURCE = {}));
|
11
11
|
export class ConfigStorage {
|
12
12
|
static addFilterBarLegacyConfig(configName, legacyConfigName) {
|
13
|
-
this.
|
13
|
+
this.validateResourceId(legacyConfigName);
|
14
14
|
this.filterBarLegacyConfig.set(configName, legacyConfigName);
|
15
15
|
}
|
16
16
|
static addFormLegacyConfig(configName, legacyConfigName) {
|
17
|
-
this.
|
17
|
+
this.validateResourceId(legacyConfigName);
|
18
18
|
this.formLegacyConfig.set(configName, legacyConfigName);
|
19
19
|
}
|
20
20
|
static addGridLegacyConfig(configName, legacyConfigName) {
|
21
|
-
this.
|
21
|
+
this.validateResourceId(legacyConfigName);
|
22
22
|
this.gridLegacyConfig.set(configName, legacyConfigName);
|
23
23
|
}
|
24
24
|
static preload(resourceID, configName, legacyConfigs) {
|
@@ -75,6 +75,10 @@ export class ConfigStorage {
|
|
75
75
|
await this.deleteGridConfigCache(name, resourceID);
|
76
76
|
return this.gridConfigFetcher.saveConfig(config, name, resourceID);
|
77
77
|
}
|
78
|
+
static async loadDefaultFilter(filterId, resourceID, configName) {
|
79
|
+
const legacyConfigName = this.filterBarLegacyConfig.get(configName);
|
80
|
+
return this.personalizedFilterFetcher.loadDefaultFilter(resourceID, filterId, configName, legacyConfigName);
|
81
|
+
}
|
78
82
|
static async loadPersonalizedFilter(filterId, resourceID, configName) {
|
79
83
|
const legacyConfigName = this.filterBarLegacyConfig.get(configName);
|
80
84
|
return this.personalizedFilterFetcher.loadPersonalizedFilter(resourceID, filterId, configName, legacyConfigName);
|
@@ -85,6 +89,13 @@ export class ConfigStorage {
|
|
85
89
|
await this.deleteFilterBarConfigCache(configName, resourceID);
|
86
90
|
return this.personalizedFilterFetcher.savePersonalizedFilter(personalizedFilter, resourceID, configName);
|
87
91
|
}
|
92
|
+
static async saveDefaultFilter(personalizedFilter, resourceID, configName) {
|
93
|
+
await this.deleteFilterBarConfigCache(configName, resourceID);
|
94
|
+
return this.personalizedFilterFetcher.saveDefaultFilter(personalizedFilter, resourceID, configName);
|
95
|
+
}
|
96
|
+
static async removeDefaultFilter(personalizedFilter, resourceID, configName) {
|
97
|
+
return this.personalizedFilterFetcher.removeDefaultFilter(personalizedFilter, resourceID, configName);
|
98
|
+
}
|
88
99
|
static async removePersonalizedFilter(personalizedFilter, resourceID, configName) {
|
89
100
|
return this.personalizedFilterFetcher.removePersonalizedFilter(personalizedFilter, resourceID, configName);
|
90
101
|
}
|
@@ -100,10 +111,8 @@ export class ConfigStorage {
|
|
100
111
|
static async deleteFilterBarConfigCache(name, resourceID) {
|
101
112
|
await this.deleteConfigCache(name, resourceID, CONFIG_SOURCE.filterBar);
|
102
113
|
}
|
103
|
-
static
|
104
|
-
if (!
|
105
|
-
throw Error(this.CONFIG_NAME_ERROR_MESSAGE);
|
106
|
-
if (!legacyConfigName)
|
114
|
+
static validateResourceId(resourceId) {
|
115
|
+
if (!resourceId)
|
107
116
|
throw Error(this.LEGACY_CONFIG_NAME_ERROR_MESSAGE);
|
108
117
|
}
|
109
118
|
static handleLegacyConfig(configName, configSource, urlParams) {
|
@@ -143,7 +152,6 @@ export class ConfigStorage {
|
|
143
152
|
return `req_${source}_${name}_${resourceID}`;
|
144
153
|
}
|
145
154
|
}
|
146
|
-
ConfigStorage.CONFIG_NAME_ERROR_MESSAGE = "ConfigName precisa ser informado.";
|
147
155
|
ConfigStorage.LEGACY_CONFIG_NAME_ERROR_MESSAGE = "LegacyConfigName precisa ser informado.";
|
148
156
|
ConfigStorage.filterBarLegacyConfig = new Map();
|
149
157
|
ConfigStorage.formLegacyConfig = new Map();
|
@@ -2,16 +2,30 @@ import { gql } from "graphql-request";
|
|
2
2
|
import { DataFetcher } from "../DataFetcher";
|
3
3
|
export default class PersonalizedFilterFetcher {
|
4
4
|
constructor() {
|
5
|
+
this.DEFAULT_RESOURCE = '_default';
|
5
6
|
this.templateByQuery = new Map();
|
6
7
|
this.buildTemplates();
|
7
8
|
}
|
8
|
-
resolveURI(resourceID, configName) {
|
9
|
+
resolveURI(resourceID, configName, isDefault) {
|
9
10
|
let uri = "filter-assistent-config://" + resourceID;
|
10
11
|
if (configName) {
|
11
12
|
uri += "." + configName;
|
12
13
|
}
|
14
|
+
if (isDefault) {
|
15
|
+
uri += this.DEFAULT_RESOURCE;
|
16
|
+
}
|
13
17
|
return uri;
|
14
18
|
}
|
19
|
+
resolveLegacyConfigName(legacyConfigName, isDefault) {
|
20
|
+
if (!legacyConfigName) {
|
21
|
+
return '';
|
22
|
+
}
|
23
|
+
let legacyConfig = `?legacyResourceID=${legacyConfigName}`;
|
24
|
+
if (isDefault) {
|
25
|
+
legacyConfig += this.DEFAULT_RESOURCE;
|
26
|
+
}
|
27
|
+
return legacyConfig;
|
28
|
+
}
|
15
29
|
buildTemplates() {
|
16
30
|
this.templateByQuery.set("fetchFilterFields", gql `
|
17
31
|
query($name: String!) {
|
@@ -74,11 +88,14 @@ export default class PersonalizedFilterFetcher {
|
|
74
88
|
}
|
75
89
|
}`);
|
76
90
|
}
|
77
|
-
async
|
91
|
+
async loadDefaultFilter(resourceID, filterID, configName, legacyConfigName) {
|
92
|
+
return this.loadPersonalizedFilter(resourceID, filterID, configName, legacyConfigName, true);
|
93
|
+
}
|
94
|
+
async loadPersonalizedFilter(resourceID, filterID, configName, legacyConfigName, isDefault) {
|
78
95
|
return new Promise((resolve, reject) => {
|
79
96
|
DataFetcher.get()
|
80
97
|
.callGraphQL({
|
81
|
-
values: { name: this.resolveURI(resourceID, configName) + "/" + filterID + this.resolveLegacyConfigName(legacyConfigName) },
|
98
|
+
values: { name: this.resolveURI(resourceID, configName, isDefault) + "/" + filterID + this.resolveLegacyConfigName(legacyConfigName, isDefault) },
|
82
99
|
query: this.templateByQuery.get("fetchFilterAssistent"),
|
83
100
|
})
|
84
101
|
.then((resp) => {
|
@@ -90,10 +107,10 @@ export default class PersonalizedFilterFetcher {
|
|
90
107
|
});
|
91
108
|
});
|
92
109
|
}
|
93
|
-
|
94
|
-
return
|
110
|
+
async saveDefaultFilter(personalizedFilter, resourceID, configName) {
|
111
|
+
return this.savePersonalizedFilter(personalizedFilter, resourceID, configName, true);
|
95
112
|
}
|
96
|
-
async savePersonalizedFilter(personalizedFilter, resourceID, configName) {
|
113
|
+
async savePersonalizedFilter(personalizedFilter, resourceID, configName, isDefault) {
|
97
114
|
if (!personalizedFilter || Object.keys(personalizedFilter).length == 0) {
|
98
115
|
return Promise.reject(new Error("personalizedFilter não pode ser vazio"));
|
99
116
|
}
|
@@ -102,7 +119,7 @@ export default class PersonalizedFilterFetcher {
|
|
102
119
|
return new Promise((resolve, reject) => {
|
103
120
|
DataFetcher.get()
|
104
121
|
.callGraphQL({
|
105
|
-
values: { name: this.resolveURI(resourceID, configName), filterAssistent: personalizedFilterParsed },
|
122
|
+
values: { name: this.resolveURI(resourceID, configName, isDefault), filterAssistent: personalizedFilterParsed },
|
106
123
|
query: this.templateByQuery.get("savePersonalizedFilter"),
|
107
124
|
})
|
108
125
|
.then((resp) => {
|
@@ -113,11 +130,14 @@ export default class PersonalizedFilterFetcher {
|
|
113
130
|
});
|
114
131
|
});
|
115
132
|
}
|
116
|
-
|
133
|
+
removeDefaultFilter(personalizedFilter, resourceID, configName) {
|
134
|
+
return this.removePersonalizedFilter(personalizedFilter, resourceID, configName, true);
|
135
|
+
}
|
136
|
+
async removePersonalizedFilter(personalizedFilter, resourceID, configName, isDefault) {
|
117
137
|
return new Promise((resolve, reject) => {
|
118
138
|
DataFetcher.get()
|
119
139
|
.callGraphQL({
|
120
|
-
values: { name: this.resolveURI(resourceID, configName), filterId: personalizedFilter.id },
|
140
|
+
values: { name: this.resolveURI(resourceID, configName, isDefault), filterId: personalizedFilter.id },
|
121
141
|
query: this.templateByQuery.get("deletePersonalizedFilter"),
|
122
142
|
})
|
123
143
|
.then((resp) => {
|
@@ -44,6 +44,12 @@ const snkFilterBarMessages = {
|
|
44
44
|
"cancelButtonLabel": "Limpar tudo",
|
45
45
|
"customFilters": "Filtros personalizados",
|
46
46
|
"quickFilters": "Filtros rápidos",
|
47
|
+
"defaultFilter": {
|
48
|
+
"title": "Filtro padrão",
|
49
|
+
"edit": "Editar filtro",
|
50
|
+
"remove": "Excluir filtro",
|
51
|
+
"create": "Criar filtro padrão",
|
52
|
+
},
|
47
53
|
"validations": {
|
48
54
|
"notFullFilled": {
|
49
55
|
"title": "Filtro parcialmente preenchido",
|
@@ -30,23 +30,37 @@ export const snkFormConfigMessages = {
|
|
30
30
|
mainArea: "Área principal",
|
31
31
|
tabGeneral: "Geral"
|
32
32
|
},
|
33
|
+
configs: {
|
34
|
+
buttonLabel: "Configurações",
|
35
|
+
selectedConfig: "configuração selecionada"
|
36
|
+
},
|
33
37
|
confirm: {
|
34
38
|
title: "Aviso",
|
35
39
|
deleteTab: "Você realmente deseja excluir a aba",
|
40
|
+
deleteGuide: "Deseja realmente excluir a guia <b>{0}</b>?",
|
36
41
|
cancel: "As alterações realizadas serão descartadas.<br/><br/><b>Gostaria de continuar?</b>",
|
37
42
|
exit: "Ao sair as alterações serão descartadas.<br/><br/><b>Você realmente gostaria de sair?</b>",
|
38
|
-
apply: "A <b>{0}</b> irá substituir a
|
43
|
+
apply: "A <b>{0}</b> irá substituir a configuração atual!<br/><br/><b>Deseja continuar?</b>",
|
39
44
|
group: "Não é possível salvar as configurações com um grupo vazio!",
|
40
45
|
labelCancel: "Cancelar",
|
41
46
|
labelDelete: "Excluir"
|
42
47
|
},
|
48
|
+
noGuideSelected: {
|
49
|
+
title: "Atenção",
|
50
|
+
message: "Selecione uma guia para iniciar a configuração!"
|
51
|
+
},
|
43
52
|
alert: {
|
44
53
|
titleGroupExists: "Já existe um grupo com título",
|
54
|
+
titleGroupEditing: "Há um <b>grupo<b/> em edição. <br/> Finalize a edição para salvar as configurações.",
|
55
|
+
titleGuideExists: "Já existe uma guia com título",
|
56
|
+
titleGuideEditing: "Há uma <b>guia<b/> em edição. <br/> Finalize a edição para salvar as configurações.",
|
57
|
+
titleGuideReservedName: "Este título é reservado para configurações internas do sistema e não pode ser utilizado.",
|
45
58
|
infoValidTitle: "Por favor, digite um título válido.",
|
46
59
|
inTab: "na aba"
|
47
60
|
},
|
48
61
|
info: {
|
49
|
-
successfullyConfigSaved: "As configurações foram salvas com sucesso!"
|
62
|
+
successfullyConfigSaved: "As configurações foram salvas com sucesso!",
|
63
|
+
successfullyGuideDeleted: 'A guia "{0}" foi excluída. Salve para confirmar a alteração.'
|
50
64
|
}
|
51
65
|
};
|
52
66
|
export const snkFieldConfigMessages = {
|
@@ -2,6 +2,8 @@ export const snkPersonalizedFilterMessages = {
|
|
2
2
|
info: {
|
3
3
|
titleEdit: "Editar filtro personalizado",
|
4
4
|
titleAdd: "Criar filtro personalizado",
|
5
|
+
titleCreateDefault: "Aplicar filtro padrão",
|
6
|
+
titleEditDefault: "Editar filtro padrão",
|
5
7
|
titleCollapsible: "Expressão a ser aplicada (gerada pelo assistente)",
|
6
8
|
labelSearchField: "Buscar campo",
|
7
9
|
labelOperator: "Operador",
|
@@ -24,7 +26,10 @@ export const snkPersonalizedFilterMessages = {
|
|
24
26
|
applyExpression: "Expressão a ser aplicada:",
|
25
27
|
tooltipDisabledAssistentMode: "Expressão não suportada pelo assistente.",
|
26
28
|
activeModeAdvanced: "Ativar modo avançado",
|
27
|
-
activeModeAssistent: "Ativar modo assistente"
|
29
|
+
activeModeAssistent: "Ativar modo assistente",
|
30
|
+
textInputDisabled: "Campo desabilitado para filtros padrões",
|
31
|
+
checkVariableDisabled: "Filtro padrão não pode ser variável.",
|
32
|
+
deleteDefaultFilterConfirm: "Deseja excluir o <b>filtro padrão</b>?",
|
28
33
|
},
|
29
34
|
confirmExpression: {
|
30
35
|
title: "Aviso",
|
@@ -57,7 +57,13 @@ export const TYPE_ACTIONS = {
|
|
57
57
|
delete: "DELETE"
|
58
58
|
};
|
59
59
|
export const TAB_NAMES = {
|
60
|
-
main: "__main"
|
60
|
+
main: "__main",
|
61
|
+
general: "Geral",
|
62
|
+
newGuide: "Nova guia",
|
63
|
+
};
|
64
|
+
export const GROUP_NAMES = {
|
65
|
+
noGroup: "__no_group",
|
66
|
+
newGroup: "Novo Grupo",
|
61
67
|
};
|
62
68
|
export const TAGS_BY_TYPE = {
|
63
69
|
LONGTEXT: "ez-text-area",
|