@sankhyalabs/sankhyablocks 10.1.0-dev.1 → 10.1.0-dev.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (197) hide show
  1. package/dist/cjs/{ConfigStorage-5a73e979.js → ConfigStorage-5c0590b3.js} +2 -2
  2. package/dist/cjs/{DataFetcher-eeb3b0b7.js → DataFetcher-5181a917.js} +23 -2
  3. package/dist/cjs/{FormConfigHelper-ebb77625.js → FormConfigHelper-28fe4668.js} +44 -0
  4. package/dist/cjs/{ISave-861e9d6d.js → ISave-0f98a457.js} +4 -4
  5. package/dist/cjs/{SnkFormConfigManager-8d4fded8.js → SnkFormConfigManager-1907ffed.js} +7 -7
  6. package/dist/cjs/{SnkMultiSelectionListDataSource-3b93f6a6.js → SnkMultiSelectionListDataSource-e4e38139.js} +4 -4
  7. package/dist/cjs/{auth-fetcher-8d8acd69.js → auth-fetcher-cff55b1f.js} +1 -1
  8. package/dist/cjs/{dataunit-fetcher-1cea0695.js → dataunit-fetcher-1ba5e2cc.js} +1 -1
  9. package/dist/cjs/field-config_2.cjs.entry.js +1 -1
  10. package/dist/cjs/fields-layout.cjs.entry.js +6 -3
  11. package/dist/cjs/fields-selector.cjs.entry.js +1 -1
  12. package/dist/cjs/{form-config-fetcher-f347f884.js → form-config-fetcher-4a679e23.js} +1 -1
  13. package/dist/cjs/guides-configurator.cjs.entry.js +5 -3
  14. package/dist/cjs/index-1cf293c1.js +4 -0
  15. package/dist/cjs/loader.cjs.js +1 -1
  16. package/dist/cjs/pesquisa-grid_2.cjs.entry.js +4 -4
  17. package/dist/cjs/sankhyablocks.cjs.js +1 -1
  18. package/dist/cjs/snk-actions-button_9.cjs.entry.js +14 -7
  19. package/dist/cjs/snk-application.cjs.entry.js +81 -69
  20. package/dist/cjs/snk-attach.cjs.entry.js +5 -5
  21. package/dist/cjs/snk-crud.cjs.entry.js +97 -6
  22. package/dist/cjs/snk-custom-slot-guide.cjs.entry.js +40 -0
  23. package/dist/cjs/snk-data-exporter.cjs.entry.js +5 -5
  24. package/dist/cjs/{snk-data-unit-de248308.js → snk-data-unit-061487a8.js} +4 -2
  25. package/dist/cjs/snk-data-unit.cjs.entry.js +3 -3
  26. package/dist/cjs/snk-detail-view.cjs.entry.js +7 -7
  27. package/dist/cjs/snk-filter-bar_4.cjs.entry.js +3 -3
  28. package/dist/cjs/snk-filter-modal-item.cjs.entry.js +3 -3
  29. package/dist/cjs/snk-form-view.cjs.entry.js +2 -6
  30. package/dist/cjs/snk-form_2.cjs.entry.js +32 -9
  31. package/dist/cjs/snk-grid.cjs.entry.js +13 -10
  32. package/dist/cjs/{snk-guides-viewer-4ec3e7e1.js → snk-guides-viewer-2efe60a7.js} +84 -38
  33. package/dist/cjs/snk-guides-viewer.cjs.entry.js +7 -7
  34. package/dist/cjs/snk-personalized-filter.cjs.entry.js +3 -3
  35. package/dist/cjs/snk-pesquisa.cjs.entry.js +16 -5
  36. package/dist/cjs/snk-simple-crud.cjs.entry.js +9 -17
  37. package/dist/cjs/snk-taskbar.cjs.entry.js +64 -48
  38. package/dist/collection/collection-manifest.json +2 -1
  39. package/dist/collection/components/snk-application/search-strategy/exec-prepared-search-advaced-mode.js +27 -0
  40. package/dist/collection/components/snk-application/search-strategy/exec-prepared-search-plus.js +5 -25
  41. package/dist/collection/components/snk-application/snk-application.js +87 -44
  42. package/dist/collection/components/snk-attach/snk-attach.js +1 -1
  43. package/dist/collection/components/snk-crud/snk-crud.js +151 -2
  44. package/dist/collection/components/snk-crud/subcomponents/snk-form-view.js +2 -6
  45. package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +133 -34
  46. package/dist/collection/components/snk-custom-slot-guide/snk-custom-slot-guide.css +3 -0
  47. package/dist/collection/components/snk-custom-slot-guide/snk-custom-slot-guide.js +95 -0
  48. package/dist/collection/components/snk-data-unit/snk-data-unit.js +2 -0
  49. package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-number.js +1 -1
  50. package/dist/collection/components/snk-form-config/FormConfigHelper.js +42 -0
  51. package/dist/collection/components/snk-form-config/SnkFormConfigManager.js +6 -6
  52. package/dist/collection/components/snk-form-config/fields-layout/fields-layout.css +16 -0
  53. package/dist/collection/components/snk-form-config/fields-layout/fields-layout.js +6 -3
  54. package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.css +3 -3
  55. package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.js +5 -3
  56. package/dist/collection/components/snk-form-config/snk-form-config.js +53 -6
  57. package/dist/collection/components/snk-grid/snk-grid.css +14 -0
  58. package/dist/collection/components/snk-grid/snk-grid.js +26 -4
  59. package/dist/collection/components/snk-layout-form-config/snk-layout-form-config.js +9 -2
  60. package/dist/collection/components/snk-pesquisa/snk-pesquisa.css +5 -1
  61. package/dist/collection/components/snk-pesquisa/snk-pesquisa.js +43 -0
  62. package/dist/collection/components/snk-simple-crud/snk-simple-crud.js +3 -11
  63. package/dist/collection/components/snk-taskbar/snk-taskbar.js +87 -48
  64. package/dist/collection/lib/http/data-fetcher/fetchers/pesquisa-fetcher.js +3 -3
  65. package/dist/collection/lib/message/resources/en-us/snk-form.msg.js +7 -0
  66. package/dist/collection/lib/message/resources/es-es/snk-form.msg.js +7 -0
  67. package/dist/collection/lib/message/resources/pt-br/snk-form.msg.js +8 -1
  68. package/dist/collection/lib/message/resources/pt-br/snk-pesquisa.msg.js +1 -1
  69. package/dist/components/DataFetcher.js +23 -2
  70. package/dist/components/ISave.js +3 -3
  71. package/dist/components/SnkFormConfigManager.js +6 -6
  72. package/dist/components/field-config2.js +43 -1
  73. package/dist/components/fields-layout2.js +6 -3
  74. package/dist/components/guides-configurator2.js +5 -3
  75. package/dist/components/index.d.ts +1 -0
  76. package/dist/components/index.js +1 -0
  77. package/dist/components/snk-application2.js +76 -63
  78. package/dist/components/snk-attach2.js +1 -1
  79. package/dist/components/snk-crud.js +96 -1
  80. package/dist/components/snk-custom-slot-guide.d.ts +11 -0
  81. package/dist/components/snk-custom-slot-guide.js +55 -0
  82. package/dist/components/snk-data-unit2.js +2 -0
  83. package/dist/components/snk-detail-view2.js +81 -34
  84. package/dist/components/snk-filter-number.js +1 -1
  85. package/dist/components/snk-form-config2.js +29 -5
  86. package/dist/components/snk-form-view2.js +2 -6
  87. package/dist/components/snk-grid2.js +9 -4
  88. package/dist/components/snk-layout-form-config2.js +9 -2
  89. package/dist/components/snk-pesquisa2.js +14 -2
  90. package/dist/components/snk-simple-crud2.js +3 -11
  91. package/dist/components/snk-taskbar2.js +66 -49
  92. package/dist/esm/{ConfigStorage-568dc227.js → ConfigStorage-bd096633.js} +2 -2
  93. package/dist/esm/{DataFetcher-743feb3b.js → DataFetcher-5780ad39.js} +23 -2
  94. package/dist/esm/{FormConfigHelper-4e42f0b6.js → FormConfigHelper-d09669f3.js} +43 -1
  95. package/dist/esm/{ISave-345481c1.js → ISave-8a22ec18.js} +4 -4
  96. package/dist/esm/{SnkFormConfigManager-d61df0c8.js → SnkFormConfigManager-437e98bb.js} +7 -7
  97. package/dist/esm/{SnkMultiSelectionListDataSource-ca8d7a09.js → SnkMultiSelectionListDataSource-42125ef4.js} +4 -4
  98. package/dist/esm/{auth-fetcher-c353127d.js → auth-fetcher-28b9d0db.js} +1 -1
  99. package/dist/esm/{dataunit-fetcher-7f2c61ca.js → dataunit-fetcher-c4251d80.js} +1 -1
  100. package/dist/esm/field-config_2.entry.js +1 -1
  101. package/dist/esm/fields-layout.entry.js +6 -3
  102. package/dist/esm/fields-selector.entry.js +1 -1
  103. package/dist/esm/{form-config-fetcher-898d2dd1.js → form-config-fetcher-d0536a71.js} +1 -1
  104. package/dist/esm/guides-configurator.entry.js +5 -3
  105. package/dist/esm/index-479e1293.js +4 -0
  106. package/dist/esm/loader.js +1 -1
  107. package/dist/esm/pesquisa-grid_2.entry.js +4 -4
  108. package/dist/esm/sankhyablocks.js +1 -1
  109. package/dist/esm/snk-actions-button_9.entry.js +14 -7
  110. package/dist/esm/snk-application.entry.js +81 -69
  111. package/dist/esm/snk-attach.entry.js +5 -5
  112. package/dist/esm/snk-crud.entry.js +97 -6
  113. package/dist/esm/snk-custom-slot-guide.entry.js +36 -0
  114. package/dist/esm/snk-data-exporter.entry.js +5 -5
  115. package/dist/esm/{snk-data-unit-60b338c5.js → snk-data-unit-4a1ef77f.js} +4 -2
  116. package/dist/esm/snk-data-unit.entry.js +3 -3
  117. package/dist/esm/snk-detail-view.entry.js +7 -7
  118. package/dist/esm/snk-filter-bar_4.entry.js +3 -3
  119. package/dist/esm/snk-filter-modal-item.entry.js +3 -3
  120. package/dist/esm/snk-form-view.entry.js +2 -6
  121. package/dist/esm/snk-form_2.entry.js +32 -9
  122. package/dist/esm/snk-grid.entry.js +13 -10
  123. package/dist/esm/{snk-guides-viewer-339e10b3.js → snk-guides-viewer-c182d058.js} +84 -38
  124. package/dist/esm/snk-guides-viewer.entry.js +7 -7
  125. package/dist/esm/snk-personalized-filter.entry.js +3 -3
  126. package/dist/esm/snk-pesquisa.entry.js +16 -5
  127. package/dist/esm/snk-simple-crud.entry.js +9 -17
  128. package/dist/esm/snk-taskbar.entry.js +65 -49
  129. package/dist/sankhyablocks/{p-e6b1c769.entry.js → p-01ca59fc.entry.js} +1 -1
  130. package/dist/sankhyablocks/p-028fb380.entry.js +11 -0
  131. package/dist/sankhyablocks/{p-1f8cb438.entry.js → p-03f02b12.entry.js} +1 -1
  132. package/dist/sankhyablocks/{p-1788d191.js → p-0e4f8b86.js} +1 -1
  133. package/dist/sankhyablocks/p-1037ea7b.entry.js +1 -0
  134. package/dist/sankhyablocks/{p-6d241415.js → p-1b1373b6.js} +1 -1
  135. package/dist/sankhyablocks/{p-27005fac.entry.js → p-2e882241.entry.js} +1 -1
  136. package/dist/sankhyablocks/p-30a58e29.entry.js +1 -0
  137. package/dist/sankhyablocks/p-3b167a03.entry.js +1 -0
  138. package/dist/sankhyablocks/{p-e8c49c12.js → p-3c046287.js} +2 -2
  139. package/dist/sankhyablocks/{p-bd203e8d.entry.js → p-42272de8.entry.js} +1 -1
  140. package/dist/sankhyablocks/{p-11346b8d.entry.js → p-4c2e2767.entry.js} +1 -1
  141. package/dist/sankhyablocks/{p-7fc46290.js → p-4db9dbf8.js} +1 -1
  142. package/dist/sankhyablocks/{p-626b7a17.js → p-55d7abe7.js} +1 -1
  143. package/dist/sankhyablocks/p-5d408e7e.entry.js +1 -0
  144. package/dist/sankhyablocks/{p-9b6d4950.entry.js → p-6e5af618.entry.js} +1 -1
  145. package/dist/sankhyablocks/{p-144da1d1.entry.js → p-78d4b3e3.entry.js} +1 -1
  146. package/dist/sankhyablocks/p-82a3d522.entry.js +1 -0
  147. package/dist/sankhyablocks/p-8b4d6719.js +1 -0
  148. package/dist/sankhyablocks/{p-e64958ba.entry.js → p-903fa0b4.entry.js} +1 -1
  149. package/dist/sankhyablocks/p-987cd79d.entry.js +1 -0
  150. package/dist/sankhyablocks/{p-88ed2793.js → p-9ab6ae1e.js} +2 -2
  151. package/dist/sankhyablocks/{p-c90f337a.entry.js → p-9f16d33e.entry.js} +1 -1
  152. package/dist/sankhyablocks/p-a1d23fef.js +1 -0
  153. package/dist/sankhyablocks/{p-bb0de89c.entry.js → p-a64ffe30.entry.js} +1 -1
  154. package/dist/sankhyablocks/p-aca74b21.js +1 -0
  155. package/dist/sankhyablocks/p-b7e891cc.entry.js +1 -0
  156. package/dist/sankhyablocks/{p-1d585081.js → p-b9699067.js} +1 -1
  157. package/dist/sankhyablocks/p-c98c79c3.entry.js +1 -0
  158. package/dist/sankhyablocks/p-d2ec9a24.entry.js +1 -0
  159. package/dist/sankhyablocks/{p-59b8f277.js → p-d3534985.js} +1 -1
  160. package/dist/sankhyablocks/{p-7b3ca294.entry.js → p-f3027bc9.entry.js} +1 -1
  161. package/dist/sankhyablocks/{p-f8f29e1a.entry.js → p-f35f2eb3.entry.js} +1 -1
  162. package/dist/sankhyablocks/p-fd05e31d.entry.js +1 -0
  163. package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
  164. package/dist/types/components/snk-application/search-strategy/exec-prepared-search-advaced-mode.d.ts +5 -0
  165. package/dist/types/components/snk-application/snk-application.d.ts +9 -0
  166. package/dist/types/components/snk-crud/snk-crud.d.ts +22 -0
  167. package/dist/types/components/snk-crud/subcomponents/snk-guides-viewer.d.ts +23 -0
  168. package/dist/types/components/snk-custom-slot-guide/snk-custom-slot-guide.d.ts +16 -0
  169. package/dist/types/components/snk-form-config/FormConfigHelper.d.ts +6 -1
  170. package/dist/types/components/snk-form-config/SnkFormConfigManager.d.ts +1 -1
  171. package/dist/types/components/snk-form-config/fields-layout/fields-layout.d.ts +2 -2
  172. package/dist/types/components/snk-form-config/guides-configurator/guides-configurator.d.ts +1 -1
  173. package/dist/types/components/snk-form-config/snk-form-config.d.ts +9 -2
  174. package/dist/types/components/snk-grid/snk-grid.d.ts +5 -0
  175. package/dist/types/components/snk-layout-form-config/snk-layout-form-config.d.ts +2 -2
  176. package/dist/types/components/snk-pesquisa/snk-pesquisa.d.ts +8 -0
  177. package/dist/types/components/snk-simple-crud/snk-simple-crud.d.ts +0 -1
  178. package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +12 -4
  179. package/dist/types/components.d.ts +105 -0
  180. package/dist/types/lib/http/data-fetcher/fetchers/pesquisa-fetcher.d.ts +1 -0
  181. package/package.json +1 -1
  182. package/react/components.d.ts +1 -0
  183. package/react/components.js +1 -0
  184. package/react/components.js.map +1 -1
  185. package/dist/sankhyablocks/p-0cf9aa38.js +0 -1
  186. package/dist/sankhyablocks/p-1649f51e.entry.js +0 -1
  187. package/dist/sankhyablocks/p-2c86cfab.entry.js +0 -1
  188. package/dist/sankhyablocks/p-4759912d.entry.js +0 -1
  189. package/dist/sankhyablocks/p-56948f00.entry.js +0 -11
  190. package/dist/sankhyablocks/p-8f73da95.js +0 -1
  191. package/dist/sankhyablocks/p-95c71f5e.entry.js +0 -1
  192. package/dist/sankhyablocks/p-9f2cdaab.entry.js +0 -1
  193. package/dist/sankhyablocks/p-9fe91526.js +0 -1
  194. package/dist/sankhyablocks/p-a5108625.entry.js +0 -1
  195. package/dist/sankhyablocks/p-aae4258d.entry.js +0 -1
  196. package/dist/sankhyablocks/p-af9d79e0.entry.js +0 -1
  197. package/dist/sankhyablocks/p-f25c50f7.entry.js +0 -1
