cat-documents-ng 0.1.26 → 0.1.28
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/fesm2022/cat-documents-ng.mjs +109 -77
- package/fesm2022/cat-documents-ng.mjs.map +1 -1
- package/lib/document/components/document-list/document-list.component.d.ts +7 -4
- package/lib/document/components/document-viewer/document-viewer.component.d.ts +3 -2
- package/lib/document/state/document.query.d.ts +1 -0
- package/lib/document/state/document.store.d.ts +1 -0
- package/package.json +1 -1
|
@@ -7,6 +7,7 @@ import { DocumentQuery } from '../../state/document.query';
|
|
|
7
7
|
import { DocumentStore } from '../../state/document.store';
|
|
8
8
|
import { PERMISSIONS } from '../../../../Shared/constant/PERMISSIONS';
|
|
9
9
|
import { SessionService } from '../../../../Shared/services/session.service';
|
|
10
|
+
import { DocumentService } from '../../services/document.service';
|
|
10
11
|
import * as i0 from "@angular/core";
|
|
11
12
|
/**
|
|
12
13
|
* This component is responsible for displaying and managing a list of documents.
|
|
@@ -19,6 +20,7 @@ export declare class DocumentListComponent implements OnInit {
|
|
|
19
20
|
documentQuery: DocumentQuery;
|
|
20
21
|
documentStore: DocumentStore;
|
|
21
22
|
private sessionService;
|
|
23
|
+
private documentService;
|
|
22
24
|
onRefresh: EventEmitter<any>;
|
|
23
25
|
/**
|
|
24
26
|
* Represents the context ID for the document list.
|
|
@@ -69,7 +71,7 @@ export declare class DocumentListComponent implements OnInit {
|
|
|
69
71
|
* @type {string}
|
|
70
72
|
* @memberof DocumentListComponent
|
|
71
73
|
*/
|
|
72
|
-
documentName: string;
|
|
74
|
+
documentName: string | undefined;
|
|
73
75
|
/**
|
|
74
76
|
* Available document types for selection.
|
|
75
77
|
* @type {string[]}
|
|
@@ -91,10 +93,10 @@ export declare class DocumentListComponent implements OnInit {
|
|
|
91
93
|
* It may be undefined until a file is selected or loaded.
|
|
92
94
|
* @type {string | undefined}
|
|
93
95
|
*/
|
|
94
|
-
fileName: string | undefined;
|
|
95
96
|
documentStatus: string | undefined;
|
|
96
97
|
hasDocumentPutAccess: any;
|
|
97
98
|
fileNameError: string;
|
|
99
|
+
documentExtension: string;
|
|
98
100
|
disallowedCharsRegex: RegExp;
|
|
99
101
|
fileInput: ElementRef<HTMLInputElement>;
|
|
100
102
|
/**
|
|
@@ -105,11 +107,12 @@ export declare class DocumentListComponent implements OnInit {
|
|
|
105
107
|
* @param {DocumentQuery} documentQuery - The service responsible for geting stored documents.
|
|
106
108
|
* @param {DocumentStore} documentStore - The service responsible for storing documents.
|
|
107
109
|
*/
|
|
108
|
-
constructor(documentUploadService: DocumentUploadService, documentHttpService: DocumentHttpService, documentQuery: DocumentQuery, documentStore: DocumentStore, sessionService: SessionService);
|
|
110
|
+
constructor(documentUploadService: DocumentUploadService, documentHttpService: DocumentHttpService, documentQuery: DocumentQuery, documentStore: DocumentStore, sessionService: SessionService, documentService: DocumentService);
|
|
109
111
|
/**
|
|
110
112
|
* Initializes the component by fetching the document type list.
|
|
111
113
|
*/
|
|
112
114
|
ngOnInit(): void;
|
|
115
|
+
handleUpdatedDocument(document: DocumentModel): void;
|
|
113
116
|
/**
|
|
114
117
|
* Handles the click event for file upload.
|
|
115
118
|
* Prevents event propagation and displays the sidebar.
|
|
@@ -137,7 +140,7 @@ export declare class DocumentListComponent implements OnInit {
|
|
|
137
140
|
* @memberof DocumentListComponent
|
|
138
141
|
*/
|
|
139
142
|
handleCloseModal(): void;
|
|
140
|
-
|
|
143
|
+
onDocumentNameChange(event: Event): void;
|
|
141
144
|
/**
|
|
142
145
|
* Handles the upload action for a document.
|
|
143
146
|
* Validates if a document type is selected and logs the result.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { OnChanges, OnDestroy } from '@angular/core';
|
|
1
|
+
import { EventEmitter, OnChanges, OnDestroy } from '@angular/core';
|
|
2
2
|
import { DynamicDialogRef } from 'primeng/dynamicdialog';
|
|
3
3
|
import { DocumentHttpService } from '../../services/document-http.service';
|
|
4
4
|
import { DocumentModel } from '../../models/document.model';
|
|
@@ -42,6 +42,7 @@ export declare class DocumentViewerComponent implements OnChanges, OnDestroy {
|
|
|
42
42
|
* @type {any}
|
|
43
43
|
*/
|
|
44
44
|
alertData: any;
|
|
45
|
+
updatedDocument: EventEmitter<DocumentModel>;
|
|
45
46
|
/**
|
|
46
47
|
* Holds the subscription to manage observable cleanup.
|
|
47
48
|
* @private
|
|
@@ -68,5 +69,5 @@ export declare class DocumentViewerComponent implements OnChanges, OnDestroy {
|
|
|
68
69
|
isImage(contentType?: string): boolean;
|
|
69
70
|
ngOnDestroy(): void;
|
|
70
71
|
static ɵfac: i0.ɵɵFactoryDeclaration<DocumentViewerComponent, never>;
|
|
71
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DocumentViewerComponent, "document-viewer", never, { "selectedDocument": { "alias": "selectedDocument"; "required": false; }; "documentList": { "alias": "documentList"; "required": false; }; }, {}, never, ["[action-launcher]", "*"], false, never>;
|
|
72
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DocumentViewerComponent, "document-viewer", never, { "selectedDocument": { "alias": "selectedDocument"; "required": false; }; "documentList": { "alias": "documentList"; "required": false; }; }, { "updatedDocument": "updatedDocument"; }, never, ["[action-launcher]", "*"], false, never>;
|
|
72
73
|
}
|
|
@@ -36,6 +36,7 @@ export declare class DocumentQuery extends QueryEntity<DocumentState> {
|
|
|
36
36
|
*/
|
|
37
37
|
selectDocumets(): Observable<DocumentModel[]>;
|
|
38
38
|
getSelectedDocument(): Observable<any>;
|
|
39
|
+
getIsDocumentUpdated(): Observable<any>;
|
|
39
40
|
static ɵfac: i0.ɵɵFactoryDeclaration<DocumentQuery, never>;
|
|
40
41
|
static ɵprov: i0.ɵɵInjectableDeclaration<DocumentQuery>;
|
|
41
42
|
}
|
|
@@ -23,6 +23,7 @@ export declare class DocumentStore extends EntityStore<DocumentState> {
|
|
|
23
23
|
setMessage(message: Message[]): void;
|
|
24
24
|
setDocumentList(documents: DocumentModel[]): void;
|
|
25
25
|
setSelectedDocument(selectedDocument: any): void;
|
|
26
|
+
setIsDocumentUpdated(isDocumentUpdated: any): void;
|
|
26
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<DocumentStore, never>;
|
|
27
28
|
static ɵprov: i0.ɵɵInjectableDeclaration<DocumentStore>;
|
|
28
29
|
}
|