@sankhyalabs/sankhyablocks 2.4.8 → 2.4.10

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.
Files changed (95) hide show
  1. package/dist/cjs/{SnkMessageBuilder-61f00e7f.js → SnkMessageBuilder-370e23ae.js} +24 -1
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/sankhyablocks.cjs.js +1 -1
  4. package/dist/cjs/snk-application.cjs.entry.js +1 -1
  5. package/dist/cjs/snk-configurator_3.cjs.entry.js +44 -6
  6. package/dist/cjs/snk-crud.cjs.entry.js +6 -2
  7. package/dist/cjs/snk-data-unit.cjs.entry.js +1 -1
  8. package/dist/cjs/{snk-filter-bar_7.cjs.entry.js → snk-exporter-email-sender_8.cjs.entry.js} +133 -15
  9. package/dist/cjs/snk-filter-detail.cjs.entry.js +8 -1
  10. package/dist/cjs/snk-form.cjs.entry.js +1 -1
  11. package/dist/cjs/{taskbar-elements-b995b84d.js → taskbar-elements-3807c809.js} +3 -0
  12. package/dist/cjs/{taskbar-processor-6bd0d35c.js → taskbar-processor-6f3d2a75.js} +9 -7
  13. package/dist/collection/collection-manifest.json +1 -0
  14. package/dist/collection/components/snk-crud/snk-crud.js +23 -1
  15. package/dist/collection/components/snk-data-exporter/data/attachment.js +1 -0
  16. package/dist/collection/components/snk-data-exporter/data/email.js +1 -0
  17. package/dist/collection/components/snk-data-exporter/data/export-config.js +1 -0
  18. package/dist/collection/components/snk-data-exporter/data/export-result.js +1 -0
  19. package/dist/collection/components/snk-data-exporter/data/report.js +1 -0
  20. package/dist/collection/components/snk-data-exporter/exporter-email-sender/email-info-step.js +6 -0
  21. package/dist/collection/components/snk-data-exporter/exporter-email-sender/options-step.js +21 -0
  22. package/dist/collection/components/snk-data-exporter/exporter-email-sender/snk-exporter-email-sender.js +146 -0
  23. package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-detail.js +8 -1
  24. package/dist/collection/components/snk-filter-bar/filter-list/snk-filter-list.js +8 -6
  25. package/dist/collection/components/snk-grid/snk-grid.js +71 -6
  26. package/dist/collection/components/snk-grid/subcomponents/snk-grid-config/snk-grid-config.js +25 -8
  27. package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +3 -0
  28. package/dist/collection/components/snk-taskbar/processor/taskbar-processor.js +9 -7
  29. package/dist/collection/components/snk-taskbar/snk-taskbar.js +2 -1
  30. package/dist/collection/lib/message/SnkMessageBuilder.js +3 -1
  31. package/dist/collection/lib/message/resources/snk-exporter.msg.js +21 -0
  32. package/dist/collection/lib/message/resources/snk-taskbar.msg.js +1 -0
  33. package/dist/components/SnkMessageBuilder.js +24 -1
  34. package/dist/components/index.d.ts +1 -0
  35. package/dist/components/index.js +1 -0
  36. package/dist/components/snk-crud.js +16 -5
  37. package/dist/components/snk-exporter-email-sender.d.ts +11 -0
  38. package/dist/components/snk-exporter-email-sender.js +6 -0
  39. package/dist/components/snk-exporter-email-sender2.js +141 -0
  40. package/dist/components/snk-filter-detail2.js +8 -1
  41. package/dist/components/snk-filter-list2.js +8 -6
  42. package/dist/components/snk-grid-config2.js +6 -8
  43. package/dist/components/snk-grid2.js +53 -9
  44. package/dist/components/snk-taskbar2.js +5 -1
  45. package/dist/components/taskbar-processor.js +9 -7
  46. package/dist/esm/{SnkMessageBuilder-f5ef87df.js → SnkMessageBuilder-7d583c9a.js} +24 -1
  47. package/dist/esm/loader.js +1 -1
  48. package/dist/esm/sankhyablocks.js +1 -1
  49. package/dist/esm/snk-application.entry.js +1 -1
  50. package/dist/esm/snk-configurator_3.entry.js +44 -6
  51. package/dist/esm/snk-crud.entry.js +6 -2
  52. package/dist/esm/snk-data-unit.entry.js +1 -1
  53. package/dist/esm/{snk-filter-bar_7.entry.js → snk-exporter-email-sender_8.entry.js} +135 -18
  54. package/dist/esm/snk-filter-detail.entry.js +8 -1
  55. package/dist/esm/snk-form.entry.js +1 -1
  56. package/dist/esm/{taskbar-elements-a0a8c3ac.js → taskbar-elements-b2bbe275.js} +3 -0
  57. package/dist/esm/{taskbar-processor-aa6772c9.js → taskbar-processor-c2a99aba.js} +9 -7
  58. package/dist/sankhyablocks/{p-a72a0a5d.entry.js → p-1b7f87cf.entry.js} +1 -1
  59. package/dist/sankhyablocks/p-2445b586.entry.js +1 -0
  60. package/dist/sankhyablocks/{p-cd486089.entry.js → p-2664ae24.entry.js} +1 -1
  61. package/dist/sankhyablocks/p-5a3e0eb6.js +1 -0
  62. package/dist/sankhyablocks/{p-eb94df0b.entry.js → p-70e52fee.entry.js} +1 -1
  63. package/dist/sankhyablocks/p-c118ef2a.entry.js +1 -0
  64. package/dist/sankhyablocks/p-dbaad88c.js +1 -0
  65. package/dist/sankhyablocks/p-df53643b.entry.js +1 -0
  66. package/dist/sankhyablocks/p-e7f772ed.js +1 -0
  67. package/dist/sankhyablocks/{p-71997e4c.entry.js → p-fb96840c.entry.js} +1 -1
  68. package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
  69. package/dist/types/components/snk-crud/snk-crud.d.ts +4 -0
  70. package/dist/types/components/snk-data-exporter/data/attachment.d.ts +4 -0
  71. package/dist/types/components/snk-data-exporter/data/email.d.ts +7 -0
  72. package/dist/types/components/snk-data-exporter/data/export-config.d.ts +9 -0
  73. package/dist/types/components/snk-data-exporter/data/export-result.d.ts +8 -0
  74. package/dist/types/components/snk-data-exporter/data/report.d.ts +4 -0
  75. package/dist/types/components/snk-data-exporter/exporter-email-sender/email-info-step.d.ts +9 -0
  76. package/dist/types/components/snk-data-exporter/exporter-email-sender/options-step.d.ts +9 -0
  77. package/dist/types/components/snk-filter-bar/filter-item/snk-filter-detail.d.ts +1 -0
  78. package/dist/types/components/snk-filter-bar/filter-list/snk-filter-list.d.ts +1 -0
  79. package/dist/types/components/snk-grid/subcomponents/snk-grid-config/snk-grid-config.d.ts +6 -3
  80. package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +2 -1
  81. package/dist/types/components/snk-taskbar/processor/taskbar-processor.d.ts +1 -1
  82. package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +1 -0
  83. package/dist/types/components.d.ts +43 -0
  84. package/dist/types/lib/message/resources/snk-exporter.msg.d.ts +2 -0
  85. package/package.json +1 -1
  86. package/react/components.d.ts +1 -0
  87. package/react/components.js +1 -0
  88. package/react/components.js.map +1 -1
  89. package/dist/sankhyablocks/p-03f0a380.entry.js +0 -1
  90. package/dist/sankhyablocks/p-03f9c407.js +0 -1
  91. package/dist/sankhyablocks/p-4cbc4ae3.js +0 -1
  92. package/dist/sankhyablocks/p-877bd6cf.js +0 -1
  93. package/dist/sankhyablocks/p-e6e0efe7.entry.js +0 -1
  94. package/dist/sankhyablocks/p-f1de5d1f.entry.js +0 -1
  95. package/dist/types/components/snk-grid/snk-grid.d.ts +0 -70
