buf displaing the role

This commit is contained in:
Eudes Inácio
2023-02-10 20:16:10 +01:00
50 changed files with 163 additions and 116 deletions
+1 -1
View File
@@ -236,7 +236,7 @@
<mat-option *ngFor="let calendars of eventService.calendarNamesAry" value="{{calendars.Fullname || calendars}}">
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Presidente da República'"> Agenda do PR </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Ministro e Director do Gabinete do PR'"> Agenda do MD </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.FullName}} </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.Fullname}} </div>
</mat-option>
</div>
@@ -38,7 +38,7 @@
<mat-option *ngFor="let calendars of eventService.calendarNamesAry" value="{{calendars.Fullname || calendars}}">
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Presidente da República'"> Agenda do PR </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Ministro e Director do Gabinete do PR'"> Agenda do MD </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.FullName}} </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.Fullname}} </div>
<div *ngIf="calendars == 'Meu calendario'"> Minha agenda </div>
</mat-option>
+3 -1
View File
@@ -410,7 +410,9 @@ export class ChatPage implements OnInit {
doRefresh(event) {
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 1000);
}
@@ -211,9 +211,13 @@ export class EditEventPage implements OnInit {
}
doRefresh(event){
/* this.RefreshEvents(); */
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -209,9 +209,13 @@ export class EventDetailModalPage implements OnInit {
}
doRefresh(event){
/* this.RefreshEvents(); */
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -207,9 +207,13 @@ export class EventDetailPage implements OnInit {
}
doRefresh(event){
/* this.RefreshEvents(); */
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
+3 -1
View File
@@ -129,7 +129,9 @@ export class EventsPage implements OnInit {
doRefresh(event) {
if (event) {
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
this.RefreshEvents();
@@ -227,7 +227,9 @@ export class DespachosPrPage implements OnInit {
doRefresh(event) {
if (event) {
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
setTimeout(() => {
@@ -117,7 +117,9 @@ export class DespachosPage implements OnInit {
this.LoadList();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -22,7 +22,7 @@
<ion-segment-button *ngFor="let calendars of eventService.calendarNamesAry" value="PR">
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Presidente da República'"> Agenda do PR </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Ministro e Director do Gabinete do PR'"> Agenda do MD </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.FullName}} </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.Fullname}} </div>
</ion-segment-button>
</ion-segment>
</ion-toolbar>
@@ -234,7 +234,9 @@ export class EventListPage implements OnInit {
setTimeout(() => {
this.LoadToApproveEvents();
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 1000);
}
@@ -44,7 +44,7 @@
<mat-option *ngFor="let calendars of eventService.calendarNamesAry" value="{{calendars.Fullname || calendars}}">
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Presidente da República'"> Agenda do PR </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role == 'Ministro e Director do Gabinete do PR'"> Agenda do MD </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.FullName}} </div>
<div *ngIf="calendars != 'Meu calendario' && calendars.Role != 'Ministro e Director do Gabinete do PR' && calendars.Role != 'Presidente da República'"> Agenda do {{calendars.Fullname}} </div>
<div *ngIf="calendars == 'Meu calendario'"> Minha agenda </div>
</mat-option>
@@ -153,7 +153,7 @@ export class BookMeetingModalPage implements OnInit {
this.taskParticipants = [{
EmailAddress: SessionStore.user.Email,
IsRequired: true,
Name: SessionStore.user.UserName
Name: SessionStore.user.FullName
}]
}
@@ -103,7 +103,9 @@ export class ExpedientePage implements OnInit {
doRefresh(event) {
this.LoadList();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 1000);
}
@@ -95,7 +95,9 @@ export class ExpedientesPrPage implements OnInit {
doRefresh(event) {
this.LoadList();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -792,7 +792,9 @@ export class GabineteDigitalPage implements OnInit {
if (event) {
setTimeout(() => {
try {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
} catch(error) {}
}, 2000);
@@ -299,7 +299,9 @@ export class PedidosPage implements OnInit {
doRefresh(event) {
this.LoadList();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -170,7 +170,9 @@ export class PendentesPage implements OnInit {
this.LoadList();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -18,8 +18,6 @@ import { Camera, CameraResultType, CameraSource, Photo } from '@capacitor/camera
import { Filesystem, Directory } from '@capacitor/filesystem';
import { NgxImageCompressService } from "ngx-image-compress";
import { readAndCompressImage } from 'browser-image-resizer';
import { environment } from 'src/environments/environment';
const IMAGE_DIR = 'stored-images';
@@ -110,7 +108,7 @@ export class NewPublicationPage implements OnInit {
}
async takePicture() {
alert('take')
const capturedImage = await Camera.getPhoto({
quality: 90,
// allowEditing: true,
@@ -121,30 +119,11 @@ export class NewPublicationPage implements OnInit {
const response = await fetch(capturedImage.webPath!);
const blob = await response.blob();
const config = {
quality: 0.5,
maxWidth: 800,
debug: true
};
var file = new File([blob], "camera.jpg");
// Note: A single file comes from event.target.files on <input>
readAndCompressImage(file, config)
.then(resizedImage => {
console.log('resizedImage', resizedImage);
this.convertBlobToBase64Worker.postMessage(resizedImage);
this.convertBlobToBase64Worker.onmessage = async (oEvent)=> {
this.capturedImage = oEvent.data
}
})
.then(result => {
// TODO: Handle the result
console.log('result', result);
});
this.convertBlobToBase64Worker.postMessage(blob);
this.convertBlobToBase64Worker.onmessage = async (oEvent)=> {
this.capturedImage = oEvent.data
}
}
imageSize(image) {
@@ -200,35 +179,12 @@ export class NewPublicationPage implements OnInit {
const response = await fetch(capturedImage.webPath!);
const blob = await response.blob();
const config = {
quality: 0.9,
maxWidth: 800,
debug: !environment.production
};
var file = new File([blob], "camera.jpg");
// Note: A single file comes from event.target.files on <input>
readAndCompressImage(file, config)
.then(resizedImage => {
console.log('resizedImage', resizedImage);
this.convertBlobToBase64Worker.postMessage(resizedImage);
this.convertBlobToBase64Worker.onmessage = async (oEvent)=> {
this.capturedImage = oEvent.data
}
})
.then(result => {
// TODO: Handle the result
// console.log('result', result);
});
this.convertBlobToBase64Worker.postMessage(blob);
this.convertBlobToBase64Worker.onmessage = async (oEvent)=> {
this.capturedImage = oEvent.data
}
}
@@ -242,7 +198,7 @@ export class NewPublicationPage implements OnInit {
this.Form = new FormGroup({
Subject: new FormControl(this.pub.Title, [
Validators.required,
//Validators.required,
// Validators.minLength(4)
]),
capturedImage: new FormControl(this.capturedImage, [
@@ -285,11 +241,11 @@ export class NewPublicationPage implements OnInit {
try {
await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise()
this.toastService.successMessage("Publicação editada")
this.toastService._successMessage("Publicação editada")
this.close();
} catch (error) {
this.toastService.badRequest("Publicação não editada")
this.toastService._badRequest("Publicação não editada")
} finally {
loader.remove()
}
@@ -54,7 +54,9 @@ export class PublicationDetailPage implements OnInit {
this.getPublicationDetail();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -124,7 +124,9 @@ export class PublicationsPage implements OnInit {
doRefresh(event) {
this.getActions();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 250);
}
@@ -63,7 +63,9 @@ export class PublicationDetailPage implements OnInit {
this.getPublicationDetail();
setTimeout(() => {
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
}, 2000);
}
@@ -98,7 +98,9 @@ export class ViewPublicationsPage implements OnInit {
//this.testForkJoin()
this.getPublicationDetail();
this.getPublicationsIds();
event?.target?.complete();
try {
event?.target?.complete();
} catch(error) {}
//}, 3000);
}