@sankhyalabs/sankhyablocks 5.0.0 → 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/sankhyablocks.cjs.js +1 -1
- package/dist/cjs/snk-application.cjs.entry.js +4 -1
- package/dist/cjs/snk-detail-view.cjs.entry.js +1 -1
- package/dist/cjs/snk-grid.cjs.entry.js +12 -2
- package/dist/cjs/snk-simple-bar.cjs.entry.js +30 -0
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/snk-application/snk-application.js +4 -1
- package/dist/collection/components/snk-crud/subcomponents/snk-detail-view.js +1 -1
- package/dist/collection/components/snk-grid/snk-grid.js +29 -2
- package/dist/collection/components/snk-simple-bar/snk-simple-bar.css +32 -0
- package/dist/collection/components/snk-simple-bar/snk-simple-bar.js +111 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/snk-application2.js +4 -1
- package/dist/components/snk-detail-view2.js +1 -1
- package/dist/components/snk-grid2.js +13 -2
- package/dist/components/snk-simple-bar.d.ts +11 -0
- package/dist/components/snk-simple-bar.js +46 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/sankhyablocks.js +1 -1
- package/dist/esm/snk-application.entry.js +4 -1
- package/dist/esm/snk-detail-view.entry.js +1 -1
- package/dist/esm/snk-grid.entry.js +12 -2
- package/dist/esm/snk-simple-bar.entry.js +26 -0
- package/dist/sankhyablocks/{p-187b6778.entry.js → p-0abc00e7.entry.js} +1 -1
- package/dist/sankhyablocks/{p-5fed359b.entry.js → p-64afbfc9.entry.js} +2 -2
- package/dist/sankhyablocks/p-8f359cbf.entry.js +1 -0
- package/dist/sankhyablocks/p-b3e71248.entry.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-grid/snk-grid.d.ts +4 -0
- package/dist/types/components/snk-simple-bar/snk-simple-bar.d.ts +23 -0
- package/dist/types/components.d.ts +50 -0
- package/package.json +1 -1
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/sankhyablocks/p-6975f711.entry.js +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
16
16
|
return patchEsm().then(() => {
|
17
|
-
return index.bootstrapLazy([["snk-simple-crud.cjs",[[6,"snk-simple-crud",{"dataState":[16],"dataUnit":[16],"mode":[2],"taskbarManager":[16],"_currentViewMode":[32],"_config":[32],"goToView":[64],"setMetadata":[64],"setRecords":[64],"getRecords":[64]},[[0,"actionClick","actionClickListener"]]]]],["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-field-search.cjs",[[2,"snk-filter-field-search",{"searchable":[4],"breadcrumbItems":[32],"linkItems":[32],"fieldItems":[32],"setDataSource":[64],"filterDataSource":[64]}]]],["snk-filter-multi-select.cjs",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number.cjs",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-param-config.cjs",[[2,"snk-filter-param-config",{"_opened":[32],"_configType":[32],"_expressionItem":[32],"_informedInstance":[32],"_canSave":[32],"open":[64],"close":[64]}]]],["snk-filter-period.cjs",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized.cjs",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search.cjs",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text.cjs",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-detail-view.cjs",[[2,"snk-detail-view",{"formConfigManager":[1040],"dataUnitName":[1,"data-unit-name"],"guideItemPath":[16],"entityName":[1,"entity-name"],"label":[1],"dataUnit":[1040],"selectedForm":[1025,"selected-form"],"dataState":[1040],"_disabledButtons":[32],"changeViewMode":[64],"configGrid":[64],"showUp":[64]},[[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-configurator.cjs",[[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[2,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}]]],["snk-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-filter-bar.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]]]],["snk-grid-config.cjs",[[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"configName":[1,"config-name"]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-data-unit.cjs",[[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],"getSelectedRecordsIDsInfo":[64]}]]],["snk-field-config.cjs",[[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-tab-config.cjs",[[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-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"configManager":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-taskbar.cjs",[[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"presentationMode":[1537,"presentation-mode"],"_permissions":[32]}]]],["snk-filter-item.cjs",[[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]]]],["snk-filter-list.cjs",[[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"]]]]],["snk-select-box.cjs",[[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}]]],["snk-exporter-email-sender.cjs",[[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64],"close":[64]}]]],["snk-data-exporter.cjs",[[2,"snk-data-exporter",{"provider":[16],"_items":[32],"_showDropdown":[32],"_releasedToExport":[32]}]]],["snk-guides-viewer.cjs",[[2,"snk-guides-viewer",{"dataUnit":[16],"dataState":[16],"configName":[1,"config-name"],"entityPath":[1,"entity-path"],"actionsList":[16],"recordsValidator":[16],"masterFormConfig":[1040],"selectedGuide":[16],"taskbarManager":[16],"presentationMode":[1,"presentation-mode"],"_breadcrumbItems":[32],"_guides":[32],"_formEditorConfigManager":[32],"_formEditorDataUnit":[32],"showFormConfig":[64]},[[2,"actionClick","onActionClick"],[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_currentViewMode":[32],"goToView":[64]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"_dataUnit":[32],"_dataState":[32],"_showFormConfig":[32],"_configManager":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-application.cjs",[[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],"webConnection":[64],"createDataunit":[64],"updateDataunitCache":[64],"getDataUnit":[64],"addClientEvent":[64],"removeClientEvent":[64],"hasClientEvent":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadGridConfig":[64],"loadTotals":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64],"getAppLabel":[64],"addSearchListener":[64]}]]],["snk-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-grid.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}]]],["snk-form-summary.cjs",[[2,"snk-form-summary",{"fixed":[1540],"contracted":[1540],"summary":[16]}]]],["snk-form-view.cjs",[[6,"snk-form-view",{"levelPath":[1,"level-path"],"label":[1],"name":[1],"fields":[16],"formMetadata":[8,"form-metadata"],"dataUnit":[16],"contracted":[4],"fixed":[1540],"summaryFields":[16],"canExpand":[4,"can-expand"],"canFix":[4,"can-fix"],"recordsValidator":[16],"showUp":[64]}]]],["snk-filter-modal.cjs",[[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]}]]]], options);
|
17
|
+
return index.bootstrapLazy([["snk-simple-crud.cjs",[[6,"snk-simple-crud",{"dataState":[16],"dataUnit":[16],"mode":[2],"taskbarManager":[16],"_currentViewMode":[32],"_config":[32],"goToView":[64],"setMetadata":[64],"setRecords":[64],"getRecords":[64]},[[0,"actionClick","actionClickListener"]]]]],["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-field-search.cjs",[[2,"snk-filter-field-search",{"searchable":[4],"breadcrumbItems":[32],"linkItems":[32],"fieldItems":[32],"setDataSource":[64],"filterDataSource":[64]}]]],["snk-filter-multi-select.cjs",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number.cjs",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-param-config.cjs",[[2,"snk-filter-param-config",{"_opened":[32],"_configType":[32],"_expressionItem":[32],"_informedInstance":[32],"_canSave":[32],"open":[64],"close":[64]}]]],["snk-filter-period.cjs",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized.cjs",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search.cjs",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text.cjs",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-simple-bar.cjs",[[6,"snk-simple-bar",{"label":[1],"breadcrumbItens":[16]}]]],["snk-detail-view.cjs",[[2,"snk-detail-view",{"formConfigManager":[1040],"dataUnitName":[1,"data-unit-name"],"guideItemPath":[16],"entityName":[1,"entity-name"],"label":[1],"dataUnit":[1040],"selectedForm":[1025,"selected-form"],"dataState":[1040],"_disabledButtons":[32],"changeViewMode":[64],"configGrid":[64],"showUp":[64]},[[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-configurator.cjs",[[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[2,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}]]],["snk-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-filter-bar.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]]]],["snk-grid-config.cjs",[[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"configName":[1,"config-name"]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-data-unit.cjs",[[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],"getSelectedRecordsIDsInfo":[64]}]]],["snk-field-config.cjs",[[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-tab-config.cjs",[[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-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"configManager":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-taskbar.cjs",[[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"presentationMode":[1537,"presentation-mode"],"_permissions":[32]}]]],["snk-filter-item.cjs",[[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]]]],["snk-filter-list.cjs",[[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"]]]]],["snk-select-box.cjs",[[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}]]],["snk-exporter-email-sender.cjs",[[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64],"close":[64]}]]],["snk-data-exporter.cjs",[[2,"snk-data-exporter",{"provider":[16],"_items":[32],"_showDropdown":[32],"_releasedToExport":[32]}]]],["snk-guides-viewer.cjs",[[2,"snk-guides-viewer",{"dataUnit":[16],"dataState":[16],"configName":[1,"config-name"],"entityPath":[1,"entity-path"],"actionsList":[16],"recordsValidator":[16],"masterFormConfig":[1040],"selectedGuide":[16],"taskbarManager":[16],"presentationMode":[1,"presentation-mode"],"_breadcrumbItems":[32],"_guides":[32],"_formEditorConfigManager":[32],"_formEditorDataUnit":[32],"showFormConfig":[64]},[[2,"actionClick","onActionClick"],[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_currentViewMode":[32],"goToView":[64]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"_dataUnit":[32],"_dataState":[32],"_showFormConfig":[32],"_configManager":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-application.cjs",[[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],"webConnection":[64],"createDataunit":[64],"updateDataunitCache":[64],"getDataUnit":[64],"addClientEvent":[64],"removeClientEvent":[64],"hasClientEvent":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadGridConfig":[64],"loadTotals":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64],"getAppLabel":[64],"addSearchListener":[64]}]]],["snk-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-grid.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"isDetail":[4,"is-detail"],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}]]],["snk-form-summary.cjs",[[2,"snk-form-summary",{"fixed":[1540],"contracted":[1540],"summary":[16]}]]],["snk-form-view.cjs",[[6,"snk-form-view",{"levelPath":[1,"level-path"],"label":[1],"name":[1],"fields":[16],"formMetadata":[8,"form-metadata"],"dataUnit":[16],"contracted":[4],"fixed":[1540],"summaryFields":[16],"canExpand":[4,"can-expand"],"canFix":[4,"can-fix"],"recordsValidator":[16],"showUp":[64]}]]],["snk-filter-modal.cjs",[[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]}]]]], options);
|
18
18
|
});
|
19
19
|
};
|
20
20
|
|
@@ -17,7 +17,7 @@ const patchBrowser = () => {
|
|
17
17
|
};
|
18
18
|
|
19
19
|
patchBrowser().then(options => {
|
20
|
-
return index.bootstrapLazy([["snk-simple-crud.cjs",[[6,"snk-simple-crud",{"dataState":[16],"dataUnit":[16],"mode":[2],"taskbarManager":[16],"_currentViewMode":[32],"_config":[32],"goToView":[64],"setMetadata":[64],"setRecords":[64],"getRecords":[64]},[[0,"actionClick","actionClickListener"]]]]],["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-field-search.cjs",[[2,"snk-filter-field-search",{"searchable":[4],"breadcrumbItems":[32],"linkItems":[32],"fieldItems":[32],"setDataSource":[64],"filterDataSource":[64]}]]],["snk-filter-multi-select.cjs",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number.cjs",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-param-config.cjs",[[2,"snk-filter-param-config",{"_opened":[32],"_configType":[32],"_expressionItem":[32],"_informedInstance":[32],"_canSave":[32],"open":[64],"close":[64]}]]],["snk-filter-period.cjs",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized.cjs",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search.cjs",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text.cjs",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-detail-view.cjs",[[2,"snk-detail-view",{"formConfigManager":[1040],"dataUnitName":[1,"data-unit-name"],"guideItemPath":[16],"entityName":[1,"entity-name"],"label":[1],"dataUnit":[1040],"selectedForm":[1025,"selected-form"],"dataState":[1040],"_disabledButtons":[32],"changeViewMode":[64],"configGrid":[64],"showUp":[64]},[[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-configurator.cjs",[[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[2,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}]]],["snk-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-filter-bar.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]]]],["snk-grid-config.cjs",[[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"configName":[1,"config-name"]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-data-unit.cjs",[[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],"getSelectedRecordsIDsInfo":[64]}]]],["snk-field-config.cjs",[[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-tab-config.cjs",[[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-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"configManager":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-taskbar.cjs",[[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"presentationMode":[1537,"presentation-mode"],"_permissions":[32]}]]],["snk-filter-item.cjs",[[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]]]],["snk-filter-list.cjs",[[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"]]]]],["snk-select-box.cjs",[[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}]]],["snk-exporter-email-sender.cjs",[[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64],"close":[64]}]]],["snk-data-exporter.cjs",[[2,"snk-data-exporter",{"provider":[16],"_items":[32],"_showDropdown":[32],"_releasedToExport":[32]}]]],["snk-guides-viewer.cjs",[[2,"snk-guides-viewer",{"dataUnit":[16],"dataState":[16],"configName":[1,"config-name"],"entityPath":[1,"entity-path"],"actionsList":[16],"recordsValidator":[16],"masterFormConfig":[1040],"selectedGuide":[16],"taskbarManager":[16],"presentationMode":[1,"presentation-mode"],"_breadcrumbItems":[32],"_guides":[32],"_formEditorConfigManager":[32],"_formEditorDataUnit":[32],"showFormConfig":[64]},[[2,"actionClick","onActionClick"],[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_currentViewMode":[32],"goToView":[64]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"_dataUnit":[32],"_dataState":[32],"_showFormConfig":[32],"_configManager":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-application.cjs",[[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],"webConnection":[64],"createDataunit":[64],"updateDataunitCache":[64],"getDataUnit":[64],"addClientEvent":[64],"removeClientEvent":[64],"hasClientEvent":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadGridConfig":[64],"loadTotals":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64],"getAppLabel":[64],"addSearchListener":[64]}]]],["snk-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-grid.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}]]],["snk-form-summary.cjs",[[2,"snk-form-summary",{"fixed":[1540],"contracted":[1540],"summary":[16]}]]],["snk-form-view.cjs",[[6,"snk-form-view",{"levelPath":[1,"level-path"],"label":[1],"name":[1],"fields":[16],"formMetadata":[8,"form-metadata"],"dataUnit":[16],"contracted":[4],"fixed":[1540],"summaryFields":[16],"canExpand":[4,"can-expand"],"canFix":[4,"can-fix"],"recordsValidator":[16],"showUp":[64]}]]],["snk-filter-modal.cjs",[[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]}]]]], options);
|
20
|
+
return index.bootstrapLazy([["snk-simple-crud.cjs",[[6,"snk-simple-crud",{"dataState":[16],"dataUnit":[16],"mode":[2],"taskbarManager":[16],"_currentViewMode":[32],"_config":[32],"goToView":[64],"setMetadata":[64],"setRecords":[64],"getRecords":[64]},[[0,"actionClick","actionClickListener"]]]]],["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-field-search.cjs",[[2,"snk-filter-field-search",{"searchable":[4],"breadcrumbItems":[32],"linkItems":[32],"fieldItems":[32],"setDataSource":[64],"filterDataSource":[64]}]]],["snk-filter-multi-select.cjs",[[0,"snk-filter-multi-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-number.cjs",[[0,"snk-filter-number",{"config":[16],"value":[2],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-param-config.cjs",[[2,"snk-filter-param-config",{"_opened":[32],"_configType":[32],"_expressionItem":[32],"_informedInstance":[32],"_canSave":[32],"open":[64],"close":[64]}]]],["snk-filter-period.cjs",[[0,"snk-filter-period",{"config":[16],"value":[8],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-personalized.cjs",[[0,"snk-filter-personalized",{"config":[16],"value":[1040],"fix":[16],"unfix":[16],"show":[64]}]]],["snk-filter-search.cjs",[[0,"snk-filter-search",{"config":[16],"value":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["snk-filter-text.cjs",[[0,"snk-filter-text",{"config":[16],"value":[1]},[[0,"ezChange","ezChangeListener"]]]]],["snk-simple-bar.cjs",[[6,"snk-simple-bar",{"label":[1],"breadcrumbItens":[16]}]]],["snk-detail-view.cjs",[[2,"snk-detail-view",{"formConfigManager":[1040],"dataUnitName":[1,"data-unit-name"],"guideItemPath":[16],"entityName":[1,"entity-name"],"label":[1],"dataUnit":[1040],"selectedForm":[1025,"selected-form"],"dataState":[1040],"_disabledButtons":[32],"changeViewMode":[64],"configGrid":[64],"showUp":[64]},[[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-configurator.cjs",[[2,"snk-configurator",{"configName":[1,"config-name"],"viewMode":[2,"view-mode"],"_opened":[32],"_permissions":[32],"open":[64],"close":[64]}]]],["snk-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-filter-bar.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32],"scrollerLocked":[32]},[[0,"filterChange","filterChangeListener"]]]]],["snk-grid-config.cjs",[[2,"snk-grid-config",{"selectedIndex":[1026,"selected-index"],"application":[16],"columns":[1040],"config":[1040],"configName":[1,"config-name"]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["snk-data-unit.cjs",[[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],"getSelectedRecordsIDsInfo":[64]}]]],["snk-field-config.cjs",[[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-tab-config.cjs",[[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-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"configManager":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-taskbar.cjs",[[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"presentationMode":[1537,"presentation-mode"],"_permissions":[32]}]]],["snk-filter-item.cjs",[[0,"snk-filter-item",{"config":[1040],"getMessage":[16],"detailIsVisible":[32],"showUp":[64],"hideDetail":[64]},[[2,"click","clickListener"],[2,"mousedown","mouseDownListener"],[0,"filterChange","filterChangeListener"]]]]],["snk-filter-list.cjs",[[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"]]]]],["snk-select-box.cjs",[[1,"snk-select-box",{"selectedOption":[1,"selected-option"]}]]],["snk-exporter-email-sender.cjs",[[0,"snk-exporter-email-sender",{"getMessage":[16],"_config":[32],"_opened":[32],"_currentStep":[32],"open":[64],"close":[64]}]]],["snk-data-exporter.cjs",[[2,"snk-data-exporter",{"provider":[16],"_items":[32],"_showDropdown":[32],"_releasedToExport":[32]}]]],["snk-guides-viewer.cjs",[[2,"snk-guides-viewer",{"dataUnit":[16],"dataState":[16],"configName":[1,"config-name"],"entityPath":[1,"entity-path"],"actionsList":[16],"recordsValidator":[16],"masterFormConfig":[1040],"selectedGuide":[16],"taskbarManager":[16],"presentationMode":[1,"presentation-mode"],"_breadcrumbItems":[32],"_guides":[32],"_formEditorConfigManager":[32],"_formEditorDataUnit":[32],"showFormConfig":[64]},[[2,"actionClick","onActionClick"],[0,"snkContentCardChanged","onContentCardChanged"]]]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_currentViewMode":[32],"goToView":[64]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"_dataUnit":[32],"_dataState":[32],"_showFormConfig":[32],"_configManager":[32],"showConfig":[64],"hideConfig":[64]}]]],["snk-application.cjs",[[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],"webConnection":[64],"createDataunit":[64],"updateDataunitCache":[64],"getDataUnit":[64],"addClientEvent":[64],"removeClientEvent":[64],"hasClientEvent":[64],"getResourceID":[64],"getUserID":[64],"alert":[64],"error":[64],"success":[64],"message":[64],"confirm":[64],"info":[64],"loadGridConfig":[64],"loadTotals":[64],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64],"getAppLabel":[64],"addSearchListener":[64]}]]],["snk-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-grid.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"isDetail":[4,"is-detail"],"taskbarManager":[16],"statusResolver":[16],"multipleSelection":[4,"multiple-selection"],"presentationMode":[1,"presentation-mode"],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"_popUpGridConfig":[32],"showConfig":[64],"hideConfig":[64],"setConfig":[64]}]]],["snk-form-summary.cjs",[[2,"snk-form-summary",{"fixed":[1540],"contracted":[1540],"summary":[16]}]]],["snk-form-view.cjs",[[6,"snk-form-view",{"levelPath":[1,"level-path"],"label":[1],"name":[1],"fields":[16],"formMetadata":[8,"form-metadata"],"dataUnit":[16],"contracted":[4],"fixed":[1540],"summaryFields":[16],"canExpand":[4,"can-expand"],"canFix":[4,"can-fix"],"recordsValidator":[16],"showUp":[64]}]]],["snk-filter-modal.cjs",[[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]}]]]], options);
|
21
21
|
});
|
22
22
|
|
23
23
|
exports.setNonce = index.setNonce;
|
@@ -1027,7 +1027,10 @@ const SnkApplication = class {
|
|
1027
1027
|
params: dependency.masterFields.map(fieldName => {
|
1028
1028
|
const masterDescriptor = dataUnit.getField(fieldName);
|
1029
1029
|
const dataType = (masterDescriptor === null || masterDescriptor === void 0 ? void 0 : masterDescriptor.dataType) || core.DataType.TEXT;
|
1030
|
-
|
1030
|
+
let value = dataUnit.getFieldValue(fieldName);
|
1031
|
+
if (dataType == core.DataType.OBJECT) {
|
1032
|
+
value = JSON.stringify(value);
|
1033
|
+
}
|
1031
1034
|
if (value == undefined) {
|
1032
1035
|
this.alert("Erro ao pesquisar", `É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
1033
1036
|
throw new Error(`É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
@@ -204,7 +204,7 @@ const SnkDetailView = class {
|
|
204
204
|
render() {
|
205
205
|
this.updateLabel();
|
206
206
|
//const cardConfig: IFormCardConfig = this._cardsState?.get(this.selectedForm);
|
207
|
-
return (index.h(index.Host, null, index.h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, index.h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, index.h("stack-item", null, index.h("div", { class: "ez-box ez-box--shadow grid-container" }, index.h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, index.h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? index.h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), index.h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(constants.VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: index$1.PresentationMode.SECONDARY }))), index.h("stack-item", null, index.h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, index.h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: index$1.PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
207
|
+
return (index.h(index.Host, null, index.h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, index.h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, index.h("stack-item", null, index.h("div", { class: "ez-box ez-box--shadow grid-container" }, index.h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, index.h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? index.h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), index.h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(constants.VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: index$1.PresentationMode.SECONDARY, isDetail: true }))), index.h("stack-item", null, index.h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, index.h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: index$1.PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
208
208
|
}
|
209
209
|
static get watchers() { return {
|
210
210
|
"dataState": ["observerDataState"]
|
@@ -28,7 +28,9 @@ const SnkGrid = class {
|
|
28
28
|
});
|
29
29
|
this._headerTaskbarProcessor = new taskbarProcessor.TaskbarProcessor({
|
30
30
|
"snkGridHeaderTaskbar.unselected": ["REFRESH", "DATA_EXPORTER"],
|
31
|
-
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"]
|
31
|
+
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"],
|
32
|
+
"snkGridHeaderTaskbar.detail.unselected": ["REFRESH"],
|
33
|
+
"snkGridHeaderTaskbar.detail.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH"]
|
32
34
|
});
|
33
35
|
this._dataUnit = undefined;
|
34
36
|
this._dataState = undefined;
|
@@ -36,6 +38,7 @@ const SnkGrid = class {
|
|
36
38
|
this._popUpGridConfig = false;
|
37
39
|
this.configName = undefined;
|
38
40
|
this.actionsList = undefined;
|
41
|
+
this.isDetail = undefined;
|
39
42
|
this.taskbarManager = undefined;
|
40
43
|
this.statusResolver = undefined;
|
41
44
|
this.multipleSelection = undefined;
|
@@ -244,7 +247,14 @@ const SnkGrid = class {
|
|
244
247
|
}
|
245
248
|
componentWillRender() {
|
246
249
|
const invisibleButtons = this._dataUnit && this._dataUnit.records.length > 0 ? [] : ["DATA_EXPORTER"];
|
247
|
-
const
|
250
|
+
const selectedRecord = this._dataState && this._dataState.selectedRecord;
|
251
|
+
let headerTaskbarId;
|
252
|
+
if (selectedRecord) {
|
253
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.selected" : "snkGridHeaderTaskbar.selected";
|
254
|
+
}
|
255
|
+
else {
|
256
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.unselected" : "snkGridHeaderTaskbar.unselected";
|
257
|
+
}
|
248
258
|
this._headerTaskbarProcessor.process(headerTaskbarId, this.taskbarManager, this._dataState, this.getHeaderDisabledButtons(), invisibleButtons);
|
249
259
|
this._topTaskbarProcessor.process(this.getTopTaskBarId(this.presentationMode === index$1.PresentationMode.SECONDARY ? ".secondary" : ""), this.taskbarManager, this._dataState, undefined, invisibleButtons);
|
250
260
|
this.dataExporterProviderStore();
|
@@ -0,0 +1,30 @@
|
|
1
|
+
'use strict';
|
2
|
+
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
4
|
+
|
5
|
+
const index = require('./index-21bd01e1.js');
|
6
|
+
const core = require('@sankhyalabs/core');
|
7
|
+
|
8
|
+
const snkSimpleBarCss = ".sc-snk-simple-bar-h{display:flex;height:100%;width:100%}.simple-bar__container.sc-snk-simple-bar{flex:1;display:flex;align-items:stretch;gap:var(--space--small)}.simple-bar__left-slot.sc-snk-simple-bar{min-width:280px;flex:1;display:flex;align-items:center}.simple-bar__right-slot.sc-snk-simple-bar{flex:1;display:flex;align-items:center;justify-content:flex-end}.simple-bar__column.sc-snk-simple-bar{flex:1;display:flex;flex-direction:column}";
|
9
|
+
|
10
|
+
const SnkSimpleBar = class {
|
11
|
+
constructor(hostRef) {
|
12
|
+
index.registerInstance(this, hostRef);
|
13
|
+
this.clickBreadcrumbItem = index.createEvent(this, "clickBreadcrumbItem", 3);
|
14
|
+
this.exit = index.createEvent(this, "exit", 3);
|
15
|
+
this.label = undefined;
|
16
|
+
this.breadcrumbItens = undefined;
|
17
|
+
}
|
18
|
+
componentDidLoad() {
|
19
|
+
if (!this._element)
|
20
|
+
return;
|
21
|
+
core.ElementIDUtils.addIDInfo(this._element);
|
22
|
+
}
|
23
|
+
render() {
|
24
|
+
return (index.h("div", { class: "simple-bar__container ez-margin-vertical--medium ez-padding--extra-small" }, index.h("div", { class: "simple-bar__left-slot" }, index.h("ez-button", { class: "ez-padding-right--medium", mode: 'icon', iconName: "arrow_back", size: 'medium', onClick: () => this.exit.emit() }), index.h("div", { class: "simple-bar__column" }, index.h("h1", { class: "ez-title ez-title--primary ez-title--extra-large" }, this.label), index.h("ez-breadcrumb", { items: this.breadcrumbItens, onSelectedItem: ({ detail }) => this.clickBreadcrumbItem.emit(detail) }))), index.h("div", { class: "simple-bar__right-slot" }, index.h("slot", { name: "rightSlot" }))));
|
25
|
+
}
|
26
|
+
get _element() { return index.getElement(this); }
|
27
|
+
};
|
28
|
+
SnkSimpleBar.style = snkSimpleBarCss;
|
29
|
+
|
30
|
+
exports.snk_simple_bar = SnkSimpleBar;
|
@@ -34,6 +34,7 @@
|
|
34
34
|
"./components/snk-grid/subcomponents/snk-select-box/snk-select-box.js",
|
35
35
|
"./components/snk-personalized-filter/subcomponents/snk-filter-param-config/snk-filter-param-config.js",
|
36
36
|
"./components/snk-pesquisa/snk-pesquisa.js",
|
37
|
+
"./components/snk-simple-bar/snk-simple-bar.js",
|
37
38
|
"./components/snk-simple-crud/snk-simple-crud.js",
|
38
39
|
"./components/teste-pesquisa/teste-pesquisa.js"
|
39
40
|
],
|
@@ -493,7 +493,10 @@ export class SnkApplication {
|
|
493
493
|
params: dependency.masterFields.map(fieldName => {
|
494
494
|
const masterDescriptor = dataUnit.getField(fieldName);
|
495
495
|
const dataType = (masterDescriptor === null || masterDescriptor === void 0 ? void 0 : masterDescriptor.dataType) || DataType.TEXT;
|
496
|
-
|
496
|
+
let value = dataUnit.getFieldValue(fieldName);
|
497
|
+
if (dataType == DataType.OBJECT) {
|
498
|
+
value = JSON.stringify(value);
|
499
|
+
}
|
497
500
|
if (value == undefined) {
|
498
501
|
this.alert("Erro ao pesquisar", `É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
499
502
|
throw new Error(`É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
@@ -186,7 +186,7 @@ export class SnkDetailView {
|
|
186
186
|
render() {
|
187
187
|
this.updateLabel();
|
188
188
|
//const cardConfig: IFormCardConfig = this._cardsState?.get(this.selectedForm);
|
189
|
-
return (h(Host, null, h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: PresentationMode.SECONDARY }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
189
|
+
return (h(Host, null, h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: PresentationMode.SECONDARY, isDetail: true }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
190
190
|
}
|
191
191
|
static get is() { return "snk-detail-view"; }
|
192
192
|
static get encapsulation() { return "scoped"; }
|
@@ -15,7 +15,9 @@ export class SnkGrid {
|
|
15
15
|
});
|
16
16
|
this._headerTaskbarProcessor = new TaskbarProcessor({
|
17
17
|
"snkGridHeaderTaskbar.unselected": ["REFRESH", "DATA_EXPORTER"],
|
18
|
-
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"]
|
18
|
+
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"],
|
19
|
+
"snkGridHeaderTaskbar.detail.unselected": ["REFRESH"],
|
20
|
+
"snkGridHeaderTaskbar.detail.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH"]
|
19
21
|
});
|
20
22
|
this._dataUnit = undefined;
|
21
23
|
this._dataState = undefined;
|
@@ -23,6 +25,7 @@ export class SnkGrid {
|
|
23
25
|
this._popUpGridConfig = false;
|
24
26
|
this.configName = undefined;
|
25
27
|
this.actionsList = undefined;
|
28
|
+
this.isDetail = undefined;
|
26
29
|
this.taskbarManager = undefined;
|
27
30
|
this.statusResolver = undefined;
|
28
31
|
this.multipleSelection = undefined;
|
@@ -231,7 +234,14 @@ export class SnkGrid {
|
|
231
234
|
}
|
232
235
|
componentWillRender() {
|
233
236
|
const invisibleButtons = this._dataUnit && this._dataUnit.records.length > 0 ? [] : ["DATA_EXPORTER"];
|
234
|
-
const
|
237
|
+
const selectedRecord = this._dataState && this._dataState.selectedRecord;
|
238
|
+
let headerTaskbarId;
|
239
|
+
if (selectedRecord) {
|
240
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.selected" : "snkGridHeaderTaskbar.selected";
|
241
|
+
}
|
242
|
+
else {
|
243
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.unselected" : "snkGridHeaderTaskbar.unselected";
|
244
|
+
}
|
235
245
|
this._headerTaskbarProcessor.process(headerTaskbarId, this.taskbarManager, this._dataState, this.getHeaderDisabledButtons(), invisibleButtons);
|
236
246
|
this._topTaskbarProcessor.process(this.getTopTaskBarId(this.presentationMode === PresentationMode.SECONDARY ? ".secondary" : ""), this.taskbarManager, this._dataState, undefined, invisibleButtons);
|
237
247
|
this.dataExporterProviderStore();
|
@@ -308,6 +318,23 @@ export class SnkGrid {
|
|
308
318
|
"text": "Lista de a\u00E7\u00F5es que devem ser usadas no bot\u00E3o \"Mais op\u00E7\u00F5es\" do componente snk-taskbar."
|
309
319
|
}
|
310
320
|
},
|
321
|
+
"isDetail": {
|
322
|
+
"type": "boolean",
|
323
|
+
"mutable": false,
|
324
|
+
"complexType": {
|
325
|
+
"original": "boolean",
|
326
|
+
"resolved": "boolean",
|
327
|
+
"references": {}
|
328
|
+
},
|
329
|
+
"required": false,
|
330
|
+
"optional": false,
|
331
|
+
"docs": {
|
332
|
+
"tags": [],
|
333
|
+
"text": "Determina se a grade est\u00E1 vinculada a um detalhe."
|
334
|
+
},
|
335
|
+
"attribute": "is-detail",
|
336
|
+
"reflect": false
|
337
|
+
},
|
311
338
|
"taskbarManager": {
|
312
339
|
"type": "unknown",
|
313
340
|
"mutable": false,
|
@@ -0,0 +1,32 @@
|
|
1
|
+
:host {
|
2
|
+
display: flex;
|
3
|
+
height: 100%;
|
4
|
+
width: 100%;
|
5
|
+
}
|
6
|
+
|
7
|
+
.simple-bar__container{
|
8
|
+
flex: 1;
|
9
|
+
display: flex;
|
10
|
+
align-items: stretch;
|
11
|
+
gap: var(--space--small);
|
12
|
+
}
|
13
|
+
|
14
|
+
.simple-bar__left-slot {
|
15
|
+
min-width: 280px;
|
16
|
+
flex: 1;
|
17
|
+
display: flex;
|
18
|
+
align-items: center;
|
19
|
+
}
|
20
|
+
|
21
|
+
.simple-bar__right-slot {
|
22
|
+
flex: 1;
|
23
|
+
display: flex;
|
24
|
+
align-items: center;
|
25
|
+
justify-content: flex-end;
|
26
|
+
}
|
27
|
+
|
28
|
+
.simple-bar__column {
|
29
|
+
flex: 1;
|
30
|
+
display: flex;
|
31
|
+
flex-direction: column;
|
32
|
+
}
|
@@ -0,0 +1,111 @@
|
|
1
|
+
import { h } from '@stencil/core';
|
2
|
+
import { ElementIDUtils } from '@sankhyalabs/core';
|
3
|
+
export class SnkSimpleBar {
|
4
|
+
constructor() {
|
5
|
+
this.label = undefined;
|
6
|
+
this.breadcrumbItens = undefined;
|
7
|
+
}
|
8
|
+
componentDidLoad() {
|
9
|
+
if (!this._element)
|
10
|
+
return;
|
11
|
+
ElementIDUtils.addIDInfo(this._element);
|
12
|
+
}
|
13
|
+
render() {
|
14
|
+
return (h("div", { class: "simple-bar__container ez-margin-vertical--medium ez-padding--extra-small" }, h("div", { class: "simple-bar__left-slot" }, h("ez-button", { class: "ez-padding-right--medium", mode: 'icon', iconName: "arrow_back", size: 'medium', onClick: () => this.exit.emit() }), h("div", { class: "simple-bar__column" }, h("h1", { class: "ez-title ez-title--primary ez-title--extra-large" }, this.label), h("ez-breadcrumb", { items: this.breadcrumbItens, onSelectedItem: ({ detail }) => this.clickBreadcrumbItem.emit(detail) }))), h("div", { class: "simple-bar__right-slot" }, h("slot", { name: "rightSlot" }))));
|
15
|
+
}
|
16
|
+
static get is() { return "snk-simple-bar"; }
|
17
|
+
static get encapsulation() { return "scoped"; }
|
18
|
+
static get originalStyleUrls() {
|
19
|
+
return {
|
20
|
+
"$": ["snk-simple-bar.css"]
|
21
|
+
};
|
22
|
+
}
|
23
|
+
static get styleUrls() {
|
24
|
+
return {
|
25
|
+
"$": ["snk-simple-bar.css"]
|
26
|
+
};
|
27
|
+
}
|
28
|
+
static get properties() {
|
29
|
+
return {
|
30
|
+
"label": {
|
31
|
+
"type": "string",
|
32
|
+
"mutable": false,
|
33
|
+
"complexType": {
|
34
|
+
"original": "string",
|
35
|
+
"resolved": "string",
|
36
|
+
"references": {}
|
37
|
+
},
|
38
|
+
"required": false,
|
39
|
+
"optional": false,
|
40
|
+
"docs": {
|
41
|
+
"tags": [],
|
42
|
+
"text": "Define o t\u00EDtulo do header"
|
43
|
+
},
|
44
|
+
"attribute": "label",
|
45
|
+
"reflect": false
|
46
|
+
},
|
47
|
+
"breadcrumbItens": {
|
48
|
+
"type": "unknown",
|
49
|
+
"mutable": false,
|
50
|
+
"complexType": {
|
51
|
+
"original": "Array<IBreadcrumbItem>",
|
52
|
+
"resolved": "IBreadcrumbItem[]",
|
53
|
+
"references": {
|
54
|
+
"Array": {
|
55
|
+
"location": "global"
|
56
|
+
},
|
57
|
+
"IBreadcrumbItem": {
|
58
|
+
"location": "import",
|
59
|
+
"path": "@sankhyalabs/ezui/dist/types/components/ez-breadcrumb/ez-breadcrumb"
|
60
|
+
}
|
61
|
+
}
|
62
|
+
},
|
63
|
+
"required": false,
|
64
|
+
"optional": false,
|
65
|
+
"docs": {
|
66
|
+
"tags": [],
|
67
|
+
"text": "Define os itens que ser\u00E3o apresentados pelo breadcrumb"
|
68
|
+
}
|
69
|
+
}
|
70
|
+
};
|
71
|
+
}
|
72
|
+
static get events() {
|
73
|
+
return [{
|
74
|
+
"method": "clickBreadcrumbItem",
|
75
|
+
"name": "clickBreadcrumbItem",
|
76
|
+
"bubbles": false,
|
77
|
+
"cancelable": true,
|
78
|
+
"composed": true,
|
79
|
+
"docs": {
|
80
|
+
"tags": [],
|
81
|
+
"text": "Emitido quando algum item do breadcrumb \u00E9 clicado"
|
82
|
+
},
|
83
|
+
"complexType": {
|
84
|
+
"original": "IBreadcrumbItem",
|
85
|
+
"resolved": "IBreadcrumbItem",
|
86
|
+
"references": {
|
87
|
+
"IBreadcrumbItem": {
|
88
|
+
"location": "import",
|
89
|
+
"path": "@sankhyalabs/ezui/dist/types/components/ez-breadcrumb/ez-breadcrumb"
|
90
|
+
}
|
91
|
+
}
|
92
|
+
}
|
93
|
+
}, {
|
94
|
+
"method": "exit",
|
95
|
+
"name": "exit",
|
96
|
+
"bubbles": false,
|
97
|
+
"cancelable": true,
|
98
|
+
"composed": true,
|
99
|
+
"docs": {
|
100
|
+
"tags": [],
|
101
|
+
"text": "Emitido quando o bot\u00E3o voltar \u00E9 acionado"
|
102
|
+
},
|
103
|
+
"complexType": {
|
104
|
+
"original": "void",
|
105
|
+
"resolved": "void",
|
106
|
+
"references": {}
|
107
|
+
}
|
108
|
+
}];
|
109
|
+
}
|
110
|
+
static get elementRef() { return "_element"; }
|
111
|
+
}
|
@@ -31,6 +31,7 @@ export { SnkGridConfig as SnkGridConfig } from '../types/components/snk-grid/sub
|
|
31
31
|
export { SnkGuidesViewer as SnkGuidesViewer } from '../types/components/snk-crud/subcomponents/snk-guides-viewer';
|
32
32
|
export { SnkPesquisa as SnkPesquisa } from '../types/components/snk-pesquisa/snk-pesquisa';
|
33
33
|
export { SelectBox as SnkSelectBox } from '../types/components/snk-grid/subcomponents/snk-select-box/snk-select-box';
|
34
|
+
export { SnkSimpleBar as SnkSimpleBar } from '../types/components/snk-simple-bar/snk-simple-bar';
|
34
35
|
export { SnkSimpleCrud as SnkSimpleCrud } from '../types/components/snk-simple-crud/snk-simple-crud';
|
35
36
|
export { SnkTabConfig as SnkTabConfig } from '../types/components/snk-form/subcomponents/snk-tab-config/snk-tab-config';
|
36
37
|
export { SnkTaskbar as SnkTaskbar } from '../types/components/snk-taskbar/snk-taskbar';
|
package/dist/components/index.js
CHANGED
@@ -31,6 +31,7 @@ export { SnkGridConfig, defineCustomElement as defineCustomElementSnkGridConfig
|
|
31
31
|
export { SnkGuidesViewer, defineCustomElement as defineCustomElementSnkGuidesViewer } from './snk-guides-viewer.js';
|
32
32
|
export { SnkPesquisa, defineCustomElement as defineCustomElementSnkPesquisa } from './snk-pesquisa.js';
|
33
33
|
export { SnkSelectBox, defineCustomElement as defineCustomElementSnkSelectBox } from './snk-select-box.js';
|
34
|
+
export { SnkSimpleBar, defineCustomElement as defineCustomElementSnkSimpleBar } from './snk-simple-bar.js';
|
34
35
|
export { SnkSimpleCrud, defineCustomElement as defineCustomElementSnkSimpleCrud } from './snk-simple-crud.js';
|
35
36
|
export { SnkTabConfig, defineCustomElement as defineCustomElementSnkTabConfig } from './snk-tab-config.js';
|
36
37
|
export { SnkTaskbar, defineCustomElement as defineCustomElementSnkTaskbar } from './snk-taskbar.js';
|
@@ -1024,7 +1024,10 @@ const SnkApplication = /*@__PURE__*/ proxyCustomElement(class extends HTMLElemen
|
|
1024
1024
|
params: dependency.masterFields.map(fieldName => {
|
1025
1025
|
const masterDescriptor = dataUnit.getField(fieldName);
|
1026
1026
|
const dataType = (masterDescriptor === null || masterDescriptor === void 0 ? void 0 : masterDescriptor.dataType) || DataType.TEXT;
|
1027
|
-
|
1027
|
+
let value = dataUnit.getFieldValue(fieldName);
|
1028
|
+
if (dataType == DataType.OBJECT) {
|
1029
|
+
value = JSON.stringify(value);
|
1030
|
+
}
|
1028
1031
|
if (value == undefined) {
|
1029
1032
|
this.alert("Erro ao pesquisar", `É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
1030
1033
|
throw new Error(`É necessario informar o campo ${masterDescriptor.label} para executar a pesquisa.`);
|
@@ -663,7 +663,7 @@ const SnkDetailView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
663
663
|
render() {
|
664
664
|
this.updateLabel();
|
665
665
|
//const cardConfig: IFormCardConfig = this._cardsState?.get(this.selectedForm);
|
666
|
-
return (h(Host, null, h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: PresentationMode.SECONDARY }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
666
|
+
return (h(Host, null, h("snk-data-unit", { dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: evt => this.dataState = evt.detail }, h("ez-view-stack", { ref: ref => this.updateViewStack(ref) }, h("stack-item", null, h("div", { class: "ez-box ez-box--shadow grid-container" }, h("div", { class: "ez-flex ez-size-width--full ez-padding--large detail-header" }, h("div", { class: "ez-flex ez-text ez-text--bold ez-flex--justify-start ez-flex--align-items-center" }, this._levelPath ? h("span", { class: "level-path" }, this._levelPath + " /") : undefined, this.label)), h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => this._snkGrid = ref, configName: this._configName, onGridDoubleClick: () => this.emitSwitchEvent(VIEW_MODE.FORM), onActionClick: evt => this.executeActionHandler(evt), presentationMode: PresentationMode.SECONDARY, isDetail: true }))), h("stack-item", null, h("snk-form-view", { ref: (ref) => this._snkFormView = ref, canExpand: false, canFix: false, name: this.selectedForm, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), label: this.label, levelPath: this._levelPath }, h("snk-taskbar", { key: "guideViewerTaskbar", class: "form-taskbar", "data-element-id": "guideViewer", configName: this._configName, disabledButtons: this._disabledButtons, buttons: "INSERT,PREVIOUS,NEXT,DIVIDER,CLONE,REMOVE,MORE_OPTIONS,DIVIDER,GRID_MODE,CONFIGURATOR", primaryButton: "INSERT", presentationMode: PresentationMode.SECONDARY, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit })))))));
|
667
667
|
}
|
668
668
|
static get watchers() { return {
|
669
669
|
"dataState": ["observerDataState"]
|
@@ -31,7 +31,9 @@ const SnkGrid = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
31
31
|
});
|
32
32
|
this._headerTaskbarProcessor = new TaskbarProcessor({
|
33
33
|
"snkGridHeaderTaskbar.unselected": ["REFRESH", "DATA_EXPORTER"],
|
34
|
-
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"]
|
34
|
+
"snkGridHeaderTaskbar.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH", "DATA_EXPORTER"],
|
35
|
+
"snkGridHeaderTaskbar.detail.unselected": ["REFRESH"],
|
36
|
+
"snkGridHeaderTaskbar.detail.selected": ["UPDATE", "CLONE", "REMOVE", "MORE_OPTIONS", "DIVIDER", "REFRESH"]
|
35
37
|
});
|
36
38
|
this._dataUnit = undefined;
|
37
39
|
this._dataState = undefined;
|
@@ -39,6 +41,7 @@ const SnkGrid = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
39
41
|
this._popUpGridConfig = false;
|
40
42
|
this.configName = undefined;
|
41
43
|
this.actionsList = undefined;
|
44
|
+
this.isDetail = undefined;
|
42
45
|
this.taskbarManager = undefined;
|
43
46
|
this.statusResolver = undefined;
|
44
47
|
this.multipleSelection = undefined;
|
@@ -247,7 +250,14 @@ const SnkGrid = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
247
250
|
}
|
248
251
|
componentWillRender() {
|
249
252
|
const invisibleButtons = this._dataUnit && this._dataUnit.records.length > 0 ? [] : ["DATA_EXPORTER"];
|
250
|
-
const
|
253
|
+
const selectedRecord = this._dataState && this._dataState.selectedRecord;
|
254
|
+
let headerTaskbarId;
|
255
|
+
if (selectedRecord) {
|
256
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.selected" : "snkGridHeaderTaskbar.selected";
|
257
|
+
}
|
258
|
+
else {
|
259
|
+
headerTaskbarId = this.isDetail ? "snkGridHeaderTaskbar.detail.unselected" : "snkGridHeaderTaskbar.unselected";
|
260
|
+
}
|
251
261
|
this._headerTaskbarProcessor.process(headerTaskbarId, this.taskbarManager, this._dataState, this.getHeaderDisabledButtons(), invisibleButtons);
|
252
262
|
this._topTaskbarProcessor.process(this.getTopTaskBarId(this.presentationMode === PresentationMode.SECONDARY ? ".secondary" : ""), this.taskbarManager, this._dataState, undefined, invisibleButtons);
|
253
263
|
this.dataExporterProviderStore();
|
@@ -275,6 +285,7 @@ const SnkGrid = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
275
285
|
}, [6, "snk-grid", {
|
276
286
|
"configName": [1, "config-name"],
|
277
287
|
"actionsList": [16],
|
288
|
+
"isDetail": [4, "is-detail"],
|
278
289
|
"taskbarManager": [16],
|
279
290
|
"statusResolver": [16],
|
280
291
|
"multipleSelection": [4, "multiple-selection"],
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import type { Components, JSX } from "../types/components";
|
2
|
+
|
3
|
+
interface SnkSimpleBar extends Components.SnkSimpleBar, HTMLElement {}
|
4
|
+
export const SnkSimpleBar: {
|
5
|
+
prototype: SnkSimpleBar;
|
6
|
+
new (): SnkSimpleBar;
|
7
|
+
};
|
8
|
+
/**
|
9
|
+
* Used to define this component and all nested components recursively.
|
10
|
+
*/
|
11
|
+
export const defineCustomElement: () => void;
|
@@ -0,0 +1,46 @@
|
|
1
|
+
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
2
|
+
import { ElementIDUtils } from '@sankhyalabs/core';
|
3
|
+
|
4
|
+
const snkSimpleBarCss = ".sc-snk-simple-bar-h{display:flex;height:100%;width:100%}.simple-bar__container.sc-snk-simple-bar{flex:1;display:flex;align-items:stretch;gap:var(--space--small)}.simple-bar__left-slot.sc-snk-simple-bar{min-width:280px;flex:1;display:flex;align-items:center}.simple-bar__right-slot.sc-snk-simple-bar{flex:1;display:flex;align-items:center;justify-content:flex-end}.simple-bar__column.sc-snk-simple-bar{flex:1;display:flex;flex-direction:column}";
|
5
|
+
|
6
|
+
const SnkSimpleBar$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
7
|
+
constructor() {
|
8
|
+
super();
|
9
|
+
this.__registerHost();
|
10
|
+
this.clickBreadcrumbItem = createEvent(this, "clickBreadcrumbItem", 3);
|
11
|
+
this.exit = createEvent(this, "exit", 3);
|
12
|
+
this.label = undefined;
|
13
|
+
this.breadcrumbItens = undefined;
|
14
|
+
}
|
15
|
+
componentDidLoad() {
|
16
|
+
if (!this._element)
|
17
|
+
return;
|
18
|
+
ElementIDUtils.addIDInfo(this._element);
|
19
|
+
}
|
20
|
+
render() {
|
21
|
+
return (h("div", { class: "simple-bar__container ez-margin-vertical--medium ez-padding--extra-small" }, h("div", { class: "simple-bar__left-slot" }, h("ez-button", { class: "ez-padding-right--medium", mode: 'icon', iconName: "arrow_back", size: 'medium', onClick: () => this.exit.emit() }), h("div", { class: "simple-bar__column" }, h("h1", { class: "ez-title ez-title--primary ez-title--extra-large" }, this.label), h("ez-breadcrumb", { items: this.breadcrumbItens, onSelectedItem: ({ detail }) => this.clickBreadcrumbItem.emit(detail) }))), h("div", { class: "simple-bar__right-slot" }, h("slot", { name: "rightSlot" }))));
|
22
|
+
}
|
23
|
+
get _element() { return this; }
|
24
|
+
static get style() { return snkSimpleBarCss; }
|
25
|
+
}, [6, "snk-simple-bar", {
|
26
|
+
"label": [1],
|
27
|
+
"breadcrumbItens": [16]
|
28
|
+
}]);
|
29
|
+
function defineCustomElement$1() {
|
30
|
+
if (typeof customElements === "undefined") {
|
31
|
+
return;
|
32
|
+
}
|
33
|
+
const components = ["snk-simple-bar"];
|
34
|
+
components.forEach(tagName => { switch (tagName) {
|
35
|
+
case "snk-simple-bar":
|
36
|
+
if (!customElements.get(tagName)) {
|
37
|
+
customElements.define(tagName, SnkSimpleBar$1);
|
38
|
+
}
|
39
|
+
break;
|
40
|
+
} });
|
41
|
+
}
|
42
|
+
|
43
|
+
const SnkSimpleBar = SnkSimpleBar$1;
|
44
|
+
const defineCustomElement = defineCustomElement$1;
|
45
|
+
|
46
|
+
export { SnkSimpleBar, defineCustomElement };
|