mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 12:37:53 +00:00
Saidas testastas
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="ion-input-class-no-height">
|
||||
<ion-textarea autocomplete="on" autocorrect="on" spellcheck="true" [(ngModel)]="note" placeholder="Comentário*" rows="6" cols="20"></ion-textarea>
|
||||
<ion-textarea autocomplete="on" autocorrect="on" spellcheck="true" [(ngModel)]="note" placeholder="Comentário" rows="6" cols="20"></ion-textarea>
|
||||
</div>
|
||||
|
||||
<div *ngIf="hideThisFeature" class="ion-item-container-no-border">
|
||||
@@ -53,6 +53,7 @@
|
||||
<button *ngIf="actionName == 'Executado'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Executado</button>
|
||||
<button *ngIf="actionName == 'Gerar Diploma'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Gerar</button>
|
||||
<button *ngIf="actionName == 'Arquivar'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Arquivar</button>
|
||||
<button *ngIf="actionName == 'Arquivo'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Arquivar</button>
|
||||
<button *ngIf="actionName == 'Reexecução'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Enviar</button>
|
||||
<button *ngIf="actionName == 'Concluido'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Concluído</button>
|
||||
<button *ngIf="actionName == 'Solicitar assinatura'" class="btn-ok cursor-pointer" shape="round" (click)="save()">Solicitar</button>
|
||||
|
||||
@@ -103,7 +103,8 @@ export class CreateProcessPage implements OnInit {
|
||||
) {
|
||||
this.loggeduser = SessionStore.user;
|
||||
this.task = this.navParams.get('task');
|
||||
|
||||
this.fulltask = this.navParams.get('fulltask');
|
||||
console.log(this.task)
|
||||
if (this.task.SerialNumber) {
|
||||
this.task.serialNumber = this.task.SerialNumber
|
||||
}
|
||||
@@ -127,9 +128,10 @@ export class CreateProcessPage implements OnInit {
|
||||
let SourceId;
|
||||
let SourceType;
|
||||
let SourceSecFsId;
|
||||
const taskId = this.task.workflowInstanceDataFields?.FolderID || this.task?.FolderId || this.task?.FolderID
|
||||
|
||||
if(this.task.workflowInstanceDataFields.FolderID || this.task.FolderId || this.task.FolderID) {
|
||||
SourceId = this.task.workflowInstanceDataFields.FolderID
|
||||
if(taskId) {
|
||||
SourceId = taskId
|
||||
SourceType = 'FOLDER'
|
||||
SourceSecFsId = 361
|
||||
} else {
|
||||
@@ -147,7 +149,7 @@ export class CreateProcessPage implements OnInit {
|
||||
SourceId: SourceId,
|
||||
DeadlineType: '',
|
||||
SubjectTypes: this.selectedTypes,
|
||||
NumberPDPP: this.task.workflowInstanceDataFields.DispatchNumber || NumberPDPP
|
||||
NumberPDPP: this.task?.workflowInstanceDataFields?.DispatchNumber || NumberPDPP || this.fulltask?.workflowInstanceDataFields?.DispatchNumber
|
||||
};
|
||||
|
||||
this.postData.DispatchFolder = this.dispatchFolder;
|
||||
@@ -155,7 +157,8 @@ export class CreateProcessPage implements OnInit {
|
||||
/* By Default TypeDeadline should be 'Normal' */
|
||||
this.postData.Priority = '99999861';
|
||||
/* Initialize 'Subject' with the title of the expedient */
|
||||
this.postData.DispatchFolder.Subject = this.task.workflowInstanceDataFields.Subject;
|
||||
console.log('Subject',this.fulltask)
|
||||
this.postData.DispatchFolder.Subject = this.task?.workflowInstanceDataFields?.Subject || this.fulltask?.workflowInstanceDataFields?.Subject;
|
||||
this.profile = this.navParams.get('profile');
|
||||
}
|
||||
|
||||
|
||||
+4
-1
@@ -73,7 +73,9 @@ export class DiplomaAssinarPage implements OnInit {
|
||||
componentProps: {
|
||||
serialNumber: this.task.SerialNumber,
|
||||
task: this.task,
|
||||
showEnviarPendentes: false
|
||||
showEnviarPendentes: false,
|
||||
fulltask: this.fulltask
|
||||
|
||||
},
|
||||
translucent: true
|
||||
});
|
||||
@@ -83,6 +85,7 @@ export class DiplomaAssinarPage implements OnInit {
|
||||
async LoadTaskDetail(serial: string) {
|
||||
|
||||
this.processes.GetTask(serial).subscribe(res => {
|
||||
console.log("res", res)
|
||||
this.task = {
|
||||
"SerialNumber": res.serialNumber,
|
||||
"Folio": res.workflowInstanceDataFields.Subject,
|
||||
|
||||
@@ -13,6 +13,8 @@
|
||||
<button (click)="openAddNoteModal('Solicitar assinatura')" class="btn-cancel" shape="round" >Solicitar assinatura do Presidente</button>
|
||||
<button (click)="openAddNoteModal('Solicitar alteração')" class="btn-cancel" shape="round" >Solicitar alteração</button>
|
||||
<button (click)="openBookMeetingModal(task)" class="btn-cancel" shape="round" >Marcar Reunião</button>
|
||||
<button (click)="openAddNoteModal('Arquivo')" class="btn-cancel" shape="round" >Arquivar</button>
|
||||
<button (click)="openExpedientActionsModal('0',fulltask)" class="btn-cancel" shape="round" >Efetuar despacho</button>
|
||||
<div class="solid"></div>
|
||||
</div>
|
||||
<div class="buttons width-100" *ngIf="task.activityInstanceName == 'Diploma Assinado'">
|
||||
@@ -21,6 +23,12 @@
|
||||
<div class="buttons width-100" *ngIf="task.activityInstanceName == 'Assinar Diploma'">
|
||||
<button (click)="openAddNoteModal('Assinar Diploma')" class="btn-cancel" shape="round" >Assinado</button>
|
||||
</div>
|
||||
<div class="buttons width-100" *ngIf="task.activityInstanceName == 'Assinar Diploma'">
|
||||
<button (click)="openAddNoteModal('Arquivo')" class="btn-cancel" shape="round" >Arquivo</button>
|
||||
</div>
|
||||
<div class="buttons width-100" *ngIf="task.activityInstanceName == 'Assinar Diploma'">
|
||||
<button (click)="openExpedientActionsModal('0',task)" class="btn-cancel" shape="round" >Efetuar despacho</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -6,6 +6,11 @@ import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { RouteService } from 'src/app/services/route.service';
|
||||
import { PermissionService } from 'src/app/services/permission.service';
|
||||
import { DiscartExpedientModalPage } from 'src/app/pages/gabinete-digital/discart-expedient-modal/discart-expedient-modal.page';
|
||||
import { CreateProcessPage } from 'src/app/modals/create-process/create-process.page';
|
||||
import { AttachmentList } from 'src/app/models/Excludetask';
|
||||
import { DespachoService } from 'src/app/Rules/despacho.service';
|
||||
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-deploma-options',
|
||||
@@ -28,14 +33,17 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
private navParams: NavParams,
|
||||
private toastService: ToastService,
|
||||
private RouteService: RouteService,
|
||||
public p: PermissionService,) {
|
||||
public p: PermissionService,
|
||||
private despachoService: DespachoService,
|
||||
private httpErroHandle: HttpErrorHandle) {
|
||||
this.serialNumber = this.navParams.get('serialNumber');
|
||||
this.task = this.navParams.get('task');
|
||||
this.fulltask = this.navParams.get('fulltask');
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
console.log(this.fulltask)
|
||||
console.log(this.task)
|
||||
}
|
||||
|
||||
async openAddNoteModal(actionName:string) {
|
||||
@@ -85,6 +93,9 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
} else if(actionName == 'Concluir diploma'){
|
||||
await this.finish(res.data.note, docs);
|
||||
this.goBack();
|
||||
} else if (actionName == 'Arquivo') {
|
||||
await this.arquivar(res.data.note, docs);
|
||||
this.goBack();
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -233,6 +244,80 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
async arquivar(note: string, documents: AttachmentList) {
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
await this.despachoService.arquivar(note, documents, this.serialNumber).toPromise()
|
||||
this.httpErroHandle.httpsSucessMessagge('Arquivar')
|
||||
this.close();
|
||||
} catch (error) {
|
||||
this.httpErroHandle.httpStatusHandle(error)
|
||||
}
|
||||
finally {
|
||||
loader.remove()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
async openExpedientActionsModal(taskAction: any, task: any) {
|
||||
|
||||
let classs;
|
||||
if (window.innerWidth <= 800) {
|
||||
classs = 'modal modal-desktop'
|
||||
} else {
|
||||
classs = 'modal modal-desktop showAsideOptions'
|
||||
}
|
||||
|
||||
console.log("fulltask options", this.fulltask)
|
||||
const modal = await this.modalController.create({
|
||||
component: CreateProcessPage,
|
||||
componentProps: {
|
||||
taskAction: taskAction,
|
||||
task: task,
|
||||
profile: this.profile,
|
||||
fulltask: this.fulltask
|
||||
},
|
||||
cssClass: classs,
|
||||
});
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then(async (res) => {
|
||||
|
||||
|
||||
if (res['data'] == 'openDiscart') {
|
||||
await this.distartExpedientModal();
|
||||
}
|
||||
|
||||
this.goBack();
|
||||
});
|
||||
}
|
||||
|
||||
async distartExpedientModal() {
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: DiscartExpedientModalPage,
|
||||
componentProps: {
|
||||
serialNumber: this.fulltask.serialNumber,
|
||||
folderId: this.fulltask.workflowInstanceDataFields.FolderID,
|
||||
action: 'complete',
|
||||
},
|
||||
cssClass: 'discart-expedient-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then(res => {
|
||||
if (res['data'] == 'close') {
|
||||
this.close();
|
||||
/*
|
||||
this.close();
|
||||
this.openMenu(); */
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
goBack() {
|
||||
this.RouteService.goBack()
|
||||
}
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
export let versionData = {
|
||||
"shortSHA": "79213a543",
|
||||
"SHA": "79213a543b0b219f83c92199296d94304dde8c74",
|
||||
"shortSHA": "75e6a6269",
|
||||
"SHA": "75e6a62695abe44be50786e4cde227eec3b2a93c",
|
||||
"branch": "no_bug_movemente",
|
||||
"lastCommitAuthor": "'Peter Maquiran'",
|
||||
"lastCommitTime": "'Mon Feb 27 18:34:42 2023 +0100'",
|
||||
"lastCommitMessage": "remove console log",
|
||||
"lastCommitNumber": "4839",
|
||||
"lastCommitTime": "'Mon Feb 27 18:38:55 2023 +0100'",
|
||||
"lastCommitMessage": "remove",
|
||||
"lastCommitNumber": "4840",
|
||||
"change": "",
|
||||
"changeStatus": "On branch no_bug_movemente\nChanges to be committed:\n (use \"git restore --staged <file>...\" to unstage)\n\tmodified: src/app/services/auth.service.ts\n\tmodified: src/app/services/events.service.ts\n\tmodified: src/environments/environment.ts\n\tmodified: version/git-version.ts",
|
||||
"changeAuthor": "peter.maquiran"
|
||||
"changeStatus": "On branch no_bug_movemente\nYour branch is up to date with 'origin/no_bug_movemente'.\n\nChanges to be committed:\n (use \"git restore --staged <file>...\" to unstage)\n\tmodified: src/app/modals/add-note/add-note.page.html\n\tmodified: src/app/modals/create-process/create-process.page.ts\n\tmodified: src/app/pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.page.ts\n\tmodified: src/app/shared/popover/deploma-options/deploma-options.page.html\n\tmodified: src/app/shared/popover/deploma-options/deploma-options.page.ts",
|
||||
"changeAuthor": "eudes.inacio"
|
||||
}
|
||||
Reference in New Issue
Block a user