@muni-sanfer/types-gestor-documental 0.0.1-beta.39 → 0.0.1-beta.40
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/base/entities.d.ts +69 -0
- package/dist/base/entities.js +15 -1
- package/dist/contracts/document.contract.d.ts +2 -0
- package/dist/contracts/draftingRequest.contract.d.ts +94 -0
- package/dist/contracts/draftingRequest.contract.js +11 -0
- package/dist/contracts/index.d.ts +10 -1
- package/dist/contracts/index.js +3 -0
- package/dist/entities/document/document.entity.d.ts +8 -0
- package/dist/entities/draftingRequest/draftingRequest.entity.d.ts +76 -0
- package/dist/entities/draftingRequest/draftingRequest.entity.js +2 -0
- package/dist/entities/draftingRequest/index.d.ts +1 -0
- package/dist/entities/draftingRequest/index.js +17 -0
- package/dist/entities/index.d.ts +1 -0
- package/dist/entities/index.js +1 -0
- package/package.json +1 -1
- package/src/base/entities.ts +77 -0
- package/src/contracts/document.contract.ts +2 -0
- package/src/contracts/draftingRequest.contract.ts +73 -0
- package/src/contracts/index.ts +5 -1
- package/src/entities/document/document.entity.ts +5 -0
- package/src/entities/draftingRequest/draftingRequest.entity.ts +78 -0
- package/src/entities/draftingRequest/index.ts +1 -0
- package/src/entities/index.ts +1 -0
package/dist/base/entities.d.ts
CHANGED
|
@@ -405,6 +405,22 @@ export declare const MailAuthentication: {
|
|
|
405
405
|
Fail: "Fail";
|
|
406
406
|
Unknown: "Unknown";
|
|
407
407
|
};
|
|
408
|
+
export type DraftingRequestStatus = 'Pending' | 'Taken' | 'Declined' | 'Cancelled';
|
|
409
|
+
export declare const DraftingRequestStatus: {
|
|
410
|
+
Pending: "Pending";
|
|
411
|
+
Taken: "Taken";
|
|
412
|
+
Declined: "Declined";
|
|
413
|
+
Cancelled: "Cancelled";
|
|
414
|
+
};
|
|
415
|
+
export type DraftingRequestEventAction = 'Created' | 'Taken' | 'Released' | 'Declined' | 'Cancelled' | 'DocumentLinked';
|
|
416
|
+
export declare const DraftingRequestEventAction: {
|
|
417
|
+
Created: "Created";
|
|
418
|
+
Taken: "Taken";
|
|
419
|
+
Released: "Released";
|
|
420
|
+
Declined: "Declined";
|
|
421
|
+
Cancelled: "Cancelled";
|
|
422
|
+
DocumentLinked: "DocumentLinked";
|
|
423
|
+
};
|
|
408
424
|
export interface DocumentTypeEntity {
|
|
409
425
|
id: string;
|
|
410
426
|
name: string;
|
|
@@ -429,6 +445,7 @@ export interface DocumentTypeEntity {
|
|
|
429
445
|
numberingMembers?: DocumentTypeEntity[];
|
|
430
446
|
enabled: boolean;
|
|
431
447
|
documents?: DocumentEntity[];
|
|
448
|
+
draftingRequests?: DraftingRequestEntity[];
|
|
432
449
|
annulledNumbers?: DocumentAnnulledNumberEntity[];
|
|
433
450
|
flowSteps?: DocumentTypeFlowStepEntity[];
|
|
434
451
|
signatureBatches?: SignatureBatchEntity[];
|
|
@@ -505,6 +522,7 @@ export interface DocumentEntity {
|
|
|
505
522
|
versions?: DocumentVersionEntity[];
|
|
506
523
|
comments?: DocumentCommentEntity[];
|
|
507
524
|
draftReviews?: DocumentDraftReviewEntity[];
|
|
525
|
+
draftingRequest?: DraftingRequestEntity | null;
|
|
508
526
|
accessRequestDeliveries?: AccessRequestDocumentEntity[];
|
|
509
527
|
dispatch?: DocumentDispatchEntity | null;
|
|
510
528
|
docDigitalInbound?: DocDigitalInboundEntity | null;
|
|
@@ -1348,6 +1366,57 @@ export interface DocumentCommentEntity {
|
|
|
1348
1366
|
resolutionNote?: string | null;
|
|
1349
1367
|
createdAt: string;
|
|
1350
1368
|
}
|
|
1369
|
+
export interface DraftingRequestEntity {
|
|
1370
|
+
id: string;
|
|
1371
|
+
number: number;
|
|
1372
|
+
year: number;
|
|
1373
|
+
subject: string;
|
|
1374
|
+
details: string;
|
|
1375
|
+
documentTypeId?: string | null;
|
|
1376
|
+
documentType?: DocumentTypeEntity | null;
|
|
1377
|
+
dueAt?: string | null;
|
|
1378
|
+
requesterEmployeeId: string;
|
|
1379
|
+
requesterFullName: string;
|
|
1380
|
+
requesterAreaName?: string | null;
|
|
1381
|
+
targetDirectorateCode: number;
|
|
1382
|
+
targetDirectorateName: string;
|
|
1383
|
+
status: DraftingRequestStatus;
|
|
1384
|
+
takenByEmployeeId?: string | null;
|
|
1385
|
+
takenByFullName?: string | null;
|
|
1386
|
+
takenAt?: string | null;
|
|
1387
|
+
closedAt?: string | null;
|
|
1388
|
+
closingNote?: string | null;
|
|
1389
|
+
documentId?: string | null;
|
|
1390
|
+
document?: DocumentEntity | null;
|
|
1391
|
+
recipients?: DraftingRequestRecipientEntity[];
|
|
1392
|
+
attachments?: DraftingRequestAttachmentEntity[];
|
|
1393
|
+
events?: DraftingRequestEventEntity[];
|
|
1394
|
+
createdAt: string;
|
|
1395
|
+
updatedAt: string;
|
|
1396
|
+
}
|
|
1397
|
+
export interface DraftingRequestRecipientEntity {
|
|
1398
|
+
id: string;
|
|
1399
|
+
requestId: string;
|
|
1400
|
+
request?: DraftingRequestEntity;
|
|
1401
|
+
employeeId: string;
|
|
1402
|
+
}
|
|
1403
|
+
export interface DraftingRequestAttachmentEntity {
|
|
1404
|
+
id: string;
|
|
1405
|
+
requestId: string;
|
|
1406
|
+
request?: DraftingRequestEntity;
|
|
1407
|
+
fileId: string;
|
|
1408
|
+
name: string;
|
|
1409
|
+
}
|
|
1410
|
+
export interface DraftingRequestEventEntity {
|
|
1411
|
+
id: string;
|
|
1412
|
+
requestId: string;
|
|
1413
|
+
request?: DraftingRequestEntity;
|
|
1414
|
+
action: DraftingRequestEventAction;
|
|
1415
|
+
note?: string | null;
|
|
1416
|
+
employeeId: string;
|
|
1417
|
+
employeeFullName: string;
|
|
1418
|
+
createdAt: string;
|
|
1419
|
+
}
|
|
1351
1420
|
type JsonValue = string | number | boolean | {
|
|
1352
1421
|
[key in string]?: JsonValue;
|
|
1353
1422
|
} | Array<JsonValue> | null;
|
package/dist/base/entities.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// This file was auto-generated by prisma-generator-typescript-interfaces
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.DeskFileSource = exports.DataBreachNoticeMeans = exports.DataBreachEventAction = exports.DataBreachStatus = exports.DataBreachKind = exports.DataRightsEventAction = exports.DataRightsResolution = exports.DataRightsRequestStatus = exports.DataRightsChannel = exports.DataRight = exports.DataLegalBasis = exports.TransparencyStatus = exports.AccessRequestEventAction = exports.AccessRequestResolution = exports.AccessRequestStatus = exports.AccessRequestChannel = exports.DispositionKind = exports.FinalDisposition = exports.AuditAction = exports.AuditEntity = exports.DocumentAccessAction = exports.QualityMetricKey = exports.ServiceOutageKind = exports.WorkFolderItemKind = exports.TextSnippetSection = exports.ScanSessionStatus = exports.CaseFileAccessAction = exports.CaseFileTrackingAction = exports.CaseFileActorType = exports.CaseFileActorRelation = exports.CaseFileEntryKind = exports.CaseFileActuationType = exports.CaseFileIncorporationMechanism = exports.CaseFileStatus = exports.DocumentInstruction = exports.DocumentDeliveryOrigin = exports.DocumentRecipientType = exports.DocumentAttachmentType = exports.DocumentFlowStepType = exports.DocDigitalInboundStatus = exports.DocumentDispatchStatus = exports.CommunicationMeans = exports.DocumentOrigin = exports.DraftReviewStatus = exports.DocumentTrackingAction = exports.DocumentParticipantStatus = exports.DocumentParticipantRole = exports.DocumentAccessLevel = exports.DocumentStatus = exports.DocumentCategory = void 0;
|
|
5
|
-
exports.MailAuthentication = exports.MailIntakeStatus = exports.DeskFileTarget = void 0;
|
|
5
|
+
exports.DraftingRequestEventAction = exports.DraftingRequestStatus = exports.MailAuthentication = exports.MailIntakeStatus = exports.DeskFileTarget = void 0;
|
|
6
6
|
exports.DocumentCategory = {
|
|
7
7
|
Decree: 'Decree',
|
|
8
8
|
Communication: 'Communication',
|
|
@@ -357,3 +357,17 @@ exports.MailAuthentication = {
|
|
|
357
357
|
Fail: 'Fail',
|
|
358
358
|
Unknown: 'Unknown',
|
|
359
359
|
};
|
|
360
|
+
exports.DraftingRequestStatus = {
|
|
361
|
+
Pending: 'Pending',
|
|
362
|
+
Taken: 'Taken',
|
|
363
|
+
Declined: 'Declined',
|
|
364
|
+
Cancelled: 'Cancelled',
|
|
365
|
+
};
|
|
366
|
+
exports.DraftingRequestEventAction = {
|
|
367
|
+
Created: 'Created',
|
|
368
|
+
Taken: 'Taken',
|
|
369
|
+
Released: 'Released',
|
|
370
|
+
Declined: 'Declined',
|
|
371
|
+
Cancelled: 'Cancelled',
|
|
372
|
+
DocumentLinked: 'DocumentLinked',
|
|
373
|
+
};
|
|
@@ -75,6 +75,8 @@ export interface DocumentWritePayload extends Pick<DocumentEntity, 'subject' | '
|
|
|
75
75
|
keywords: string[];
|
|
76
76
|
/** Qué cambió, si el guardado crea una versión nueva (otro PDF, otro texto u otro asunto). */
|
|
77
77
|
versionNote?: string | null;
|
|
78
|
+
/** Al crearlo: solicitud de redacción que atiende (la tomó quien redacta). */
|
|
79
|
+
draftingRequestId?: string | null;
|
|
78
80
|
accessLevel?: DocumentAccessLevel;
|
|
79
81
|
hasSensitiveData?: boolean;
|
|
80
82
|
directorateCodeReference?: number | null;
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { type DraftingRequestDetailEntity, type DraftingRequestListItemEntity } from '../entities';
|
|
2
|
+
import { type RpcPage } from './contract';
|
|
3
|
+
/** Patrones NATS de `draftingRequest`: solicitudes de redacción entre áreas. */
|
|
4
|
+
export declare const DraftingRequestPatterns: {
|
|
5
|
+
readonly getAll: "gestorDocumental.draftingRequest.getAll";
|
|
6
|
+
readonly getById: "gestorDocumental.draftingRequest.getById";
|
|
7
|
+
readonly create: "gestorDocumental.draftingRequest.create";
|
|
8
|
+
readonly act: "gestorDocumental.draftingRequest.act";
|
|
9
|
+
readonly getAttachmentFile: "gestorDocumental.draftingRequest.getAttachmentFile";
|
|
10
|
+
};
|
|
11
|
+
/** Quien consulta o actúa: el funcionario de la sesión, con su nombre. */
|
|
12
|
+
export interface DraftingRequestActor {
|
|
13
|
+
employeeId: string;
|
|
14
|
+
fullName: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Bandeja: las que le llegaron a su dirección, las que tomó o las que pidió. `state`: abiertas (sin tomar, tomadas o
|
|
18
|
+
* en redacción), cerradas (atendidas, devueltas o retiradas) o todas.
|
|
19
|
+
*/
|
|
20
|
+
export type DraftingRequestBox = 'received' | 'taken' | 'sent';
|
|
21
|
+
export interface DraftingRequestCreatePayload {
|
|
22
|
+
subject: string;
|
|
23
|
+
details: string;
|
|
24
|
+
documentTypeId?: string | null;
|
|
25
|
+
dueAt?: string | null;
|
|
26
|
+
attachments?: {
|
|
27
|
+
fileId: string;
|
|
28
|
+
name: string;
|
|
29
|
+
}[];
|
|
30
|
+
/** Dirección a la que se pide, con el nombre que le pone el gateway. */
|
|
31
|
+
targetDirectorateCode: number;
|
|
32
|
+
targetDirectorateName: string;
|
|
33
|
+
/** Quienes la integran hoy, resueltos por el gateway (sin quien la pide). */
|
|
34
|
+
recipientEmployeeIds: string[];
|
|
35
|
+
requesterAreaName?: string | null;
|
|
36
|
+
actor: DraftingRequestActor;
|
|
37
|
+
}
|
|
38
|
+
/** Lo que se hace con una solicitud, un paso a la vez. */
|
|
39
|
+
export type DraftingRequestAction = {
|
|
40
|
+
type: 'take';
|
|
41
|
+
} | {
|
|
42
|
+
type: 'release';
|
|
43
|
+
note?: string | null;
|
|
44
|
+
} | {
|
|
45
|
+
type: 'decline';
|
|
46
|
+
note: string;
|
|
47
|
+
} | {
|
|
48
|
+
type: 'cancel';
|
|
49
|
+
note?: string | null;
|
|
50
|
+
};
|
|
51
|
+
export interface DraftingRequestContract {
|
|
52
|
+
[DraftingRequestPatterns.getAll]: {
|
|
53
|
+
payload: {
|
|
54
|
+
box: DraftingRequestBox;
|
|
55
|
+
state?: 'open' | 'closed' | 'all';
|
|
56
|
+
search?: string;
|
|
57
|
+
page?: number;
|
|
58
|
+
limit?: number;
|
|
59
|
+
actor: Pick<DraftingRequestActor, 'employeeId'>;
|
|
60
|
+
};
|
|
61
|
+
response: RpcPage<DraftingRequestListItemEntity[]>;
|
|
62
|
+
};
|
|
63
|
+
[DraftingRequestPatterns.getById]: {
|
|
64
|
+
payload: {
|
|
65
|
+
id: string;
|
|
66
|
+
actor: Pick<DraftingRequestActor, 'employeeId'>;
|
|
67
|
+
};
|
|
68
|
+
response: DraftingRequestDetailEntity;
|
|
69
|
+
};
|
|
70
|
+
[DraftingRequestPatterns.create]: {
|
|
71
|
+
payload: DraftingRequestCreatePayload;
|
|
72
|
+
response: DraftingRequestDetailEntity;
|
|
73
|
+
};
|
|
74
|
+
[DraftingRequestPatterns.act]: {
|
|
75
|
+
payload: {
|
|
76
|
+
id: string;
|
|
77
|
+
action: DraftingRequestAction;
|
|
78
|
+
actor: DraftingRequestActor;
|
|
79
|
+
};
|
|
80
|
+
response: DraftingRequestDetailEntity;
|
|
81
|
+
};
|
|
82
|
+
/** Archivo adjunto, con las mismas reglas de acceso del detalle. */
|
|
83
|
+
[DraftingRequestPatterns.getAttachmentFile]: {
|
|
84
|
+
payload: {
|
|
85
|
+
id: string;
|
|
86
|
+
attachmentId: string;
|
|
87
|
+
actor: Pick<DraftingRequestActor, 'employeeId'>;
|
|
88
|
+
};
|
|
89
|
+
response: {
|
|
90
|
+
fileId: string;
|
|
91
|
+
fileName: string;
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DraftingRequestPatterns = void 0;
|
|
4
|
+
/** Patrones NATS de `draftingRequest`: solicitudes de redacción entre áreas. */
|
|
5
|
+
exports.DraftingRequestPatterns = {
|
|
6
|
+
getAll: 'gestorDocumental.draftingRequest.getAll',
|
|
7
|
+
getById: 'gestorDocumental.draftingRequest.getById',
|
|
8
|
+
create: 'gestorDocumental.draftingRequest.create',
|
|
9
|
+
act: 'gestorDocumental.draftingRequest.act',
|
|
10
|
+
getAttachmentFile: 'gestorDocumental.draftingRequest.getAttachmentFile',
|
|
11
|
+
};
|
|
@@ -23,6 +23,7 @@ import { type ProcedureContract } from './procedure.contract';
|
|
|
23
23
|
import { type RegisterBookContract } from './registerBook.contract';
|
|
24
24
|
import { type SignatureBatchContract } from './signatureBatch.contract';
|
|
25
25
|
import { type WorkFolderContract } from './workFolder.contract';
|
|
26
|
+
import { type DraftingRequestContract } from './draftingRequest.contract';
|
|
26
27
|
export * from './contract';
|
|
27
28
|
export * from './document.contract';
|
|
28
29
|
export * from './documentType.contract';
|
|
@@ -49,6 +50,7 @@ export * from './dataProtection.contract';
|
|
|
49
50
|
export * from './desk.contract';
|
|
50
51
|
export * from './mailIntake.contract';
|
|
51
52
|
export * from './push.contract';
|
|
53
|
+
export * from './draftingRequest.contract';
|
|
52
54
|
/** Patrones NATS de gestor-documental-ms, por recurso: `gestorDocumental.<recurso>.<acción>`. */
|
|
53
55
|
export declare const GestorDocumentalPatterns: {
|
|
54
56
|
readonly documentType: {
|
|
@@ -298,6 +300,13 @@ export declare const GestorDocumentalPatterns: {
|
|
|
298
300
|
readonly test: "gestorDocumental.push.test";
|
|
299
301
|
readonly send: "gestorDocumental.push.send";
|
|
300
302
|
};
|
|
303
|
+
readonly draftingRequest: {
|
|
304
|
+
readonly getAll: "gestorDocumental.draftingRequest.getAll";
|
|
305
|
+
readonly getById: "gestorDocumental.draftingRequest.getById";
|
|
306
|
+
readonly create: "gestorDocumental.draftingRequest.create";
|
|
307
|
+
readonly act: "gestorDocumental.draftingRequest.act";
|
|
308
|
+
readonly getAttachmentFile: "gestorDocumental.draftingRequest.getAttachmentFile";
|
|
309
|
+
};
|
|
301
310
|
};
|
|
302
311
|
/** Contrato completo de gestor-documental-ms: la unión de los contratos de sus recursos. */
|
|
303
|
-
export type GestorDocumentalContract = DocumentTypeContract & DocumentContract & ProcedureContract & IssuingEntityContract & CaseFileContract & PartsOfficeContract & RegisterBookContract & SignatureBatchContract & WorkFolderContract & ScanContract & ArchivalSeriesContract & TextSnippetContract & DocumentTemplateContract & HolidayContract & IndicatorsContract & AuditContract & SignatureCheckContract & RepositoryExportContract & RetentionContract & AccessRequestContract & TransparencyContract & DataProtectionContract & DeskContract & MailIntakeContract & PushContract;
|
|
312
|
+
export type GestorDocumentalContract = DocumentTypeContract & DocumentContract & ProcedureContract & IssuingEntityContract & CaseFileContract & PartsOfficeContract & RegisterBookContract & SignatureBatchContract & WorkFolderContract & ScanContract & ArchivalSeriesContract & TextSnippetContract & DocumentTemplateContract & HolidayContract & IndicatorsContract & AuditContract & SignatureCheckContract & RepositoryExportContract & RetentionContract & AccessRequestContract & TransparencyContract & DataProtectionContract & DeskContract & MailIntakeContract & PushContract & DraftingRequestContract;
|
package/dist/contracts/index.js
CHANGED
|
@@ -40,6 +40,7 @@ const procedure_contract_1 = require("./procedure.contract");
|
|
|
40
40
|
const registerBook_contract_1 = require("./registerBook.contract");
|
|
41
41
|
const signatureBatch_contract_1 = require("./signatureBatch.contract");
|
|
42
42
|
const workFolder_contract_1 = require("./workFolder.contract");
|
|
43
|
+
const draftingRequest_contract_1 = require("./draftingRequest.contract");
|
|
43
44
|
__exportStar(require("./contract"), exports);
|
|
44
45
|
__exportStar(require("./document.contract"), exports);
|
|
45
46
|
__exportStar(require("./documentType.contract"), exports);
|
|
@@ -66,6 +67,7 @@ __exportStar(require("./dataProtection.contract"), exports);
|
|
|
66
67
|
__exportStar(require("./desk.contract"), exports);
|
|
67
68
|
__exportStar(require("./mailIntake.contract"), exports);
|
|
68
69
|
__exportStar(require("./push.contract"), exports);
|
|
70
|
+
__exportStar(require("./draftingRequest.contract"), exports);
|
|
69
71
|
/** Patrones NATS de gestor-documental-ms, por recurso: `gestorDocumental.<recurso>.<acción>`. */
|
|
70
72
|
exports.GestorDocumentalPatterns = {
|
|
71
73
|
documentType: documentType_contract_1.DocumentTypePatterns,
|
|
@@ -93,4 +95,5 @@ exports.GestorDocumentalPatterns = {
|
|
|
93
95
|
desk: desk_contract_1.DeskPatterns,
|
|
94
96
|
mailIntake: mailIntake_contract_1.MailIntakePatterns,
|
|
95
97
|
push: push_contract_1.PushPatterns,
|
|
98
|
+
draftingRequest: draftingRequest_contract_1.DraftingRequestPatterns,
|
|
96
99
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type CommunicationMeans, DocumentAnnulledNumberEntity, DocumentAttachmentEntity, DocumentDeliveryEntity, DocumentEntity, DocumentParticipantEntity, DocumentRecipientEntity, type DocumentStatus, DocumentTrackingEntity, DocumentTypeEntity } from '../../base/entities';
|
|
2
|
+
import { type DocumentDraftingRequestEntity } from '../draftingRequest/draftingRequest.entity';
|
|
2
3
|
/** Tipo documental de un documento, con lo necesario para citarlo. */
|
|
3
4
|
export interface DocumentTypeSummaryEntity {
|
|
4
5
|
id: DocumentTypeEntity['id'];
|
|
@@ -186,6 +187,8 @@ export interface DocumentGetByIdResponseEntity {
|
|
|
186
187
|
* más reciente primero) y si la versión vigente ya está aprobada. `null` si el tipo no la exige.
|
|
187
188
|
*/
|
|
188
189
|
draftReview: DocumentDraftReviewInfoEntity | null;
|
|
190
|
+
/** Solicitud de redacción que atiende, si se redactó a pedido de otra área. */
|
|
191
|
+
draftingRequest: DocumentDraftingRequestEntity | null;
|
|
189
192
|
replies: DocumentLinkEntity[];
|
|
190
193
|
/** Expedientes en que está incorporado y que quien consulta puede ver. */
|
|
191
194
|
caseFiles: {
|
|
@@ -244,6 +247,11 @@ export interface DocumentGetSummaryResponseEntity {
|
|
|
244
247
|
toSign: number;
|
|
245
248
|
/** Borradores que esperan su revisión (como jefatura de la dirección que los revisa). */
|
|
246
249
|
toReview: number;
|
|
250
|
+
/** Solicitudes de redacción: sin tomar dirigidas a su dirección, y tomadas por él aún sin atender. */
|
|
251
|
+
draftingRequests: {
|
|
252
|
+
pending: number;
|
|
253
|
+
taken: number;
|
|
254
|
+
};
|
|
247
255
|
/** Lotes de firma con documentos en su turno (los documentos de un lote no se cuentan en `toVisa` ni `toSign`). */
|
|
248
256
|
batches: {
|
|
249
257
|
toVisa: number;
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { type DocumentStatus, type DraftingRequestEventAction, type DraftingRequestStatus } from '../../base/entities';
|
|
2
|
+
/**
|
|
3
|
+
* Cómo va la solicitud, para mostrarla: sin tomar, tomada (aún sin documento), en redacción (con documento en curso),
|
|
4
|
+
* atendida (su documento quedó finalizado), devuelta o retirada.
|
|
5
|
+
*/
|
|
6
|
+
export type DraftingRequestState = 'Pending' | 'Taken' | 'Drafting' | 'Completed' | 'Declined' | 'Cancelled';
|
|
7
|
+
/** Documento que atiende la solicitud. */
|
|
8
|
+
export interface DraftingRequestDocumentEntity {
|
|
9
|
+
id: string;
|
|
10
|
+
status: DocumentStatus;
|
|
11
|
+
/** «D.E. N° 590/2026», o `null` mientras no tiene número. */
|
|
12
|
+
folio: string | null;
|
|
13
|
+
}
|
|
14
|
+
export interface DraftingRequestListItemEntity {
|
|
15
|
+
id: string;
|
|
16
|
+
/** «N° 3/2026». */
|
|
17
|
+
label: string;
|
|
18
|
+
subject: string;
|
|
19
|
+
status: DraftingRequestStatus;
|
|
20
|
+
state: DraftingRequestState;
|
|
21
|
+
requesterEmployeeId: string;
|
|
22
|
+
requesterFullName: string;
|
|
23
|
+
requesterAreaName: string | null;
|
|
24
|
+
targetDirectorateCode: number;
|
|
25
|
+
targetDirectorateName: string;
|
|
26
|
+
takenByEmployeeId: string | null;
|
|
27
|
+
takenByFullName: string | null;
|
|
28
|
+
documentType: {
|
|
29
|
+
id: string;
|
|
30
|
+
name: string;
|
|
31
|
+
} | null;
|
|
32
|
+
dueAt: string | null;
|
|
33
|
+
createdAt: string;
|
|
34
|
+
document: DraftingRequestDocumentEntity | null;
|
|
35
|
+
}
|
|
36
|
+
export interface DraftingRequestAttachmentResponseEntity {
|
|
37
|
+
id: string;
|
|
38
|
+
name: string;
|
|
39
|
+
}
|
|
40
|
+
export interface DraftingRequestEventResponseEntity {
|
|
41
|
+
id: string;
|
|
42
|
+
action: DraftingRequestEventAction;
|
|
43
|
+
note: string | null;
|
|
44
|
+
employeeFullName: string;
|
|
45
|
+
createdAt: string;
|
|
46
|
+
}
|
|
47
|
+
export interface DraftingRequestDetailEntity extends DraftingRequestListItemEntity {
|
|
48
|
+
details: string;
|
|
49
|
+
takenAt: string | null;
|
|
50
|
+
closedAt: string | null;
|
|
51
|
+
closingNote: string | null;
|
|
52
|
+
/** Funcionarios de la dirección a los que les llegó. */
|
|
53
|
+
recipientCount: number;
|
|
54
|
+
attachments: DraftingRequestAttachmentResponseEntity[];
|
|
55
|
+
events: DraftingRequestEventResponseEntity[];
|
|
56
|
+
/** Qué puede hacer con ella quien la consulta. */
|
|
57
|
+
capabilities: {
|
|
58
|
+
canTake: boolean;
|
|
59
|
+
canRelease: boolean;
|
|
60
|
+
canDecline: boolean;
|
|
61
|
+
canCancel: boolean;
|
|
62
|
+
/** La tomó y aún no tiene documento (o lo descartó): puede redactarlo. */
|
|
63
|
+
canDraft: boolean;
|
|
64
|
+
};
|
|
65
|
+
/** Funcionarios a los que avisar de la operación que se acaba de hacer (lo usa el gateway). */
|
|
66
|
+
notify?: {
|
|
67
|
+
employeeIds: string[];
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
/** Solicitud enlazada a un documento, como se muestra en su detalle. */
|
|
71
|
+
export interface DocumentDraftingRequestEntity {
|
|
72
|
+
id: string;
|
|
73
|
+
label: string;
|
|
74
|
+
requesterFullName: string;
|
|
75
|
+
requesterAreaName: string | null;
|
|
76
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './draftingRequest.entity';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./draftingRequest.entity"), exports);
|
package/dist/entities/index.d.ts
CHANGED
package/dist/entities/index.js
CHANGED
package/package.json
CHANGED
package/src/base/entities.ts
CHANGED
|
@@ -604,6 +604,26 @@ export const MailAuthentication = {
|
|
|
604
604
|
Unknown: 'Unknown',
|
|
605
605
|
} satisfies Record<string, MailAuthentication>;
|
|
606
606
|
|
|
607
|
+
export type DraftingRequestStatus = 'Pending' | 'Taken' | 'Declined' | 'Cancelled';
|
|
608
|
+
|
|
609
|
+
export const DraftingRequestStatus = {
|
|
610
|
+
Pending: 'Pending',
|
|
611
|
+
Taken: 'Taken',
|
|
612
|
+
Declined: 'Declined',
|
|
613
|
+
Cancelled: 'Cancelled',
|
|
614
|
+
} satisfies Record<string, DraftingRequestStatus>;
|
|
615
|
+
|
|
616
|
+
export type DraftingRequestEventAction = 'Created' | 'Taken' | 'Released' | 'Declined' | 'Cancelled' | 'DocumentLinked';
|
|
617
|
+
|
|
618
|
+
export const DraftingRequestEventAction = {
|
|
619
|
+
Created: 'Created',
|
|
620
|
+
Taken: 'Taken',
|
|
621
|
+
Released: 'Released',
|
|
622
|
+
Declined: 'Declined',
|
|
623
|
+
Cancelled: 'Cancelled',
|
|
624
|
+
DocumentLinked: 'DocumentLinked',
|
|
625
|
+
} satisfies Record<string, DraftingRequestEventAction>;
|
|
626
|
+
|
|
607
627
|
export interface DocumentTypeEntity {
|
|
608
628
|
id: string;
|
|
609
629
|
name: string;
|
|
@@ -628,6 +648,7 @@ export interface DocumentTypeEntity {
|
|
|
628
648
|
numberingMembers?: DocumentTypeEntity[];
|
|
629
649
|
enabled: boolean;
|
|
630
650
|
documents?: DocumentEntity[];
|
|
651
|
+
draftingRequests?: DraftingRequestEntity[];
|
|
631
652
|
annulledNumbers?: DocumentAnnulledNumberEntity[];
|
|
632
653
|
flowSteps?: DocumentTypeFlowStepEntity[];
|
|
633
654
|
signatureBatches?: SignatureBatchEntity[];
|
|
@@ -705,6 +726,7 @@ export interface DocumentEntity {
|
|
|
705
726
|
versions?: DocumentVersionEntity[];
|
|
706
727
|
comments?: DocumentCommentEntity[];
|
|
707
728
|
draftReviews?: DocumentDraftReviewEntity[];
|
|
729
|
+
draftingRequest?: DraftingRequestEntity | null;
|
|
708
730
|
accessRequestDeliveries?: AccessRequestDocumentEntity[];
|
|
709
731
|
dispatch?: DocumentDispatchEntity | null;
|
|
710
732
|
docDigitalInbound?: DocDigitalInboundEntity | null;
|
|
@@ -1602,4 +1624,59 @@ export interface DocumentCommentEntity {
|
|
|
1602
1624
|
createdAt: string;
|
|
1603
1625
|
}
|
|
1604
1626
|
|
|
1627
|
+
export interface DraftingRequestEntity {
|
|
1628
|
+
id: string;
|
|
1629
|
+
number: number;
|
|
1630
|
+
year: number;
|
|
1631
|
+
subject: string;
|
|
1632
|
+
details: string;
|
|
1633
|
+
documentTypeId?: string | null;
|
|
1634
|
+
documentType?: DocumentTypeEntity | null;
|
|
1635
|
+
dueAt?: string | null;
|
|
1636
|
+
requesterEmployeeId: string;
|
|
1637
|
+
requesterFullName: string;
|
|
1638
|
+
requesterAreaName?: string | null;
|
|
1639
|
+
targetDirectorateCode: number;
|
|
1640
|
+
targetDirectorateName: string;
|
|
1641
|
+
status: DraftingRequestStatus;
|
|
1642
|
+
takenByEmployeeId?: string | null;
|
|
1643
|
+
takenByFullName?: string | null;
|
|
1644
|
+
takenAt?: string | null;
|
|
1645
|
+
closedAt?: string | null;
|
|
1646
|
+
closingNote?: string | null;
|
|
1647
|
+
documentId?: string | null;
|
|
1648
|
+
document?: DocumentEntity | null;
|
|
1649
|
+
recipients?: DraftingRequestRecipientEntity[];
|
|
1650
|
+
attachments?: DraftingRequestAttachmentEntity[];
|
|
1651
|
+
events?: DraftingRequestEventEntity[];
|
|
1652
|
+
createdAt: string;
|
|
1653
|
+
updatedAt: string;
|
|
1654
|
+
}
|
|
1655
|
+
|
|
1656
|
+
export interface DraftingRequestRecipientEntity {
|
|
1657
|
+
id: string;
|
|
1658
|
+
requestId: string;
|
|
1659
|
+
request?: DraftingRequestEntity;
|
|
1660
|
+
employeeId: string;
|
|
1661
|
+
}
|
|
1662
|
+
|
|
1663
|
+
export interface DraftingRequestAttachmentEntity {
|
|
1664
|
+
id: string;
|
|
1665
|
+
requestId: string;
|
|
1666
|
+
request?: DraftingRequestEntity;
|
|
1667
|
+
fileId: string;
|
|
1668
|
+
name: string;
|
|
1669
|
+
}
|
|
1670
|
+
|
|
1671
|
+
export interface DraftingRequestEventEntity {
|
|
1672
|
+
id: string;
|
|
1673
|
+
requestId: string;
|
|
1674
|
+
request?: DraftingRequestEntity;
|
|
1675
|
+
action: DraftingRequestEventAction;
|
|
1676
|
+
note?: string | null;
|
|
1677
|
+
employeeId: string;
|
|
1678
|
+
employeeFullName: string;
|
|
1679
|
+
createdAt: string;
|
|
1680
|
+
}
|
|
1681
|
+
|
|
1605
1682
|
type JsonValue = string | number | boolean | { [key in string]?: JsonValue } | Array<JsonValue> | null;
|
|
@@ -115,6 +115,8 @@ export interface DocumentWritePayload extends Pick<DocumentEntity, 'subject' | '
|
|
|
115
115
|
keywords: string[];
|
|
116
116
|
/** Qué cambió, si el guardado crea una versión nueva (otro PDF, otro texto u otro asunto). */
|
|
117
117
|
versionNote?: string | null;
|
|
118
|
+
/** Al crearlo: solicitud de redacción que atiende (la tomó quien redacta). */
|
|
119
|
+
draftingRequestId?: string | null;
|
|
118
120
|
accessLevel?: DocumentAccessLevel;
|
|
119
121
|
hasSensitiveData?: boolean;
|
|
120
122
|
directorateCodeReference?: number | null;
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { type DraftingRequestDetailEntity, type DraftingRequestListItemEntity } from '../entities';
|
|
2
|
+
import { type RpcPage } from './contract';
|
|
3
|
+
|
|
4
|
+
/** Patrones NATS de `draftingRequest`: solicitudes de redacción entre áreas. */
|
|
5
|
+
export const DraftingRequestPatterns = {
|
|
6
|
+
getAll: 'gestorDocumental.draftingRequest.getAll',
|
|
7
|
+
getById: 'gestorDocumental.draftingRequest.getById',
|
|
8
|
+
create: 'gestorDocumental.draftingRequest.create',
|
|
9
|
+
act: 'gestorDocumental.draftingRequest.act',
|
|
10
|
+
getAttachmentFile: 'gestorDocumental.draftingRequest.getAttachmentFile',
|
|
11
|
+
} as const;
|
|
12
|
+
|
|
13
|
+
/** Quien consulta o actúa: el funcionario de la sesión, con su nombre. */
|
|
14
|
+
export interface DraftingRequestActor {
|
|
15
|
+
employeeId: string;
|
|
16
|
+
fullName: string;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Bandeja: las que le llegaron a su dirección, las que tomó o las que pidió. `state`: abiertas (sin tomar, tomadas o
|
|
21
|
+
* en redacción), cerradas (atendidas, devueltas o retiradas) o todas.
|
|
22
|
+
*/
|
|
23
|
+
export type DraftingRequestBox = 'received' | 'taken' | 'sent';
|
|
24
|
+
|
|
25
|
+
export interface DraftingRequestCreatePayload {
|
|
26
|
+
subject: string;
|
|
27
|
+
details: string;
|
|
28
|
+
documentTypeId?: string | null;
|
|
29
|
+
dueAt?: string | null;
|
|
30
|
+
attachments?: { fileId: string; name: string }[];
|
|
31
|
+
/** Dirección a la que se pide, con el nombre que le pone el gateway. */
|
|
32
|
+
targetDirectorateCode: number;
|
|
33
|
+
targetDirectorateName: string;
|
|
34
|
+
/** Quienes la integran hoy, resueltos por el gateway (sin quien la pide). */
|
|
35
|
+
recipientEmployeeIds: string[];
|
|
36
|
+
requesterAreaName?: string | null;
|
|
37
|
+
actor: DraftingRequestActor;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/** Lo que se hace con una solicitud, un paso a la vez. */
|
|
41
|
+
export type DraftingRequestAction =
|
|
42
|
+
| { type: 'take' }
|
|
43
|
+
| { type: 'release'; note?: string | null }
|
|
44
|
+
| { type: 'decline'; note: string }
|
|
45
|
+
| { type: 'cancel'; note?: string | null };
|
|
46
|
+
|
|
47
|
+
export interface DraftingRequestContract {
|
|
48
|
+
[DraftingRequestPatterns.getAll]: {
|
|
49
|
+
payload: {
|
|
50
|
+
box: DraftingRequestBox;
|
|
51
|
+
state?: 'open' | 'closed' | 'all';
|
|
52
|
+
search?: string;
|
|
53
|
+
page?: number;
|
|
54
|
+
limit?: number;
|
|
55
|
+
actor: Pick<DraftingRequestActor, 'employeeId'>;
|
|
56
|
+
};
|
|
57
|
+
response: RpcPage<DraftingRequestListItemEntity[]>;
|
|
58
|
+
};
|
|
59
|
+
[DraftingRequestPatterns.getById]: {
|
|
60
|
+
payload: { id: string; actor: Pick<DraftingRequestActor, 'employeeId'> };
|
|
61
|
+
response: DraftingRequestDetailEntity;
|
|
62
|
+
};
|
|
63
|
+
[DraftingRequestPatterns.create]: { payload: DraftingRequestCreatePayload; response: DraftingRequestDetailEntity };
|
|
64
|
+
[DraftingRequestPatterns.act]: {
|
|
65
|
+
payload: { id: string; action: DraftingRequestAction; actor: DraftingRequestActor };
|
|
66
|
+
response: DraftingRequestDetailEntity;
|
|
67
|
+
};
|
|
68
|
+
/** Archivo adjunto, con las mismas reglas de acceso del detalle. */
|
|
69
|
+
[DraftingRequestPatterns.getAttachmentFile]: {
|
|
70
|
+
payload: { id: string; attachmentId: string; actor: Pick<DraftingRequestActor, 'employeeId'> };
|
|
71
|
+
response: { fileId: string; fileName: string };
|
|
72
|
+
};
|
|
73
|
+
}
|
package/src/contracts/index.ts
CHANGED
|
@@ -23,6 +23,7 @@ import { ProcedurePatterns, type ProcedureContract } from './procedure.contract'
|
|
|
23
23
|
import { RegisterBookPatterns, type RegisterBookContract } from './registerBook.contract';
|
|
24
24
|
import { SignatureBatchPatterns, type SignatureBatchContract } from './signatureBatch.contract';
|
|
25
25
|
import { WorkFolderPatterns, type WorkFolderContract } from './workFolder.contract';
|
|
26
|
+
import { DraftingRequestPatterns, type DraftingRequestContract } from './draftingRequest.contract';
|
|
26
27
|
|
|
27
28
|
export * from './contract';
|
|
28
29
|
export * from './document.contract';
|
|
@@ -50,6 +51,7 @@ export * from './dataProtection.contract';
|
|
|
50
51
|
export * from './desk.contract';
|
|
51
52
|
export * from './mailIntake.contract';
|
|
52
53
|
export * from './push.contract';
|
|
54
|
+
export * from './draftingRequest.contract';
|
|
53
55
|
|
|
54
56
|
/** Patrones NATS de gestor-documental-ms, por recurso: `gestorDocumental.<recurso>.<acción>`. */
|
|
55
57
|
export const GestorDocumentalPatterns = {
|
|
@@ -78,6 +80,7 @@ export const GestorDocumentalPatterns = {
|
|
|
78
80
|
desk: DeskPatterns,
|
|
79
81
|
mailIntake: MailIntakePatterns,
|
|
80
82
|
push: PushPatterns,
|
|
83
|
+
draftingRequest: DraftingRequestPatterns,
|
|
81
84
|
} as const;
|
|
82
85
|
|
|
83
86
|
/** Contrato completo de gestor-documental-ms: la unión de los contratos de sus recursos. */
|
|
@@ -105,4 +108,5 @@ export type GestorDocumentalContract = DocumentTypeContract &
|
|
|
105
108
|
DataProtectionContract &
|
|
106
109
|
DeskContract &
|
|
107
110
|
MailIntakeContract &
|
|
108
|
-
PushContract
|
|
111
|
+
PushContract &
|
|
112
|
+
DraftingRequestContract;
|
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
DocumentTrackingEntity,
|
|
11
11
|
DocumentTypeEntity,
|
|
12
12
|
} from '../../base/entities';
|
|
13
|
+
import { type DocumentDraftingRequestEntity } from '../draftingRequest/draftingRequest.entity';
|
|
13
14
|
|
|
14
15
|
/** Tipo documental de un documento, con lo necesario para citarlo. */
|
|
15
16
|
export interface DocumentTypeSummaryEntity {
|
|
@@ -217,6 +218,8 @@ export interface DocumentGetByIdResponseEntity {
|
|
|
217
218
|
* más reciente primero) y si la versión vigente ya está aprobada. `null` si el tipo no la exige.
|
|
218
219
|
*/
|
|
219
220
|
draftReview: DocumentDraftReviewInfoEntity | null;
|
|
221
|
+
/** Solicitud de redacción que atiende, si se redactó a pedido de otra área. */
|
|
222
|
+
draftingRequest: DocumentDraftingRequestEntity | null;
|
|
220
223
|
replies: DocumentLinkEntity[];
|
|
221
224
|
/** Expedientes en que está incorporado y que quien consulta puede ver. */
|
|
222
225
|
caseFiles: { id: string; code: string; title: string; status: 'Open' | 'Closed' }[];
|
|
@@ -279,6 +282,8 @@ export interface DocumentGetSummaryResponseEntity {
|
|
|
279
282
|
toSign: number;
|
|
280
283
|
/** Borradores que esperan su revisión (como jefatura de la dirección que los revisa). */
|
|
281
284
|
toReview: number;
|
|
285
|
+
/** Solicitudes de redacción: sin tomar dirigidas a su dirección, y tomadas por él aún sin atender. */
|
|
286
|
+
draftingRequests: { pending: number; taken: number };
|
|
282
287
|
/** Lotes de firma con documentos en su turno (los documentos de un lote no se cuentan en `toVisa` ni `toSign`). */
|
|
283
288
|
batches: { toVisa: number; toSign: number };
|
|
284
289
|
created: {
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { type DocumentStatus, type DraftingRequestEventAction, type DraftingRequestStatus } from '../../base/entities';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Cómo va la solicitud, para mostrarla: sin tomar, tomada (aún sin documento), en redacción (con documento en curso),
|
|
5
|
+
* atendida (su documento quedó finalizado), devuelta o retirada.
|
|
6
|
+
*/
|
|
7
|
+
export type DraftingRequestState = 'Pending' | 'Taken' | 'Drafting' | 'Completed' | 'Declined' | 'Cancelled';
|
|
8
|
+
|
|
9
|
+
/** Documento que atiende la solicitud. */
|
|
10
|
+
export interface DraftingRequestDocumentEntity {
|
|
11
|
+
id: string;
|
|
12
|
+
status: DocumentStatus;
|
|
13
|
+
/** «D.E. N° 590/2026», o `null` mientras no tiene número. */
|
|
14
|
+
folio: string | null;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface DraftingRequestListItemEntity {
|
|
18
|
+
id: string;
|
|
19
|
+
/** «N° 3/2026». */
|
|
20
|
+
label: string;
|
|
21
|
+
subject: string;
|
|
22
|
+
status: DraftingRequestStatus;
|
|
23
|
+
state: DraftingRequestState;
|
|
24
|
+
requesterEmployeeId: string;
|
|
25
|
+
requesterFullName: string;
|
|
26
|
+
requesterAreaName: string | null;
|
|
27
|
+
targetDirectorateCode: number;
|
|
28
|
+
targetDirectorateName: string;
|
|
29
|
+
takenByEmployeeId: string | null;
|
|
30
|
+
takenByFullName: string | null;
|
|
31
|
+
documentType: { id: string; name: string } | null;
|
|
32
|
+
dueAt: string | null;
|
|
33
|
+
createdAt: string;
|
|
34
|
+
document: DraftingRequestDocumentEntity | null;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface DraftingRequestAttachmentResponseEntity {
|
|
38
|
+
id: string;
|
|
39
|
+
name: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export interface DraftingRequestEventResponseEntity {
|
|
43
|
+
id: string;
|
|
44
|
+
action: DraftingRequestEventAction;
|
|
45
|
+
note: string | null;
|
|
46
|
+
employeeFullName: string;
|
|
47
|
+
createdAt: string;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export interface DraftingRequestDetailEntity extends DraftingRequestListItemEntity {
|
|
51
|
+
details: string;
|
|
52
|
+
takenAt: string | null;
|
|
53
|
+
closedAt: string | null;
|
|
54
|
+
closingNote: string | null;
|
|
55
|
+
/** Funcionarios de la dirección a los que les llegó. */
|
|
56
|
+
recipientCount: number;
|
|
57
|
+
attachments: DraftingRequestAttachmentResponseEntity[];
|
|
58
|
+
events: DraftingRequestEventResponseEntity[];
|
|
59
|
+
/** Qué puede hacer con ella quien la consulta. */
|
|
60
|
+
capabilities: {
|
|
61
|
+
canTake: boolean;
|
|
62
|
+
canRelease: boolean;
|
|
63
|
+
canDecline: boolean;
|
|
64
|
+
canCancel: boolean;
|
|
65
|
+
/** La tomó y aún no tiene documento (o lo descartó): puede redactarlo. */
|
|
66
|
+
canDraft: boolean;
|
|
67
|
+
};
|
|
68
|
+
/** Funcionarios a los que avisar de la operación que se acaba de hacer (lo usa el gateway). */
|
|
69
|
+
notify?: { employeeIds: string[] };
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/** Solicitud enlazada a un documento, como se muestra en su detalle. */
|
|
73
|
+
export interface DocumentDraftingRequestEntity {
|
|
74
|
+
id: string;
|
|
75
|
+
label: string;
|
|
76
|
+
requesterFullName: string;
|
|
77
|
+
requesterAreaName: string | null;
|
|
78
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './draftingRequest.entity';
|
package/src/entities/index.ts
CHANGED