mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
teste mobile done!
This commit is contained in:
@@ -129,9 +129,14 @@ export class ApproveEventPage implements OnInit {
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise()
|
||||
/* await this.processes.PostTaskAction(body).toPromise() */
|
||||
this.agendaDataRepository.eventToaprovalStatus(serialNumber, 'Declined').subscribe((value) => {
|
||||
this.httpErroHandle.httpsSucessMessagge('Rejeitar');
|
||||
this.TaskService.loadEventosParaAprovacao();
|
||||
}, ((error) => {
|
||||
console.log('reject event error: ', error)
|
||||
this.httpErroHandle.httpStatusHandle(error)
|
||||
}))
|
||||
} catch (error) {
|
||||
this.httpErroHandle.httpStatusHandle(error)
|
||||
|
||||
|
||||
@@ -143,7 +143,7 @@ export class EditEventToApprovePage implements OnInit {
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
console.log('here!!!')
|
||||
if (this.restoreTemporaryData()) {
|
||||
this.setOtherData()
|
||||
} else {
|
||||
@@ -384,7 +384,7 @@ export class EditEventToApprovePage implements OnInit {
|
||||
}));
|
||||
|
||||
if (this.addedAttachmentsList.length > 0) {
|
||||
this.agendaDataRepository.addEventAttachment(this.eventProcess.serialNumber, { attachments: this.loadedAttachments }).subscribe((value) => {
|
||||
this.agendaDataRepository.addEventAttachment(this.eventProcess.serialNumber, this.loadedAttachments).subscribe((value) => {
|
||||
console.log(value)
|
||||
}, ((error) => {
|
||||
this.showLoader = false
|
||||
@@ -393,13 +393,13 @@ export class EditEventToApprovePage implements OnInit {
|
||||
}
|
||||
|
||||
if (this.deletedAttachmentsList.length > 0) {
|
||||
this.agendaDataRepository.removeEventAttachment(this.eventProcess.serialNumber, { attachments: [] }).subscribe((value) => {
|
||||
console.log(value)
|
||||
}, ((error) => {
|
||||
this.showLoader = false
|
||||
console.log('remove attachment error: ', error)
|
||||
}));
|
||||
}
|
||||
this.agendaDataRepository.removeEventAttachment(this.eventProcess.serialNumber, { attachments: this.deletedAttachmentsList }).subscribe((value) => {
|
||||
console.log(value)
|
||||
}, ((error) => {
|
||||
this.showLoader = false
|
||||
console.log('remove attachment error: ', error)
|
||||
}));
|
||||
}
|
||||
|
||||
this.close()
|
||||
|
||||
@@ -578,10 +578,12 @@ export class EditEventToApprovePage implements OnInit {
|
||||
}
|
||||
|
||||
deleteAttachment(attachment: Attachment, index) {
|
||||
const id: any = this.loadedEventAttachments[index].Id
|
||||
console.log(attachment)
|
||||
this.loadedAttachments[index]['action'] = 'delete'
|
||||
this.deletedAttachmentsList.push(id)
|
||||
if (this.loadedEventAttachments[index].Id) {
|
||||
const id: any = this.loadedEventAttachments[index].Id
|
||||
console.log(attachment)
|
||||
this.loadedAttachments[index]['action'] = 'delete'
|
||||
this.deletedAttachmentsList.push(id)
|
||||
}
|
||||
}
|
||||
|
||||
async getDoc() {
|
||||
|
||||
@@ -374,7 +374,7 @@ export class EditEventPage implements OnInit {
|
||||
await this.saveDocument()
|
||||
|
||||
if (this.addedAttachmentsList.length > 0) {
|
||||
this.agendaDataRepository.addEventAttachment(this._postEvent.EventId, { "attachments": this._postEvent.Attachments }).subscribe((value) => {
|
||||
this.agendaDataRepository.addEventAttachment(this._postEvent.EventId, this._postEvent.Attachments).subscribe((value) => {
|
||||
console.log(value)
|
||||
}, ((error) => {
|
||||
this.showLoader = false
|
||||
|
||||
Reference in New Issue
Block a user