This commit is contained in:
tiago.kayaya
2021-06-14 14:04:00 +01:00
parent 035af8f533
commit f901627147
3 changed files with 34 additions and 25 deletions
@@ -85,6 +85,9 @@ export class CreateProcessPage implements OnInit {
this.postData = new Despacho();
this.participants = this.participants = new Array();
//Initialize SubjectTypes Array with the value "Indefinido"
this.selectedTypes = ['99999850'];
this.dispatchFolder = {
Nad: 30,
Subject: '',
@@ -93,12 +96,11 @@ export class CreateProcessPage implements OnInit {
SourceType: 'DOC', //FOLDER
SourceId: this.task.workflowInstanceDataFields.SourceID, //FolderId
DeadlineType: '',
SubjectTypes: ['99999850'],
SubjectTypes: this.selectedTypes,
NumberPDPP: this.task.workflowInstanceDataFields.DispatchNumber,
};
//Initialize SubjectTypes Array with the value "Indefinido"
this.selectedTypes = ['99999850'];
this.postData.DispatchFolder = this.dispatchFolder;
this.postData.UsersSelected = this.participants;
/* By Default TypeDeadline should be 'Normal' */
@@ -198,7 +200,7 @@ export class CreateProcessPage implements OnInit {
try {
await this.processes.postDespatcho(this.postData).toPromise();
this.executado();
this.toastService.successMessage('Despacho criado');
this.toastService.badRequest('Despacho criado');
} catch (error) {
this.toastService.badRequest('Processo não efectuado');
}