@@ -10,7 +10,7 @@ const patchEsm = () => {
10
10
  const defineCustomElements = (win, options) => {
11
11
  if (typeof window === 'undefined') return Promise.resolve();
12
12
  return patchEsm().then(() => {
13
- return bootstrapLazy([["teste-pesquisa",[[1,"teste-pesquisa"]]],["snk-data-unit",[[2,"snk-data-unit",{"dataState":[1040],"dataUnitName":[1,"data-unit-name"],"entityName":[1,"entity-name"],"pageSize":[2,"page-size"],"dataUnit":[1040],"beforeSave":[16],"afterSave":[16],"getDataUnit":[64]}]]],["snk-filter-binary-select",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-multi-select",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-period",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-pesquisa",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-tab-config",[[6,"snk-tab-config",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1],"_processedTabs":[32],"_activeEditText":[32],"_activeEditTextIndex":[32],"_actionsHide":[32],"_actionsShow":[32]}]]],["snk-filter-detail",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-configurator_3",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}],[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[1,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"configName":[513,"config-name"],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-filter-bar_7",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]],[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"columns":[1040],"config":[1040],"saveConfig":[64]}],[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]],[4,"snk-filter-list",{"label":[1],"iconName":[1,"icon-name"],"items":[16],"getMessage":[16],"emptyText":[1,"empty-text"],"findFilterText":[1,"find-filter-text"],"buttonClass":[1,"button-class"],"_filterArgument":[32],"_showAll":[32],"hideDetail":[64]},[[2,"keydown","keyDownHandler"]]],[0,"snk-filter-modal",{"getMessage":[16],"items":[1040],"modalTitle":[1,"modal-title"],"modalSubTitle":[1,"modal-sub-title"],"cancelButtonLabel":[1,"cancel-button-label"],"okButtonLabel":[1,"ok-button-label"],"infoText":[1,"info-text"],"useSearch":[4,"use-search"],"processModalAction":[16],"_filterArgument":[32]}],[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}]]],["snk-form",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-crud",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"_dataUnit":[32],"_dataState":[32],"_viewMode":[32],"goToView":[64]}]]],["snk-application",[[2,"snk-application",{"messagesBuilder":[1040],"configName":[1,"config-name"],"isUserSup":[64],"hasAccess":[64],"getAllAccess":[64],"getStringParam":[64],"getIntParam":[64],"getFloatParam":[64],"getBooleanParam":[64],"getDateParam":[64],"showPopUp":[64],"showModal":[64],"closeModal":[64],"closePopUp":[64],"temOpcional":[64],"getConfig":[64],"saveConfig":[64],"getAttributeFromHTMLWrapper":[64],"openApp":[64],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadFormConfig":[64],"loadGridConfig":[64],"fetchUserAvailableConfigs":[64],"fetchLegacyConfig":[64],"fetchDefaultConfig":[64],"loadTotals":[64],"saveGridConfig":[64],"getFilterBarConfig":[64],"saveFilterBarConfig":[64],"saveFormConfig":[64],"getDefaultValues":[64],"getDefaultValue":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
13
+ return bootstrapLazy([["teste-pesquisa",[[1,"teste-pesquisa"]]],["snk-data-unit",[[2,"snk-data-unit",{"dataState":[1040],"dataUnitName":[1,"data-unit-name"],"entityName":[1,"entity-name"],"pageSize":[2,"page-size"],"dataUnit":[1040],"beforeSave":[16],"afterSave":[16],"getDataUnit":[64]}]]],["snk-filter-binary-select",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-multi-select",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-period",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-pesquisa",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-tab-config",[[6,"snk-tab-config",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1],"_processedTabs":[32],"_activeEditText":[32],"_activeEditTextIndex":[32],"_actionsHide":[32],"_actionsShow":[32]}]]],["snk-filter-detail",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-configurator_3",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"enableDataExporter":[4,"enable-data-exporter"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]},[[0,"actionClick","actionClickHandler"]]],[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[1,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"configName":[513,"config-name"],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-exporter-email-sender_8",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]],[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"saveConfig":[64]}],[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64]}],[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]],[4,"snk-filter-list",{"label":[1],"iconName":[1,"icon-name"],"items":[16],"getMessage":[16],"emptyText":[1,"empty-text"],"findFilterText":[1,"find-filter-text"],"buttonClass":[1,"button-class"],"_filterArgument":[32],"_showAll":[32],"hideDetail":[64]},[[2,"keydown","keyDownHandler"]]],[0,"snk-filter-modal",{"getMessage":[16],"items":[1040],"modalTitle":[1,"modal-title"],"modalSubTitle":[1,"modal-sub-title"],"cancelButtonLabel":[1,"cancel-button-label"],"okButtonLabel":[1,"ok-button-label"],"infoText":[1,"info-text"],"useSearch":[4,"use-search"],"processModalAction":[16],"_filterArgument":[32]}],[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}]]],["snk-form",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-crud",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"enableDataExporter":[4,"enable-data-exporter"],"_dataUnit":[32],"_dataState":[32],"_viewMode":[32],"goToView":[64]}]]],["snk-application",[[2,"snk-application",{"messagesBuilder":[1040],"configName":[1,"config-name"],"isUserSup":[64],"hasAccess":[64],"getAllAccess":[64],"getStringParam":[64],"getIntParam":[64],"getFloatParam":[64],"getBooleanParam":[64],"getDateParam":[64],"showPopUp":[64],"showModal":[64],"closeModal":[64],"closePopUp":[64],"temOpcional":[64],"getConfig":[64],"saveConfig":[64],"getAttributeFromHTMLWrapper":[64],"openApp":[64],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadFormConfig":[64],"loadGridConfig":[64],"fetchUserAvailableConfigs":[64],"fetchLegacyConfig":[64],"fetchDefaultConfig":[64],"loadTotals":[64],"saveGridConfig":[64],"getFilterBarConfig":[64],"saveFilterBarConfig":[64],"saveFormConfig":[64],"getDefaultValues":[64],"getDefaultValue":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
14
14
  });
15
15
  };
16
16
 
@@ -13,5 +13,5 @@ const patchBrowser = () => {
13
13
  };
14
14
 
