@sankhyalabs/sankhyablocks 2.5.2 → 2.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{SnkMessageBuilder-370e23ae.js → SnkMessageBuilder-09b25b0a.js} +20 -1
- package/dist/cjs/data-exporter-option-417da37a.js +19 -0
- package/dist/cjs/{index-20e8b68a.js → index-2cd6f753.js} +26 -0
- package/dist/cjs/index-696b5c3b.js +200 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/sankhyablocks.cjs.js +2 -2
- package/dist/cjs/snk-application.cjs.entry.js +11 -3
- package/dist/cjs/snk-config-options.cjs.entry.js +1 -1
- package/dist/cjs/snk-configurator_3.cjs.entry.js +71 -13
- package/dist/cjs/snk-crud.cjs.entry.js +3 -2
- package/dist/cjs/{snk-exporter-email-sender_8.cjs.entry.js → snk-data-exporter_9.cjs.entry.js} +305 -8
- package/dist/cjs/snk-data-unit.cjs.entry.js +2 -2
- package/dist/cjs/snk-filter-binary-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-detail.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-number.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-period.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-personalized.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-search.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-text.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-form.cjs.entry.js +1 -1
- package/dist/cjs/snk-pesquisa.cjs.entry.js +1 -1
- package/dist/cjs/snk-tab-config.cjs.entry.js +1 -1
- package/dist/cjs/{taskbar-elements-3807c809.js → taskbar-elements-bbb89cdb.js} +8 -5
- package/dist/cjs/teste-pesquisa.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/snk-data-exporter/enum/data-exporter-option.js +11 -0
- package/dist/collection/components/snk-data-exporter/exporter-email-sender/snk-exporter-email-sender.js +4 -4
- package/dist/collection/components/snk-data-exporter/interfaces/IExporterProvider.js +1 -0
- package/dist/collection/components/snk-data-exporter/snk-data-exporter.css +19 -0
- package/dist/collection/components/snk-data-exporter/snk-data-exporter.js +181 -0
- package/dist/collection/components/snk-data-exporter/structure/ItemBuilder.js +140 -0
- package/dist/collection/components/snk-grid/snk-grid.js +69 -10
- package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +7 -4
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +2 -2
- package/dist/collection/lib/http/data-fetcher/fetchers/dataunit-fetcher.js +9 -1
- package/dist/collection/lib/http/data-fetcher/fetchers/fetchDataExporter/index.js +33 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IExporterColumnMetadata.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IFetchDataExporterParams.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IFetchDataExporterResponse.js +1 -0
- package/dist/collection/lib/message/SnkMessageBuilder.js +3 -1
- package/dist/collection/lib/message/resources/snk-data-exporter.msg.js +16 -0
- package/dist/collection/lib/message/resources/snk-taskbar.msg.js +1 -0
- package/dist/collection/lib/store/index.js +5 -0
- package/dist/collection/lib/utils/fileViewer/index.js +3 -0
- package/dist/collection/lib/utils/fileViewer/interfaces/IFileViewerParams.js +1 -0
- package/dist/components/ConfigStorage.js +3 -6694
- package/dist/components/DataFetcher.js +6695 -0
- package/dist/components/SnkMessageBuilder.js +20 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/snk-application2.js +11 -2
- package/dist/components/snk-crud.js +10 -4
- package/dist/components/snk-data-exporter.d.ts +11 -0
- package/dist/components/snk-data-exporter.js +6 -0
- package/dist/components/snk-data-exporter2.js +330 -0
- package/dist/components/snk-form-config2.js +1 -1
- package/dist/components/snk-form2.js +8 -2
- package/dist/components/snk-grid2.js +74 -10
- package/dist/components/snk-taskbar2.js +212 -9
- package/dist/esm/{SnkMessageBuilder-7d583c9a.js → SnkMessageBuilder-47db5d75.js} +20 -1
- package/dist/esm/data-exporter-option-006307dd.js +19 -0
- package/dist/esm/{index-e4121713.js → index-a77b6f35.js} +25 -1
- package/dist/esm/index-d89e384f.js +198 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/sankhyablocks.js +2 -2
- package/dist/esm/snk-application.entry.js +11 -3
- package/dist/esm/snk-config-options.entry.js +1 -1
- package/dist/esm/snk-configurator_3.entry.js +68 -10
- package/dist/esm/snk-crud.entry.js +3 -2
- package/dist/esm/{snk-exporter-email-sender_8.entry.js → snk-data-exporter_9.entry.js} +304 -8
- package/dist/esm/snk-data-unit.entry.js +2 -2
- package/dist/esm/snk-filter-binary-select.entry.js +1 -1
- package/dist/esm/snk-filter-detail.entry.js +1 -1
- package/dist/esm/snk-filter-multi-select.entry.js +1 -1
- package/dist/esm/snk-filter-number.entry.js +1 -1
- package/dist/esm/snk-filter-period.entry.js +1 -1
- package/dist/esm/snk-filter-personalized.entry.js +1 -1
- package/dist/esm/snk-filter-search.entry.js +1 -1
- package/dist/esm/snk-filter-text.entry.js +1 -1
- package/dist/esm/snk-form-config.entry.js +1 -1
- package/dist/esm/snk-form.entry.js +1 -1
- package/dist/esm/snk-pesquisa.entry.js +1 -1
- package/dist/esm/snk-tab-config.entry.js +1 -1
- package/dist/esm/{taskbar-elements-b2bbe275.js → taskbar-elements-beec3b27.js} +8 -5
- package/dist/esm/teste-pesquisa.entry.js +1 -1
- package/dist/sankhyablocks/p-04581d0c.entry.js +1 -0
- package/dist/sankhyablocks/p-112bb324.js +1 -0
- package/dist/sankhyablocks/{p-c17be74f.entry.js → p-12ebe36a.entry.js} +1 -1
- package/dist/sankhyablocks/p-13116d05.entry.js +1 -0
- package/dist/sankhyablocks/{p-14af45cc.entry.js → p-187b0d06.entry.js} +1 -1
- package/dist/sankhyablocks/{p-570cc474.entry.js → p-1a2533d0.entry.js} +1 -1
- package/dist/sankhyablocks/{p-fd3b562d.entry.js → p-1ccaea51.entry.js} +1 -1
- package/dist/sankhyablocks/p-1d7a0daf.js +1 -0
- package/dist/sankhyablocks/p-50c8bcb7.entry.js +1 -0
- package/dist/sankhyablocks/{p-44ce5b90.entry.js → p-57895452.entry.js} +1 -1
- package/dist/sankhyablocks/{p-48bbbd2c.entry.js → p-68fcc226.entry.js} +1 -1
- package/dist/sankhyablocks/p-719e570a.js +1 -0
- package/dist/sankhyablocks/{p-00b3c5d8.entry.js → p-772f1c44.entry.js} +1 -1
- package/dist/sankhyablocks/{p-c30d0966.entry.js → p-82e20fc0.entry.js} +1 -1
- package/dist/sankhyablocks/{p-eff899b0.entry.js → p-91c23d20.entry.js} +1 -1
- package/dist/sankhyablocks/p-a77dd79a.js +2 -0
- package/dist/sankhyablocks/{p-f50c6ef6.entry.js → p-ab4ff312.entry.js} +1 -1
- package/dist/sankhyablocks/p-c8327a5c.js +1 -0
- package/dist/sankhyablocks/{p-2664ae24.entry.js → p-d3e402d3.entry.js} +1 -1
- package/dist/sankhyablocks/{p-9593c937.entry.js → p-d7ae56ce.entry.js} +1 -1
- package/dist/sankhyablocks/{p-70e52fee.entry.js → p-d96bf6a7.entry.js} +1 -1
- package/dist/sankhyablocks/{p-b0a0222f.entry.js → p-df5d94c6.entry.js} +1 -1
- package/dist/sankhyablocks/{p-db111acd.entry.js → p-e075dba7.entry.js} +1 -1
- package/dist/sankhyablocks/{p-a3871147.entry.js → p-f8fdd16c.entry.js} +11 -4
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-data-exporter/data/attachment.d.ts +1 -1
- package/dist/types/components/snk-data-exporter/data/email.d.ts +3 -3
- package/dist/types/components/snk-data-exporter/data/export-config.d.ts +5 -5
- package/dist/types/components/snk-data-exporter/data/export-result.d.ts +5 -5
- package/dist/types/components/snk-data-exporter/data/report.d.ts +1 -1
- package/dist/types/components/snk-data-exporter/enum/data-exporter-option.d.ts +10 -0
- package/dist/types/components/snk-data-exporter/exporter-email-sender/email-info-step.d.ts +4 -4
- package/dist/types/components/snk-data-exporter/exporter-email-sender/options-step.d.ts +4 -4
- package/dist/types/components/snk-data-exporter/interfaces/IExporterProvider.d.ts +9 -0
- package/dist/types/components/snk-data-exporter/snk-data-exporter.d.ts +40 -0
- package/dist/types/components/snk-data-exporter/structure/ItemBuilder.d.ts +61 -0
- package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +2 -2
- package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +1 -1
- package/dist/types/components.d.ts +33 -3
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/index.d.ts +3 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IExporterColumnMetadata.d.ts +9 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IFetchDataExporterParams.d.ts +14 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IFetchDataExporterResponse.d.ts +7 -0
- package/dist/types/lib/message/resources/snk-data-exporter.msg.d.ts +1 -0
- package/dist/types/lib/store/index.d.ts +4 -0
- package/dist/types/lib/utils/fileViewer/index.d.ts +2 -0
- package/dist/types/lib/utils/fileViewer/interfaces/IFileViewerParams.d.ts +4 -0
- package/package.json +2 -1
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/cjs/AuthorizationConfig-79ffae4b.js +0 -7
- package/dist/esm/AuthorizationConfig-dcbd207a.js +0 -7
- package/dist/sankhyablocks/p-8a872a35.entry.js +0 -1
- package/dist/sankhyablocks/p-9ba3df4c.js +0 -2
- package/dist/sankhyablocks/p-9e67cf79.entry.js +0 -1
- package/dist/sankhyablocks/p-c118ef2a.entry.js +0 -1
- package/dist/sankhyablocks/p-dbaad88c.js +0 -1
- package/dist/sankhyablocks/p-dc36cfbf.js +0 -1
- package/dist/sankhyablocks/p-e7f772ed.js +0 -1
|
@@ -18,7 +18,7 @@ export class SnkTaskbar {
|
|
|
18
18
|
[TaskbarElement.GRID_MODE]: "snkTaskbar.titleGridMode",
|
|
19
19
|
[TaskbarElement.FORM_MODE]: "snkTaskbar.titleFormMode",
|
|
20
20
|
[TaskbarElement.CONFIGURATOR]: "snkTaskbar.titleConfigurator",
|
|
21
|
-
[TaskbarElement.
|
|
21
|
+
[TaskbarElement.DATA_EXPORTER]: "snkTaskbar.titleDataExporter"
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
24
|
observeButtons() {
|
|
@@ -109,7 +109,7 @@ export class SnkTaskbar {
|
|
|
109
109
|
className += "ez-padding-left--medium";
|
|
110
110
|
}
|
|
111
111
|
if (TaskbarElement[def.toString()]) {
|
|
112
|
-
return buildElem(def, className, this.getIdElemBtnNative(def), elem => this.getTitle(elem), elem => this.elementClick(elem), elem => this.isEnabled(elem), this.actionsList);
|
|
112
|
+
return buildElem(def, className, this.getIdElemBtnNative(def), elem => this.getTitle(elem), elem => this.elementClick(elem), elem => this.isEnabled(elem), this.actionsList, this.configName);
|
|
113
113
|
}
|
|
114
114
|
else {
|
|
115
115
|
return buildCustomButton(def, className, this.getIdElemBtnCustom(def), elem => this.elementClick(elem), elem => this.isEnabled(elem));
|
|
@@ -32,6 +32,13 @@ export default class DataUnitFetcher {
|
|
|
32
32
|
expression
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
+
children{
|
|
36
|
+
name
|
|
37
|
+
links{
|
|
38
|
+
source
|
|
39
|
+
target
|
|
40
|
+
}
|
|
41
|
+
}
|
|
35
42
|
}
|
|
36
43
|
}`);
|
|
37
44
|
this.templateByQuery.set("fetchData", gql `query($dataunit: String! $limit: Int $offset:Int $filters: [InputFilter!] $sort: [InputSort!]) {
|
|
@@ -94,7 +101,8 @@ export default class DataUnitFetcher {
|
|
|
94
101
|
const metadata = {
|
|
95
102
|
name: resp.name,
|
|
96
103
|
label: resp.name,
|
|
97
|
-
|
|
104
|
+
children: [...resp.children],
|
|
105
|
+
fields: []
|
|
98
106
|
};
|
|
99
107
|
(_a = resp.fields) === null || _a === void 0 ? void 0 : _a.forEach((source) => {
|
|
100
108
|
let properties = undefined;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
+
var t = {};
|
|
3
|
+
for (var p in s)
|
|
4
|
+
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
+
t[p] = s[p];
|
|
6
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
+
t[p[i]] = s[p[i]];
|
|
10
|
+
}
|
|
11
|
+
return t;
|
|
12
|
+
};
|
|
13
|
+
import { ObjectUtils } from "@sankhyalabs/core";
|
|
14
|
+
import { DataFetcher } from '../../DataFetcher';
|
|
15
|
+
export default function fetchDataExporter(_a) {
|
|
16
|
+
var { methodName } = _a, requestBody = __rest(_a, ["methodName"]);
|
|
17
|
+
const serviceName = `DataExporterSPBean.${methodName}`;
|
|
18
|
+
const payload = { serviceName, requestBody };
|
|
19
|
+
return new Promise((resolve, reject) => {
|
|
20
|
+
DataFetcher.get()
|
|
21
|
+
.callServiceBroker(serviceName, ObjectUtils.objectToString(payload))
|
|
22
|
+
.then(result => resolve(getFormatResponse(result)))
|
|
23
|
+
.catch(error => reject(error));
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
function getFormatResponse(result) {
|
|
27
|
+
var _a;
|
|
28
|
+
const response = (_a = result === null || result === void 0 ? void 0 : result.json) === null || _a === void 0 ? void 0 : _a.$;
|
|
29
|
+
if (response == undefined) {
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
return ObjectUtils.stringToObject(response);
|
|
33
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -6,6 +6,7 @@ import snkExporterMessages from "./resources/snk-exporter.msg.js";
|
|
|
6
6
|
import { snkFormMessages, snkFormConfigMessages, snkConfigOptionsMessages, snkFieldConfigMessages, snkTabConfigMessages } from "./resources/snk-form.msg.js";
|
|
7
7
|
import { snkConfiguratorMessages } from "./resources/snk-configurator.msg.js";
|
|
8
8
|
import { snkGridMessages, snkGridConfigMessages } from "./resources/snk-grid.msg.js";
|
|
9
|
+
import { snkDataExporterMessages } from "./resources/snk-data-exporter.msg.js";
|
|
9
10
|
export class SnkMessageBuilder {
|
|
10
11
|
constructor() {
|
|
11
12
|
this._defaults = {
|
|
@@ -21,7 +22,8 @@ export class SnkMessageBuilder {
|
|
|
21
22
|
crudUtils: crudUtilsMessages,
|
|
22
23
|
snkGrid: snkGridMessages,
|
|
23
24
|
snkGridConfig: snkGridConfigMessages,
|
|
24
|
-
snkExporter: snkExporterMessages
|
|
25
|
+
snkExporter: snkExporterMessages,
|
|
26
|
+
snkDataExporter: snkDataExporterMessages
|
|
25
27
|
};
|
|
26
28
|
this._currentOperation = OperationMap.CLEAN;
|
|
27
29
|
this.loadAppMessages().then((msgs) => {
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export const snkDataExporterMessages = {
|
|
2
|
+
group: {
|
|
3
|
+
export: {
|
|
4
|
+
default: "Exportar para",
|
|
5
|
+
multiSelected: "Exportar {0} linhas selecionadas",
|
|
6
|
+
selectedLine: "Exportar somente 1 linha selecionada",
|
|
7
|
+
},
|
|
8
|
+
custom: "Personalizado"
|
|
9
|
+
},
|
|
10
|
+
label: {
|
|
11
|
+
currentPage: "Somente a página atual",
|
|
12
|
+
spreadsheet: "Planilha",
|
|
13
|
+
cube: "Cubo",
|
|
14
|
+
sendByEmail: "Enviar por email",
|
|
15
|
+
}
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|