mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
fix
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { DomSanitizer } from '@angular/platform-browser';
|
||||
import { ModalController, NavParams } from '@ionic/angular';
|
||||
import { NavParams } from '@ionic/angular';
|
||||
import { ExpedientTaskModalPageNavParamsTask } from 'src/app/models/ExpedientTaskModalPage';
|
||||
import { ExpedientTaskModalPage } from 'src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page';
|
||||
import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { EventDetailsDocumentsOptionsPage } from 'src/app/shared/popover/event-details-documents-options/event-details-documents-options.page';
|
||||
import { DocumentSetUpMeetingPage } from '../document-set-up-meeting/document-set-up-meeting.page';
|
||||
|
||||
|
||||
import { AlertService } from 'src/app/services/alert.service';
|
||||
import { AlertController, ModalController } from '@ionic/angular';
|
||||
@Component({
|
||||
selector: 'app-view-document',
|
||||
templateUrl: './view-document.page.html',
|
||||
@@ -27,6 +27,7 @@ export class ViewDocumentPage implements OnInit {
|
||||
private navParams: NavParams,
|
||||
private sanitazer: DomSanitizer,
|
||||
private processes: ProcessesService,
|
||||
private alertController: AlertController,
|
||||
) {
|
||||
this.file = this.navParams.get('file');
|
||||
this.applicationId = this.navParams.get('applicationId');
|
||||
@@ -44,10 +45,27 @@ export class ViewDocumentPage implements OnInit {
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
this.processes.GetViewer(this.docId, this.applicationId).subscribe(res=> {
|
||||
console.log(res)
|
||||
this.processes.GetViewer(this.docId, this.applicationId).subscribe(async(res)=> {
|
||||
|
||||
const link: string = res.replace('//pdfjs/web/', '/pdfjs/web/')
|
||||
this.trustedUrl = this.sanitazer.bypassSecurityTrustResourceUrl(link);
|
||||
|
||||
if(res == "") {
|
||||
const alert = await this.alertController.create({
|
||||
cssClass: 'my-custom-class',
|
||||
//header: 'Apagar evento!',
|
||||
message: 'Sem imagem',
|
||||
buttons: [
|
||||
{
|
||||
text: 'Sim',
|
||||
handler: () => {
|
||||
this.close();
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
}, ()=>{
|
||||
this.close();
|
||||
});
|
||||
|
||||
@@ -153,8 +153,8 @@ export class ViewEventPage implements OnInit {
|
||||
});
|
||||
} else {
|
||||
|
||||
|
||||
if(this.CalendarId) {
|
||||
console.log('calendar id')
|
||||
this.eventsService.genericGetEvent(this.eventId, this.CalendarId).subscribe(res => {
|
||||
this.loadedEvent = res;
|
||||
this.addEventToDb(res);
|
||||
@@ -172,6 +172,8 @@ export class ViewEventPage implements OnInit {
|
||||
}
|
||||
loader.remove()
|
||||
});
|
||||
} else {
|
||||
console.log('no calendar id')
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -331,6 +331,8 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy {
|
||||
|
||||
async goToEvent(event: any) {
|
||||
|
||||
// console.log(event)
|
||||
|
||||
let classs;
|
||||
if (window.innerWidth < 701) {
|
||||
classs = 'modal modal-desktop'
|
||||
|
||||
@@ -259,7 +259,7 @@
|
||||
|
||||
</div>
|
||||
|
||||
<div (click)="openDiplomasPage('assinados'); selectedElement='DiplomasAssinados'" [class.active]="selectedElement == 'DiplomasAssinados'" class="box-hover exp-card d-flex flex-column justify-center">
|
||||
<div *ngIf="deplomasStore.countDiplomasAssinadoListCount >= 1" (click)="openDiplomasPage('assinados'); selectedElement='DiplomasAssinados'" [class.active]="selectedElement == 'DiplomasAssinados'" class="box-hover exp-card d-flex flex-column justify-center">
|
||||
<div class="d-flex justify-center">
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-diplomas-assinados-presidente.svg"></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' && selectedElement != 'DiplomasAssinados'" src="assets/images/theme/gov/icons-diplomas-assinados-presidente.svg"></ion-icon>
|
||||
@@ -372,7 +372,6 @@
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -106,6 +106,8 @@ export class GabineteDigitalPage implements OnInit {
|
||||
|
||||
AllProcess = []
|
||||
|
||||
workerList : Worker
|
||||
|
||||
@ViewChild(ExpedientsPage) expedientesPage: ExpedientsPage;
|
||||
@ViewChild(PendentesPage) pendentesListPage: PendentesPage;
|
||||
@ViewChild(EventsToApprovePage) eventsToApprove: EventsToApprovePage;
|
||||
@@ -126,6 +128,12 @@ export class GabineteDigitalPage implements OnInit {
|
||||
public NotificationsService: NotificationsService
|
||||
) {
|
||||
|
||||
this.workerList = new Worker(new URL('./list.worker.js', import.meta.url));
|
||||
|
||||
this.workerList.onmessage = (oEvent) => {
|
||||
this.AllProcess = oEvent.data
|
||||
}
|
||||
|
||||
window.onresize = (event) => {
|
||||
// if not mobile remove all component
|
||||
if (window.innerWidth < 701) {
|
||||
@@ -571,6 +579,20 @@ export class GabineteDigitalPage implements OnInit {
|
||||
this.AllProcess = this.expedientegbstore.list.concat(this.pedidosstore.listparecer).concat(this.pedidosstore.listdeferimento)
|
||||
.concat(this.despachoprstore.list).concat(this.eventoaprovacaostore.listmd).concat(this.eventoaprovacaostore.listpr).concat(this.despachoStore.list)
|
||||
.concat(this.deplomasStore.diplomasParaAssinarList).concat(this.deplomasStore.diplomasAssinadoList).concat(this.deplomasStore.DiplomaGerarList)
|
||||
|
||||
// try{
|
||||
// this.workerList.postMessage([
|
||||
// this.expedientegbstore.list,this.pedidosstore.listparecer,this.pedidosstore.listdeferimento,
|
||||
// this.despachoprstore.list, this.eventoaprovacaostore.listmd, this.eventoaprovacaostore.listpr, this.despachoStore.list,
|
||||
// this.deplomasStore.diplomasParaAssinarList, this.deplomasStore.diplomasAssinadoList, this.deplomasStore.DiplomaGerarList
|
||||
// ])
|
||||
// } catch (e) {
|
||||
// this.AllProcess = this.expedientegbstore.list.concat(this.pedidosstore.listparecer).concat(this.pedidosstore.listdeferimento)
|
||||
// .concat(this.despachoprstore.list).concat(this.eventoaprovacaostore.listmd).concat(this.eventoaprovacaostore.listpr).concat(this.despachoStore.list)
|
||||
// .concat(this.deplomasStore.diplomasParaAssinarList).concat(this.deplomasStore.diplomasAssinadoList).concat(this.deplomasStore.DiplomaGerarList)
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
get getAllProcessCount() {
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
onmessage = function(oEvent) {
|
||||
|
||||
|
||||
const list = Event.data
|
||||
var a = []
|
||||
postMessage(
|
||||
a.concat.apply([], [list])
|
||||
);
|
||||
|
||||
};
|
||||
@@ -25,6 +25,7 @@ export class ChatMethodsService {
|
||||
"end_date": data.end,
|
||||
"venue": data.venue,
|
||||
"id": data.id,
|
||||
"calendarId": data.calendarId
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -585,7 +585,6 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
this.postEvent.CalendarName
|
||||
|
||||
|
||||
const CalendarId = this.selectedCalendarId()
|
||||
let loader = this.toastService.loading();
|
||||
|
||||
@@ -643,15 +642,18 @@ export class NewEventPage implements OnInit {
|
||||
}
|
||||
|
||||
selectedCalendarId () {
|
||||
console.log('1:1',this.eventService.calendarNamesType,'2', this.CalendarName)
|
||||
|
||||
if (this.eventService.calendarNamesType[this.CalendarName]?.['Oficial'] && this.postEvent.CalendarName == 'Oficial') {
|
||||
console.log('1')
|
||||
return this.eventService.calendarNamesType[this.CalendarName]['OficialId']
|
||||
|
||||
} else if (this.eventService.calendarNamesType[this.CalendarName]?.['Pessoal'] && this.postEvent.CalendarName == 'Pessoal') {
|
||||
|
||||
console.log('2')
|
||||
return this.eventService.calendarNamesType[this.CalendarName]['PessoalId']
|
||||
|
||||
} else {
|
||||
console.log('1:1',this.eventService.calendarNamesType,'2', this.CalendarName)
|
||||
return '11:11'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<ion-header class="ion-no-border">
|
||||
<ion-progress-bar type="indeterminate" *ngIf="skeletonLoader"></ion-progress-bar>
|
||||
<!-- <ion-progress-bar type="indeterminate" *ngIf="skeletonLoader"></ion-progress-bar> -->
|
||||
<div class="title">
|
||||
<div class="thetitle"><ion-label >Todas as tarefas</ion-label></div>
|
||||
<div class="theicon">
|
||||
@@ -119,6 +119,4 @@
|
||||
</div>
|
||||
|
||||
|
||||
</ion-content>
|
||||
|
||||
|
||||
</ion-content>
|
||||
Reference in New Issue
Block a user