@sankhyalabs/sankhyablocks 1.4.0-beta.8 → 2.0.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/{constants-aebcc2f5.js → constants-9056ca9e.js} +15 -0
- package/dist/cjs/{index-188190ee.js → index-20e8b68a.js} +48 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/sankhyablocks.cjs.js +2 -2
- package/dist/cjs/snk-application.cjs.entry.js +27 -21
- package/dist/cjs/snk-config-modal.cjs.entry.js +3 -3
- package/dist/cjs/snk-config-options.cjs.entry.js +139 -72
- package/dist/cjs/snk-configurator_6.cjs.entry.js +5 -5
- package/dist/cjs/snk-crud.cjs.entry.js +3 -3
- package/dist/cjs/snk-data-unit.cjs.entry.js +2 -2
- package/dist/cjs/snk-field-config_2.cjs.entry.js +8 -3
- package/dist/cjs/snk-filter-binary-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-detail.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-number.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-period.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-personalized.cjs.entry.js +3 -2
- package/dist/cjs/snk-filter-search.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-text.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-config.cjs.entry.js +29 -18
- package/dist/cjs/snk-form.cjs.entry.js +1 -1
- package/dist/cjs/snk-pesquisa.cjs.entry.js +1 -1
- package/dist/cjs/snk-tab-config.cjs.entry.js +3 -3
- package/dist/cjs/{taskbar-elements-4c2c6704.js → taskbar-elements-9a4b1e19.js} +1 -1
- package/dist/cjs/teste-pesquisa.cjs.entry.js +1 -1
- package/dist/collection/components/snk-application/snk-application.js +27 -5
- package/dist/collection/components/snk-configurator/subcomponents/snk-config-modal/snk-config-modal.css +2 -2
- package/dist/collection/components/snk-data-unit/snk-data-unit.js +1 -1
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-personalized.js +2 -1
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +3 -2
- package/dist/collection/components/snk-form/subcomponents/snk-config-options/snk-config-options.js +139 -72
- package/dist/collection/components/snk-form/subcomponents/snk-field-config/snk-field-config.js +26 -1
- package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.css +1 -1
- package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.js +27 -16
- package/dist/collection/components/snk-form/subcomponents/snk-tab-config/snk-tab-config.css +1 -1
- package/dist/collection/lib/http/data-fetcher/fetchers/parameters-fecher.js +15 -15
- package/dist/collection/lib/utils/constants.js +14 -0
- package/dist/components/constants.js +15 -1
- package/dist/components/snk-application2.js +27 -20
- package/dist/components/snk-config-modal2.js +1 -1
- package/dist/components/snk-config-options2.js +139 -72
- package/dist/components/snk-data-unit.js +1 -1
- package/dist/components/snk-field-config2.js +8 -2
- package/dist/components/snk-filter-modal2.js +3 -2
- package/dist/components/snk-filter-personalized.js +2 -1
- package/dist/components/snk-form-config2.js +28 -17
- package/dist/components/snk-tab-config2.js +2 -2
- package/dist/esm/{constants-c4e3341e.js → constants-c6039d3d.js} +15 -1
- package/dist/esm/{index-bafb2cef.js → index-e4121713.js} +48 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm/sankhyablocks.js +2 -2
- package/dist/esm/snk-application.entry.js +27 -21
- package/dist/esm/snk-config-modal.entry.js +3 -3
- package/dist/esm/snk-config-options.entry.js +140 -73
- package/dist/esm/snk-configurator_6.entry.js +6 -6
- package/dist/esm/snk-crud.entry.js +3 -3
- package/dist/esm/snk-data-unit.entry.js +2 -2
- package/dist/esm/snk-field-config_2.entry.js +8 -3
- package/dist/esm/snk-filter-binary-select.entry.js +1 -1
- package/dist/esm/snk-filter-detail.entry.js +1 -1
- package/dist/esm/snk-filter-multi-select.entry.js +1 -1
- package/dist/esm/snk-filter-number.entry.js +1 -1
- package/dist/esm/snk-filter-period.entry.js +1 -1
- package/dist/esm/snk-filter-personalized.entry.js +3 -2
- package/dist/esm/snk-filter-search.entry.js +1 -1
- package/dist/esm/snk-filter-text.entry.js +1 -1
- package/dist/esm/snk-form-config.entry.js +29 -18
- package/dist/esm/snk-form.entry.js +1 -1
- package/dist/esm/snk-pesquisa.entry.js +1 -1
- package/dist/esm/snk-tab-config.entry.js +3 -3
- package/dist/esm/{taskbar-elements-2035b1c7.js → taskbar-elements-e2ed0536.js} +1 -1
- package/dist/esm/teste-pesquisa.entry.js +1 -1
- package/dist/sankhyablocks/{p-8cd8977c.entry.js → p-029ae4e4.entry.js} +1 -1
- package/dist/sankhyablocks/p-12ad2a19.entry.js +1 -0
- package/dist/sankhyablocks/{p-1963b46f.entry.js → p-2b891c4a.entry.js} +1 -1
- package/dist/sankhyablocks/{p-d1ae76ec.entry.js → p-2dc76d79.entry.js} +1 -1
- package/dist/sankhyablocks/{p-916068ff.entry.js → p-3a276f3d.entry.js} +1 -1
- package/dist/sankhyablocks/{p-31631fb6.entry.js → p-400cc777.entry.js} +1 -1
- package/dist/sankhyablocks/p-4392f13f.entry.js +1 -0
- package/dist/sankhyablocks/{p-ccdf59eb.entry.js → p-44ce5b90.entry.js} +1 -1
- package/dist/sankhyablocks/p-521c96f0.entry.js +1 -0
- package/dist/sankhyablocks/p-60eef7cd.entry.js +1 -0
- package/dist/sankhyablocks/{p-6c61416a.entry.js → p-6988f4a6.entry.js} +1 -1
- package/dist/sankhyablocks/p-9ba3df4c.js +2 -0
- package/dist/sankhyablocks/{p-cc85ba53.entry.js → p-9dc4426d.entry.js} +1 -1
- package/dist/sankhyablocks/{p-ee906940.entry.js → p-a17a4fca.entry.js} +1 -1
- package/dist/sankhyablocks/p-a5b26df2.js +1 -0
- package/dist/sankhyablocks/{p-f9084ecb.entry.js → p-cc4bef9f.entry.js} +1 -1
- package/dist/sankhyablocks/p-d690b6b5.entry.js +75 -0
- package/dist/sankhyablocks/{p-ad658f44.js → p-d9fbb26f.js} +1 -1
- package/dist/sankhyablocks/{p-857c4735.entry.js → p-deb1f523.entry.js} +1 -1
- package/dist/sankhyablocks/p-e871aa92.entry.js +1 -0
- package/dist/sankhyablocks/{p-04ad681a.entry.js → p-e9beab79.entry.js} +1 -1
- package/dist/sankhyablocks/p-eb23420d.entry.js +1 -0
- package/dist/sankhyablocks/p-f37cdeb5.entry.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-application/snk-application.d.ts +4 -0
- package/dist/types/components/snk-form/subcomponents/snk-config-options/snk-config-options.d.ts +17 -7
- package/dist/types/components/snk-form/subcomponents/snk-field-config/snk-field-config.d.ts +6 -0
- package/dist/types/components.d.ts +12 -0
- package/dist/types/lib/http/data-fetcher/fetchers/parameters-fecher.d.ts +7 -7
- package/dist/types/lib/utils/constants.d.ts +14 -0
- package/package.json +5 -5
- package/dist/sankhyablocks/p-26c503a6.entry.js +0 -1
- package/dist/sankhyablocks/p-434e0dcf.entry.js +0 -1
- package/dist/sankhyablocks/p-9f2c5fac.entry.js +0 -1
- package/dist/sankhyablocks/p-ae302037.entry.js +0 -75
- package/dist/sankhyablocks/p-af11b0e7.js +0 -1
- package/dist/sankhyablocks/p-af306302.entry.js +0 -1
- package/dist/sankhyablocks/p-ce789145.entry.js +0 -1
- package/dist/sankhyablocks/p-cf81e313.entry.js +0 -1
- package/dist/sankhyablocks/p-ddb03141.js +0 -2
- package/dist/sankhyablocks/p-fa75fba5.entry.js +0 -1
|
@@ -58,12 +58,27 @@ const TYPE_ACTIONS = {
|
|
|
58
58
|
const TAB_NAMES = {
|
|
59
59
|
main: "__main"
|
|
60
60
|
};
|
|
61
|
+
const TAGS_BY_TYPE = {
|
|
62
|
+
LONGTEXT: "ez-text-area",
|
|
63
|
+
FILE: "ez-upload",
|
|
64
|
+
DATE: "ez-date-input",
|
|
65
|
+
TIME: "ez-time",
|
|
66
|
+
DATETIME: "ez-date-time-input",
|
|
67
|
+
DEFAULT: "ez-text-input",
|
|
68
|
+
SWITCH: "ez-check",
|
|
69
|
+
CHECKBOX: "ez-check",
|
|
70
|
+
OPTIONSELECTOR: "ez-combo-box",
|
|
71
|
+
SEARCH: "ez-search",
|
|
72
|
+
INTEGERNUMBER: "ez-number-input",
|
|
73
|
+
DECIMALNUMBER: "ez-number-input"
|
|
74
|
+
};
|
|
61
75
|
|
|
62
76
|
exports.ACTION_CONFIG = ACTION_CONFIG;
|
|
63
77
|
exports.CONFIG_EVENTS = CONFIG_EVENTS;
|
|
64
78
|
exports.DEFAULT_TYPE = DEFAULT_TYPE;
|
|
65
79
|
exports.KEY_EVENTS = KEY_EVENTS;
|
|
66
80
|
exports.TAB_NAMES = TAB_NAMES;
|
|
81
|
+
exports.TAGS_BY_TYPE = TAGS_BY_TYPE;
|
|
67
82
|
exports.TYPE_ACTIONS = TYPE_ACTIONS;
|
|
68
83
|
exports.VARS_BY_TYPE = VARS_BY_TYPE;
|
|
69
84
|
exports.VIEW_MODE = VIEW_MODE;
|
|
@@ -53,6 +53,7 @@ const uniqueTime = (key, measureText) => {
|
|
|
53
53
|
}
|
|
54
54
|
};
|
|
55
55
|
const HYDRATED_CSS = '{visibility:hidden}.hydrated{visibility:inherit}';
|
|
56
|
+
const XLINK_NS = 'http://www.w3.org/1999/xlink';
|
|
56
57
|
/**
|
|
57
58
|
* Default style mode id
|
|
58
59
|
*/
|
|
@@ -361,6 +362,31 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
361
362
|
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
362
363
|
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
363
364
|
}
|
|
365
|
+
else if (memberName === 'style') {
|
|
366
|
+
// update style attribute, css properties and values
|
|
367
|
+
{
|
|
368
|
+
for (const prop in oldValue) {
|
|
369
|
+
if (!newValue || newValue[prop] == null) {
|
|
370
|
+
if (prop.includes('-')) {
|
|
371
|
+
elm.style.removeProperty(prop);
|
|
372
|
+
}
|
|
373
|
+
else {
|
|
374
|
+
elm.style[prop] = '';
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
for (const prop in newValue) {
|
|
380
|
+
if (!oldValue || newValue[prop] !== oldValue[prop]) {
|
|
381
|
+
if (prop.includes('-')) {
|
|
382
|
+
elm.style.setProperty(prop, newValue[prop]);
|
|
383
|
+
}
|
|
384
|
+
else {
|
|
385
|
+
elm.style[prop] = newValue[prop];
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
}
|
|
364
390
|
else if (memberName === 'key')
|
|
365
391
|
;
|
|
366
392
|
else if (memberName === 'ref') {
|
|
@@ -429,16 +455,36 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
429
455
|
}
|
|
430
456
|
catch (e) { }
|
|
431
457
|
}
|
|
458
|
+
/**
|
|
459
|
+
* Need to manually update attribute if:
|
|
460
|
+
* - memberName is not an attribute
|
|
461
|
+
* - if we are rendering the host element in order to reflect attribute
|
|
462
|
+
* - if it's a SVG, since properties might not work in <svg>
|
|
463
|
+
* - if the newValue is null/undefined or 'false'.
|
|
464
|
+
*/
|
|
465
|
+
let xlink = false;
|
|
466
|
+
{
|
|
467
|
+
if (ln !== (ln = ln.replace(/^xlink\:?/, ''))) {
|
|
468
|
+
memberName = ln;
|
|
469
|
+
xlink = true;
|
|
470
|
+
}
|
|
471
|
+
}
|
|
432
472
|
if (newValue == null || newValue === false) {
|
|
433
473
|
if (newValue !== false || elm.getAttribute(memberName) === '') {
|
|
434
|
-
{
|
|
474
|
+
if (xlink) {
|
|
475
|
+
elm.removeAttributeNS(XLINK_NS, memberName);
|
|
476
|
+
}
|
|
477
|
+
else {
|
|
435
478
|
elm.removeAttribute(memberName);
|
|
436
479
|
}
|
|
437
480
|
}
|
|
438
481
|
}
|
|
439
482
|
else if ((!isProp || flags & 4 /* VNODE_FLAGS.isHost */ || isSvg) && !isComplex) {
|
|
440
483
|
newValue = newValue === true ? '' : newValue;
|
|
441
|
-
{
|
|
484
|
+
if (xlink) {
|
|
485
|
+
elm.setAttributeNS(XLINK_NS, memberName, newValue);
|
|
486
|
+
}
|
|
487
|
+
else {
|
|
442
488
|
elm.setAttribute(memberName, newValue);
|
|
443
489
|
}
|
|
444
490
|
}
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-20e8b68a.js');
|
|
6
6
|
|
|
7
7
|
/*
|
|
8
8
|
Stencil Client Patch Esm v2.18.1 | MIT Licensed | https://stenciljs.com
|
|
@@ -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([["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["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]}]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["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-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-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["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-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-field-config_2.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"setShowGridConfig":[64],"setConfig":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"]}]]],["snk-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"parentForm":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-config-modal.cjs",[[2,"snk-config-modal",{"configName":[1,"config-name"],"gridMode":[4,"grid-mode"]}]]],["snk-configurator_6.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32]},[[0,"filterChange","filterChangeListener"]]],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}],[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]}],[2,"snk-configurator",{"configName":[1,"config-name"],"name":[1],"enabled":[4]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"setShowFormConfig":[64],"setConfig":[64]}]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"goToView":[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],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[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],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
|
|
17
|
+
return index.bootstrapLazy([["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["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]}]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["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-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-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["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-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-field-config_2.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"setShowGridConfig":[64],"setConfig":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"parentForm":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-config-modal.cjs",[[2,"snk-config-modal",{"configName":[1,"config-name"],"gridMode":[4,"grid-mode"]}]]],["snk-configurator_6.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32]},[[0,"filterChange","filterChangeListener"]]],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}],[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]}],[2,"snk-configurator",{"configName":[1,"config-name"],"name":[1],"enabled":[4]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"setShowFormConfig":[64],"setConfig":[64]}]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"goToView":[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],"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],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-20e8b68a.js');
|
|
4
4
|
|
|
5
5
|
/*
|
|
6
6
|
Stencil Client Patch Browser v2.18.1 | MIT Licensed | https://stenciljs.com
|
|
@@ -15,5 +15,5 @@ const patchBrowser = () => {
|
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(options => {
|
|
18
|
-
return index.bootstrapLazy([["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["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]}]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["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-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-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["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-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-field-config_2.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"setShowGridConfig":[64],"setConfig":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"]}]]],["snk-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"parentForm":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-config-modal.cjs",[[2,"snk-config-modal",{"configName":[1,"config-name"],"gridMode":[4,"grid-mode"]}]]],["snk-configurator_6.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32]},[[0,"filterChange","filterChangeListener"]]],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}],[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]}],[2,"snk-configurator",{"configName":[1,"config-name"],"name":[1],"enabled":[4]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"setShowFormConfig":[64],"setConfig":[64]}]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"goToView":[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],"createDataunit":[64],"getDataUnit":[64],"getResourceID":[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],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
|
|
18
|
+
return index.bootstrapLazy([["teste-pesquisa.cjs",[[1,"teste-pesquisa"]]],["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]}]]],["snk-filter-binary-select.cjs",[[0,"snk-filter-binary-select",{"value":[1544],"config":[16],"show":[64]},[[0,"ezChange","ezChangeListener"]]]]],["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-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-pesquisa.cjs",[[2,"snk-pesquisa",{"searchLoader":[16],"selectItem":[16],"argument":[1025],"_itemList":[32],"_startLoading":[32]}]]],["snk-config-options.cjs",[[2,"snk-config-options",{"fieldConfig":[16],"idConfig":[513,"id-config"],"dataUnit":[16],"_defaultType":[32]}]]],["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-filter-detail.cjs",[[0,"snk-filter-detail",{"config":[1040],"getMessage":[16],"show":[64]}]]],["snk-field-config_2.cjs",[[6,"snk-grid",{"configName":[1,"config-name"],"actionsList":[16],"taskbarManager":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"_gridConfig":[32],"setShowGridConfig":[64],"setConfig":[64]}],[2,"snk-field-config",{"isConfigActive":[16],"fieldConfig":[16],"modeInsertion":[516,"mode-insertion"],"dataUnit":[16]}]]],["snk-form-config.cjs",[[2,"snk-form-config",{"dataUnit":[16],"formConfig":[16],"parentForm":[16],"_formConfigOptions":[32],"_fieldConfigSelected":[32],"_layoutFormConfig":[32],"_fieldsAvailable":[32],"_formConfig":[32],"_formConfigChanged":[32],"_optionFormConfigSelected":[32],"_optionFormConfigChanged":[32],"_tempGroups":[32]}]]],["snk-config-modal.cjs",[[2,"snk-config-modal",{"configName":[1,"config-name"],"gridMode":[4,"grid-mode"]}]]],["snk-configurator_6.cjs",[[2,"snk-filter-bar",{"dataUnit":[1040],"configName":[1,"config-name"],"filterConfig":[1040],"allowDefault":[32]},[[0,"filterChange","filterChangeListener"]]],[6,"snk-taskbar",{"configName":[1,"config-name"],"buttons":[1],"customButtons":[16],"actionsList":[16],"primaryButton":[1,"primary-button"],"disabledButtons":[16],"dataUnit":[16],"_permissions":[32]}],[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]}],[2,"snk-configurator",{"configName":[1,"config-name"],"name":[1],"enabled":[4]}]]],["snk-form.cjs",[[2,"snk-form",{"configName":[1,"config-name"],"recordsValidator":[16],"actionsList":[16],"taskbarManager":[16],"_dataUnit":[32],"_dataState":[32],"_editionFormConfig":[32],"_insertionFormConfig":[32],"_showFormConfig":[32],"setShowFormConfig":[64],"setConfig":[64]}]]],["snk-crud.cjs",[[6,"snk-crud",{"configName":[1025,"config-name"],"actionsList":[16],"taskbarManager":[16],"recordsValidator":[16],"statusResolver":[16],"_dataUnit":[32],"_dataState":[32],"goToView":[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],"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],"executeSearch":[64],"executePreparedSearch":[64],"isDebugMode":[64]}]]]], options);
|
|
19
19
|
});
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-20e8b68a.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
const formConfigFetcher = require('./form-config-fetcher-2de7c16a.js');
|
|
8
8
|
const utils = require('@sankhyalabs/ezui/dist/collection/utils');
|
|
@@ -493,35 +493,35 @@ class ParametersFetcher {
|
|
|
493
493
|
}
|
|
494
494
|
}`);
|
|
495
495
|
}
|
|
496
|
-
async getParam(name
|
|
497
|
-
const completPath = `param
|
|
496
|
+
async getParam(name) {
|
|
497
|
+
const completPath = `param://application?params=${name}`;
|
|
498
498
|
return formConfigFetcher.DataFetcher.get().callGraphQL({
|
|
499
499
|
values: { name: completPath },
|
|
500
500
|
query: this.templateByQuery.get("fetchParam"),
|
|
501
501
|
});
|
|
502
502
|
}
|
|
503
|
-
async asString(name
|
|
504
|
-
const paramArr = await this.getParam(name
|
|
503
|
+
async asString(name) {
|
|
504
|
+
const paramArr = await this.getParam(name);
|
|
505
505
|
return this.getValue(paramArr);
|
|
506
506
|
}
|
|
507
|
-
async asInteger(name
|
|
508
|
-
const paramArr = await this.getParam(name
|
|
507
|
+
async asInteger(name) {
|
|
508
|
+
const paramArr = await this.getParam(name);
|
|
509
509
|
return parseInt(this.getValue(paramArr));
|
|
510
510
|
}
|
|
511
|
-
async asFloat(name
|
|
512
|
-
const paramArr = await this.getParam(name
|
|
511
|
+
async asFloat(name) {
|
|
512
|
+
const paramArr = await this.getParam(name);
|
|
513
513
|
return parseFloat(this.getValue(paramArr));
|
|
514
514
|
}
|
|
515
|
-
async asBoolean(name
|
|
516
|
-
const paramArr = await this.getParam(name
|
|
517
|
-
return this.getValue(paramArr)
|
|
515
|
+
async asBoolean(name) {
|
|
516
|
+
const paramArr = await this.getParam(name);
|
|
517
|
+
return this.getValue(paramArr).includes('"S"');
|
|
518
518
|
}
|
|
519
|
-
async asDate(name
|
|
520
|
-
const paramArr = await this.getParam(name
|
|
519
|
+
async asDate(name) {
|
|
520
|
+
const paramArr = await this.getParam(name);
|
|
521
521
|
return core.DateUtils.strToDate(this.getValue(paramArr));
|
|
522
522
|
}
|
|
523
|
-
async getBatchParams(names
|
|
524
|
-
const paramArr = await this.getParam(names.join(",")
|
|
523
|
+
async getBatchParams(names) {
|
|
524
|
+
const paramArr = await this.getParam(names.join(","));
|
|
525
525
|
//TODO: try to typed params val?
|
|
526
526
|
const response = {};
|
|
527
527
|
paramArr.forEach((param) => (response[param.name] = param.resource));
|
|
@@ -758,31 +758,31 @@ const SnkApplication = class {
|
|
|
758
758
|
* Retorna o valor de um parâmetro do tipo string.
|
|
759
759
|
*/
|
|
760
760
|
async getStringParam(name) {
|
|
761
|
-
return this.parameters.asString(name
|
|
761
|
+
return this.parameters.asString(name);
|
|
762
762
|
}
|
|
763
763
|
/**
|
|
764
764
|
* Retorna o valor de um parâmetro do tipo Inteiro.
|
|
765
765
|
*/
|
|
766
766
|
async getIntParam(name) {
|
|
767
|
-
return this.parameters.asInteger(name
|
|
767
|
+
return this.parameters.asInteger(name);
|
|
768
768
|
}
|
|
769
769
|
/**
|
|
770
770
|
* Retorna o valor de um parâmetro do tipo Decimal.
|
|
771
771
|
*/
|
|
772
772
|
async getFloatParam(name) {
|
|
773
|
-
return this.parameters.asFloat(name
|
|
773
|
+
return this.parameters.asFloat(name);
|
|
774
774
|
}
|
|
775
775
|
/**
|
|
776
776
|
* Retorna o valor de um parâmetro do tipo booleano.
|
|
777
777
|
*/
|
|
778
778
|
async getBooleanParam(name) {
|
|
779
|
-
return this.parameters.asBoolean(name
|
|
779
|
+
return this.parameters.asBoolean(name);
|
|
780
780
|
}
|
|
781
781
|
/**
|
|
782
782
|
* Retorna o valor de um parâmetro do tipo data.
|
|
783
783
|
*/
|
|
784
784
|
async getDateParam(name) {
|
|
785
|
-
return this.parameters.asDate(name
|
|
785
|
+
return this.parameters.asDate(name);
|
|
786
786
|
}
|
|
787
787
|
/**
|
|
788
788
|
* Mostra o conteúdo passado em um Popup
|
|
@@ -953,6 +953,12 @@ const SnkApplication = class {
|
|
|
953
953
|
async getResourceID() {
|
|
954
954
|
return Promise.resolve(this.resourceID);
|
|
955
955
|
}
|
|
956
|
+
/**
|
|
957
|
+
* Retorna o resourceID da tela em questão.
|
|
958
|
+
*/
|
|
959
|
+
async getUserID() {
|
|
960
|
+
return Promise.resolve(window["UID"]);
|
|
961
|
+
}
|
|
956
962
|
/**
|
|
957
963
|
* Mostra o diálogo de alerta de acordo com os parâmetros passados.
|
|
958
964
|
*/
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-20e8b68a.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const constants = require('./constants-
|
|
7
|
+
const constants = require('./constants-9056ca9e.js');
|
|
8
8
|
const configurableElementsStorage = require('./configurableElementsStorage-93459c72.js');
|
|
9
9
|
|
|
10
|
-
const snkConfigModalCss = ".sc-snk-config-modal-h{--snk-config-modal__button-close--padding-left:var(--space--medium, 12px);--snk-config-modal__title--color:var(--title--primary, #2B3A54);--snk-config-modal__title--font-family:var(--font-pattern, \"
|
|
10
|
+
const snkConfigModalCss = ".sc-snk-config-modal-h{--snk-config-modal__button-close--padding-left:var(--space--medium, 12px);--snk-config-modal__title--color:var(--title--primary, #2B3A54);--snk-config-modal__title--font-family:var(--font-pattern, \"Roboto\");--snk-config-modal__title--font-size:var(--title--large, 20px);--snk-config-modal__title--font-weight:var(--text-weight--extra-large, 700);--snk-config-modal__subtitle--color:var(--title--primary, #2B3A54);--snk-config-modal__subtitle--font-family:var(--font-pattern, \"Roboto\");--snk-config-modal__subtitle--font-size:var(--text--medium, 14px);--snk-config-modal__subtitle--font-weight:var(--text-weight--large, 600);--snk-config-modal__scrollbar--border-radius:var(--border--radius-small, 6px);--snk-config-modal__scrollbar--width:var(--space--medium, 12px);--snk-config-modal__scrollbar--background-color-primary:var(--scrollbar--primary, #2B3A54);--snk-config-modal__scrollbar--background-color-secondary:var(--scrollbar--secondary, #E5EAF0);display:grid;grid-template-rows:auto 1fr auto;max-height:100%;width:100%}@media screen and (min-width: 480px){.sc-snk-config-modal-h{width:359px;max-width:359px}}.snk-config-modal__button-config.sc-snk-config-modal{--ez-button--min-width:100%}.snk-config-modal__header.sc-snk-config-modal{display:flex;justify-content:space-between;align-items:center;width:100%}.snk-config-modal__title.sc-snk-config-modal{display:flex;margin:0;line-height:normal;letter-spacing:0em;text-align:left;color:var(--snk-config-modal__title--color);font-size:var(--snk-config-modal__title--font-size);font-family:var(--snk-config-modal__title--font-family);font-weight:var(--snk-config-modal__title--font-weight)}.snk-config-modal__subtitle.sc-snk-config-modal{display:flex;margin:0;padding-top:var(--space--medium);padding-bottom:var(--space--small);color:var(--snk-config-modal__subtitle--color);font-size:var(--snk-config-modal__subtitle--font-size);font-family:var(--snk-config-modal__subtitle--font-family);font-weight:var(--snk-config-modal__subtitle--font-weight)}.snk-config-modal__button-close.sc-snk-config-modal{padding-left:var(--snk-config-modal__button-close--padding-left)}.snk-config-modal__main.sc-snk-config-modal{overflow-y:auto;scrollbar-width:thin;scrollbar-color:var(--snk-config-modal__scrollbar--background-color-primary) var(--snk-config-modal__scrollbar--background-color-secondary)}.snk-config-modal__main.sc-snk-config-modal::-webkit-scrollbar-track{background-color:var(--snk-config-modal__scrollbar--background-color-secondary)}.snk-config-modal__main.sc-snk-config-modal::-webkit-scrollbar-thumb{background-color:var(--snk-config-modal__scrollbar--background-color-primary);border-radius:var(--snk-config-modal__scrollbar--border-radius)}.snk-config-modal__main.sc-snk-config-modal::-webkit-scrollbar{background-color:var(--snk-config-modal__scrollbar--background-color-secondary);width:var(--snk-config-modal__scrollbar--width);max-width:var(--snk-config-modal__scrollbar--width);min-width:var(--snk-config-modal__scrollbar--width)}";
|
|
11
11
|
|
|
12
12
|
const GRID_MODE = constants.VIEW_MODE.grid;
|
|
13
13
|
const FORM_MODE = constants.VIEW_MODE.form;
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-20e8b68a.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const utils = require('@sankhyalabs/ezui/dist/collection/utils');
|
|
8
7
|
const DataType = require('@sankhyalabs/core/dist/dataunit/metadata/DataType');
|
|
9
|
-
const
|
|
8
|
+
const utils = require('@sankhyalabs/ezui/dist/collection/utils');
|
|
9
|
+
const constants = require('./constants-9056ca9e.js');
|
|
10
10
|
|
|
11
11
|
const snkConfigOptionsCss = ".sc-snk-config-options-h{width:100%;border:2px solid var(--color--secondary-200);border-radius:15px}.config-options__switch-row.sc-snk-config-options{margin-top:-30px}";
|
|
12
12
|
|
|
@@ -36,71 +36,20 @@ const SnkConfigOptions = class {
|
|
|
36
36
|
enabledValueDefault() {
|
|
37
37
|
var _a, _b, _c;
|
|
38
38
|
const field = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField((_b = this.fieldConfig) === null || _b === void 0 ? void 0 : _b.name);
|
|
39
|
-
|
|
39
|
+
const allowDefault = (_c = field === null || field === void 0 ? void 0 : field.properties) === null || _c === void 0 ? void 0 : _c.allowDefault;
|
|
40
|
+
const hasVariableVar = constants.VARS_BY_TYPE.UserInterface.hasOwnProperty(field === null || field === void 0 ? void 0 : field.userInterface);
|
|
41
|
+
if ((allowDefault == undefined || allowDefault === "true") && hasVariableVar) {
|
|
40
42
|
return true;
|
|
41
43
|
}
|
|
42
44
|
return false;
|
|
43
45
|
}
|
|
44
|
-
|
|
45
|
-
var _a;
|
|
46
|
-
if (field != undefined) {
|
|
47
|
-
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField(field);
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
getMessage(key, params) {
|
|
51
|
-
return this._application.messagesBuilder.getMessage(key, params);
|
|
52
|
-
}
|
|
53
|
-
getDefaultType() {
|
|
54
|
-
var _a;
|
|
55
|
-
return (_a = this.fieldConfig.defaultValue.type) !== null && _a !== void 0 ? _a : constants.DEFAULT_TYPE.fixed;
|
|
56
|
-
}
|
|
57
|
-
getValidatedValue(fieldValue) {
|
|
46
|
+
isAllowDefault() {
|
|
58
47
|
var _a, _b;
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
const field = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField((_b = this.fieldConfig) === null || _b === void 0 ? void 0 : _b.name);
|
|
63
|
-
const dataType = field === null || field === void 0 ? void 0 : field.dataType;
|
|
64
|
-
if (dataType == undefined) {
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
const value = dataType !== DataType.DataType.OBJECT && dataType !== DataType.DataType.DATE
|
|
68
|
-
&& typeof fieldValue === "object" && "value" in fieldValue
|
|
69
|
-
? fieldValue.value
|
|
70
|
-
: fieldValue;
|
|
71
|
-
return dataType === DataType.DataType.OBJECT ? JSON.stringify(value) : value;
|
|
72
|
-
}
|
|
73
|
-
onChange(evt) {
|
|
74
|
-
this.fieldConfig.defaultValue.value = this.getValidatedValue(evt === null || evt === void 0 ? void 0 : evt.detail);
|
|
75
|
-
this.configOptionsChanged.emit(this.fieldConfig);
|
|
76
|
-
}
|
|
77
|
-
onSearch(searchArgument) {
|
|
78
|
-
if (this._application != undefined && this.fieldConfig != undefined) {
|
|
79
|
-
return this._application.executeSearch(searchArgument, this.fieldConfig.name, this.dataUnit);
|
|
48
|
+
const allowDefault = (_b = (_a = this._fieldProperties) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.allowDefault;
|
|
49
|
+
if (allowDefault == undefined) {
|
|
50
|
+
return true;
|
|
80
51
|
}
|
|
81
|
-
|
|
82
|
-
loadDataField() {
|
|
83
|
-
this._element.querySelectorAll("[data-field-name]")
|
|
84
|
-
.forEach((field) => {
|
|
85
|
-
var _a, _b, _c, _d;
|
|
86
|
-
field.enabled = ((_b = (_a = this._fieldProperties) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.allowDefault) === "true";
|
|
87
|
-
if (field.enabled) {
|
|
88
|
-
const value = this.fieldConfig.defaultValue.value;
|
|
89
|
-
if (value != undefined) {
|
|
90
|
-
const fieldName = field.dataset.fieldName;
|
|
91
|
-
const dataType = (_d = (_c = this.dataUnit) === null || _c === void 0 ? void 0 : _c.getField(fieldName)) === null || _d === void 0 ? void 0 : _d.dataType;
|
|
92
|
-
field.value = DataType.getConvertedValue(dataType, value);
|
|
93
|
-
}
|
|
94
|
-
field.addEventListener(constants.CONFIG_EVENTS.fieldChanged, (evt) => {
|
|
95
|
-
return this.onChange(evt);
|
|
96
|
-
});
|
|
97
|
-
if (field.tagName === "EZ-SEARCH") {
|
|
98
|
-
field.optionLoader = (searchArgument) => {
|
|
99
|
-
return this.onSearch(searchArgument);
|
|
100
|
-
};
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
});
|
|
52
|
+
return allowDefault === "true";
|
|
104
53
|
}
|
|
105
54
|
loadDefaultValue() {
|
|
106
55
|
var _a;
|
|
@@ -122,6 +71,19 @@ const SnkConfigOptions = class {
|
|
|
122
71
|
this._defaultType = this.fieldConfig.defaultValue.type;
|
|
123
72
|
}
|
|
124
73
|
}
|
|
74
|
+
getFieldProperties(field) {
|
|
75
|
+
var _a;
|
|
76
|
+
if (field != undefined) {
|
|
77
|
+
return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField(field);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
getMessage(key, params) {
|
|
81
|
+
return this._application.messagesBuilder.getMessage(key, params);
|
|
82
|
+
}
|
|
83
|
+
getDefaultType() {
|
|
84
|
+
var _a;
|
|
85
|
+
return (_a = this.fieldConfig.defaultValue.type) !== null && _a !== void 0 ? _a : constants.DEFAULT_TYPE.fixed;
|
|
86
|
+
}
|
|
125
87
|
getEnabledByProperty(property) {
|
|
126
88
|
const properties = this._fieldProperties;
|
|
127
89
|
if (properties != undefined && properties[property] === true) {
|
|
@@ -136,25 +98,130 @@ const SnkConfigOptions = class {
|
|
|
136
98
|
}
|
|
137
99
|
return this.fieldConfig[property];
|
|
138
100
|
}
|
|
101
|
+
getValidatedValue(fieldValue) {
|
|
102
|
+
var _a, _b;
|
|
103
|
+
if (fieldValue == undefined) {
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
const field = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField((_b = this.fieldConfig) === null || _b === void 0 ? void 0 : _b.name);
|
|
107
|
+
const dataType = field === null || field === void 0 ? void 0 : field.dataType;
|
|
108
|
+
if (dataType == undefined) {
|
|
109
|
+
return;
|
|
110
|
+
}
|
|
111
|
+
const value = (fieldValue === null || fieldValue === void 0 ? void 0 : fieldValue.waitmessage) != undefined ? undefined :
|
|
112
|
+
dataType !== DataType.DataType.OBJECT && dataType !== DataType.DataType.DATE
|
|
113
|
+
&& typeof fieldValue === "object"
|
|
114
|
+
? fieldValue.value
|
|
115
|
+
: fieldValue;
|
|
116
|
+
return dataType === DataType.DataType.OBJECT ? JSON.stringify(value) : value;
|
|
117
|
+
}
|
|
118
|
+
buildInputDefault({ value, enabled, label, name, required, userInterface }, properties = undefined, mode = undefined) {
|
|
119
|
+
let options;
|
|
120
|
+
let precision = 0;
|
|
121
|
+
let prettyPrecision = 0;
|
|
122
|
+
const TagName = userInterface == undefined || constants.TAGS_BY_TYPE[userInterface] == undefined
|
|
123
|
+
? constants.TAGS_BY_TYPE.DEFAULT
|
|
124
|
+
: constants.TAGS_BY_TYPE[userInterface];
|
|
125
|
+
if (userInterface === core.UserInterface.OPTIONSELECTOR) {
|
|
126
|
+
const prop = properties === null || properties === void 0 ? void 0 : properties.options;
|
|
127
|
+
if (typeof prop === "string") {
|
|
128
|
+
const parsed = core.ObjectUtils.stringToObject(prop);
|
|
129
|
+
options = Object.keys(parsed).map(key => { return { value: key, label: parsed[key] }; });
|
|
130
|
+
}
|
|
131
|
+
else {
|
|
132
|
+
options = prop;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
else if (userInterface === core.UserInterface.DECIMALNUMBER) {
|
|
136
|
+
precision = Number((properties === null || properties === void 0 ? void 0 : properties.precision) || 2);
|
|
137
|
+
prettyPrecision = Number((properties === null || properties === void 0 ? void 0 : properties.prettyPrecision) || precision);
|
|
138
|
+
}
|
|
139
|
+
return index.h(TagName, Object.assign({ value: value, enabled: enabled, label: label, "data-field-name": name, key: name, onEzChange: (evt) => this.onChange(evt === null || evt === void 0 ? void 0 : evt.detail) }, (this.getConditionalAttributes(userInterface, required, options, precision, prettyPrecision, mode))));
|
|
140
|
+
}
|
|
141
|
+
getConditionalAttributes(userInterface, required, options, precision, prettyPrecision, mode) {
|
|
142
|
+
switch (userInterface) {
|
|
143
|
+
case core.UserInterface.SEARCH:
|
|
144
|
+
return {
|
|
145
|
+
suppressEmptyOption: required,
|
|
146
|
+
optionLoader: (searchArgument) => this.onSearch(searchArgument)
|
|
147
|
+
};
|
|
148
|
+
case core.UserInterface.OPTIONSELECTOR:
|
|
149
|
+
return {
|
|
150
|
+
suppressEmptyOption: required,
|
|
151
|
+
options
|
|
152
|
+
};
|
|
153
|
+
case core.UserInterface.CHECKBOX:
|
|
154
|
+
case core.UserInterface.SWITCH:
|
|
155
|
+
return {
|
|
156
|
+
mode
|
|
157
|
+
};
|
|
158
|
+
case core.UserInterface.INTEGERNUMBER:
|
|
159
|
+
case core.UserInterface.DECIMALNUMBER:
|
|
160
|
+
return {
|
|
161
|
+
precision,
|
|
162
|
+
prettyPrecision,
|
|
163
|
+
onEzStartChange: (evt) => this.onChange(evt === null || evt === void 0 ? void 0 : evt.detail)
|
|
164
|
+
};
|
|
165
|
+
case core.UserInterface.DATE:
|
|
166
|
+
case core.UserInterface.DATETIME:
|
|
167
|
+
case core.UserInterface.TIME:
|
|
168
|
+
return {
|
|
169
|
+
onEzStartChange: (evt) => this.onChange(evt === null || evt === void 0 ? void 0 : evt.detail)
|
|
170
|
+
};
|
|
171
|
+
default:
|
|
172
|
+
return {};
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
onChange(fieldValue) {
|
|
176
|
+
this.fieldConfig.defaultValue.value = this.getValidatedValue(fieldValue);
|
|
177
|
+
this.configOptionsChanged.emit(this.fieldConfig);
|
|
178
|
+
}
|
|
179
|
+
onSearch(searchArgument) {
|
|
180
|
+
if (this._application != undefined && this.fieldConfig != undefined) {
|
|
181
|
+
return this._application.executeSearch(searchArgument, this.fieldConfig.name, this.dataUnit);
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
buildField(field) {
|
|
185
|
+
const { config, descriptor } = field;
|
|
186
|
+
const { name, label, readOnly, required, defaultValue } = config;
|
|
187
|
+
const { userInterface, properties } = descriptor;
|
|
188
|
+
const enabled = (properties === null || properties === void 0 ? void 0 : properties.allowDefault) != undefined ? properties.allowDefault === "true" : !readOnly;
|
|
189
|
+
let value;
|
|
190
|
+
if (enabled) {
|
|
191
|
+
value = defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.value;
|
|
192
|
+
if (value != undefined) {
|
|
193
|
+
value = DataType.getConvertedValue(descriptor === null || descriptor === void 0 ? void 0 : descriptor.dataType, value);
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
const configField = { value, enabled, label, name, required, userInterface };
|
|
197
|
+
switch (userInterface) {
|
|
198
|
+
case core.UserInterface.SWITCH:
|
|
199
|
+
return this.buildInputDefault(configField, undefined, utils.CheckMode.SWITCH);
|
|
200
|
+
case core.UserInterface.CHECKBOX:
|
|
201
|
+
return this.buildInputDefault(configField, undefined, utils.CheckMode.REGULAR);
|
|
202
|
+
case core.UserInterface.OPTIONSELECTOR:
|
|
203
|
+
case core.UserInterface.DECIMALNUMBER:
|
|
204
|
+
return this.buildInputDefault(configField, properties);
|
|
205
|
+
default:
|
|
206
|
+
return this.buildInputDefault(configField);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
139
209
|
componentWillLoad() {
|
|
140
210
|
var _a;
|
|
141
|
-
this._application = core.ApplicationContext.getContextValue("__SNK__APPLICATION__");
|
|
142
211
|
this.loadDefaultValue();
|
|
212
|
+
this._application = core.ApplicationContext.getContextValue("__SNK__APPLICATION__");
|
|
143
213
|
this._fieldProperties = this.getFieldProperties((_a = this.fieldConfig) === null || _a === void 0 ? void 0 : _a.name);
|
|
144
214
|
}
|
|
145
|
-
componentDidRender() {
|
|
146
|
-
this.loadDataField();
|
|
147
|
-
}
|
|
148
215
|
render() {
|
|
149
|
-
var _a, _b
|
|
150
|
-
return (index.h(index.Host, null, index.h("div", { id: this.idConfig }, index.h("div", { class: "ez-row ez-padding--medium" }, index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-text-input", { label: this.getMessage("snkConfigOptions.label.nameField"), value: (_a = this.fieldConfig) === null || _a === void 0 ? void 0 : _a.label, onEzChange: (evt) => { this.fieldConfig.label = evt.detail; this.configOptionsChanged.emit(this.fieldConfig); } })), index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-combo-box", { label: this.getMessage("snkConfigOptions.label.typeValueDefault"), suppressEmptyOption: true, enabled:
|
|
151
|
-
index.h("ez-combo-box", { label: this.getMessage("snkConfigOptions.label.valueDefault"), enabled: this.
|
|
216
|
+
var _a, _b;
|
|
217
|
+
return (index.h(index.Host, null, index.h("div", { id: this.idConfig }, index.h("div", { class: "ez-row ez-padding--medium" }, index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-text-input", { label: this.getMessage("snkConfigOptions.label.nameField"), value: (_a = this.fieldConfig) === null || _a === void 0 ? void 0 : _a.label, onEzChange: (evt) => { this.fieldConfig.label = evt.detail; this.configOptionsChanged.emit(this.fieldConfig); } })), index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-combo-box", { label: this.getMessage("snkConfigOptions.label.typeValueDefault"), suppressEmptyOption: true, enabled: this.enabledValueDefault(), onEzChange: (evt) => { var _a; return this.onConfigDefault((_a = evt.detail) === null || _a === void 0 ? void 0 : _a.value); }, value: this.getDefaultType() }, index.h("option", { value: constants.DEFAULT_TYPE.fixed }, this.getMessage("snkConfigOptions.options.valueFixed")), index.h("option", { value: constants.DEFAULT_TYPE.variable }, this.getMessage("snkConfigOptions.options.variable")))), index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, this._defaultType === constants.DEFAULT_TYPE.variable ?
|
|
218
|
+
index.h("ez-combo-box", { label: this.getMessage("snkConfigOptions.label.valueDefault"), enabled: this.isAllowDefault(), onEzChange: (evt) => { var _a; this.fieldConfig.defaultValue.value = (_a = evt.detail) === null || _a === void 0 ? void 0 : _a.value; this.configOptionsChanged.emit(this.fieldConfig); }, value: this.fieldConfig.defaultValue.value, options: this.buildOptions() })
|
|
152
219
|
:
|
|
153
|
-
((
|
|
154
|
-
|
|
220
|
+
((_b = this._fieldProperties) === null || _b === void 0 ? void 0 : _b.userInterface) &&
|
|
221
|
+
this.buildField({
|
|
155
222
|
descriptor: this._fieldProperties,
|
|
156
223
|
config: this.fieldConfig
|
|
157
|
-
})
|
|
224
|
+
}))), index.h("div", { class: "ez-row ez-padding--medium config-options__switch-row" }, index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-check", { mode: utils.CheckMode.SWITCH, label: this.getMessage("snkConfigOptions.label.clearDuplicate"), value: this.fieldConfig.cleanOnCopy, onEzChange: (evt) => { this.fieldConfig.cleanOnCopy = evt.detail; this.configOptionsChanged.emit(this.fieldConfig); } })), index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-check", { mode: utils.CheckMode.SWITCH, label: this.getMessage("snkConfigOptions.label.requiredField"), enabled: this.getEnabledByProperty("required"), value: this.getValueByProperty("required"), onEzChange: (evt) => { this.fieldConfig.required = evt.detail; this.configOptionsChanged.emit(this.fieldConfig); } })), index.h("div", { class: "ez-col ez-col--sd-12 ez-col--tb-4 ez-padding--small" }, index.h("ez-check", { mode: utils.CheckMode.SWITCH, label: this.getMessage("snkConfigOptions.label.protectedField"), enabled: this.getEnabledByProperty("readOnly"), value: this.getValueByProperty("readOnly"), onEzChange: (evt) => { this.fieldConfig.readOnly = evt.detail; this.configOptionsChanged.emit(this.fieldConfig); } }))))));
|
|
158
225
|
}
|
|
159
226
|
get _element() { return index.getElement(this); }
|
|
160
227
|
};
|
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-20e8b68a.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
const utils = require('@sankhyalabs/ezui/dist/collection/utils');
|
|
8
|
-
const constants = require('./constants-
|
|
8
|
+
const constants = require('./constants-9056ca9e.js');
|
|
9
9
|
const configurableElementsStorage = require('./configurableElementsStorage-93459c72.js');
|
|
10
10
|
const filterItemType_enum = require('./filter-item-type.enum-3daf58d3.js');
|
|
11
11
|
const ezModalContainer = require('@sankhyalabs/ezui/dist/collection/components/ez-modal-container');
|
|
12
12
|
const DataType = require('@sankhyalabs/core/dist/dataunit/metadata/DataType');
|
|
13
|
-
const taskbarElements = require('./taskbar-elements-
|
|
13
|
+
const taskbarElements = require('./taskbar-elements-9a4b1e19.js');
|
|
14
14
|
|
|
15
15
|
const GRID_MODE = constants.VIEW_MODE.grid;
|
|
16
16
|
const FORM_MODE = constants.VIEW_MODE.form;
|
|
@@ -949,7 +949,7 @@ const SnkFilterModal = class {
|
|
|
949
949
|
}
|
|
950
950
|
updateValue(id, value = undefined) {
|
|
951
951
|
this.items = this.items.map(item => {
|
|
952
|
-
if (item.id === id) {
|
|
952
|
+
if (item.id === id && item.enabled) {
|
|
953
953
|
if (value == undefined) {
|
|
954
954
|
value = !item.active;
|
|
955
955
|
}
|
|
@@ -967,7 +967,7 @@ const SnkFilterModal = class {
|
|
|
967
967
|
}
|
|
968
968
|
buildItems(list) {
|
|
969
969
|
return list.map(item => {
|
|
970
|
-
return (index.h("button", { onClick: () => this.updateValue(item.id), class: "ez-padding--medium sc-snk-filter-bar snk-filter-bar__filter-modal-item ez-align--middle ez-margin-bottom--small" }, index.h("ez-check", { id: `checkbox_${item.id}`, tabIndex: "-1", class: "sc-snk-filter-bar snk-filter-bar__filter-modal-item__check", onEzChange: evt => this.updateValue(item.id, evt.detail), enabled: item.enabled, value: item.active, mode:
|
|
970
|
+
return (index.h("button", { onClick: () => this.updateValue(item.id), class: "ez-padding--medium sc-snk-filter-bar snk-filter-bar__filter-modal-item ez-align--middle ez-margin-bottom--small" }, index.h("ez-check", { id: `checkbox_${item.id}`, tabIndex: "-1", class: "sc-snk-filter-bar snk-filter-bar__filter-modal-item__check", onEzChange: evt => this.updateValue(item.id, evt.detail), enabled: item.enabled, value: item.active, mode: utils.CheckMode.SWITCH }), index.h("div", { class: "ez-text ez-title--primary ez-text--medium ez-margin-left--medium sc-snk-filter-bar snk-filter-bar__filter-modal-item__label" }, item.label)));
|
|
971
971
|
});
|
|
972
972
|
}
|
|
973
973
|
itemKeyBoardSelect(event, item) {
|