@senior-gestao-relacionamento/angular-components 2.5.0-master-5861fa25 → 2.6.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/esm2022/lib/components/export-data/entities/export-data.interface.mjs +1 -1
- package/esm2022/lib/components/export-data/export-data.component.mjs +53 -498
- package/esm2022/lib/components/export-data/services/export-data.service.mjs +2 -3
- package/esm2022/lib/i18n/en-US.json +16 -1
- package/esm2022/lib/i18n/es-ES.json +16 -1
- package/esm2022/lib/i18n/pt-BR.json +16 -1
- package/fesm2022/senior-gestao-relacionamento-angular-components.mjs +123 -524
- package/fesm2022/senior-gestao-relacionamento-angular-components.mjs.map +1 -1
- package/lib/components/export-data/entities/export-data.interface.d.ts +2 -2
- package/lib/components/export-data/export-data.component.d.ts +11 -10
- package/lib/components/export-data/services/export-data.service.d.ts +1 -2
- package/package.json +2 -2
|
@@ -71,9 +71,9 @@ export interface ExportAllPayload {
|
|
|
71
71
|
* O componente normaliza internamente.
|
|
72
72
|
*/
|
|
73
73
|
export interface ExportDataConfig {
|
|
74
|
-
/**
|
|
74
|
+
/** Chave de tradução da entidade (ex: 'crmx.business.entity_name') — usada no título do arquivo */
|
|
75
75
|
entityName: string;
|
|
76
|
-
/** Datasource: domínio, serviço e primitiva de listagem */
|
|
76
|
+
/** Datasource: domínio, serviço e primitiva de listagem (a mesma usada para carregar os dados na tela) */
|
|
77
77
|
datasource: ExportDatasource;
|
|
78
78
|
/** Colunas disponíveis para exportação */
|
|
79
79
|
columns: (ExportColumn | ExportColumnInput)[];
|
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
import { OnChanges
|
|
1
|
+
import { OnChanges } from '@angular/core';
|
|
2
2
|
import { ExportDataConfig, ExportColumn } from './entities/export-data.interface';
|
|
3
3
|
import { ExportFileType, ExportOrientation, ExportFileFormat } from './enums/export-data.enums';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
/**
|
|
6
|
+
* Componente de exportação de dados (s-export-data).
|
|
7
|
+
* Permite ao usuário escolher o formato do arquivo (Excel ou PDF), a orientação da página,
|
|
8
|
+
* o formato da folha, o escopo (todos os registros ou apenas os selecionados) e
|
|
9
|
+
* as colunas a serem exportadas.
|
|
10
|
+
*
|
|
11
|
+
* Comunica-se com o `crmx-data-export-backend` via HTTP (fire-and-forget).
|
|
12
|
+
*/
|
|
13
|
+
export declare class ExportDataComponent implements OnChanges {
|
|
14
|
+
private readonly exportDataService;
|
|
11
15
|
visible: import("@angular/core").InputSignal<boolean>;
|
|
12
16
|
visibleChange: import("@angular/core").OutputEmitterRef<boolean>;
|
|
13
17
|
config: import("@angular/core").InputSignal<ExportDataConfig>;
|
|
@@ -51,8 +55,6 @@ export declare class ExportDataComponent implements OnChanges, OnDestroy {
|
|
|
51
55
|
description: string;
|
|
52
56
|
}[];
|
|
53
57
|
ngOnChanges(): void;
|
|
54
|
-
ngOnDestroy(): void;
|
|
55
|
-
private subscribeToWebSocket;
|
|
56
58
|
private isExportColumn;
|
|
57
59
|
private normalizeColumn;
|
|
58
60
|
selectAllColumns(): void;
|
|
@@ -64,7 +66,6 @@ export declare class ExportDataComponent implements OnChanges, OnDestroy {
|
|
|
64
66
|
refreshColumns(): void;
|
|
65
67
|
onDialogHide(): void;
|
|
66
68
|
doExport(): Promise<void>;
|
|
67
|
-
private exportViaBackend;
|
|
68
69
|
static ɵfac: i0.ɵɵFactoryDeclaration<ExportDataComponent, never>;
|
|
69
70
|
static ɵcmp: i0.ɵɵComponentDeclaration<ExportDataComponent, "s-export-data", never, { "visible": { "alias": "visible"; "required": false; "isSignal": true; }; "config": { "alias": "config"; "required": true; "isSignal": true; }; "selectedIds": { "alias": "selectedIds"; "required": false; "isSignal": true; }; }, { "visibleChange": "visibleChange"; "exported": "exported"; "exportError": "exportError"; }, never, never, true, never>;
|
|
70
71
|
}
|
|
@@ -4,8 +4,7 @@ import * as i0 from "@angular/core";
|
|
|
4
4
|
/**
|
|
5
5
|
* Serviço que dispara os signals de exportação no `crmx-data-export-backend`.
|
|
6
6
|
*
|
|
7
|
-
* Os signals são fire-and-forget: o backend gera o arquivo
|
|
8
|
-
* e notifica o usuário via WebSocket/notificação.
|
|
7
|
+
* Os signals são fire-and-forget: o backend processa e gera o arquivo de forma assíncrona.
|
|
9
8
|
*/
|
|
10
9
|
export declare class ExportDataService {
|
|
11
10
|
private readonly http;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@senior-gestao-relacionamento/angular-components",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.6.0",
|
|
4
4
|
"description": "Biblioteca de componentes reutilizáveis para aplicações Angular do CRM Senior Sistemas",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -48,4 +48,4 @@
|
|
|
48
48
|
"default": "./fesm2022/senior-gestao-relacionamento-angular-components.mjs"
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
|
-
}
|
|
51
|
+
}
|