cat-documents-ng 0.2.34 → 0.2.36
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/Shared/components/table-primary/table-primary.component.d.ts +11 -13
- package/Shared/components/table-primary/table-primary.model.d.ts +19 -0
- package/Shared/constant/ERROR.d.ts +1 -0
- package/Shared/constant/SHARED.d.ts +113 -0
- package/Shared/constant/URLS.d.ts +22 -0
- package/fesm2022/cat-documents-ng.mjs +1333 -678
- package/fesm2022/cat-documents-ng.mjs.map +1 -1
- package/lib/document/components/document-container/document-container.component.d.ts +36 -35
- package/lib/document/components/document-list/document-list.component.d.ts +53 -35
- package/lib/document/components/document-status/document-status.component.d.ts +9 -12
- package/lib/document/components/document-viewer/document-viewer.component.d.ts +6 -6
- package/lib/document/components/documents-menu/documents-menu.component.d.ts +33 -11
- package/lib/document/components/folder-container/folder-container.component.d.ts +23 -6
- package/lib/document/components/linked-document/linked-document.component.d.ts +5 -4
- package/lib/document/components/user-list/user-list.component.d.ts +19 -22
- package/lib/document/directives/document.directive.d.ts +2 -2
- package/lib/document/models/document-category.model.d.ts +19 -0
- package/lib/document/models/document-list-response.model.d.ts +25 -0
- package/lib/document/models/status-data.model.d.ts +27 -0
- package/lib/document/models/user-list.model.d.ts +8 -0
- package/lib/document/services/document-http.service.d.ts +28 -2
- package/lib/document/services/document-menu.service.d.ts +65 -0
- package/lib/document/services/document-table-builder.service.d.ts +21 -35
- package/lib/document/services/document.service.d.ts +29 -8
- package/lib/document/services/status-calculator.service.d.ts +20 -0
- package/lib/document/services/user-list.service.d.ts +36 -0
- package/lib/document/state/document.query.d.ts +52 -1
- package/lib/document/state/document.state.d.ts +9 -0
- package/lib/document/state/document.store.d.ts +9 -0
- package/package.json +1 -1
- package/lib/document/models/document-status.model.d.ts +0 -6
|
@@ -1,23 +1,21 @@
|
|
|
1
|
+
import { EventEmitter, OnChanges, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { SHARED } from '../../constant/SHARED';
|
|
3
|
+
import { ProcessedRowData, TableData } from './table-primary.model';
|
|
1
4
|
import * as i0 from "@angular/core";
|
|
2
|
-
export
|
|
3
|
-
field: string;
|
|
4
|
-
header: string;
|
|
5
|
-
type?: 'text' | 'status' | 'document' | 'actions';
|
|
6
|
-
width?: string;
|
|
7
|
-
}
|
|
8
|
-
export interface TableData {
|
|
9
|
-
columns: TableColumn[];
|
|
10
|
-
data: any[];
|
|
11
|
-
}
|
|
12
|
-
export declare class TablePrimaryComponent {
|
|
5
|
+
export declare class TablePrimaryComponent implements OnChanges {
|
|
13
6
|
tableData: TableData;
|
|
14
7
|
showHeader: boolean;
|
|
15
8
|
tableStyle: any;
|
|
9
|
+
rowClick: EventEmitter<any>;
|
|
10
|
+
processedData: ProcessedRowData[];
|
|
11
|
+
readonly SHARED: typeof SHARED;
|
|
12
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
13
|
+
private processTableData;
|
|
16
14
|
getStatusClass(status: string): string;
|
|
17
15
|
getStatusIcon(status: string): string;
|
|
18
|
-
getFileSize(fileName: string): string;
|
|
19
16
|
getFileExtension(fileName: string): string;
|
|
20
17
|
onActionClick(event: Event, rowData: any): void;
|
|
18
|
+
onRowClick(rowData: any): void;
|
|
21
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<TablePrimaryComponent, never>;
|
|
22
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<TablePrimaryComponent, "lib-table-primary", never, { "tableData": { "alias": "tableData"; "required": false; }; "showHeader": { "alias": "showHeader"; "required": false; }; "tableStyle": { "alias": "tableStyle"; "required": false; }; }, {}, never, never, false, never>;
|
|
20
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TablePrimaryComponent, "lib-table-primary", never, { "tableData": { "alias": "tableData"; "required": false; }; "showHeader": { "alias": "showHeader"; "required": false; }; "tableStyle": { "alias": "tableStyle"; "required": false; }; }, { "rowClick": "rowClick"; }, never, never, false, never>;
|
|
23
21
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export interface TableColumn {
|
|
2
|
+
field: string;
|
|
3
|
+
header: string;
|
|
4
|
+
type?: 'text' | 'status' | 'document' | 'actions';
|
|
5
|
+
width?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface TableData {
|
|
8
|
+
columns: TableColumn[];
|
|
9
|
+
data: any[];
|
|
10
|
+
}
|
|
11
|
+
export interface ProcessedRowData {
|
|
12
|
+
_fileExtension?: string;
|
|
13
|
+
_isPdfFile?: boolean;
|
|
14
|
+
_isImageFile?: boolean;
|
|
15
|
+
_isExcelFile?: boolean;
|
|
16
|
+
_isOtherFile?: boolean;
|
|
17
|
+
_statusClass?: string;
|
|
18
|
+
_statusIcon?: string;
|
|
19
|
+
}
|
|
@@ -3,6 +3,34 @@
|
|
|
3
3
|
* These constants are related to document statuses and other shared data.
|
|
4
4
|
*/
|
|
5
5
|
export declare class SHARED {
|
|
6
|
+
/**
|
|
7
|
+
* Represents the info.
|
|
8
|
+
*/
|
|
9
|
+
static VISIBLE: string;
|
|
10
|
+
/**
|
|
11
|
+
* Represents the info.
|
|
12
|
+
*/
|
|
13
|
+
static HIDDEN: string;
|
|
14
|
+
/**
|
|
15
|
+
* Represents the info.
|
|
16
|
+
*/
|
|
17
|
+
static APPLICATION_DOCS: string;
|
|
18
|
+
/**
|
|
19
|
+
* Represents the info.
|
|
20
|
+
*/
|
|
21
|
+
static INFO: string;
|
|
22
|
+
/**
|
|
23
|
+
* Represents the success.
|
|
24
|
+
*/
|
|
25
|
+
static SUCCESS: string;
|
|
26
|
+
/**
|
|
27
|
+
* Represents the warning.
|
|
28
|
+
*/
|
|
29
|
+
static WARNING: string;
|
|
30
|
+
/**
|
|
31
|
+
* Represents the warning.
|
|
32
|
+
*/
|
|
33
|
+
static DANGER: string;
|
|
6
34
|
/**
|
|
7
35
|
* Represents the stores userData.
|
|
8
36
|
*/
|
|
@@ -63,6 +91,24 @@ export declare class SHARED {
|
|
|
63
91
|
* @type {string}
|
|
64
92
|
*/
|
|
65
93
|
static FILE: string;
|
|
94
|
+
/**
|
|
95
|
+
* Query parameter for menu item filter.
|
|
96
|
+
* @static
|
|
97
|
+
* @type {string}
|
|
98
|
+
*/
|
|
99
|
+
static MENU_ITEM_PARAM: string;
|
|
100
|
+
/**
|
|
101
|
+
* Query parameter for user ID filter.
|
|
102
|
+
* @static
|
|
103
|
+
* @type {string}
|
|
104
|
+
*/
|
|
105
|
+
static USER_ID_PARAM: string;
|
|
106
|
+
/**
|
|
107
|
+
* Query parameter for status filter.
|
|
108
|
+
* @static
|
|
109
|
+
* @type {string}
|
|
110
|
+
*/
|
|
111
|
+
static STATUS_PARAM: string;
|
|
66
112
|
/**
|
|
67
113
|
* Represents the array of file size units ('B', 'KB', 'MB') used for file size formatting.
|
|
68
114
|
* @static
|
|
@@ -105,6 +151,12 @@ export declare class SHARED {
|
|
|
105
151
|
* @type {string}
|
|
106
152
|
*/
|
|
107
153
|
static CONTEXT_ID: string;
|
|
154
|
+
/**
|
|
155
|
+
* Represent contextId.
|
|
156
|
+
* @static
|
|
157
|
+
* @type {string}
|
|
158
|
+
*/
|
|
159
|
+
static CATEGORY: string;
|
|
108
160
|
/**
|
|
109
161
|
* Represent fileSize.
|
|
110
162
|
* @static
|
|
@@ -153,6 +205,67 @@ export declare class SHARED {
|
|
|
153
205
|
badge?: undefined;
|
|
154
206
|
})[];
|
|
155
207
|
}[];
|
|
208
|
+
static APPLICATION: string;
|
|
209
|
+
static APPLICANTS: string;
|
|
210
|
+
static EMPTY_SPACE: string;
|
|
211
|
+
static COLORS: string[];
|
|
212
|
+
static COLOR_MAP: {
|
|
213
|
+
orange: string;
|
|
214
|
+
blue: string;
|
|
215
|
+
green: string;
|
|
216
|
+
grey: string;
|
|
217
|
+
purple: string;
|
|
218
|
+
};
|
|
219
|
+
static DEFAULT_COLOR: string;
|
|
220
|
+
static STATUS_WITH_DASH: string;
|
|
221
|
+
static ICON_WITH_DASH: string;
|
|
222
|
+
static SEARCH_KEY: string;
|
|
223
|
+
static APPROVED: string;
|
|
224
|
+
static UPLOADED: string;
|
|
225
|
+
static PENDING: string;
|
|
226
|
+
static DOT: string;
|
|
227
|
+
static PDF: string;
|
|
228
|
+
static PENDING_STATUS: string;
|
|
229
|
+
static JPG: string;
|
|
230
|
+
static PNG: string;
|
|
231
|
+
static XLSX: string;
|
|
232
|
+
static APPROVED_STATUS: string;
|
|
233
|
+
static ALERT_STATUS: string;
|
|
234
|
+
static UPLOADED_STATUS: string;
|
|
235
|
+
static REVIEWING_STATUS: string;
|
|
236
|
+
static REJECTED_STATUS: string;
|
|
237
|
+
static STATUS_PENDING_CLASS: string;
|
|
238
|
+
static STATUS_APPROVED_CLASS: string;
|
|
239
|
+
static STATUS_ALERT_CLASS: string;
|
|
240
|
+
static STATUS_UPLOADED_CLASS: string;
|
|
241
|
+
static STATUS_REVIEWING_CLASS: string;
|
|
242
|
+
static STATUS_REJECTED_CLASS: string;
|
|
243
|
+
static ICON_CHECK: string;
|
|
244
|
+
static ICON_EXCLAMATION_TRIANGLE: string;
|
|
245
|
+
static ICON_CLOUD_UPLOAD: string;
|
|
246
|
+
static ICON_EYE: string;
|
|
247
|
+
static ICON_TIMES: string;
|
|
248
|
+
static ICON_CLOCK: string;
|
|
249
|
+
static ICON_FILE_PDF: string;
|
|
250
|
+
static ICON_IMAGE: string;
|
|
251
|
+
static ICON_FILE_EXCEL: string;
|
|
252
|
+
static ICON_FILE: string;
|
|
253
|
+
static ICON_DELETE: string;
|
|
254
|
+
static CELL_TYPE_DOCUMENT: string;
|
|
255
|
+
static CELL_TYPE_STATUS: string;
|
|
256
|
+
static CELL_TYPE_ACTIONS: string;
|
|
257
|
+
static CELL_TYPE_TEXT: string;
|
|
258
|
+
/**
|
|
259
|
+
* Document table columns configuration
|
|
260
|
+
* @static
|
|
261
|
+
* @type {Array<{field: string, header: string, type: 'text' | 'status' | 'document' | 'actions', width: string}>}
|
|
262
|
+
*/
|
|
263
|
+
static DOCUMENT_TABLE_COLUMNS: Array<{
|
|
264
|
+
field: string;
|
|
265
|
+
header: string;
|
|
266
|
+
type: 'text' | 'status' | 'document' | 'actions';
|
|
267
|
+
width: string;
|
|
268
|
+
}>;
|
|
156
269
|
}
|
|
157
270
|
/**
|
|
158
271
|
* `DUMMYDOCUMENTLIST` is a mock list of document objects used for testing and development purposes.
|
|
@@ -19,6 +19,13 @@ export declare class URLS {
|
|
|
19
19
|
* @type {string}
|
|
20
20
|
*/
|
|
21
21
|
static DOCUMENT_UPLOAD: string;
|
|
22
|
+
/**
|
|
23
|
+
* The URL endpoint for document uploads.
|
|
24
|
+
* Used to send documents to the server for storage or processing.
|
|
25
|
+
* @static
|
|
26
|
+
* @type {string}
|
|
27
|
+
*/
|
|
28
|
+
static DOCUMENTS_CATAGORIES: string;
|
|
22
29
|
/**
|
|
23
30
|
* The query parameter to pass a context ID in API requests.
|
|
24
31
|
* Used to specify the context for certain API calls, such as filtering or scoping the request.
|
|
@@ -50,6 +57,19 @@ export declare class URLS {
|
|
|
50
57
|
* @type {string}
|
|
51
58
|
*/
|
|
52
59
|
static PARENT_DOCUMENT_TYPE_ID: string;
|
|
60
|
+
/**
|
|
61
|
+
* The query parameter to pass a document ID in API requests.
|
|
62
|
+
* @static
|
|
63
|
+
* @type {string}
|
|
64
|
+
*/
|
|
65
|
+
static USERLIST: string;
|
|
66
|
+
/**
|
|
67
|
+
* The URL endpoint for getting document status count by context ID.
|
|
68
|
+
* Used to fetch status data with applicationId, contextId, and category parameters.
|
|
69
|
+
* @static
|
|
70
|
+
* @type {string}
|
|
71
|
+
*/
|
|
72
|
+
static STATUS_DOCUMENT_COUNT: string;
|
|
53
73
|
/**
|
|
54
74
|
* The query parameter to pass a context ID in API requests.
|
|
55
75
|
* Used to specify the context for certain API calls, such as filtering or scoping the request.
|
|
@@ -57,4 +77,6 @@ export declare class URLS {
|
|
|
57
77
|
* @type {string}
|
|
58
78
|
*/
|
|
59
79
|
static CONTEXT_ID: string;
|
|
80
|
+
static GETALL: string;
|
|
81
|
+
static DOCUMENT_LIST: string;
|
|
60
82
|
}
|