15
15
  patchBrowser().then(options => {
16
- return bootstrapLazy([["teste-pesquisa",[[1,"teste-pesquisa"]]],["snk-data-unit",[[2,"snk-data-unit",{"dataState":[1040],"dataUnitName":[1,"data-unit-name"],"entityName":[1,"entity-name"],"pageSize":[2,"page-size"],"dataUnit":[1040],"beforeSave":[16],"afterSave":[16],"getDataUnit":[64]}]]],["snk-filter-binary-select",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-multi-select",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-period",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-pesquisa",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-tab-config",[[6,"snk-tab-config",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1],"_processedTabs":[32],"_activeEditText":[32],"_activeEditTextIndex":[32],"_actionsHide":[32],"_actionsShow":[32]}]]],["snk-filter-detail",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-configurator_3",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}],[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[1,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"configName":[513,"config-name"],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-filter-bar_7",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]],[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"columns":[1040],"config":[1040],"saveConfig":[64]}],[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]],[4,"snk-filter-list",{"label":[1],"iconName":[1,"icon-name"],"items":[16],"getMessage":[16],"emptyText":[1,"empty-text"],"findFilterText":[1,"find-filter-text"],"buttonClass":[1,"button-class"],"_filterArgument":[32],"_showAll":[32],"hideDetail":[64]},[[2,"keydown","keyDownHandler"]]],[0,"snk-filter-modal",{"getMessage":[16],"items":[1040],"modalTitle":[1,"modal-title"],"modalSubTitle":[1,"modal-sub-title"],"cancelButtonLabel":[1,"cancel-button-label"],"okButtonLabel":[1,"ok-button-label"],"infoText":[1,"info-text"],"useSearch":[4,"use-search"],"processModalAction":[16],"_filterArgument":[32]}],[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}]]],["snk-form",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-crud",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"_dataUnit":[32],"_dataState":[32],"_viewMode":[32],"goToView":[64]}]]],["snk-application",[[2,"snk-application",{"messagesBuilder":[1040],"configName":[1,"config-name"],"isUserSup":[64],"hasAccess":[64],"getAllAccess":[64],"getStringParam":[64],"getIntParam":[64],"getFloatParam":[64],"getBooleanParam":[64],"getDateParam":[64],"showPopUp":[64],"showModal":[64],"closeModal":[64],"closePopUp":[64],"temOpcional":[64],"getConfig":[64],"saveConfig":[64],"getAttributeFromHTMLWrapper":[64],"openApp":[64],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadFormConfig":[64],"loadGridConfig":[64],"fetchUserAvailableConfigs":[64],"fetchLegacyConfig":[64],"fetchDefaultConfig":[64],"loadTotals":[64],"saveGridConfig":[64],"getFilterBarConfig":[64],"saveFilterBarConfig":[64],"saveFormConfig":[64],"getDefaultValues":[64],"getDefaultValue":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
16
+ return bootstrapLazy([["teste-pesquisa",[[1,"teste-pesquisa"]]],["snk-data-unit",[[2,"snk-data-unit",{"dataState":[1040],"dataUnitName":[1,"data-unit-name"],"entityName":[1,"entity-name"],"pageSize":[2,"page-size"],"dataUnit":[1040],"beforeSave":[16],"afterSave":[16],"getDataUnit":[64]}]]],["snk-filter-binary-select",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-multi-select",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-period",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-pesquisa",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-tab-config",[[6,"snk-tab-config",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1],"_processedTabs":[32],"_activeEditText":[32],"_activeEditTextIndex":[32],"_actionsHide":[32],"_actionsShow":[32]}]]],["snk-filter-detail",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-configurator_3",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"enableDataExporter":[4,"enable-data-exporter"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]},[[0,"actionClick","actionClickHandler"]]],[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[1,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"configName":[513,"config-name"],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-exporter-email-sender_8",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]],[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"saveConfig":[64]}],[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64]}],[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]],[4,"snk-filter-list",{"label":[1],"iconName":[1,"icon-name"],"items":[16],"getMessage":[16],"emptyText":[1,"empty-text"],"findFilterText":[1,"find-filter-text"],"buttonClass":[1,"button-class"],"_filterArgument":[32],"_showAll":[32],"hideDetail":[64]},[[2,"keydown","keyDownHandler"]]],[0,"snk-filter-modal",{"getMessage":[16],"items":[1040],"modalTitle":[1,"modal-title"],"modalSubTitle":[1,"modal-sub-title"],"cancelButtonLabel":[1,"cancel-button-label"],"okButtonLabel":[1,"ok-button-label"],"infoText":[1,"info-text"],"useSearch":[4,"use-search"],"processModalAction":[16],"_filterArgument":[32]}],[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}]]],["snk-form",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-crud",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"enableDataExporter":[4,"enable-data-exporter"],"_dataUnit":[32],"_dataState":[32],"_viewMode":[32],"goToView":[64]}]]],["snk-application",[[2,"snk-application",{"messagesBuilder":[1040],"configName":[1,"config-name"],"isUserSup":[64],"hasAccess":[64],"getAllAccess":[64],"getStringParam":[64],"getIntParam":[64],"getFloatParam":[64],"getBooleanParam":[64],"getDateParam":[64],"showPopUp":[64],"showModal":[64],"closeModal":[64],"closePopUp":[64],"temOpcional":[64],"getConfig":[64],"saveConfig":[64],"getAttributeFromHTMLWrapper":[64],"openApp":[64],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadFormConfig":[64],"loadGridConfig":[64],"fetchUserAvailableConfigs":[64],"fetchLegacyConfig":[64],"fetchDefaultConfig":[64],"loadTotals":[64],"saveGridConfig":[64],"getFilterBarConfig":[64],"saveFilterBarConfig":[64],"saveFormConfig":[64],"getDefaultValues":[64],"getDefaultValue":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
17
17
  });
@@ -2,7 +2,7 @@ import { r as registerInstance, c as createEvent, h, g as getElement } from './i
2
2
  import { WaitingChangeException, WarningException, ErrorException, ObjectUtils, DataType, DataUnit, StringUtils, ChangeOperation, DateUtils, DependencyType, ElementIDUtils, ApplicationContext, ErrorTracking } from '@sankhyalabs/core';
3
3
  import { d as dist, D as DataFetcher, R as ResourceFetcher, U as UrlUtils, F as FormConfigFetcher, G as GridConfigFetcher, C as ConfigStorage } from './ConfigStorage-99025655.js';
4
4
  import { ApplicationUtils } from '@sankhyalabs/ezui/dist/collection/utils';
5
- import { S as SnkMessageBuilder } from './SnkMessageBuilder-f5ef87df.js';
5
+ import { S as SnkMessageBuilder } from './SnkMessageBuilder-7d583c9a.js';
6
6
  import './_commonjsHelpers-9943807e.js';
7
7
 
8
8
  class SnkErrorHandler {
@@ -2,8 +2,9 @@ import { r as registerInstance, c as createEvent, h, H as Host, g as getElement
2
2
  import { ApplicationContext, ElementIDUtils } from '@sankhyalabs/core';
3
3
  import { c as VIEW_MODE, A as ACTION_CONFIG } from './constants-babe1a08.js';
4
4
  import { A as AuthorizationConfig } from './AuthorizationConfig-dcbd207a.js';
5
- import { T as TaskbarProcessor } from './taskbar-processor-aa6772c9.js';
5
+ import { T as TaskbarProcessor } from './taskbar-processor-c2a99aba.js';
6
6
  import { C as ConfigStorage } from './ConfigStorage-99025655.js';
7
+ import { T as TaskbarElement } from './taskbar-elements-b2bbe275.js';
7
8
  import './_commonjsHelpers-9943807e.js';
8
9
 
9
10
  const snkConfiguratorCss = ".sc-snk-configurator-h{--snk-configurator__button-close--padding-left:var(--space--medium, 12px);--snk-configurator__title--color:var(--title--primary, #2B3A54);--snk-configurator__title--font-family:var(--font-pattern, \"Roboto\");--snk-configurator__title--font-size:var(--title--large, 20px);--snk-configurator__title--font-weight:var(--text-weight--extra-large, 700);--snk-configurator__subtitle--color:var(--title--primary, #2B3A54);--snk-configurator__subtitle--font-family:var(--font-pattern, \"Roboto\");--snk-configurator__subtitle--font-size:var(--text--medium, 14px);--snk-configurator__subtitle--font-weight:var(--text-weight--large, 600);--snk-configurator__scrollbar--color-default:var(--scrollbar--default, #626e82);--snk-configurator__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--snk-configurator__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--snk-configurator__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--snk-configurator__scrollbar--border-radius:var(--border--radius-small, 6px);--snk-configurator__scrollbar--width:var(--space--medium, 12px)}.snk-configurator.sc-snk-configurator{display:grid;grid-template-rows:auto 1fr auto;max-height:100%;width:100%}@media screen and (min-width: 480px){.snk-configurator.sc-snk-configurator{width:359px;max-width:359px}}.snk-configurator__button-config.sc-snk-configurator{--ez-button--min-width:100%}.snk-configurator__header.sc-snk-configurator{display:flex;justify-content:space-between;align-items:center;width:100%}.snk-configurator__title.sc-snk-configurator{display:flex;margin:0;line-height:normal;letter-spacing:0em;text-align:left;color:var(--snk-configurator__title--color);font-size:var(--snk-configurator__title--font-size);font-family:var(--snk-configurator__title--font-family);font-weight:var(--snk-configurator__title--font-weight)}.snk-configurator__subtitle.sc-snk-configurator{display:flex;margin:0;padding-top:var(--space--medium);padding-bottom:var(--space--small);color:var(--snk-configurator__subtitle--color);font-size:var(--snk-configurator__subtitle--font-size);font-family:var(--snk-configurator__subtitle--font-family);font-weight:var(--snk-configurator__subtitle--font-weight)}.snk-configurator__button-close.sc-snk-configurator{padding-left:var(--snk-configurator__button-close--padding-left)}.snk-configurator__main.sc-snk-configurator{overflow-y:auto;scrollbar-width:thin;scrollbar-color:var(--snk-configurator__scrollbar--color-clicked) var(--snk-configurator__scrollbar--color-background)}.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar{background-color:var(--snk-configurator__scrollbar--color-background);width:var(--snk-configurator__scrollbar--width);max-width:var(--snk-configurator__scrollbar--width);min-width:var(--snk-configurator__scrollbar--width)}.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-track{background-color:var(--snk-configurator__scrollbar--color-background);border-radius:var(--snk-configurator__scrollbar--border-radius)}.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-thumb{background-color:var(--snk-configurator__scrollbar--color-default);border-radius:var(--snk-configurator__scrollbar--border-radius)}.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-thumb:vertical:hover,.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--snk-configurator__scrollbar--color-hover)}.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-thumb:vertical:active,.snk-configurator__main.sc-snk-configurator::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--snk-configurator__scrollbar--color-clicked)}";
@@ -162,10 +163,14 @@ const SnkGrid = class {
162
163
  "snkGridTopTaskbar": ["FORM_MODE", "CONFIGURATOR", "INSERT"]
163
164
  });
164
165
  this._headerTaskbarProcessor = new TaskbarProcessor({
165
- "snkGridHeaderTaskbar.unselected": ["REFRESH"],
166
- "snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH"]
166
+ "snkGridHeaderTaskbar.unselected": ["REFRESH", "EXPORT"],
167
+ "snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "EXPORT"]
167
168
  });