@@ -1,15 +1,15 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-479e1293.js';
2
2
  import { DateUtils, StringUtils, ObjectUtils, WaitingChangeException, SilentException, WarningException, ErrorException, ElementIDUtils, SearchUtils, ArrayUtils, KeyboardManager, OnboardingUtils, DependencyType, DataType, ApplicationContext, ErrorTracking, UserAgentUtils, LockManager, LockManagerOperation } from '@sankhyalabs/core';
3
3
  import { ApplicationUtils } from '@sankhyalabs/ezui/dist/collection/utils';
4
- import { C as ConfigStorage } from './ConfigStorage-568dc227.js';
5
- import { d as dist, D as DataFetcher, U as UrlUtils, S as SnkMessageBuilder } from './DataFetcher-743feb3b.js';
6
- import { A as AutorizationType, a as AuthFetcher } from './auth-fetcher-c353127d.js';
7
- import { P as PreloadManager, D as DataUnitFetcher } from './dataunit-fetcher-7f2c61ca.js';
8
- import { P as PesquisaFetcher } from './ISave-345481c1.js';
4
+ import { C as ConfigStorage } from './ConfigStorage-bd096633.js';
5
+ import { d as dist, D as DataFetcher, U as UrlUtils, S as SnkMessageBuilder } from './DataFetcher-5780ad39.js';
6
+ import { A as AutorizationType, a as AuthFetcher } from './auth-fetcher-28b9d0db.js';
7
+ import { P as PreloadManager, D as DataUnitFetcher } from './dataunit-fetcher-c4251d80.js';
8
+ import { P as PesquisaFetcher } from './ISave-8a22ec18.js';
9
9
  import { T as TEMPLATES_SKELETON } from './constants-7b422de0.js';
