@sankhyalabs/sankhyablocks 8.15.0-dev.1 → 8.15.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.
- package/dist/cjs/{ConfigStorage-0d507a8f.js → ConfigStorage-302bbbd4.js} +25 -15
- package/dist/cjs/{ISave-d68ce3cd.js → ISave-e91b70a7.js} +1 -0
- package/dist/cjs/{SnkFormConfigManager-467907f6.js → SnkFormConfigManager-71c4768e.js} +1 -1
- package/dist/cjs/{SnkMessageBuilder-7293d0ad.js → SnkMessageBuilder-e7dcf408.js} +13 -0
- package/dist/cjs/{index-0e663819.js → index-0922807b.js} +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{dataunit-fetcher-bdaf9482.js → pesquisa-fetcher-7a08d110.js} +205 -12
- package/dist/cjs/sankhyablocks.cjs.js +1 -1
- package/dist/cjs/snk-actions-button_2.cjs.entry.js +21 -5
- package/dist/cjs/snk-application.cjs.entry.js +65 -6
- package/dist/cjs/snk-attach.cjs.entry.js +395 -57
- package/dist/cjs/snk-crud.cjs.entry.js +5 -6
- package/dist/cjs/snk-data-exporter.cjs.entry.js +4 -4
- package/dist/cjs/{snk-data-unit-1bc69073.js → snk-data-unit-82c08a8c.js} +1 -1
- package/dist/cjs/snk-data-unit.cjs.entry.js +2 -2
- package/dist/cjs/snk-detail-view.cjs.entry.js +8 -9
- package/dist/cjs/snk-filter-bar.cjs.entry.js +33 -5
- package/dist/cjs/snk-filter-item.cjs.entry.js +47 -1
- package/dist/cjs/snk-filter-modal-item.cjs.entry.js +1 -2
- package/dist/cjs/snk-filter-modal.cjs.entry.js +14 -0
- package/dist/cjs/snk-form.cjs.entry.js +2 -2
- package/dist/cjs/snk-grid-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-grid.cjs.entry.js +41 -18
- package/dist/cjs/{snk-guides-viewer-9342bca1.js → snk-guides-viewer-546509df.js} +6 -7
- package/dist/cjs/snk-guides-viewer.cjs.entry.js +7 -8
- package/dist/cjs/snk-personalized-filter.cjs.entry.js +2 -2
- package/dist/cjs/snk-simple-crud.cjs.entry.js +6 -7
- package/dist/cjs/snk-taskbar.cjs.entry.js +2 -2
- package/dist/cjs/{taskbar-elements-b8c428a9.js → taskbar-elements-01b85b99.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/snk-application/snk-application.js +68 -5
- package/dist/collection/components/snk-attach/snk-attach.js +194 -38
- package/dist/collection/components/snk-attach/structure/{crud-config-builder.js → builder/anexo-sistema-crud-config.builder.js} +1 -1
- package/dist/collection/components/snk-attach/structure/builder/attach-crud-config.builder.js +62 -0
- package/dist/collection/components/snk-attach/structure/{taskbar-builder.js → builder/taskbar-builder.js} +1 -1
- package/dist/collection/components/snk-attach/structure/fetcher/facade/fetcher.facade.js +1 -0
- package/dist/collection/components/snk-attach/structure/{data-unit-builder.js → fetcher/factory/anexo-sistema-data-unit.factory.js} +14 -11
- package/dist/collection/components/snk-attach/structure/fetcher/factory/attach-fetcher-data-unit.factory.js +111 -0
- package/dist/collection/components/snk-attach/structure/index.js +6 -3
- package/dist/collection/components/snk-crud/snk-crud.js +2 -2
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +2 -2
- package/dist/collection/components/snk-data-exporter/snk-data-exporter.js +1 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-item.js +47 -1
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +65 -1
- package/dist/collection/components/snk-filter-bar/filter-modal/subcomponents/snk-filter-modal-item.js +0 -1
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.js +62 -3
- package/dist/collection/components/snk-filter-bar/utils/SnkFilterModalFactory.js +3 -1
- package/dist/collection/components/snk-grid/snk-grid.js +39 -16
- package/dist/collection/components/snk-personalized-filter/snk-personalized-filter.js +1 -1
- package/dist/collection/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.js +24 -1
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +1 -1
- package/dist/collection/lib/@types/index.js +1 -0
- package/dist/collection/lib/configs/ConfigStorage.js +24 -14
- package/dist/collection/lib/http/data-fetcher/fetchers/{attach-fetcher.js → AttachFetcher/anexo-sistema-fetcher.js} +16 -15
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/attach-fetcher.js +90 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/facade/attach-fetcher.facade.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/index.js +2 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/interfaces/IDelete.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/AttachFetcher/interfaces/IDownloadKey.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/ISave.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.js +16 -2
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/loadstrategy/DatasetStrategy.js +28 -11
- package/dist/collection/lib/http/data-fetcher/fetchers/filter-bar-config-fetcher.js +1 -1
- package/dist/collection/lib/index.js +1 -1
- package/dist/collection/lib/message/resources/snk-attach.msg.js +13 -0
- package/dist/components/ConfigStorage.js +25 -15
- package/dist/components/SnkMessageBuilder.js +13 -0
- package/dist/components/dataunit-fetcher.js +44 -13
- package/dist/components/index2.js +1 -0
- package/dist/components/snk-actions-button2.js +1 -0
- package/dist/components/snk-application2.js +62 -2
- package/dist/components/snk-attach2.js +400 -56
- package/dist/components/snk-crud.js +1 -1
- package/dist/components/snk-data-exporter2.js +1 -1
- package/dist/components/snk-detail-view2.js +1 -1
- package/dist/components/snk-filter-bar2.js +34 -5
- package/dist/components/snk-filter-item2.js +47 -1
- package/dist/components/snk-filter-modal-item2.js +0 -1
- package/dist/components/snk-filter-modal.js +18 -2
- package/dist/components/snk-grid2.js +38 -15
- package/dist/components/snk-personalized-filter2.js +1 -1
- package/dist/components/taskbar-actions-button2.js +19 -2
- package/dist/esm/{ConfigStorage-379a9cba.js → ConfigStorage-4151acc8.js} +25 -15
- package/dist/esm/{ISave-4412b20c.js → ISave-d8c8bc59.js} +1 -0
- package/dist/esm/{SnkFormConfigManager-587e9030.js → SnkFormConfigManager-5c7d3771.js} +1 -1
- package/dist/esm/{SnkMessageBuilder-ca843d1b.js → SnkMessageBuilder-0fb796b9.js} +13 -0
- package/dist/esm/{index-1564817d.js → index-0ece87a6.js} +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{dataunit-fetcher-cc1650eb.js → pesquisa-fetcher-d6ff9386.js} +206 -14
- package/dist/esm/sankhyablocks.js +1 -1
- package/dist/esm/snk-actions-button_2.entry.js +21 -5
- package/dist/esm/snk-application.entry.js +65 -6
- package/dist/esm/snk-attach.entry.js +396 -58
- package/dist/esm/snk-crud.entry.js +5 -6
- package/dist/esm/snk-data-exporter.entry.js +4 -4
- package/dist/esm/{snk-data-unit-6208ebf0.js → snk-data-unit-5d201fb3.js} +1 -1
- package/dist/esm/snk-data-unit.entry.js +2 -2
- package/dist/esm/snk-detail-view.entry.js +8 -9
- package/dist/esm/snk-filter-bar.entry.js +33 -5
- package/dist/esm/snk-filter-item.entry.js +47 -1
- package/dist/esm/snk-filter-modal-item.entry.js +1 -2
- package/dist/esm/snk-filter-modal.entry.js +14 -0
- package/dist/esm/snk-form.entry.js +2 -2
- package/dist/esm/snk-grid-config.entry.js +1 -1
- package/dist/esm/snk-grid.entry.js +41 -18
- package/dist/esm/{snk-guides-viewer-9ce9588c.js → snk-guides-viewer-4e56a2e0.js} +6 -7
- package/dist/esm/snk-guides-viewer.entry.js +7 -8
- package/dist/esm/snk-personalized-filter.entry.js +2 -2
- package/dist/esm/snk-simple-crud.entry.js +4 -5
- package/dist/esm/snk-taskbar.entry.js +2 -2
- package/dist/esm/{taskbar-elements-26c981af.js → taskbar-elements-d4d0b424.js} +1 -1
- package/dist/sankhyablocks/{p-ff6064e7.js → p-05243555.js} +1 -1
- package/dist/sankhyablocks/{p-729f5f5b.entry.js → p-1d75d9f9.entry.js} +1 -1
- package/dist/sankhyablocks/{p-9e7d65a4.js → p-21749402.js} +1 -1
- package/dist/sankhyablocks/p-32460e98.entry.js +11 -0
- package/dist/sankhyablocks/p-374d03f6.js +1 -0
- package/dist/sankhyablocks/p-38289a55.js +1 -0
- package/dist/sankhyablocks/{p-35fe6e61.entry.js → p-40915359.entry.js} +1 -1
- package/dist/sankhyablocks/p-42af1bbf.js +65 -0
- package/dist/sankhyablocks/{p-2028633c.js → p-573a07c5.js} +1 -1
- package/dist/sankhyablocks/{p-953346b9.entry.js → p-69efa80d.entry.js} +1 -1
- package/dist/sankhyablocks/{p-6977a26c.entry.js → p-71439fd9.entry.js} +1 -1
- package/dist/sankhyablocks/{p-aaa1438e.entry.js → p-761ed32f.entry.js} +1 -1
- package/dist/sankhyablocks/p-7d8d7fe9.entry.js +1 -0
- package/dist/sankhyablocks/p-7f3c7b09.entry.js +1 -0
- package/dist/sankhyablocks/p-8c74258e.entry.js +1 -0
- package/dist/sankhyablocks/p-8f0488b8.entry.js +1 -0
- package/dist/sankhyablocks/p-9ebcfeb6.entry.js +1 -0
- package/dist/sankhyablocks/p-a9e5b094.entry.js +1 -0
- package/dist/sankhyablocks/p-aa95fb2c.js +56 -0
- package/dist/sankhyablocks/p-b05ab13d.entry.js +1 -0
- package/dist/sankhyablocks/p-c2137023.entry.js +1 -0
- package/dist/sankhyablocks/p-c4874327.entry.js +1 -0
- package/dist/sankhyablocks/p-d82f6eda.entry.js +1 -0
- package/dist/sankhyablocks/p-dcb6aad1.entry.js +1 -0
- package/dist/sankhyablocks/p-e0fd9555.entry.js +1 -0
- package/dist/sankhyablocks/p-e8812d8a.js +1 -0
- package/dist/sankhyablocks/{p-32f0935f.js → p-f3d1c48e.js} +1 -1
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-actions-button/subcomponents/snk-actions-form.d.ts +1 -1
- package/dist/types/components/snk-application/snk-application.d.ts +5 -2
- package/dist/types/components/snk-attach/{structure/crud-config-builder.d.ts → interfaces/ICrudConfig.d.ts} +1 -2
- package/dist/types/components/snk-attach/interfaces/TFetcherType.d.ts +1 -0
- package/dist/types/components/snk-attach/snk-attach.d.ts +28 -6
- package/dist/types/components/snk-attach/structure/builder/anexo-sistema-crud-config.builder.d.ts +2 -0
- package/dist/types/components/snk-attach/structure/builder/attach-crud-config.builder.d.ts +31 -0
- package/dist/types/components/snk-attach/structure/{taskbar-builder.d.ts → builder/taskbar-builder.d.ts} +1 -1
- package/dist/types/components/snk-attach/structure/fetcher/facade/fetcher.facade.d.ts +11 -0
- package/dist/types/components/snk-attach/structure/fetcher/factory/anexo-sistema-data-unit.factory.d.ts +17 -0
- package/dist/types/components/snk-attach/structure/fetcher/factory/attach-fetcher-data-unit.factory.d.ts +15 -0
- package/dist/types/components/snk-attach/structure/index.d.ts +6 -3
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-item.d.ts +1 -0
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +14 -1
- package/dist/types/components/snk-filter-bar/snk-filter-bar.d.ts +11 -0
- package/dist/types/components/snk-filter-bar/utils/SnkFilterModalFactory.d.ts +5 -1
- package/dist/types/components/snk-grid/snk-grid.d.ts +1 -0
- package/dist/types/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.d.ts +2 -0
- package/dist/types/components/snk-taskbar/subcomponents/field-search.d.ts +1 -0
- package/dist/types/components.d.ts +70 -13
- package/dist/types/lib/@types/index.d.ts +2 -1
- package/dist/types/lib/configs/ConfigStorage.d.ts +4 -0
- package/dist/types/lib/http/data-fetcher/DataFetcher.d.ts +1 -1
- package/dist/types/lib/http/data-fetcher/fetchers/{attach-fetcher.d.ts → AttachFetcher/anexo-sistema-fetcher.d.ts} +3 -2
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/attach-fetcher.d.ts +11 -0
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/facade/attach-fetcher.facade.d.ts +8 -0
- package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/index.d.ts +3 -0
- package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/ISave.d.ts +2 -1
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/loadstrategy/DatasetStrategy.d.ts +3 -1
- package/dist/types/lib/index.d.ts +1 -1
- package/package.json +8 -6
- package/dist/cjs/pesquisa-fetcher-ef050a47.js +0 -167
- package/dist/esm/pesquisa-fetcher-dd3ca0a5.js +0 -165
- package/dist/sankhyablocks/p-145c4434.js +0 -1
- package/dist/sankhyablocks/p-17dda7a2.entry.js +0 -1
- package/dist/sankhyablocks/p-19f51c6b.entry.js +0 -11
- package/dist/sankhyablocks/p-311c6173.entry.js +0 -1
- package/dist/sankhyablocks/p-4396d1a6.js +0 -56
- package/dist/sankhyablocks/p-44e894af.entry.js +0 -1
- package/dist/sankhyablocks/p-4775a293.entry.js +0 -1
- package/dist/sankhyablocks/p-4b0ea83f.entry.js +0 -1
- package/dist/sankhyablocks/p-5534e08c.js +0 -1
- package/dist/sankhyablocks/p-78777ae0.entry.js +0 -1
- package/dist/sankhyablocks/p-9c3229fc.entry.js +0 -1
- package/dist/sankhyablocks/p-a037f5b4.entry.js +0 -1
- package/dist/sankhyablocks/p-a702a1a2.js +0 -60
- package/dist/sankhyablocks/p-c259545b.entry.js +0 -1
- package/dist/sankhyablocks/p-d1677df0.entry.js +0 -1
- package/dist/sankhyablocks/p-d9bb09b3.js +0 -6
- package/dist/sankhyablocks/p-dd6a8377.js +0 -1
- package/dist/sankhyablocks/p-e138e7d4.entry.js +0 -1
- package/dist/sankhyablocks/p-e1b29d4c.entry.js +0 -1
- package/dist/types/components/snk-attach/structure/data-unit-builder.d.ts +0 -15
- /package/dist/collection/{lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDelete.js → components/snk-attach/interfaces/ICrudConfig.js} +0 -0
- /package/dist/collection/{lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDownloadKey.js → components/snk-attach/interfaces/TFetcherType.js} +0 -0
- /package/dist/collection/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/index.js +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/IDelete.d.ts +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/IDownloadKey.d.ts +0 -0
- /package/dist/types/lib/http/data-fetcher/fetchers/{fecthAttach → AttachFetcher}/interfaces/index.d.ts +0 -0
@@ -1,7 +1,6 @@
|
|
1
1
|
import { IGridConfig } from "@sankhyalabs/ezui/dist/types/components/ez-grid/controller/EzGridController";
|
2
2
|
import { IFormConfig } from '@sankhyalabs/ezui/dist/types/utils/form/interfaces';
|
3
|
-
export type
|
3
|
+
export type TCrudConfig = {
|
4
4
|
grid: IGridConfig;
|
5
5
|
form: IFormConfig;
|
6
6
|
};
|
7
|
-
export declare const crudConfig: CrudConfig;
|
@@ -0,0 +1 @@
|
|
1
|
+
export type TFetcherType = "Attach" | "AnexoSistema" | "Another";
|
@@ -1,12 +1,30 @@
|
|
1
1
|
import { EventEmitter } from "../../stencil-public-runtime";
|
2
2
|
import { DataUnit } from "@sankhyalabs/core";
|
3
|
-
import {
|
3
|
+
import { AttachFetcherFacadeInterface } from "../../lib";
|
4
|
+
import { FetcherFacade } from "./structure";
|
4
5
|
import { SnkMessageBuilder } from "../../lib/message/SnkMessageBuilder";
|
6
|
+
import { TCrudConfig } from "./interfaces/ICrudConfig";
|
7
|
+
import { TFetcherType } from "./interfaces/TFetcherType";
|
5
8
|
export declare class SnkAttach {
|
6
9
|
private _application;
|
7
|
-
private _attachFetcher;
|
8
10
|
private _crudElement;
|
9
|
-
private
|
11
|
+
private _currentDataUnitBuilder;
|
12
|
+
/**
|
13
|
+
* FetcherType define o tipo de fetcher responsável por carregar os dados do DataUnit.
|
14
|
+
*/
|
15
|
+
fetcherType: TFetcherType;
|
16
|
+
/**
|
17
|
+
* Fetcher responsável por carregar os dados do DataUnit.
|
18
|
+
*/
|
19
|
+
fetcher: AttachFetcherFacadeInterface;
|
20
|
+
/**
|
21
|
+
* DataUnit responsável por carregar os dados.
|
22
|
+
*/
|
23
|
+
dataUnit: DataUnit;
|
24
|
+
/**
|
25
|
+
* DataUnitBuilder responsável por implementar dados a serem utilizados no DataUnit.
|
26
|
+
*/
|
27
|
+
dataUnitBuilder: FetcherFacade;
|
10
28
|
/**
|
11
29
|
* Identificação do registro pai.
|
12
30
|
*/
|
@@ -19,13 +37,14 @@ export declare class SnkAttach {
|
|
19
37
|
* Responsável por flexibilizar e padronizar o uso de mensagens nos blocos de construção.
|
20
38
|
*/
|
21
39
|
messagesBuilder: SnkMessageBuilder;
|
22
|
-
|
23
|
-
|
40
|
+
_currentFetcher: AttachFetcherFacadeInterface;
|
41
|
+
_currentDataUnit: DataUnit;
|
42
|
+
crudConfig: TCrudConfig;
|
24
43
|
/**
|
25
44
|
* Evento disparado quando o usuário clica no botão voltar.
|
26
45
|
*/
|
27
46
|
back: EventEmitter<void>;
|
28
|
-
registerKeyWatcher(newRegisterKey: string, oldRegisterKey: string): void
|
47
|
+
registerKeyWatcher(newRegisterKey: string, oldRegisterKey: string): Promise<void> | Promise<import("@sankhyalabs/core").LoadDataResponse>;
|
29
48
|
/**
|
30
49
|
* Conforme mecanismo de mensagens, é possível customizar as mensagens dos blocos de construção
|
31
50
|
* através de um pequeno modulo na estrutura da aplicação:
|
@@ -37,10 +56,13 @@ export declare class SnkAttach {
|
|
37
56
|
private downloadAttachment;
|
38
57
|
private returnToGridMode;
|
39
58
|
private loadAttachmentDataUnit;
|
59
|
+
private loadAnexoSistema;
|
60
|
+
private loadAttach;
|
40
61
|
private disableEditFieldsNotInForm;
|
41
62
|
private handleTaskbarClick;
|
42
63
|
private handleBack;
|
43
64
|
private handleFinish;
|
44
65
|
componentWillLoad(): void;
|
66
|
+
componentWillRender(): void;
|
45
67
|
render(): any;
|
46
68
|
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import { TCrudConfig } from "../../interfaces/ICrudConfig";
|
2
|
+
import { DataType, UserInterface } from "@sankhyalabs/core";
|
3
|
+
export declare const attachCrudConfig: TCrudConfig;
|
4
|
+
export declare const attachFetcherMetadataBuilder: {
|
5
|
+
name: string;
|
6
|
+
label: string;
|
7
|
+
fields: ({
|
8
|
+
name: string;
|
9
|
+
label: string;
|
10
|
+
dataType: DataType;
|
11
|
+
userInterface?: undefined;
|
12
|
+
readOnly?: undefined;
|
13
|
+
required?: undefined;
|
14
|
+
visible?: undefined;
|
15
|
+
properties?: undefined;
|
16
|
+
} | {
|
17
|
+
name: string;
|
18
|
+
label: string;
|
19
|
+
dataType: DataType;
|
20
|
+
userInterface: UserInterface;
|
21
|
+
readOnly: boolean;
|
22
|
+
required: boolean;
|
23
|
+
visible: boolean;
|
24
|
+
properties: {
|
25
|
+
subTitle: string;
|
26
|
+
MAX_FILES: number;
|
27
|
+
STORAGESTRATEGY: string;
|
28
|
+
INTERNAL_FILENAME: string;
|
29
|
+
};
|
30
|
+
})[];
|
31
|
+
};
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import { Change, DataUnit, DataUnitAction, Filter, LoadDataRequest, LoadDataResponse, SavedRecord, UnitMetadata } from "@sankhyalabs/core";
|
2
|
+
import { AttachFetcherFacadeInterface } from "../../../../../lib";
|
3
|
+
export interface FetcherFacade {
|
4
|
+
initLoaders(dataUnit: DataUnit, fetcher: AttachFetcherFacadeInterface, onSuccess: (data?: any) => void): any;
|
5
|
+
metadataLoader(dataUnit: DataUnit): Promise<UnitMetadata>;
|
6
|
+
dataLoader(dataUnit: DataUnit, request: LoadDataRequest): Promise<LoadDataResponse>;
|
7
|
+
saveLoader(changes: Array<Change>, fetcher: AttachFetcherFacadeInterface): Promise<Array<SavedRecord>>;
|
8
|
+
removeLoader(dataUnit: DataUnit, ids: string[], fetcher: AttachFetcherFacadeInterface): Promise<string[]>;
|
9
|
+
getFilters(registerKey: string): Array<Filter>;
|
10
|
+
getInterceptions(dataUnit: DataUnit, action: DataUnitAction, crudRef: HTMLSnkSimpleCrudElement): Promise<DataUnitAction>;
|
11
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import { Change, DataUnit, DataUnitAction, Filter, LoadDataRequest, LoadDataResponse, SavedRecord, UnitMetadata } from "@sankhyalabs/core";
|
2
|
+
import { AttachFetcherFacadeInterface } from "../../../../../lib";
|
3
|
+
import { FetcherFacade } from "../facade/fetcher.facade";
|
4
|
+
export declare class AnexoSistemaDataUnitFactory implements FetcherFacade {
|
5
|
+
private entityName;
|
6
|
+
private getMessage;
|
7
|
+
private _application;
|
8
|
+
private loader;
|
9
|
+
constructor(entityName: string, getMessage: Function);
|
10
|
+
initLoaders(dataUnit: DataUnit, fetcher: AttachFetcherFacadeInterface, onSuccess: (data?: any) => void): void;
|
11
|
+
metadataLoader(dataUnit: DataUnit): Promise<UnitMetadata>;
|
12
|
+
dataLoader(dataUnit: DataUnit, request: LoadDataRequest): Promise<LoadDataResponse>;
|
13
|
+
saveLoader(changes: Array<Change>, fetcher: AttachFetcherFacadeInterface): Promise<Array<SavedRecord>>;
|
14
|
+
removeLoader(dataUnit: DataUnit, ids: string[], fetcher: AttachFetcherFacadeInterface): Promise<string[]>;
|
15
|
+
getFilters(registerKey: string): Array<Filter>;
|
16
|
+
getInterceptions(dataUnit: DataUnit, action: DataUnitAction, crudRef: HTMLSnkSimpleCrudElement): Promise<DataUnitAction>;
|
17
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
import { Change, DataUnit, DataUnitAction, Filter, LoadDataRequest, LoadDataResponse, SavedRecord, UnitMetadata } from "@sankhyalabs/core";
|
2
|
+
import { AttachFetcherFacadeInterface } from "../../../../../lib";
|
3
|
+
import { FetcherFacade } from "../facade/fetcher.facade";
|
4
|
+
export declare class AttachFetcherDataUnitFactory implements FetcherFacade {
|
5
|
+
private getMessage?;
|
6
|
+
private _application;
|
7
|
+
constructor(getMessage?: Function);
|
8
|
+
initLoaders(dataUnit: DataUnit, fetcher: AttachFetcherFacadeInterface, onSuccess: (data?: any) => void): void;
|
9
|
+
metadataLoader(_: DataUnit): Promise<UnitMetadata>;
|
10
|
+
dataLoader(_: DataUnit, request: LoadDataRequest): Promise<LoadDataResponse>;
|
11
|
+
saveLoader(changes: Array<Change>, fetcher: AttachFetcherFacadeInterface): Promise<Array<SavedRecord>>;
|
12
|
+
removeLoader(dataUnit: DataUnit, ids: string[], fetcher: AttachFetcherFacadeInterface): Promise<string[]>;
|
13
|
+
getFilters(): Array<Filter>;
|
14
|
+
getInterceptions(dataUnit: DataUnit, action: DataUnitAction, crudRef: HTMLSnkSimpleCrudElement): Promise<DataUnitAction>;
|
15
|
+
}
|
@@ -1,3 +1,6 @@
|
|
1
|
-
export * from './
|
2
|
-
export * from './
|
3
|
-
export * from './
|
1
|
+
export * from './fetcher/facade/fetcher.facade';
|
2
|
+
export * from './fetcher/factory/anexo-sistema-data-unit.factory';
|
3
|
+
export * from './fetcher/factory/attach-fetcher-data-unit.factory';
|
4
|
+
export * from './builder/taskbar-builder';
|
5
|
+
export * from './builder/anexo-sistema-crud-config.builder';
|
6
|
+
export * from './builder/attach-crud-config.builder';
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import { SnkFilterItemConfig } from '../filter-item/snk-filter-item';
|
2
|
+
import { IPersonalizedFilter } from '../../snk-personalized-filter/interfaces/IPersonalizedFilter';
|
2
3
|
export declare class SnkFilterModal {
|
3
4
|
private _modalTitle;
|
4
5
|
private _cancelButtonLabel;
|
@@ -29,9 +30,21 @@ export declare class SnkFilterModal {
|
|
29
30
|
*/
|
30
31
|
addPersonalizedFilter: () => void;
|
31
32
|
/**
|
32
|
-
* Ação executada ao
|
33
|
+
* Ação executada ao editar um filtro personalizado
|
33
34
|
*/
|
34
35
|
editPersonalizedFilter: (id: string) => void;
|
36
|
+
/**
|
37
|
+
* Ação executada ao deletar um filtro personalizado
|
38
|
+
*/
|
39
|
+
deletePersonalizedFilter: (filter: IPersonalizedFilter, configName: string) => void;
|
40
|
+
/**
|
41
|
+
* Guarda filtros a serem deletados no Apply do modal
|
42
|
+
*/
|
43
|
+
filtersToDelete: IPersonalizedFilter[];
|
44
|
+
/**
|
45
|
+
* Emitido quando um filtro personalizado é deletado.
|
46
|
+
*/
|
47
|
+
deletePersonalizedFilterListener(event: CustomEvent<IPersonalizedFilter>): void;
|
35
48
|
private getCustomMessage;
|
36
49
|
private handleClearAll;
|
37
50
|
private handleClearOthersFilters;
|
@@ -3,7 +3,9 @@ import { Filter, FilterProvider } from '@sankhyalabs/core/dist/dataunit/metadata
|
|
3
3
|
import { EventEmitter } from '../../stencil-public-runtime';
|
4
4
|
import { SnkMessageBuilder } from '../../lib/message/SnkMessageBuilder';
|
5
5
|
import { SnkApplication } from '../snk-application/snk-application';
|
6
|
+
import FilterItemType from './filter-item/filter-item-type.enum';
|
6
7
|
import { SnkFilterItemConfig } from './filter-item/snk-filter-item';
|
8
|
+
import { IPersonalizedFilter } from '../snk-personalized-filter/interfaces/IPersonalizedFilter';
|
7
9
|
export declare class SnkFilterBar implements FilterProvider {
|
8
10
|
private _filterModalFactory;
|
9
11
|
private _elPersonalizedFilter;
|
@@ -64,6 +66,14 @@ export declare class SnkFilterBar implements FilterProvider {
|
|
64
66
|
* @param filterItem - Item a ser adicionado, caso o item já exista com o ID ele não será adicionado novamente
|
65
67
|
*/
|
66
68
|
addFilterItem(filterItem: SnkFilterItemConfig): Promise<void>;
|
69
|
+
/**
|
70
|
+
* Remove um item de filtro.
|
71
|
+
*
|
72
|
+
* @param filterID - ID do a ser adicionado
|
73
|
+
*
|
74
|
+
* @returns {Promise<SnkFilterItemConfig|undefined>} - Retorna o item de filtro removido, ou undefined caso não encontrado.
|
75
|
+
*/
|
76
|
+
removeFilterItem(filterID: string): Promise<SnkFilterItemConfig | undefined>;
|
67
77
|
componentDidLoad(): void;
|
68
78
|
private processPendingFilter;
|
69
79
|
private getPersonalizedFilterItem;
|
@@ -94,6 +104,7 @@ export declare class SnkFilterBar implements FilterProvider {
|
|
94
104
|
private showFilterModal;
|
95
105
|
addPersonalizedFilter(): void;
|
96
106
|
editPersonalizedFilter(id: string): void;
|
107
|
+
deletePersonalizedFilter(filter: IPersonalizedFilter, filterItemType: FilterItemType, configName: string): void;
|
97
108
|
handleHidePersonalizedFilter(reloadFilterBar: boolean): void;
|
98
109
|
hidePersonalizedFilter(): void;
|
99
110
|
componentWillLoad(): void;
|
@@ -1,8 +1,10 @@
|
|
1
1
|
import { SnkFilterItemConfig } from "../filter-item/snk-filter-item";
|
2
|
+
import { IPersonalizedFilter } from "../../snk-personalized-filter/interfaces/IPersonalizedFilter";
|
2
3
|
type OnCompleteCallback = (filter: SnkFilterItemConfig[]) => void;
|
3
4
|
type GetMessageFn = (key: string, params?: any) => string;
|
4
5
|
type AddPersonalizedFilterFn = () => void;
|
5
6
|
type EditPersonalizedFilterFn = (id: string) => void;
|
7
|
+
type deletePersonalizedFilterFn = (filter: IPersonalizedFilter, configName: string) => void;
|
6
8
|
export type SnkFilterModalFactoryParams = {
|
7
9
|
filterConfig: SnkFilterItemConfig[];
|
8
10
|
configName: string;
|
@@ -10,6 +12,7 @@ export type SnkFilterModalFactoryParams = {
|
|
10
12
|
getMessage: GetMessageFn;
|
11
13
|
onAddPersonalizedFilter: AddPersonalizedFilterFn;
|
12
14
|
onEditPersonalizedFilter: EditPersonalizedFilterFn;
|
15
|
+
onDeletePersonalizedFilter: deletePersonalizedFilterFn;
|
13
16
|
};
|
14
17
|
declare class SnkFilterModalFactory {
|
15
18
|
private _closeModal;
|
@@ -19,7 +22,8 @@ declare class SnkFilterModalFactory {
|
|
19
22
|
private _getMessage;
|
20
23
|
private _addPersonalizedFilterFn;
|
21
24
|
private _editPersonalizedFilterFn;
|
22
|
-
|
25
|
+
private _onDeletePersonalizedFilter;
|
26
|
+
constructor({ filterConfig, configName, onComplete, getMessage, onAddPersonalizedFilter, onEditPersonalizedFilter, onDeletePersonalizedFilter }: SnkFilterModalFactoryParams);
|
23
27
|
private applyFilters;
|
24
28
|
private buildFilterModal;
|
25
29
|
showModal(): Promise<void>;
|
@@ -143,6 +143,7 @@ export declare class SnkGrid {
|
|
143
143
|
getHeaderDisabledButtons(): Array<string>;
|
144
144
|
private getInvisibleButtons;
|
145
145
|
componentWillRender(): void;
|
146
|
+
private getHeaderTaskbarId;
|
146
147
|
private getTopTaskBarId;
|
147
148
|
private getPrimaryButton;
|
148
149
|
private getColumnSearch;
|
@@ -24,6 +24,7 @@ export declare class TaskbarActionsButton {
|
|
24
24
|
*/
|
25
25
|
taskbarActionsOpened: EventEmitter<HTMLElement>;
|
26
26
|
handleKeyDown(event: KeyboardEvent): Promise<void>;
|
27
|
+
handleClose(): Promise<void>;
|
27
28
|
/**
|
28
29
|
* Exibe a lista de ações.
|
29
30
|
*/
|
@@ -44,6 +45,7 @@ export declare class TaskbarActionsButton {
|
|
44
45
|
private loadItems;
|
45
46
|
private canShowDropdown;
|
46
47
|
private onSelectAction;
|
48
|
+
private getSelectedAction;
|
47
49
|
private dropdownItemBuilder;
|
48
50
|
/**
|
49
51
|
* Existem algumas actions que precisam ser inicializadas assim que o componente é carregado,
|
@@ -1,3 +1,4 @@
|
|
1
1
|
import { IOption, ISearchArgument } from '@sankhyalabs/ezui/dist/types/components/ez-combo-box/ez-combo-box';
|
2
|
+
import { IAction } from '@sankhyalabs/ezui/dist/types/utils';
|
2
3
|
export declare const buildFieldSearch: (action: IAction, optionLoader: (argument: ISearchArgument) => Promise<Array<IOption>>, onSelectField: (field: IOption) => void) => any;
|
3
4
|
export declare const openFieldSearch: (moreOptions: HTMLEzActionsButtonElement, field: HTMLEzSearchElement) => Promise<void>;
|
@@ -15,14 +15,16 @@ import { IAppletCallerParams } from "./lib/applet-caller/applet-caller";
|
|
15
15
|
import { IClientEventResponse } from "./lib/http/data-fetcher/interfaces/IClientEventResponse";
|
16
16
|
import { IDataFetcherRecaller } from "./lib/http/data-fetcher/recaller/IDataFetcherRecaller";
|
17
17
|
import { DialogType, MessageOptions } from "@sankhyalabs/ezui/dist/collection/utils";
|
18
|
-
import { IOption, ISearchArgument } from "@sankhyalabs/ezui/dist/types/components/ez-
|
18
|
+
import { IOption, ISearchArgument } from "@sankhyalabs/ezui/dist/types/components/ez-search/ez-search";
|
19
19
|
import { IRemoveSearchListener, ISearchListener, SearchCriteria } from "./lib/http/data-fetcher/fetchers/pesquisa-fetcher";
|
20
|
+
import { TFetcherType } from "./components/snk-attach/interfaces/TFetcherType";
|
21
|
+
import { AttachFetcherFacadeInterface, PresentationMode } from "./lib";
|
22
|
+
import { FetcherFacade } from "./components/snk-attach/structure";
|
20
23
|
import { IFieldConfig, IFormCardConfig, IFormConfig, IRecordValidator, ISummaryField } from "@sankhyalabs/ezui/dist/types/utils/form/interfaces";
|
21
24
|
import { SIMPLE_CRUD_MODE, VIEW_MODE } from "./lib/utils/constants";
|
22
25
|
import { ISelectionToastConfig } from "@sankhyalabs/ezui/dist/types/components/ez-grid/interfaces";
|
23
26
|
import { Action, TaskbarManager } from "./components/snk-taskbar/snk-taskbar";
|
24
27
|
import { EzGridColumn, IGridConfig, IStatusResolver, StatusResolverFunction } from "@sankhyalabs/ezui/dist/types/components/ez-grid/controller/EzGridController";
|
25
|
-
import { PresentationMode } from "./lib";
|
26
28
|
import { IExporterProvider } from "./components/snk-data-exporter/interfaces/IExporterProvider";
|
27
29
|
import { DataState } from "./components/snk-data-unit/snk-data-unit";
|
28
30
|
import { IRecordID } from "./components/snk-data-exporter/interfaces/IRecordID";
|
@@ -43,6 +45,7 @@ import { FilterFieldsDataSource, IFilterField, IFilterLink } from "./components/
|
|
43
45
|
import { IEzPopoverAnchorOptions } from "@sankhyalabs/ezui/dist/types/components/ez-popover/ez-popover";
|
44
46
|
import { SnkFilterItemConfig as SnkFilterItemConfig1 } from "./components/snk-filter-bar/filter-item/snk-filter-item";
|
45
47
|
import { ListItem as ListItem1 } from "./components/snk-filter-bar/filter-list/snk-filter-list";
|
48
|
+
import { IOption as IOption1 } from "@sankhyalabs/ezui/dist/types/components/ez-combo-box/ez-combo-box";
|
46
49
|
import { IFormViewField } from "@sankhyalabs/ezui/dist/types/components/ez-form-view/interfaces/IFormViewField";
|
47
50
|
import { FormMetadata } from "@sankhyalabs/ezui/dist/collection/utils/form";
|
48
51
|
import { IMultiSelectionListDataSource } from "@sankhyalabs/ezui/dist/types/components/ez-multi-selection-list/interfaces/IMultiSelectionListDataSource";
|
@@ -294,10 +297,26 @@ export namespace Components {
|
|
294
297
|
"whenApplicationReady": () => Promise<SnkApplication>;
|
295
298
|
}
|
296
299
|
interface SnkAttach {
|
300
|
+
/**
|
301
|
+
* DataUnit responsável por carregar os dados.
|
302
|
+
*/
|
303
|
+
"dataUnit": DataUnit;
|
304
|
+
/**
|
305
|
+
* DataUnitBuilder responsável por implementar dados a serem utilizados no DataUnit.
|
306
|
+
*/
|
307
|
+
"dataUnitBuilder": FetcherFacade;
|
297
308
|
/**
|
298
309
|
* Nome da entidade à ser utilizada para relacionar o anexo ao DataUnit pai.
|
299
310
|
*/
|
300
311
|
"entityName": string;
|
312
|
+
/**
|
313
|
+
* Fetcher responsável por carregar os dados do DataUnit.
|
314
|
+
*/
|
315
|
+
"fetcher": AttachFetcherFacadeInterface;
|
316
|
+
/**
|
317
|
+
* FetcherType define o tipo de fetcher responsável por carregar os dados do DataUnit.
|
318
|
+
*/
|
319
|
+
"fetcherType": TFetcherType;
|
301
320
|
/**
|
302
321
|
* Responsável por flexibilizar e padronizar o uso de mensagens nos blocos de construção.
|
303
322
|
*/
|
@@ -725,6 +744,12 @@ export namespace Components {
|
|
725
744
|
* Faz o recarregamento da filterbar buscando o state no servidor.
|
726
745
|
*/
|
727
746
|
"reload": () => Promise<void>;
|
747
|
+
/**
|
748
|
+
* Remove um item de filtro.
|
749
|
+
* @param filterID - ID do a ser adicionado
|
750
|
+
* @returns - Retorna o item de filtro removido, ou undefined caso não encontrado.
|
751
|
+
*/
|
752
|
+
"removeFilterItem": (filterID: string) => Promise<SnkFilterItemConfig | undefined>;
|
728
753
|
/**
|
729
754
|
* Identificador de recursos como configurações e acesso.
|
730
755
|
*/
|
@@ -865,13 +890,21 @@ export namespace Components {
|
|
865
890
|
*/
|
866
891
|
"configName": string;
|
867
892
|
/**
|
868
|
-
* Ação executada ao
|
893
|
+
* Ação executada ao deletar um filtro personalizado
|
894
|
+
*/
|
895
|
+
"deletePersonalizedFilter": (filter: IPersonalizedFilter, configName: string) => void;
|
896
|
+
/**
|
897
|
+
* Ação executada ao editar um filtro personalizado
|
869
898
|
*/
|
870
899
|
"editPersonalizedFilter": (id:string) => void;
|
871
900
|
/**
|
872
901
|
* Filtros a serem apresentados
|
873
902
|
*/
|
874
903
|
"filters": Array<SnkFilterItemConfig>;
|
904
|
+
/**
|
905
|
+
* Guarda filtros a serem deletados no Apply do modal
|
906
|
+
*/
|
907
|
+
"filtersToDelete": IPersonalizedFilter[];
|
875
908
|
/**
|
876
909
|
* Usado pra flexibilizar os verbetes e mensagens de acordo com o SnkMessageBuilder.
|
877
910
|
*/
|
@@ -972,7 +1005,7 @@ export namespace Components {
|
|
972
1005
|
/**
|
973
1006
|
* Define o valor do componente snk-filter-search
|
974
1007
|
*/
|
975
|
-
"value":
|
1008
|
+
"value": IOption1;
|
976
1009
|
}
|
977
1010
|
interface SnkFilterText {
|
978
1011
|
/**
|
@@ -1317,7 +1350,7 @@ export namespace Components {
|
|
1317
1350
|
/**
|
1318
1351
|
* Controla o valor do componente.
|
1319
1352
|
*/
|
1320
|
-
"value": Array<
|
1353
|
+
"value": Array<IOption1|boolean|string|number|Date>;
|
1321
1354
|
}
|
1322
1355
|
interface SnkPesquisa {
|
1323
1356
|
/**
|
@@ -1331,7 +1364,7 @@ export namespace Components {
|
|
1331
1364
|
/**
|
1332
1365
|
* Função disparada ao selecionar um item.
|
1333
1366
|
*/
|
1334
|
-
"selectItem": (option:
|
1367
|
+
"selectItem": (option: IOption1) => void;
|
1335
1368
|
}
|
1336
1369
|
interface SnkPrintSelector {
|
1337
1370
|
"openPrintSelector": (printJobData: PendingPrintJobData) => Promise<PrintSelectorResponse>;
|
@@ -1340,7 +1373,7 @@ export namespace Components {
|
|
1340
1373
|
/**
|
1341
1374
|
* Determina a opção selecionada.
|
1342
1375
|
*/
|
1343
|
-
"selectedOption":
|
1376
|
+
"selectedOption": IOption1 | string;
|
1344
1377
|
}
|
1345
1378
|
interface SnkSimpleBar {
|
1346
1379
|
/**
|
@@ -2049,10 +2082,26 @@ declare namespace LocalJSX {
|
|
2049
2082
|
"onApplicationLoading"?: (event: SnkApplicationCustomEvent<boolean>) => void;
|
2050
2083
|
}
|
2051
2084
|
interface SnkAttach {
|
2085
|
+
/**
|
2086
|
+
* DataUnit responsável por carregar os dados.
|
2087
|
+
*/
|
2088
|
+
"dataUnit"?: DataUnit;
|
2089
|
+
/**
|
2090
|
+
* DataUnitBuilder responsável por implementar dados a serem utilizados no DataUnit.
|
2091
|
+
*/
|
2092
|
+
"dataUnitBuilder"?: FetcherFacade;
|
2052
2093
|
/**
|
2053
2094
|
* Nome da entidade à ser utilizada para relacionar o anexo ao DataUnit pai.
|
2054
2095
|
*/
|
2055
|
-
"entityName"
|
2096
|
+
"entityName"?: string;
|
2097
|
+
/**
|
2098
|
+
* Fetcher responsável por carregar os dados do DataUnit.
|
2099
|
+
*/
|
2100
|
+
"fetcher"?: AttachFetcherFacadeInterface;
|
2101
|
+
/**
|
2102
|
+
* FetcherType define o tipo de fetcher responsável por carregar os dados do DataUnit.
|
2103
|
+
*/
|
2104
|
+
"fetcherType"?: TFetcherType;
|
2056
2105
|
/**
|
2057
2106
|
* Responsável por flexibilizar e padronizar o uso de mensagens nos blocos de construção.
|
2058
2107
|
*/
|
@@ -2650,13 +2699,21 @@ declare namespace LocalJSX {
|
|
2650
2699
|
*/
|
2651
2700
|
"configName"?: string;
|
2652
2701
|
/**
|
2653
|
-
* Ação executada ao
|
2702
|
+
* Ação executada ao deletar um filtro personalizado
|
2703
|
+
*/
|
2704
|
+
"deletePersonalizedFilter"?: (filter: IPersonalizedFilter, configName: string) => void;
|
2705
|
+
/**
|
2706
|
+
* Ação executada ao editar um filtro personalizado
|
2654
2707
|
*/
|
2655
2708
|
"editPersonalizedFilter"?: (id:string) => void;
|
2656
2709
|
/**
|
2657
2710
|
* Filtros a serem apresentados
|
2658
2711
|
*/
|
2659
2712
|
"filters"?: Array<SnkFilterItemConfig>;
|
2713
|
+
/**
|
2714
|
+
* Guarda filtros a serem deletados no Apply do modal
|
2715
|
+
*/
|
2716
|
+
"filtersToDelete"?: IPersonalizedFilter[];
|
2660
2717
|
/**
|
2661
2718
|
* Usado pra flexibilizar os verbetes e mensagens de acordo com o SnkMessageBuilder.
|
2662
2719
|
*/
|
@@ -2752,7 +2809,7 @@ declare namespace LocalJSX {
|
|
2752
2809
|
/**
|
2753
2810
|
* Define o valor do componente snk-filter-search
|
2754
2811
|
*/
|
2755
|
-
"value"?:
|
2812
|
+
"value"?: IOption1;
|
2756
2813
|
}
|
2757
2814
|
interface SnkFilterText {
|
2758
2815
|
/**
|
@@ -3124,7 +3181,7 @@ declare namespace LocalJSX {
|
|
3124
3181
|
/**
|
3125
3182
|
* Controla o valor do componente.
|
3126
3183
|
*/
|
3127
|
-
"value"?: Array<
|
3184
|
+
"value"?: Array<IOption1|boolean|string|number|Date>;
|
3128
3185
|
}
|
3129
3186
|
interface SnkPesquisa {
|
3130
3187
|
/**
|
@@ -3138,7 +3195,7 @@ declare namespace LocalJSX {
|
|
3138
3195
|
/**
|
3139
3196
|
* Função disparada ao selecionar um item.
|
3140
3197
|
*/
|
3141
|
-
"selectItem"?: (option:
|
3198
|
+
"selectItem"?: (option: IOption1) => void;
|
3142
3199
|
}
|
3143
3200
|
interface SnkPrintSelector {
|
3144
3201
|
}
|
@@ -3150,7 +3207,7 @@ declare namespace LocalJSX {
|
|
3150
3207
|
/**
|
3151
3208
|
* Determina a opção selecionada.
|
3152
3209
|
*/
|
3153
|
-
"selectedOption"?:
|
3210
|
+
"selectedOption"?: IOption1 | string;
|
3154
3211
|
}
|
3155
3212
|
interface SnkSimpleBar {
|
3156
3213
|
/**
|
@@ -21,5 +21,9 @@ export declare class ConfigStorage {
|
|
21
21
|
static savePersonalizedFilter(personalizedFilter: IPersonalizedFilter, resourceID: string, configName?: string): Promise<IPersonalizedFilter>;
|
22
22
|
static removePersonalizedFilter(personalizedFilter: IPersonalizedFilter, resourceID: string, configName?: string): Promise<IPersonalizedFilter>;
|
23
23
|
static validatePersonalizedFilter(dataUnitName: string, expression: string): Promise<IValidateFilter>;
|
24
|
+
static deleteGridConfigCache(name: string, resourceID: string): Promise<void>;
|
25
|
+
static deleteFormConfigCache(name: string, resourceID: string): Promise<void>;
|
26
|
+
static deleteFilterBarConfigCache(name: string, resourceID: string): Promise<void>;
|
27
|
+
private static deleteConfigCache;
|
24
28
|
private static buildCacheID;
|
25
29
|
}
|
@@ -1,6 +1,5 @@
|
|
1
1
|
import { IClientEventResponse } from './interfaces/IClientEventResponse';
|
2
2
|
import { IDataFetcherRecaller } from './recaller/IDataFetcherRecaller';
|
3
|
-
type ClientEventHandler = (clientEvent: IClientEventResponse, dataFetcherReacaller: IDataFetcherRecaller) => Promise<void>;
|
4
3
|
export declare class DataFetcher {
|
5
4
|
private static appTagName;
|
6
5
|
private static instance;
|
@@ -39,6 +38,7 @@ export declare class DataFetcher {
|
|
39
38
|
static hasClientEvent(eventID: String): boolean;
|
40
39
|
static removeClientEvent(eventID: String): boolean;
|
41
40
|
}
|
41
|
+
type ClientEventHandler = (clientEvent: IClientEventResponse, dataFetcherReacaller: IDataFetcherRecaller) => void | Promise<void>;
|
42
42
|
export interface RequestListener {
|
43
43
|
onRequestStart(param: RequestListenerParams): void;
|
44
44
|
onRequestEnd(param: RequestListenerParams): void;
|
@@ -1,6 +1,7 @@
|
|
1
1
|
import { Change, Record } from "@sankhyalabs/core";
|
2
|
-
import {
|
3
|
-
|
2
|
+
import { DeleteResponse, DownloadKeyResponse, SaveResponse } from "./interfaces";
|
3
|
+
import { AttachFetcherFacadeInterface } from "./facade/attach-fetcher.facade";
|
4
|
+
export declare class AnexoSistemaFetcher implements AttachFetcherFacadeInterface {
|
4
5
|
private entityName;
|
5
6
|
private registerKey;
|
6
7
|
private dataUnitName;
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import { Change, Record } from "@sankhyalabs/core";
|
2
|
+
import { SaveResponse, DeleteResponse, DownloadKeyResponse } from "./interfaces";
|
3
|
+
import { AttachFetcherFacadeInterface } from "./facade/attach-fetcher.facade";
|
4
|
+
export declare class AttachFetcher implements AttachFetcherFacadeInterface {
|
5
|
+
private dataUnitName?;
|
6
|
+
constructor(dataUnitName?: string);
|
7
|
+
save({ dataUnit: dataUnitName, record, updatingFields: fields, operation }: Change): Promise<Array<SaveResponse>>;
|
8
|
+
edit(change: Change): Promise<SaveResponse[]>;
|
9
|
+
delete(record: Record): Promise<DeleteResponse>;
|
10
|
+
getDownloadKey(record: Record): Promise<DownloadKeyResponse>;
|
11
|
+
}
|
package/dist/types/lib/http/data-fetcher/fetchers/AttachFetcher/facade/attach-fetcher.facade.d.ts
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
import { Change, Record } from '@sankhyalabs/core';
|
2
|
+
import { DeleteResponse, DownloadKeyResponse, SaveResponse } from '../interfaces';
|
3
|
+
export interface AttachFetcherFacadeInterface {
|
4
|
+
save(change: Change): Promise<Array<SaveResponse>>;
|
5
|
+
edit(change: Change): Promise<Array<SaveResponse>>;
|
6
|
+
delete(record: Record): Promise<DeleteResponse>;
|
7
|
+
getDownloadKey(record: Record): Promise<DownloadKeyResponse>;
|
8
|
+
}
|
@@ -22,5 +22,6 @@ export type SaveResponse = {
|
|
22
22
|
export declare enum SaveErrorsEnum {
|
23
23
|
LINK_AND_FILE_AT_THE_SAME_TIME = "LINK_AND_FILE_AT_THE_SAME_TIME",
|
24
24
|
ANY_LINK_OR_FILE_FILLED = "ANY_LINK_OR_FILE_FILLED",
|
25
|
-
UNKNOWN = "UNKNOWN"
|
25
|
+
UNKNOWN = "UNKNOWN",
|
26
|
+
DESCRIPTION_CANNOT_BE_CHANGED = "DESCRIPTION_CANNOT_BE_CHANGED"
|
26
27
|
}
|
@@ -10,6 +10,7 @@ export default class DataUnitFetcher {
|
|
10
10
|
getDataUnit(entityName: string, resourceID: string, parentDataUnit?: DataUnit, configName?: string): DataUnit;
|
11
11
|
private loadMetadata;
|
12
12
|
loadSelectDistinct(dataUnit: DataUnit, fieldName: string, argument: string): Promise<Array<string>>;
|
13
|
+
private addTransientProperties;
|
13
14
|
private saveData;
|
14
15
|
private updateCache;
|
15
16
|
private getTransientInfo;
|
package/dist/types/lib/http/data-fetcher/fetchers/data-unit/loadstrategy/DatasetStrategy.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { DataUnit, LoadDataRequest } from
|
1
|
+
import { DataUnit, LoadDataRequest } from '@sankhyalabs/core';
|
2
2
|
import { ILoadDataResult } from "../interfaces/ILoadDataResult";
|
3
3
|
import { ILoadDataStrategy } from "../interfaces/ILoadDataStrategy";
|
4
4
|
import { ILoadingInfo } from "../interfaces/ILoadingInfo";
|
@@ -6,8 +6,10 @@ export declare class DatasetStrategy implements ILoadDataStrategy {
|
|
6
6
|
canSlice(): boolean;
|
7
7
|
load(dataUnit: DataUnit, request: LoadDataRequest, loadingInfo: ILoadingInfo): Promise<ILoadDataResult>;
|
8
8
|
private getFieldsList;
|
9
|
+
private getStandAloneFieldsList;
|
9
10
|
private getFieldNames;
|
10
11
|
private buildRequestBody;
|
12
|
+
private getModuleName;
|
11
13
|
private getTxProperties;
|
12
14
|
private processRecords;
|
13
15
|
private buildFieldValue;
|
@@ -4,7 +4,7 @@ export { CrudUtils } from './utils/CrudUtils';
|
|
4
4
|
export { PresentationMode } from "./@types";
|
5
5
|
export { TotalsFetcher } from './http/data-fetcher/fetchers/totals-fetcher';
|
6
6
|
export { default as ApplicationConfigFetcher } from './http/data-fetcher/fetchers/application-config-fetcher';
|
7
|
-
export { AttachFetcher } from './http/data-fetcher/fetchers/
|
7
|
+
export { AttachFetcher, AnexoSistemaFetcher, AttachFetcherFacadeInterface } from './http/data-fetcher/fetchers/AttachFetcher';
|
8
8
|
export { Authorization } from './http/data-fetcher/fetchers/auth-fetcher';
|
9
9
|
export { default as DataUnitFetcher } from './http/data-fetcher/fetchers/data-unit/dataunit-fetcher';
|
10
10
|
export { default as FilterBarConfigFetcher } from './http/data-fetcher/fetchers/filter-bar-config-fetcher';
|