168
169
  this._popUpGridConfig = false;
170
+ /**
171
+ * Determina se haverá exportação de dados
172
+ */
173
+ this.enableDataExporter = false;
169
174
  }
170
175
  /**
171
176
  * Exibe a janela de configurações da grade.
@@ -191,6 +196,37 @@ const SnkGrid = class {
191
196
  async setConfig(config) {
192
197
  this.setGridConfig(config);
193
198
  }
199
+ actionClickHandler(event) {
200
+ if (event.detail === TaskbarElement.EXPORT) {
201
+ // TODO: Quando o exportador de grades for implementado, essa ação
202
+ // vai fazer mostrar as opções disponíveis. Enviar por email será
203
+ // apenas mais uma
204
+ const selectedRows = this._dataState.selectedRecords.length;
205
+ const config = {
206
+ format: "pdf",
207
+ type: selectedRows > 0 ? "selection" : "all",
208
+ selectedRows,
209
+ email: {
210
+ attachments: [
211
+ { name: "Movimentação Financeira.pdf", size: 1024 * 231 }
212
+ ]
213
+ }
214
+ };
215
+ this._snkEmailSender.open(config)
216
+ .then((result) => {
217
+ this._application.message("resultado", JSON.stringify(result));
218
+ });
219
+ }
220
+ }
221
+ /**
222
+ * Conforme mecanismo de mensagens, é possível customizar as mensagens dos blocos de construção
223
+ * através de um pequeno modulo na estrutura da aplicação:
224
+ * - Criar um arquivo no seguinte caminho: /messages/appmessages.msg.js.
225
+ * Para conhecer os detalhes do módulo, vide o arquivo neste projeto "/src/lib/message/resources/snk-grid.msg.ts"
226
+ */
227
+ getMessage(key, params) {
228
+ return this._application.messagesBuilder.getMessage(key, params);
229
+ }
194
230
  openGridConfig() {
195
231
  this._grid.getColumnsState()
196
232
  .then((gridColumns) => {
@@ -226,6 +262,7 @@ const SnkGrid = class {
226
262
  });
227
263
  }
228
264
  componentWillLoad() {
265
+ this._application = ApplicationContext.getContextValue("__SNK__APPLICATION__");
229
266
  let parent = this._element.parentElement;
230
267
  while (parent) {
231
268
  if (parent.tagName.toUpperCase() === "SNK-DATA-UNIT") {
@@ -250,9 +287,10 @@ const SnkGrid = class {
250
287
  this.loadConfig();
251
288
  }
252
289
  componentWillRender() {
290
+ const invisibleButtons = this.enableDataExporter ? [] : ["EXPORT"];
253
291
  const headerTaskbarId = this._dataState && this._dataState.selectedRecords.length > 0 ? "snkGridHeaderTaskbar.selected" : "snkGridHeaderTaskbar.unselected";
254
- this._headerTaskbarProcessor.process(headerTaskbarId, this.taskbarManager, this._dataState);
255
- this._topTaskbarProcessor.process("snkGridTopTaskbar", this.taskbarManager, this._dataState);
292
+ this._headerTaskbarProcessor.process(headerTaskbarId, this.taskbarManager, this._dataState, undefined, invisibleButtons);
293
+ this._topTaskbarProcessor.process("snkGridTopTaskbar", this.taskbarManager, this._dataState, undefined, invisibleButtons);
256
294
  }
257
295
  addElementID() {
258
296
  const dataInfo = { dataUnit: this._dataUnit };
@@ -262,7 +300,7 @@ const SnkGrid = class {
262
300
  if (!this._dataUnit) {
263
301
  return undefined;
264
302
  }
265
- return (h("div", { class: "snk-grid__container ez-flex ez-flex--column ez-flex-item--auto ez-padding--large" }, h("div", { class: "snk-grid__header ez-padding-bottom--medium ez-margin-bottom--medium" }, h("snk-filter-bar", { dataUnit: this._dataUnit, "data-element-id": "gridFilter", class: "snk-grid__filter-bar ez-align--top", configName: this.configName }), h("hr", { class: "ez-divider-vertical ez-divider--dark ez-margin-left--medium snk-grid__header-divider" }), h("snk-taskbar", { class: "ez-padding-left--medium", "data-element-id": "grid_top", key: "topTaskbar", configName: this.configName, dataUnit: this._dataUnit, buttons: this._topTaskbarProcessor.buttons, disabledButtons: this._topTaskbarProcessor.disabledButtons, customButtons: this._topTaskbarProcessor.customButtons, primaryButton: "INSERT" })), h("ez-grid", { ref: ref => this._grid = ref, "data-element-id": "embedded", dataUnit: this._dataUnit, key: "grid-" + this._snkDataUnit.entityName, config: this._gridConfig, onConfigChange: (evt) => { this.saveConfig(evt.detail); }, onEzDoubleClick: () => this.gridDoubleClick.emit(), statusResolver: this.statusResolver, multipleSelection: this.multipleSelection }, h("snk-taskbar", { dataUnit: this._dataUnit, "data-element-id": "grid_left", buttons: this._headerTaskbarProcessor.buttons, disabledButtons: this._headerTaskbarProcessor.disabledButtons, customButtons: this._headerTaskbarProcessor.customButtons, slot: "leftButtons", actionsList: this.actionsList })), h("div", { class: "ez-col ez-col--sd-12" }, h("slot", { name: "SnkGridFooter" })), h("ez-modal", { modalSize: "small", closeEsc: false, closeOutsideClick: false, opened: this._popUpGridConfig, onEzCloseModal: () => this.closeGridConfig() }, h("snk-grid-config", { ref: ref => this._snkGridConfig = ref, config: this._gridConfig, "data-element-id": this._element.getAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME), selectedIndex: 0, onConfigChange: (evt) => this.changeConfig(evt.detail), onConfigCancel: () => this.closeGridConfig() }))));
303
+ return (h("div", { class: "snk-grid__container ez-flex ez-flex--column ez-flex-item--auto ez-padding--large" }, h("div", { class: "snk-grid__header ez-padding-bottom--medium ez-margin-bottom--medium" }, h("snk-filter-bar", { dataUnit: this._dataUnit, "data-element-id": "gridFilter", class: "snk-grid__filter-bar ez-align--top", configName: this.configName }), h("hr", { class: "ez-divider-vertical ez-divider--dark ez-margin-left--medium snk-grid__header-divider" }), h("snk-taskbar", { class: "ez-padding-left--medium", "data-element-id": "grid_top", key: "topTaskbar", configName: this.configName, dataUnit: this._dataUnit, buttons: this._topTaskbarProcessor.buttons, disabledButtons: this._topTaskbarProcessor.disabledButtons, customButtons: this._topTaskbarProcessor.customButtons, primaryButton: "INSERT" })), h("ez-grid", { ref: ref => this._grid = ref, "data-element-id": "embedded", dataUnit: this._dataUnit, key: "grid-" + this._snkDataUnit.entityName, config: this._gridConfig, onConfigChange: (evt) => { this.saveConfig(evt.detail); }, onEzDoubleClick: () => this.gridDoubleClick.emit(), statusResolver: this.statusResolver, multipleSelection: this.multipleSelection }, h("snk-taskbar", { dataUnit: this._dataUnit, "data-element-id": "grid_left", buttons: this._headerTaskbarProcessor.buttons, disabledButtons: this._headerTaskbarProcessor.disabledButtons, customButtons: this._headerTaskbarProcessor.customButtons, slot: "leftButtons", actionsList: this.actionsList })), h("div", { class: "ez-col ez-col--sd-12" }, h("slot", { name: "SnkGridFooter" })), h("snk-exporter-email-sender", { ref: ref => this._snkEmailSender = ref, getMessage: (key, params) => this.getMessage(key, params) }), h("ez-modal", { modalSize: "small", closeEsc: false, closeOutsideClick: false, opened: this._popUpGridConfig, onEzCloseModal: () => this.closeGridConfig() }, h("snk-grid-config", { ref: ref => this._snkGridConfig = ref, config: this._gridConfig, "data-element-id": this._element.getAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME), application: this._application, selectedIndex: 0, onConfigChange: (evt) => this.changeConfig(evt.detail), onConfigCancel: () => this.closeGridConfig() }))));
266
304
  }
267
305
  get _element() { return getElement(this); }
268
306
  };
@@ -1,7 +1,7 @@
1
1
  import { r as registerInstance, c as createEvent, h, g as getElement } from './index-e4121713.js';
2
2
  import { ApplicationContext, ElementIDUtils } from '@sankhyalabs/core';
3
3
  import { c as VIEW_MODE } from './constants-babe1a08.js';
4
- import { T as TaskbarElement } from './taskbar-elements-a0a8c3ac.js';
4
+ import { T as TaskbarElement } from './taskbar-elements-b2bbe275.js';
5
5
 
6
6
  const snkCrudCss = ".sc-snk-crud-h{display:flex;flex-direction:column;height:100%;width:100%}";
7
7
 
@@ -16,6 +16,10 @@ const SnkCrud = class {
16
16
  * Determina se pode haver mais de uma linha selecionada na grade.
17
17
  */
18
18
  this.multipleSelection = true;
19
+ /**
20
+ * Determina se haverá exportação de dados
21
+ */
22
+ this.enableDataExporter = false;
19
23
  }
20
24
  /**
21
25
  * Usado para alternar a visão entre GRID e FORM externamente.
@@ -94,7 +98,7 @@ const SnkCrud = class {
94
98
  ElementIDUtils.addIDInfo(this._element, null, dataInfo);
95
99
  }
96
100
  render() {
97
- return (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), actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection }, h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }))), h("stack-item", null, h("snk-form", { ref: (ref) => this._snkForm = ref, "data-element-id": "crud_form", configName: this.configName, actionsList: this.actionsList, onExit: () => this.setViewMode(GRID_MODE), recordsValidator: this.recordsValidator, taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail) }, h("slot", { name: "SnkFormTaskBar" }))), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, viewMode: this._viewMode, onConfigSelected: (evt) => this.executeAction(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail) })));
101
+ return (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), actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, enableDataExporter: this.enableDataExporter }, h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }))), h("stack-item", null, h("snk-form", { ref: (ref) => this._snkForm = ref, "data-element-id": "crud_form", configName: this.configName, actionsList: this.actionsList, onExit: () => this.setViewMode(GRID_MODE), recordsValidator: this.recordsValidator, taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail) }, h("slot", { name: "SnkFormTaskBar" }))), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, viewMode: this._viewMode, onConfigSelected: (evt) => this.executeAction(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail) })));
98
102
  }
99
103
  get _element() { return getElement(this); }
100
104
  };
@@ -1,7 +1,7 @@
1
1
  import { r as registerInstance, c as createEvent, h, g as getElement, H as Host } from './index-e4121713.js';
2
2
  import { Action, ApplicationContext } from '@sankhyalabs/core';
3
3
  import { ApplicationUtils, DialogType } from '@sankhyalabs/ezui/dist/collection/utils';
4
- import { O as OperationMap } from './SnkMessageBuilder-f5ef87df.js';
4
+ import { O as OperationMap } from './SnkMessageBuilder-7d583c9a.js';
5
5
 
6
6
  const snkDataUnitCss = ".sc-snk-data-unit-h{display:flex;flex-direction:column;height:100%}";
7
7
 
@@ -1,5 +1,5 @@
1
- import { r as registerInstance, h, H as Host, g as getElement, c as createEvent } from './index-e4121713.js';
2
- import { DataType, ObjectUtils, ElementIDUtils, StringUtils, ErrorException, ApplicationContext, FloatingManager, ArrayUtils } from '@sankhyalabs/core';
1
+ import { h, r as registerInstance, g as getElement, H as Host, c as createEvent } from './index-e4121713.js';
2
+ import { ElementIDUtils, DataType, ObjectUtils, StringUtils, ErrorException, ApplicationContext, FloatingManager, ArrayUtils } from '@sankhyalabs/core';
3
3
  import { F as FilterItemType } from './filter-item-type.enum-a79b2fa8.js';
4
4
  import { ModalAction, ModalButtonStatus } from '@sankhyalabs/ezui/dist/collection/components/ez-modal-container';
5
5
  import { toString } from '@sankhyalabs/core/dist/dataunit/metadata/DataType';
@@ -7,9 +7,126 @@ import { CheckMode, ApplicationUtils, DialogType } from '@sankhyalabs/ezui/dist/
7
7
  import { C as ConfigStorage } from './ConfigStorage-99025655.js';
8
8
  import { O as ORDER_VALUES } from './constants-babe1a08.js';
9
9
  import { A as AuthorizationConfig } from './AuthorizationConfig-dcbd207a.js';
10
- import { T as TaskbarElement, V as VisibleWhenForbidden, A as AuthorizationElements, b as buildElem, a as buildCustomButton } from './taskbar-elements-a0a8c3ac.js';
10
+ import { T as TaskbarElement, V as VisibleWhenForbidden, A as AuthorizationElements, b as buildElem, a as buildCustomButton } from './taskbar-elements-b2bbe275.js';
11
11
  import './_commonjsHelpers-9943807e.js';
12
12
 
13
+ const EmailInfoStep = ({ getMessage, changeInfo, data }) => {
14
+ return h("div", null,
15
+ h("ez-text-input", Object.assign({ label: `${getMessage("snkExporter.emailSenderInfoStep_sendTo")} (obrigatório) *`, required: true, value: data === null || data === void 0 ? void 0 : data.to, onEzChange: evt => changeInfo("to", evt.detail) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("sendTo")}` })),
16
+ h("ez-text-input", Object.assign({ label: `${getMessage("snkExporter.emailSenderInfoStep_subject")} (obrigatório) *`, required: true, value: data === null || data === void 0 ? void 0 : data.subject, onEzChange: evt => changeInfo("subject", evt.detail) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("subject")}` })),
17
+ h("ez-text-area", Object.assign({ label: getMessage("snkExporter.emailSenderInfoStep_message"), value: data === null || data === void 0 ? void 0 : data.message, onEzChange: evt => changeInfo("message", evt.detail) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("message")}` })),
18
+ ((data === null || data === void 0 ? void 0 : data.attachments) || [])
19
+ .map((file, index) => h("ez-file-item", Object.assign({ class: "ez-padding-bottom--large", fileName: file.name, fileSize: file.size, canRemove: false }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("fileItem_") + (index + 1)}` }))));
20
+ };
21
+
22
+ const OptionsStep = ({ getMessage, changeInfo, data }) => {
23
+ const selectionCount = (data === null || data === void 0 ? void 0 : data.selectedRows) || 0;
24
+ const formatOptions = [
25
+ { label: getMessage("snkExporter.emailSenderOptStep_formatPDF"), value: "pdf" },
26
+ { label: getMessage("snkExporter.emailSenderOptStep_formatXLSX"), value: "xlsx" }
27
+ ];
28
+ const typeOptions = [
29
+ { label: getMessage("snkExporter.emailSenderOptStep_allData"), value: "all" },
30
+ { label: getMessage("snkExporter.emailSenderOptStep_currentPage"), value: "page" },
31
+ ];
32
+ if (selectionCount > 0) {
33
+ const label = getMessage(selectionCount > 1 ? "snkExporter.emailSenderOptStep_someRecords" : "snkExporter.emailSenderOptStep_oneRecord", { SELECTION_COUNT: selectionCount });
34
+ typeOptions.push({
35
+ label,
36
+ value: "selection"
37
+ });
38
+ }
39
+ return h("div", null,
40
+ h("ez-radio-button", Object.assign({ class: "ez-margin-bottom--large" }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("formato")}` }, { label: getMessage("snkExporter.emailSenderOptStep_lblFormat"), direction: "horizontal", value: (data === null || data === void 0 ? void 0 : data.format) || "pdf", onEzChange: evt => changeInfo("format", evt.detail), options: formatOptions })),
41
+ h("ez-radio-button", Object.assign({ class: "ez-margin-bottom--large" }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("type")}` }, { label: getMessage("snkExporter.emailSenderOptStep_export"), value: (data === null || data === void 0 ? void 0 : data.type) || "all", onEzChange: evt => changeInfo("type", evt.detail), options: typeOptions })));
42
+ };
43
+
44
+ const SnkExporterEmailSender = class {
45
+ constructor(hostRef) {
46
+ registerInstance(this, hostRef);
47
+ this._stepInfo = [
48
+ {
49
+ subTitle: "snkExporter.emailSenderOptStep_subtitle",
50
+ firstButton: "snkExporter.emailSenderCancelButton",
51
+ secondButton: "snkExporter.emailSenderNextButton",
52
+ firstButtonAction: () => this.close(),
53
+ secondButtonAction: () => this.changeStep(1)
54
+ },
55
+ {
56
+ subTitle: "snkExporter.emailSenderInfoStep_subtitle",
57
+ firstButton: "snkExporter.emailSenderBackButton",
58
+ secondButton: "snkExporter.emailSenderSendButton",
59
+ firstButtonAction: () => this.changeStep(0),
60
+ secondButtonAction: () => this.send(),
61
+ secondButtonEnabledTester: () => this.isFilled(),
62
+ secondButtonClass: "ez-button--primary"
63
+ }
64
+ ];
65
+ this._opened = false;
66
+ this._currentStep = 0;
67
+ }
68
+ open(config) {
69
+ this._config = config;
70
+ this._opened = true;
71
+ this.changeStep(0);
72
+ return new Promise(accept => {
73
+ this._promiseResolver = accept;
74
+ });
75
+ }
76
+ getStepMessage(key) {
77
+ const stepInfo = this._stepInfo[this._currentStep] || {};
78
+ return this.getMessage(stepInfo[key]);
79
+ }
80
+ executeButtonAction(first) {
81
+ const stepInfo = this._stepInfo[this._currentStep] || {};
82
+ stepInfo[first ? "firstButtonAction" : "secondButtonAction"]();
83
+ }
84
+ checkButtonEnabled(first) {
85
+ const stepInfo = this._stepInfo[this._currentStep] || {};
86
+ const testFunction = stepInfo[first ? "firstButtonEnabledTester" : "secondButtonEnabledTester"];
87
+ if (testFunction) {
88
+ return testFunction();
89
+ }
90
+ return true;
91
+ }
92
+ changeStep(index) {
93
+ this._currentStep = index;
94
+ if (this._viewStack) {
95
+ this._viewStack.show(this._currentStep);
96
+ }
97
+ }
98
+ send() {
99
+ const { format, type, email } = this._config;
100
+ this._promiseResolver({ format, type, email, report: undefined });
101
+ }
102
+ close() {
103
+ this._opened = false;
104
+ }
105
+ isFilled() {
106
+ var _a, _b;
107
+ return ((_a = this._config.email) === null || _a === void 0 ? void 0 : _a.to) && ((_b = this._config.email) === null || _b === void 0 ? void 0 : _b.subject) ? true : false;
108
+ }
109
+ updateEmailInfo(field, value) {
110
+ this._config = Object.assign(Object.assign({}, this._config), { email: Object.assign(Object.assign({}, this._config.email), { [field]: value }) });
111
+ }
112
+ updateConfigInfo(field, value) {
113
+ this._config = Object.assign(Object.assign({}, this._config), { [field]: value });
114
+ }
115
+ getSecondButtonClass() {
116
+ const stepInfo = this._stepInfo[this._currentStep] || {};
117
+ return stepInfo["secondButtonClass"] || "ez-button--secondary";
118
+ }
119
+ render() {
120
+ var _a;
121
+ ElementIDUtils.addIDInfoIfNotExists(this._element, 'snkExporterEmailSender');
122
+ return (h("ez-popup", { useHeader: false, size: "x-small", heightMode: "auto", opened: this._opened }, h("ez-modal-container", { onEzModalAction: evt => {
123
+ if (evt.detail === "CLOSE")
124
+ this.close();
125
+ }, modalTitle: this.getMessage("snkExporter.emailSenderTitle"), modalSubTitle: this.getStepMessage("subTitle") }, h("ez-view-stack", { ref: ref => this._viewStack = ref }, h("stack-item", null, h(OptionsStep, { getMessage: this.getMessage, data: this._config, changeInfo: (field, value) => this.updateConfigInfo(field, value) })), h("stack-item", null, h(EmailInfoStep, { getMessage: this.getMessage, data: (_a = this._config) === null || _a === void 0 ? void 0 : _a.email, changeInfo: (field, value) => this.updateEmailInfo(field, value) }))), h("div", { class: "ez-col ez-col--sd-12 ez-flex--justify-end ez-margin-vertical--small" }, h("ez-button", Object.assign({ class: "ez-button--tertiary ez-padding-right--medium", label: this.getStepMessage("firstButton"), onClick: () => this.executeButtonAction(true), enabled: this.checkButtonEnabled(true) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("firstButton")}` })), h("ez-button", Object.assign({ class: this.getSecondButtonClass(), label: this.getStepMessage("secondButton"), onClick: () => this.executeButtonAction(false), enabled: this.checkButtonEnabled(false) }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo("secondButton")}` }))))));
126
+ }
127
+ get _element() { return getElement(this); }
128
+ };
129
+
13
130
  const buildFilter = (item) => {
14
131
  switch (item.type) {
15
132
  case FilterItemType.DEFAULT_FILTER:
@@ -730,15 +847,17 @@ const SnkFilterList = class {
730
847
  this._popover.remove();
731
848
  }
732
849
  }
733
- this._element.querySelectorAll("button.sc-snk-filter-bar").forEach((itemListElement) => {
734
- const dataElement = { id: itemListElement.getAttribute("name") };
735
- itemListElement === null || itemListElement === void 0 ? void 0 : itemListElement.removeAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME);
736
- ElementIDUtils.addIDInfoIfNotExists(itemListElement, "filterItemList", dataElement);
737
- });
850
+ }
851
+ buildIdElement(buttonElement, name) {
852
+ if (!buttonElement)
853
+ return;
854
+ const dataElement = { id: name };
855
+ buttonElement.removeAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME);
856
+ ElementIDUtils.addIDInfoIfNotExists(buttonElement, "filterItemList", dataElement);
738
857
  }
739
858
  buildItemElement(item) {
740
859
  const itemId = ++this._selectableItemsCount;
741
- return (h("button", { id: `filter-item${itemId}`, onFocusin: () => this._preselection = itemId, class: `ez-col ez-col--sd-12 ez-align--middle ez-padding--small sc-snk-filter-bar snk-filter-bar__filter-list-item`, onClick: () => this.itemSelected(item.name), name: item.label, key: itemId }, item.iconName ? h("ez-icon", { iconName: item.iconName, size: "small", class: `ez-padding-right--extra-small sc-snk-filter-bar snk-filter-bar__filter-list-item__icon ${item.iconClass || ""}` }) : undefined, h("div", { class: `ez-text ez-text--medium ez-text--primary ez-padding--extra-small sc-snk-filter-bar snk-filter-bar__filter-list-item__label ${item.labelClass || ""}` }, item.label)));
860
+ return (h("button", { ref: elem => elem && this.buildIdElement(elem, item.label), id: `filter-item${itemId}`, onFocusin: () => this._preselection = itemId, class: `ez-col ez-col--sd-12 ez-align--middle ez-padding--small sc-snk-filter-bar snk-filter-bar__filter-list-item`, onClick: () => this.itemSelected(item.name), name: item.label, key: itemId }, item.iconName ? h("ez-icon", { iconName: item.iconName, size: "small", class: `ez-padding-right--extra-small sc-snk-filter-bar snk-filter-bar__filter-list-item__icon ${item.iconClass || ""}` }) : undefined, h("div", { class: `ez-text ez-text--medium ez-text--primary ez-padding--extra-small sc-snk-filter-bar snk-filter-bar__filter-list-item__label ${item.labelClass || ""}` }, item.label)));
742
861
  }
743
862
  itemSelected(itemName) {
744
863
  if (itemName === SHOW_MORE_ITEM_NAME) {
@@ -875,7 +994,7 @@ const EzGridConfig = class {
875
994
  this._componenteInternalKey = Date.now();
876
995
  /**
877
996
  * Aba selecionada das configurações da grade.
878
- */
997
+ */
879
998
  this.selectedIndex = 0;
880
999
  }
881
1000
  /* Creation Methods */
@@ -884,10 +1003,10 @@ const EzGridConfig = class {
884
1003
  */
885
1004
  async saveConfig(config) {
886
1005
  var _a;
887
- if (config == undefined || ((_a = this._application) === null || _a === void 0 ? void 0 : _a.configName) == undefined) {
1006
+ if (config == undefined || ((_a = this.application) === null || _a === void 0 ? void 0 : _a.configName) == undefined) {
888
1007
  return;
889
1008
  }
890
- ConfigStorage.saveGridConfig(config, this._application.configName)
1009
+ ConfigStorage.saveGridConfig(config, this.application.configName)
891
1010
  .then((response) => {
892
1011
  if ((response === null || response === void 0 ? void 0 : response.resource) != undefined) {
893
1012
  this.configChange.emit(config);
@@ -902,7 +1021,7 @@ const EzGridConfig = class {
902
1021
  * Para conhecer os detalhes do módulo, vide o arquivo neste projeto "/src/lib/message/resources/snk-grid.msg.ts"
903
1022
  */
904
1023
  getMessage(key, params) {
905
- return this._application.messagesBuilder.getMessage(key, params);
1024
+ return this.application.messagesBuilder.getMessage(key, params);
906
1025
  }
907
1026
  createOrderList() {
908
1027
  let newList = [];
@@ -1321,9 +1440,6 @@ const EzGridConfig = class {
1321
1440
  this.locateColumn(new KeyboardEvent("arrow-right", { key: "ArrowRight" }), this._searchElement.value);
1322
1441
  }
1323
1442
  }
1324
- componentWillLoad() {
1325
- this._application = ApplicationContext.getContextValue("__SNK__APPLICATION__");
1326
- }
1327
1443
  componentDidLoad() {
1328
1444
  ElementIDUtils.addIDInfo(this._element);
1329
1445
  }
@@ -1375,7 +1491,8 @@ const SnkTaskbar = class {
1375
1491
  [TaskbarElement.SAVE]: "snkTaskbar.titleSave",
1376
1492
  [TaskbarElement.GRID_MODE]: "snkTaskbar.titleGridMode",
1377
1493
  [TaskbarElement.FORM_MODE]: "snkTaskbar.titleFormMode",
1378
- [TaskbarElement.CONFIGURATOR]: "snkTaskbar.titleConfigurator"
1494
+ [TaskbarElement.CONFIGURATOR]: "snkTaskbar.titleConfigurator",
1495
+ [TaskbarElement.EXPORT]: "snkTaskbar.titleExportar"
1379
1496
  };
1380
1497
  }
1381
1498
  observeButtons() {
@@ -1544,4 +1661,4 @@ const SnkTaskbar = class {
1544
1661
  };
1545
1662
  SnkTaskbar.style = snkTaskbarCss;
1546
1663
 
1547
- export { SnkFilterBar as snk_filter_bar, SnkFilterItem as snk_filter_item, SnkFilterList as snk_filter_list, SnkFilterModal as snk_filter_modal, EzGridConfig as snk_grid_config, SelectBox as snk_select_box, SnkTaskbar as snk_taskbar };
1664
+ export { SnkExporterEmailSender as snk_exporter_email_sender, SnkFilterBar as snk_filter_bar, SnkFilterItem as snk_filter_item, SnkFilterList as snk_filter_list, SnkFilterModal as snk_filter_modal, EzGridConfig as snk_grid_config, SelectBox as snk_select_box, SnkTaskbar as snk_taskbar };
@@ -54,7 +54,14 @@ const SnkFilterDetail = class {
54
54
  ]);
55
55
  }
56
56
  buildIcon(title, iconName, action) {
57
- return (h("button", { onClick: () => action(), class: "sc-snk-filter-bar snk-filter-item__editor-header-button" }, h("ez-icon", { title: title, iconName: iconName })));
57
+ return (h("button", { onClick: () => action(), class: "sc-snk-filter-bar snk-filter-item__editor-header-button", ref: elem => elem && this.buildIdButton(elem, title) }, h("ez-icon", Object.assign({ title: title, iconName: iconName }, { [ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${ElementIDUtils.getInternalIDInfo(`_${title}`)}` }))));
58
+ }
59
+ buildIdButton(buttonElement, title) {
60
+ if (!buttonElement)
61
+ return;
62
+ const dataElement = { id: title };
63
+ buttonElement.removeAttribute(ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME);
64
+ ElementIDUtils.addIDInfoIfNotExists(buttonElement, "button", dataElement);
58
65
  }
59
66
  getNormalizedValue(params, value) {
60
67
  return params.reduce((arrayValues, currentParam, index) => {
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, c as createEvent, h, g as getElement } from './index-e4121713.js';
2
2
  import { DateUtils, ObjectUtils, ElementIDUtils, ApplicationContext } from '@sankhyalabs/core';
3
- import { T as TaskbarProcessor } from './taskbar-processor-aa6772c9.js';
3
+ import { T as TaskbarProcessor } from './taskbar-processor-c2a99aba.js';
4
4
  import { C as ConfigStorage } from './ConfigStorage-99025655.js';
5
5
  import './_commonjsHelpers-9943807e.js';
6
6
 
@@ -16,6 +16,7 @@ var TaskbarElement;
16
16
  TaskbarElement["MORE_OPTIONS"] = "MORE_OPTIONS";
17
17
  TaskbarElement["DIVIDER"] = "DIVIDER";
18
18
  TaskbarElement["CONFIGURATOR"] = "CONFIGURATOR";
19
+ TaskbarElement["EXPORT"] = "EXPORT";
19
20
  })(TaskbarElement || (TaskbarElement = {}));
20
21
  var AuthorizationElements;
21
22
  (function (AuthorizationElements) {
@@ -70,6 +71,8 @@ const buildElem = (element, className, dataElementId, getTitle, action, isEnable
70
71
  return iconButton("list", element, className, dataElementId, title, action, isEnabled);
71
72
  case TaskbarElement.CONFIGURATOR:
72
73
  return iconButton("settings-inverted", element, className, dataElementId, title, action, isEnabled);
74
+ case TaskbarElement.EXPORT:
75
+ return iconButton("file-download", element, className, dataElementId, title, action, isEnabled);
73
76
  case TaskbarElement.MORE_OPTIONS:
74
77
  return actionButton(element, className, dataElementId, title, action, isEnabled, actions);
75
78
  case TaskbarElement.DIVIDER:
@@ -2,7 +2,7 @@ class TaskbarProcessor {
2
2
  constructor(defaultButtons) {
3
3
  this._defaultButtons = defaultButtons;
4
4
  }
5
- process(taskbarId, taskbarManager, dataState, disabledButtons = []) {
5
+ process(taskbarId, taskbarManager, dataState, disabledButtons = [], invisibleButtons = []) {
6
6
  var _a;
7
7
  this.customButtons = new Map();
8
8
  this.buttons = "";
@@ -17,13 +17,15 @@ class TaskbarProcessor {
17
17
  this.customButtons.set(customBtn.name, customBtn);
18
18
  buttonName = customBtn.name;
19
19
  }
20
- if (!this.isEnabled(taskbarId, taskbarManager, buttonName, dataState, disabledButtons)) {
21
- this.disabledButtons.push(buttonName);
20
+ if (!invisibleButtons.includes(buttonName)) {
21
+ if (!this.isEnabled(taskbarId, taskbarManager, buttonName, dataState, disabledButtons)) {
22
+ this.disabledButtons.push(buttonName);
23
+ }
24
+ if (this.buttons.length > 0) {
25
+ this.buttons += ",";
26
+ }
27
+ this.buttons += buttonName;
22
28
  }
23
- if (this.buttons.length > 0) {
24
- this.buttons += ",";
25
- }
26
- this.buttons += buttonName;
27
29
  });
28
30
  }
29
31
  getButtonsArray(taskbarId, taskbarManager, dataState) {
@@ -1,4 +1,4 @@
1
- import{r as t,c as e,h as s,g as i}from"./p-9ba3df4c.js";import{WaitingChangeException as r,WarningException as n,ErrorException as a,ObjectUtils as o,DataType as c,DataUnit as h,StringUtils as u,ChangeOperation as l,DateUtils as d,DependencyType as p,ElementIDUtils as m,ApplicationContext as f,ErrorTracking as y}from"@sankhyalabs/core";import{d as g,D as v,R as w,U as I,F as _,G as P,C as $}from"./p-6ba8f415.js";import{ApplicationUtils as D}from"@sankhyalabs/ezui/dist/collection/utils";import{S}from"./p-877bd6cf.js";import"./p-112455b1.js";class C{constructor(t){this._app=t,window.addEventListener("error",(t=>this.errorHandler(t))),window.addEventListener("unhandledrejection",(t=>this.rejectionHandler(t)))}rejectionHandler(t){const e=t.reason;e instanceof r||(e?this.processException(e):this._app.isDebugMode().then((t=>{t&&this._app.error("Promise rejeitada","Erro interno: Uma promise foi rejeitada sem razão determinada.")})))}errorHandler(t){this.processException(t.error)}buildErrorCodeHTML(t){return'<br><a href="#" onclick="try{window.workspace.openHelp(\'_tbcode:'+t.errorCode+"')} catch(e){alert('Não é possível abrir a ajuda fora do workspace Sankhya');}\">Código: "+t.errorCode+"</a>"}processException(t){t.errorCode&&(t.message+=this.buildErrorCodeHTML(t)),t instanceof r||t instanceof n?this._app.alert(t.title,t.message):t instanceof a?this._app.error(t.title,t.message):this._app.isDebugMode().then((e=>{if(e)if(t instanceof Error)this._app.error(t.name,t.message);else{const e=(null==t?void 0:t.title)||"Erro detectado",s="string"==typeof t?t:t.message||`Erro interno "${o.objectToString(t)}"`;this._app.error(e,s)}}))}}class A{constructor(){this._defaultPageSize=100,this._templateByQuery=new Map,this.buldTemplates()}buldTemplates(){this._templateByQuery.set("search",g.gql`query($entityName: String! $argument: String $criteria: InputSearchCriteria $options: InputSearchOptions) {
1
+ import{r as t,c as e,h as s,g as i}from"./p-9ba3df4c.js";import{WaitingChangeException as r,WarningException as n,ErrorException as a,ObjectUtils as o,DataType as c,DataUnit as h,StringUtils as u,ChangeOperation as l,DateUtils as d,DependencyType as p,ElementIDUtils as m,ApplicationContext as f,ErrorTracking as y}from"@sankhyalabs/core";import{d as g,D as v,R as w,U as I,F as _,G as P,C as $}from"./p-6ba8f415.js";import{ApplicationUtils as D}from"@sankhyalabs/ezui/dist/collection/utils";import{S}from"./p-e7f772ed.js";import"./p-112455b1.js";class C{constructor(t){this._app=t,window.addEventListener("error",(t=>this.errorHandler(t))),window.addEventListener("unhandledrejection",(t=>this.rejectionHandler(t)))}rejectionHandler(t){const e=t.reason;e instanceof r||(e?this.processException(e):this._app.isDebugMode().then((t=>{t&&this._app.error("Promise rejeitada","Erro interno: Uma promise foi rejeitada sem razão determinada.")})))}errorHandler(t){this.processException(t.error)}buildErrorCodeHTML(t){return'<br><a href="#" onclick="try{window.workspace.openHelp(\'_tbcode:'+t.errorCode+"')} catch(e){alert('Não é possível abrir a ajuda fora do workspace Sankhya');}\">Código: "+t.errorCode+"</a>"}processException(t){t.errorCode&&(t.message+=this.buildErrorCodeHTML(t)),t instanceof r||t instanceof n?this._app.alert(t.title,t.message):t instanceof a?this._app.error(t.title,t.message):this._app.isDebugMode().then((e=>{if(e)if(t instanceof Error)this._app.error(t.name,t.message);else{const e=(null==t?void 0:t.title)||"Erro detectado",s="string"==typeof t?t:t.message||`Erro interno "${o.objectToString(t)}"`;this._app.error(e,s)}}))}}class A{constructor(){this._defaultPageSize=100,this._templateByQuery=new Map,this.buldTemplates()}buldTemplates(){this._templateByQuery.set("search",g.gql`query($entityName: String! $argument: String $criteria: InputSearchCriteria $options: InputSearchOptions) {
2
2
  $queryAlias$: search(entityName: $entityName argument: $argument criteria: $criteria options: $options){
3
3
  value
4
4
  label