10
10
  import './index-b40568ff.js';
11
11
  import './filter-item-type.enum-d45e026f.js';
12
- import { F as FormConfigFetcher } from './form-config-fetcher-898d2dd1.js';
12
+ import { F as FormConfigFetcher } from './form-config-fetcher-d0536a71.js';
13
13
  import './PrintUtils-3e4ff0f5.js';
14
14
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
15
15
  import '@sankhyalabs/ezui/dist/collection/utils/constants';
@@ -389,32 +389,40 @@ class RequestListenerFactory {
389
389
  }
390
390
  }
391
391
 
392
+ const executeAdvancedModeSearch = async (argument, options, app, pesquisaFetcher) => {
393
+ const { entity, entityDescription, criteria, searchOptions, isHierarchyEntity, allowsNonAnalytic, executeOnOpen } = options;
394
+ return new Promise((accept, reject) => {
395
+ const pesquisaContent = document.createElement("snk-pesquisa");
396
+ pesquisaContent[ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME] = `entity_${entity}`;
397
+ pesquisaContent.entityName = entity;
398
+ pesquisaContent.argument = argument;
399
+ pesquisaContent.searchLoader = (text) => pesquisaFetcher.loadAdvancedSearch(entity, text, criteria, searchOptions);
400
+ pesquisaContent.isHierarchyEntity = isHierarchyEntity;
401
+ if (isHierarchyEntity) {
402
+ pesquisaContent.treeLoader = (text) => pesquisaFetcher.loadTree(entity, text, criteria, searchOptions);
403
+ pesquisaContent.allowsNonAnalytic = allowsNonAnalytic;
404
+ }
405
+ pesquisaContent.selectItem = (option) => {
406
+ accept(option);
407
+ app.clearPopUpTitle();
408
+ app.closePopUp();
409
+ };
410
+ app.setPopUpTitle(entityDescription);
411
+ app.showPopUp(pesquisaContent, undefined, undefined, reject);
412
+ if (executeOnOpen) {
413
+ pesquisaContent.executeSearch(argument);
414
+ }
415
+ });
416
+ };
417
+
392
418
  const QTD_DETAIL_FIELDS_PREDICTIVE_SEARCH = 6;
393
419
  const INVALID_CONTENT_PATTERNS = ['<img', '<svg'];
394
420
  const executePreparedSearchPlus = async (mode, argument, options, app, pesquisaFetcher) => {
395
421
  var _a;
396
422
  const mdByName = {};
397
- const { entity, entityDescription, criteria, searchOptions, isHierarchyEntity, allowsNonAnalytic } = options;
423
+ const { entity, criteria, searchOptions } = options;
398
424
  if (mode === "ADVANCED") {
399
- return new Promise((accept, reject) => {
400
- const pesquisaContent = document.createElement("snk-pesquisa");
401
- pesquisaContent[ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME] = `entity_${entity}`;
402
- pesquisaContent.entityName = entity;
403
- pesquisaContent.argument = argument;
404
- pesquisaContent.searchLoader = (text) => pesquisaFetcher.loadAdvancedSearch(entity, text, criteria, searchOptions);
405
- pesquisaContent.isHierarchyEntity = isHierarchyEntity;
406
- if (isHierarchyEntity) {
407
- pesquisaContent.treeLoader = (text) => pesquisaFetcher.loadTree(entity, text, criteria, searchOptions);
408
- pesquisaContent.allowsNonAnalytic = allowsNonAnalytic;
409
- }
410
- pesquisaContent.selectItem = (option) => {
411
- accept(option);
412
- app.clearPopUpTitle();
413
- app.closePopUp();
414
- };
415
- app.setPopUpTitle(entityDescription);
416
- app.showPopUp(pesquisaContent, undefined, undefined, reject);
417
- });
425
+ return executeAdvancedModeSearch(argument, options, app, pesquisaFetcher);
418
426
  }
419
427
  else if (mode === "LOAD_DESCRIPTION") {
420
428
  let result = await pesquisaFetcher.loadByCode(entity, argument, criteria, searchOptions);
@@ -451,14 +459,13 @@ const buildOptionItem = (argument, item, fields, descriptionField, pkField) => {
451
459
  const matchFields = item['__matchFields'];
452
460
  const descriptionValue = (_a = item[descriptionField]) !== null && _a !== void 0 ? _a : "";
453
461
  const pkValue = item[pkField];
454
- let searchOption = {
462
+ return {
455
463
  value: pkValue,
456
464
  label: descriptionValue,
457
465
  presentationValue: StringUtils.highlightValue(argument, matchFields, pkValue, fields, true),
458
466
  presentationLabel: descriptionField ? StringUtils.highlightValue(argument, matchFields, descriptionValue, fields, true) : "",
459
467
  details: SearchUtils.buildDetails(argument, fields, item)
460
468
  };
461
- return searchOption;
462
469
  };
463
470
  const filterInvalidFields = (resp, item, mdByName) => {
464
471
  let fieldsMetadata = resp.fieldsMetadata.filter((field) => {
@@ -893,7 +900,7 @@ const SnkApplication = class {
893
900
  if (this._featureFlagsCache.get(featureName) && now < this._featureFlagsCache.get(featureName).expires) {
894
901
  return Promise.resolve(this._featureFlagsCache.get(featureName).isActive);
895
902
  }
896
- //Caso ocorra um erro nessa chamada, o reject do error é feito automaticamente
903
+ //Caso ocorra um erro nessa chamada, o reject do error é feito automaticamente
897
904
  const result = await DataFetcher.get().callServiceBroker("SystemUtilsSP.featureIsActive", JSON.stringify(payload));
898
905
  const isActive = result.isActive;
899
906
  this._featureFlagsCache.set(featureName, {
@@ -1384,52 +1391,57 @@ const SnkApplication = class {
1384
1391
  */
1385
1392
  async executePreparedSearch(mode, argument, options) {
1386
1393
  const mdByName = {};
1387
- const { entity, entityDescription, criteria, searchOptions, isHierarchyEntity, allowsNonAnalytic, useSearchPlus } = options;
1394
+ const { entity, criteria, searchOptions, useSearchPlus } = options;
1388
1395
  if (useSearchPlus) {
1389
1396
  return executePreparedSearchPlus(mode, argument, options, this, this.pesquisaFetcher);
1390
1397
  }
1391
1398
  if (mode === "ADVANCED") {
1392
- return new Promise((accept, reject) => {
1393
- const pesquisaContent = document.createElement("snk-pesquisa");
1394
- pesquisaContent[ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME] = `entity_${entity}`;
1395
- pesquisaContent.entityName = entity;
1396
- pesquisaContent.argument = argument;
1397
- pesquisaContent.searchLoader = (text) => this.pesquisaFetcher.loadAdvancedSearch(entity, text, criteria, searchOptions);
1398
- pesquisaContent.isHierarchyEntity = isHierarchyEntity;
1399
- if (isHierarchyEntity) {
1400
- pesquisaContent.treeLoader = (text) => this.pesquisaFetcher.loadTree(entity, text, criteria, searchOptions);
1401
- pesquisaContent.allowsNonAnalytic = allowsNonAnalytic;
1402
- }
1403
- pesquisaContent.selectItem = (option) => {
1404
- accept(option);
1405
- this.clearPopUpTitle();
1406
- this.closePopUp();
1407
- };
1408
- this.setPopUpTitle(entityDescription);
1409
- this.showPopUp(pesquisaContent, undefined, undefined, reject);
1410
- });
1399
+ return executeAdvancedModeSearch(argument, options, this, this.pesquisaFetcher);
1411
1400
  }
1412
- else {
1413
- return new Promise((resolve, reject) => {
1414
- this.pesquisaFetcher.loadAdvancedSearch(entity, argument, criteria, searchOptions)
1415
- .then(result => {
1416
- result = ObjectUtils.stringToObject(result.json.$);
1417
- let descriptionField = result.descriptionField;
1418
- let pkField = result.pkField;
1419
- const list = [];
1420
- result.data.forEach((item) => {
1421
- let fieldsMetadata = this.filterInvalidFields(result, item, mdByName);
1422
- let qtyFields = 6;
1423
- let fields = this.filterMathFields(item['__matchFields'], fieldsMetadata, qtyFields, mdByName);
1424
- list.push(this.builOptionItem(argument, item, fields, descriptionField, pkField));
1425
- });
1426
- resolve(list);
1427
- })
1428
- .catch(error => {
1429
- reject(error);
1430
- });
1401
+ return new Promise((resolve, reject) => {
1402
+ this.pesquisaFetcher.loadAdvancedSearch(entity, argument, criteria, searchOptions)
1403
+ .then(result => {
1404
+ result = ObjectUtils.stringToObject(result.json.$);
1405
+ resolve(this.buildSearchResultList(result, mdByName, argument));
1406
+ })
1407
+ .catch(error => {
1408
+ reject(error);
1431
1409
  });
1432
- }
1410
+ });
1411
+ }
1412
+ /**
1413
+ * Obtém as opções em componentes de pesquisa além dos metadados como showMore e entityPk.
1414
+ * @param {string} argument - O argumento da pesquisa.
1415
+ * @param {any} options - Opções preparadas para a pesquisa.
1416
+ * @returns {Promise<Array<IOption> | IOption>} Uma lista de opções ou uma única opção.
1417
+ * @async
1418
+ */
1419
+ async executePreparedSearchWithFullResponse(argument, options) {
1420
+ const mdByName = {};
1421
+ const { entity, criteria, searchOptions } = options;
1422
+ return new Promise((resolve, reject) => {
1423
+ this.pesquisaFetcher.loadAdvancedSearch(entity, argument, criteria, searchOptions)
1424
+ .then(result => {
1425
+ result = ObjectUtils.stringToObject(result.json.$);
1426
+ result.data = this.buildSearchResultList(result, mdByName, argument);
1427
+ resolve(result);
1428
+ })
1429
+ .catch(error => {
1430
+ reject(error);
1431
+ });
1432
+ });
1433
+ }
1434
+ buildSearchResultList(result, mdByName, argument) {
1435
+ let descriptionField = result.descriptionField;
1436
+ let pkField = result.pkField;
1437
+ const list = [];
1438
+ result.data.forEach((item) => {
1439
+ let fieldsMetadata = this.filterInvalidFields(result, item, mdByName);
1440
+ let qtyFields = 6;
1441
+ let fields = this.filterMathFields(item['__matchFields'], fieldsMetadata, qtyFields, mdByName);
1442
+ list.push(this.builOptionItem(argument, item, fields, descriptionField, pkField));
1443
+ });
1444
+ return list;
1433
1445
  }
1434
1446
  /**
1435
1447
  * Obtém `true` caso a tela esteja em modo de debug.
@@ -1,13 +1,13 @@
1
1
  import { r as registerInstance, c as createEvent, h } from './index-479e1293.js';
2
2
  import { ApplicationContext, DataType, Action, UserInterface, StringUtils, DataUnitLoaderUtils, DataUnit } from '@sankhyalabs/core';
3
- import { D as DataFetcher, S as SnkMessageBuilder } from './DataFetcher-743feb3b.js';
4
- import { S as SaveErrorsEnum } from './ISave-345481c1.js';
3
+ import { D as DataFetcher, S as SnkMessageBuilder } from './DataFetcher-5780ad39.js';
4
+ import { S as SaveErrorsEnum } from './ISave-8a22ec18.js';
5
5
  import './index-b40568ff.js';
6
- import { P as PreloadManager, D as DataUnitFetcher, I as InMemoryLoader } from './dataunit-fetcher-7f2c61ca.js';
6
+ import { P as PreloadManager, D as DataUnitFetcher, I as InMemoryLoader } from './dataunit-fetcher-c4251d80.js';
7
7
  import './filter-item-type.enum-d45e026f.js';
8
- import './form-config-fetcher-898d2dd1.js';
8
+ import './form-config-fetcher-d0536a71.js';
9
9
  import { V as VIEW_MODE } from './constants-7b422de0.js';
10
- import { A as AutorizationType } from './auth-fetcher-c353127d.js';
10
+ import { A as AutorizationType } from './auth-fetcher-28b9d0db.js';
11
11
  import { T as TaskbarElement } from './taskbar-elements-faaf5d8f.js';
12
12
  import './PrintUtils-3e4ff0f5.js';
13
13
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
@@ -1,15 +1,15 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-479e1293.js';
2
2
  import { Action, StringUtils, ElementIDUtils, ApplicationContext, KeyboardManager } from '@sankhyalabs/core';
3
- import './DataFetcher-743feb3b.js';
4
- import './ISave-345481c1.js';
3
+ import './DataFetcher-5780ad39.js';
4
+ import './ISave-8a22ec18.js';
5
5
  import { P as PresentationMode, E as ExporterStrategy } from './index-b40568ff.js';
6
6
  import '@sankhyalabs/ezui/dist/collection/utils/constants';
7
7
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
8
- import './dataunit-fetcher-7f2c61ca.js';
8
+ import './dataunit-fetcher-c4251d80.js';
9
9
  import './filter-item-type.enum-d45e026f.js';
10
- import './form-config-fetcher-898d2dd1.js';
10
+ import './form-config-fetcher-d0536a71.js';
11
11
  import { V as VIEW_MODE } from './constants-7b422de0.js';
12
- import { A as AutorizationType } from './auth-fetcher-c353127d.js';
12
+ import { A as AutorizationType } from './auth-fetcher-28b9d0db.js';
13
13
  import { S as ServicesNumberingConfig } from './ServicesNumberingConfig-2f7b050e.js';
14
14
  import { T as TaskbarElement } from './taskbar-elements-faaf5d8f.js';
15
15
  import './PrintUtils-3e4ff0f5.js';
@@ -23,6 +23,7 @@ const snkCrudCss = ".sc-snk-crud-h{display:flex;flex-direction:column;height:100
23
23
  const SnkCrud = class {
24
24
  constructor(hostRef) {
25
25
  registerInstance(this, hostRef);
26
+ this.snkShowGuide = createEvent(this, "snkShowGuide", 7);
26
27
  this.actionClick = createEvent(this, "actionClick", 7);
27
28
  this.configuratorSave = createEvent(this, "configuratorSave", 7);
28
29
  this.configuratorCancel = createEvent(this, "configuratorCancel", 7);
@@ -32,6 +33,38 @@ const SnkCrud = class {
32
33
  this._viewHistory = [];
33
34
  this._customEditors = new Map();
34
35
  this._customRenders = new Map();
36
+ this.loadEntitySuggestions = async (argument) => {
37
+ var _a;
38
+ const value = (_a = argument === null || argument === void 0 ? void 0 : argument.argument) !== null && _a !== void 0 ? _a : '';
39
+ const mode = (argument === null || argument === void 0 ? void 0 : argument.mode) || "PREDICTIVE";
40
+ if (!value || value.trim().length === 0) {
41
+ return [];
42
+ }
43
+ try {
44
+ this._showMoreOnSearch = false;
45
+ const entityName = this._snkDataUnit.entityName;
46
+ if (mode === "PREDICTIVE") {
47
+ return await this.handlePredictiveSearch(value, entityName);
48
+ }
49
+ return await this._application.executePreparedSearch(mode, value, this.buildSearchOptions(entityName));
50
+ }
51
+ catch (error) {
52
+ console.error('Erro ao carregar sugestões de entidades:', error);
53
+ return [];
54
+ }
55
+ };
56
+ this.searchEntitySelect = async (item) => {
57
+ if (!this._entityPKField || !item) {
58
+ return;
59
+ }
60
+ try {
61
+ const pk = [{ name: this._entityPKField, value: item.value }];
62
+ await this.refreshDataUnitByPk(pk);
63
+ }
64
+ catch (error) {
65
+ console.error('Erro ao selecionar entidade:', error);
66
+ }
67
+ };
35
68
  this.dataUnitInterceptor = {
36
69
  interceptAction: (action) => {
37
70
  if (action.type === Action.DATA_SAVED) {
@@ -48,6 +81,8 @@ const SnkCrud = class {
48
81
  this._resourceID = undefined;
49
82
  this.customContainerId = `SNK-CRUD-CUSTOM-CONTAINER-${StringUtils.generateUUID()}`;
50
83
  this.numberingConfig = undefined;
84
+ this._showMoreOnSearch = false;
85
+ this._entityPKField = undefined;
51
86
  this.enableLockManagerLoadingComp = false;
52
87
  this.enableLockManagerTaskbarClick = false;
53
88
  this.configName = undefined;
@@ -76,6 +111,8 @@ const SnkCrud = class {
76
111
  this.layoutFormConfig = true;
77
112
  this.multipleEditionEnabled = true;
78
113
  this.paginationCounterMode = 'auto';
114
+ this.customGuidesConfig = [];
115
+ this.showEntitySearch = true;
79
116
  this.disableNumberingConfig = false;
80
117
  }
81
118
  /**
@@ -371,6 +408,49 @@ const SnkCrud = class {
371
408
  var _a;
372
409
  (_a = this._keyboardManager) === null || _a === void 0 ? void 0 : _a.unbindAllShortcutKeys();
373
410
  }
411
+ async handlePredictiveSearch(argument, entityName) {
412
+ var _a, _b;
413
+ const response = await this._application.executePreparedSearchWithFullResponse(argument, this.buildSearchOptions(entityName, 5));
414
+ this._showMoreOnSearch = (_a = response === null || response === void 0 ? void 0 : response.hasMore) !== null && _a !== void 0 ? _a : false;
415
+ this._entityPKField = response === null || response === void 0 ? void 0 : response.pkField;
416
+ return (_b = response === null || response === void 0 ? void 0 : response.data) !== null && _b !== void 0 ? _b : [];
417
+ }
418
+ async refreshDataUnitByPk(pks) {
419
+ try {
420
+ const pkField = pks[0].name;
421
+ const pkValue = pks[0].value;
422
+ // Criar filtro para a busca específica
423
+ const quickFilter = {
424
+ term: '',
425
+ filter: {
426
+ name: '',
427
+ params: [],
428
+ expression: `(${pkField} = ${pkValue})`
429
+ }
430
+ };
431
+ // Carregar dados com o filtro aplicado diretamente
432
+ await this._dataUnit.loadData(quickFilter);
433
+ // Navegar para o formulário se houver apenas um registro
434
+ if (this._dataUnit.records.length === 1) {
435
+ this._dataUnit.selectFirst();
436
+ this.gridToForm(true);
437
+ }
438
+ }
439
+ catch (error) {
440
+ console.error('Erro ao atualizar dataset:', error);
441
+ }
442
+ }
443
+ buildSearchOptions(entityName, limit) {
444
+ return {
445
+ entity: entityName,
446
+ entityDescription: entityName,
447
+ executeOnOpen: true,
448
+ searchOptions: {
449
+ localEntityName: entityName,
450
+ limit,
451
+ }
452
+ };
453
+ }
374
454
  async toggleView() {
375
455
  const currentView = await this._viewStack.getSelectedIndex();
376
456
  this.setViewMode(VIEW_MODE.GRID === currentView ? VIEW_MODE.FORM : VIEW_MODE.GRID);
@@ -477,12 +557,23 @@ const SnkCrud = class {
477
557
  }
478
558
  this.configuratorCancel.emit();
479
559
  }
560
+ renderCustomGuideSlots() {
561
+ if (!this.customGuidesConfig)
562
+ return;
563
+ return this.customGuidesConfig.map(g => h("slot", { name: g.id }));
564
+ }
565
+ renderDynamicSearch(slotName) {
566
+ var _a;
567
+ if (!this.showEntitySearch || ((_a = this._dataState) === null || _a === void 0 ? void 0 : _a.insertionMode) === true)
568
+ return;
569
+ return (h("div", { slot: slotName, class: "entity-search-container", style: { position: 'relative', display: 'inline-block', marginLeft: '10px', minWidth: '200px' } }, h("ez-search", { label: "Buscar registros", optionLoader: this.loadEntitySuggestions, onEzChange: (evt) => this.searchEntitySelect(evt.detail), mode: "slim", showMore: this._showMoreOnSearch, suppressEmptyOption: true, suppressInputPersist: true })));
570
+ }
480
571
  render() {
481
572
  if (this._resourceID == undefined) {
482
573
  return;
483
574
  }
484
575
  this._snkDataUnit.ignoreSaveMessage = (this._currentViewMode === VIEW_MODE.GRID && !this.enableGridInsert);
485
- return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", { class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full ez-padding--medium' }, h("snk-grid", { ref: (ref) => this._snkGrid = ref, class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full', filterBarTitle: this.filterBarTitle, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, recordsValidator: this.recordsValidator, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID, disablePersonalizedFilter: this.disablePersonalizedFilter, gridLegacyConfigName: this.gridLegacyConfigName, filterBarLegacyConfigName: this.filterBarLegacyConfigName, autoLoad: this.autoLoad, autoFocus: this.autoFocus, enableGridInsert: this.enableGridInsert, enableLockManagerTaskbarClick: this.enableLockManagerTaskbarClick, enableLockManagerLoadingComp: this.enableLockManagerLoadingComp, strategyExporter: this.strategyExporter, multipleEditionEnabled: this.multipleEditionEnabled, paginationCounterMode: this.paginationCounterMode }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, recordsValidator: this.recordsValidator, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId, formLegacyConfigName: this.formLegacyConfigName, enableGridInsert: this.enableGridInsert, getCustomTitle: this.setCustomFormTitle, ignoreReadOnlyFormFields: this.ignoreReadOnlyFormFields }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", { tabIndex: "0" }, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, entityName: this._snkDataUnit.entityName, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId, layoutFormConfig: this.layoutFormConfig })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
576
+ return (h(Host, null, h("ez-view-stack", { ref: (ref) => this._viewStack = ref, "data-element-id": "crud" }, h("stack-item", { class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full ez-padding--medium' }, h("snk-grid", { ref: (ref) => this._snkGrid = ref, class: 'ez-flex ez-flex--column ez-size-height--full ez-size-width--full', filterBarTitle: this.filterBarTitle, "data-element-id": "crud_grid", configName: this.configName, onGridDoubleClick: () => this.gridToForm(true), taskbarManager: this.taskbarManager, onActionClick: evt => this.executeAction(evt.detail), messagesBuilder: this.messagesBuilder, actionsList: this.actionsList, statusResolver: this.statusResolver, multipleSelection: this.multipleSelection, presentationMode: this.presentationMode, recordsValidator: this.recordsValidator, selectionToastConfig: this.selectionToastConfig, useEnterLikeTab: this.useEnterLikeTab, canEdit: this._canEdit, resourceID: this._resourceID, disablePersonalizedFilter: this.disablePersonalizedFilter, gridLegacyConfigName: this.gridLegacyConfigName, filterBarLegacyConfigName: this.filterBarLegacyConfigName, autoLoad: this.autoLoad, autoFocus: this.autoFocus, enableGridInsert: this.enableGridInsert, enableLockManagerTaskbarClick: this.enableLockManagerTaskbarClick, enableLockManagerLoadingComp: this.enableLockManagerLoadingComp, strategyExporter: this.strategyExporter, multipleEditionEnabled: this.multipleEditionEnabled, paginationCounterMode: this.paginationCounterMode }, h("slot", { name: "GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "SnkGridHeader" }), h("slot", { name: "SnkGridFooter" }), h("slot", { name: "SnkGridTaskBar" }), this.renderDynamicSearch("GRID_HEADER_DYNAMIC_SEARCH"))), h("stack-item", null, h("snk-guides-viewer", { ref: ref => this._guidesViewer = ref, customGuidesConfig: this.customGuidesConfig, entityPath: this._snkDataUnit.entityName, messagesBuilder: this.messagesBuilder, onExit: () => this.setViewMode(VIEW_MODE.GRID), dataState: this._dataState, dataUnit: this._dataUnit, actionsList: this.actionsList, taskbarManager: this.taskbarManager, configName: this.configName, onActionClick: evt => this.executeAction(evt.detail), presentationMode: this.presentationMode, "data-element-id": "crud_form", canEdit: this._canEdit, recordsValidator: this.recordsValidator, resourceID: this._resourceID, detailTaskbarCustomContainerId: this.customContainerId, formLegacyConfigName: this.formLegacyConfigName, enableGridInsert: this.enableGridInsert, getCustomTitle: this.setCustomFormTitle, ignoreReadOnlyFormFields: this.ignoreReadOnlyFormFields }, h("slot", { name: "GUIDES_VIEWER_TASKBAR_CUSTOM_ELEMENTS" }), this.renderCustomGuideSlots(), this.renderDynamicSearch("GUIDES_VIEWER_DYNAMIC_SEARCH"), h("slot", { name: "SnkFormTaskBar" }))), h("stack-item", { tabIndex: "0" }, h("snk-attach", { registerKey: this.attachmentRegisterKey, messagesBuilder: this.messagesBuilder, entityName: this._snkDataUnit.entityName, onBack: this.backView.bind(this) })), h("snk-configurator", { ref: (ref) => this._snkConfigurator = ref, entityName: this._snkDataUnit.entityName, viewMode: this._currentViewMode, messagesBuilder: this.messagesBuilder, onConfigSelected: (evt) => this.setViewMode(evt.detail), onOpenConfig: (evt) => this.openConfig(evt.detail), showActionButtons: this.showActionButtons, onSave: evt => this.handleConfiguratorEvent(evt, 'SAVE'), onCancel: evt => this.handleConfiguratorEvent(evt, 'CANCEL'), resourceID: this._resourceID, customContainerId: this.customContainerId, layoutFormConfig: this.layoutFormConfig })), h("div", { id: `${this.customContainerId}` }, h("slot", { name: "SnkConfigContainerSlot" }), h("slot", { name: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS" }), h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" }))));
486
577
  }
487
578
  get _element() { return getElement(this); }
488
579
  static get watchers() { return {
@@ -0,0 +1,36 @@
1
+ import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-479e1293.js';
2
+
3
+ const snkCustomSlotGuideCss = ".sc-snk-custom-slot-guide-h{display:none}";
4
+
5
+ const SnkCustomSlotGuide = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ this.snkCustomSlotGuideLoaded = createEvent(this, "snkCustomSlotGuideLoaded", 7);
9
+ this.slotName = 'CUSTOM_SLOT_GUIDE';
10
+ }
11
+ onGuideChange(evt) {
12
+ const guideName = evt.detail;
13
+ if (guideName === this.slotName) {
14
+ this._element.style.setProperty('display', 'block');
15
+ }
16
+ else {
17
+ this._element.style.setProperty('display', 'none');
18
+ }
19
+ }
20
+ onFormConfigVisibilityChange(evt) {
21
+ const isFormConfigVisible = evt.detail;
22
+ if (isFormConfigVisible) {
23
+ this._element.style.setProperty('display', 'none');
24
+ }
25
+ }
26
+ componentDidLoad() {
27
+ this.snkCustomSlotGuideLoaded.emit(this.slotName);
28
+ }
29
+ render() {
30
+ return (h(Host, { slot: this.slotName, id: this.slotName, class: "custom-slot-guide-container" }, h("slot", null)));
31
+ }
32
+ get _element() { return getElement(this); }
33
+ };
34
+ SnkCustomSlotGuide.style = snkCustomSlotGuideCss;
35
+
36
+ export { SnkCustomSlotGuide as snk_custom_slot_guide };
@@ -4,14 +4,14 @@ import { ApplicationUtils, DialogType } from '@sankhyalabs/ezui/dist/collection/
4
4
  import { I as IExportType } from './IFetchDataExporterParams-d73bed3d.js';
5
5
  import { D as DataExporterOption, a as DataExporterType, b as DataExporterFormat } from './index-b40568ff.js';
6
6
  import { R as REPORT_LAUNCHER_RESOURCE_ID } from './constants-7b422de0.js';
7
- import { D as DataFetcher } from './DataFetcher-743feb3b.js';
8
- import { S as SnkDataUnit } from './snk-data-unit-60b338c5.js';
9
- import './ISave-345481c1.js';
7
+ import { D as DataFetcher } from './DataFetcher-5780ad39.js';
8
+ import { S as SnkDataUnit } from './snk-data-unit-4a1ef77f.js';
9
+ import './ISave-8a22ec18.js';
10
10
  import '@sankhyalabs/ezui/dist/collection/utils/constants';
11
11
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
12
- import './dataunit-fetcher-7f2c61ca.js';
12
+ import './dataunit-fetcher-c4251d80.js';
13
13
  import './filter-item-type.enum-d45e026f.js';
14
- import './form-config-fetcher-898d2dd1.js';
14
+ import './form-config-fetcher-d0536a71.js';
15
15
  import './PrintUtils-3e4ff0f5.js';
16
16
  import '@sankhyalabs/core/dist/dataunit/metadata/DataType';
17
17
  import './GetSelectedRecordsIDsInfo-9fa41508.js';
@@ -1,8 +1,8 @@
1
1
  import { r as registerInstance, c as createEvent, h, g as getElement, H as Host } from './index-479e1293.js';
2
2
  import { ApplicationContext, Action, ObjectUtils, DataUnitAction, StringUtils } from '@sankhyalabs/core';
3
3
  import { ApplicationUtils, DialogType } from '@sankhyalabs/ezui/dist/collection/utils';
4
- import { O as OperationMap, S as SnkMessageBuilder } from './DataFetcher-743feb3b.js';
5
- import { g as getRecordValue, a as DatasetStrategy } from './dataunit-fetcher-7f2c61ca.js';
4
+ import { O as OperationMap, S as SnkMessageBuilder } from './DataFetcher-5780ad39.js';
5
+ import { g as getRecordValue, a as DatasetStrategy } from './dataunit-fetcher-c4251d80.js';
6
6
  import { convertType } from '@sankhyalabs/core/dist/dataunit/metadata/DataType';
7
7
  import { g as getSelectedRecordsIDsInfo } from './GetSelectedRecordsIDsInfo-9fa41508.js';
8
8
 
@@ -614,6 +614,8 @@ const SnkDataUnit = class {
614
614
  return records;
615
615
  const parentSelectedRecord = parentDataUnit.getSelectedRecord();
616
616
  const selfInfo = parentDataUnit === null || parentDataUnit === void 0 ? void 0 : parentDataUnit.getChildInfo(this.getCleanDataUnitName());
617
+ if (!selfInfo)
618
+ return records;
617
619
  const { links } = selfInfo;
618
620
  if (!links || links.length === 0)
619
621
  return records;
@@ -1,11 +1,11 @@
1
- export { S as snk_data_unit } from './snk-data-unit-60b338c5.js';
1
+ export { S as snk_data_unit } from './snk-data-unit-4a1ef77f.js';
2
2
  import './index-479e1293.js';
3
3
  import '@sankhyalabs/core';
4
4
  import '@sankhyalabs/ezui/dist/collection/utils';
5
- import './DataFetcher-743feb3b.js';
5
+ import './DataFetcher-5780ad39.js';
6
6
  import './PrintUtils-3e4ff0f5.js';
7
7
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
8
- import './dataunit-fetcher-7f2c61ca.js';
8
+ import './dataunit-fetcher-c4251d80.js';
9
9
  import '@sankhyalabs/ezui/dist/collection/utils/constants';
10
10
  import '@sankhyalabs/ezui/dist/collection/components/ez-grid/utils';
11
11
  import '@sankhyalabs/core/dist/utils/SortingUtils';
@@ -1,20 +1,20 @@
1
1
  import { r as registerInstance, c as createEvent, f as forceUpdate, h, H as Host, g as getElement } from './index-479e1293.js';
2
2
  import { Action, StringUtils, KeyboardManager } from '@sankhyalabs/core';
3
- import { S as SnkFormConfigManager } from './SnkFormConfigManager-d61df0c8.js';
3
+ import { S as SnkFormConfigManager } from './SnkFormConfigManager-437e98bb.js';
4
4
  import { FormMetadata, buildFormMetadata } from '@sankhyalabs/ezui/dist/collection/utils/form';
5
- import { S as SnkMessageBuilder } from './DataFetcher-743feb3b.js';
6
- import './ISave-345481c1.js';
5
+ import { S as SnkMessageBuilder } from './DataFetcher-5780ad39.js';
6
+ import './ISave-8a22ec18.js';
7
7
  import { P as PresentationMode } from './index-b40568ff.js';
8
8
  import '@sankhyalabs/ezui/dist/collection/utils/constants';
9
9
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
10
- import './dataunit-fetcher-7f2c61ca.js';
10
+ import './dataunit-fetcher-c4251d80.js';
11
11
  import './filter-item-type.enum-d45e026f.js';
12
- import './form-config-fetcher-898d2dd1.js';
12
+ import './form-config-fetcher-d0536a71.js';
13
13
  import { V as VIEW_MODE } from './constants-7b422de0.js';
14
14
  import { T as TaskbarElement } from './taskbar-elements-faaf5d8f.js';
15
- import { S as SnkGuidesViewer } from './snk-guides-viewer-339e10b3.js';
15
+ import { S as SnkGuidesViewer } from './snk-guides-viewer-c182d058.js';
16
16
  import { buildFieldSearch, SHORTCUT_SEARCH_FIELD } from '@sankhyalabs/ezui/dist/collection/utils';
17
- import './ConfigStorage-568dc227.js';
17
+ import './ConfigStorage-bd096633.js';
18
18
  import './PrintUtils-3e4ff0f5.js';
19
19
  import '@sankhyalabs/ezui/dist/collection/components/ez-grid/utils';
20
20
  import '@sankhyalabs/core/dist/utils/SortingUtils';
@@ -1,7 +1,7 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-479e1293.js';
2
2
  import { DataType, StringUtils, ObjectUtils, ElementIDUtils, ErrorException, ApplicationContext, LockManager, LockManagerOperation, DateUtils, MaskFormatter, KeyboardManager, FloatingManager, ArrayUtils } from '@sankhyalabs/core';
3
3
  import { EzScrollDirection } from '@sankhyalabs/ezui/dist/collection/components/ez-scroller/EzScrollDirection';
4
- import { C as ConfigStorage } from './ConfigStorage-568dc227.js';
4
+ import { C as ConfigStorage } from './ConfigStorage-bd096633.js';
5
5
  import { P as PersonalizedFilterUtils } from './PersonalizedFilterUtils-2db38ff2.js';
6
6
  import { toString } from '@sankhyalabs/core/dist/dataunit/metadata/DataType';
7
7
  import { F as FilterItemType } from './filter-item-type.enum-d45e026f.js';
@@ -12,8 +12,8 @@ import { ApplicationUtils } from '@sankhyalabs/ezui/dist/collection/utils';
12
12
  import { A as ActionDefaultFilter } from './default-filters-50105e43.js';
13
13
  import { F as FilterType } from './filter-type.enum-f6a8fe23.js';
14
14
  import { g as getInvalidFilters } from './filter-validate-faf51fa9.js';
15
- import './form-config-fetcher-898d2dd1.js';
16
- import './DataFetcher-743feb3b.js';
15
+ import './form-config-fetcher-d0536a71.js';
16
+ import './DataFetcher-5780ad39.js';
17
17
  import './PrintUtils-3e4ff0f5.js';
18
18
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
19
19
 
@@ -1,11 +1,11 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-479e1293.js';
2
2
  import { ElementIDUtils, ObjectUtils } from '@sankhyalabs/core';
3
- import { C as ConfigStorage } from './ConfigStorage-568dc227.js';
3
+ import { C as ConfigStorage } from './ConfigStorage-bd096633.js';
4
4
  import { E as EPresentationMode } from './presentationMode-783bbf9d.js';
5
5
  import { F as FilterItemType } from './filter-item-type.enum-d45e026f.js';
6
6
  import { F as FilterType } from './filter-type.enum-f6a8fe23.js';
7
- import './form-config-fetcher-898d2dd1.js';
8
- import './DataFetcher-743feb3b.js';
7
+ import './form-config-fetcher-d0536a71.js';
8
+ import './DataFetcher-5780ad39.js';
9
9
  import './PrintUtils-3e4ff0f5.js';
10
10
  import '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
11
11
 
@@ -13,7 +13,7 @@ const SnkFormView = class {
13
13
  this.formItemsReady = createEvent(this, "formItemsReady", 7);
14
14
  this._customEditors = new Map();
15
15
  this._fieldProps = new Map();
16
- this._singleColumn = true;
16
+ this._singleColumn = false;
17
17
  this.levelPath = undefined;
18
18
  this.fieldSearch = undefined;
19
19
  this.label = undefined;
@@ -151,11 +151,7 @@ const SnkFormView = class {
151
151
  }
152
152
  }
153
153
  setSingleColumn(layoutFormConfig) {
154
- if (!(layoutFormConfig === null || layoutFormConfig === void 0 ? void 0 : layoutFormConfig.config)) {
155
- this._singleColumn = true;
156
- return;
157
- }
158
- this._singleColumn = (layoutFormConfig.config === FormLayout.CASCADE);
154
+ this._singleColumn = (layoutFormConfig === null || layoutFormConfig === void 0 ? void 0 : layoutFormConfig.config) === FormLayout.CASCADE;
159
155
  }
160
156
  registerNotifyListeners(layoutFormConfig) {
161
157
  if (!layoutFormConfig)