some changes

This commit is contained in:
Eudes Inácio
2023-01-20 16:06:29 +01:00
26 changed files with 166 additions and 154 deletions
-7
View File
@@ -39,7 +39,6 @@ export class HomePage implements OnInit {
toDayEventStorage = ToDayEventStorage
totalDocumentStore = TotalDocumentStore
expedienteGdStore = ExpedienteGdStore
adding: "intervenient" | "CC" = "intervenient";
mobileComponent = {
showAddNewEvent: false,
@@ -126,12 +125,6 @@ export class HomePage implements OnInit {
}
window.addEventListener('storage', (event) => {
// When local storage changes, dump the list to
// the console.
console.log(event);
});
}
goto(url) {
@@ -98,10 +98,10 @@
<img style="width: 40px;" src="assets/images/logo-removebg-preview.png"/>
</div>
<div class="btn-close d-flex cursor-pointer pr-10" (click)="changeTheme('doneIt')" >
<!-- <div class="btn-close d-flex cursor-pointer pr-10" (click)="changeTheme('doneIt')" >
<img *ngIf="ThemeService.currentTheme == 'gov'" style="width: 40px;" src="assets/images/theme/doneIt/governoangola_A.png"/>
<img *ngIf="ThemeService.currentTheme != 'gov'" style="width: 40px;" src="assets/images/theme/doneIt/governoangola_A1.png"/>
</div>
</div> -->
</div>
</div>
@@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { ModalController, NavParams } from '@ionic/angular';
import { ModalController, NavParams, Platform } from '@ionic/angular';
import { EventAttachment } from 'src/app/models/attachment.model';
import { EventBody } from 'src/app/models/eventbody.model';
import { EventPerson } from 'src/app/models/eventperson.model';
@@ -91,7 +91,8 @@ export class NewEventPage implements OnInit {
public eventService: EventsService,
private attachmentsService: AttachmentsService,
private toastService: ToastService,
public ThemeService: ThemeService
public ThemeService: ThemeService,
private platform: Platform,
) {
this.loggeduser = SessionStore.user;
this.postEvent = new Event();
@@ -106,7 +107,10 @@ export class NewEventPage implements OnInit {
}
ngOnInit() {
this.taskParticipants = [];
if (this.platform.is('desktop')) {
this.taskParticipants = [];
}
this.CalendarName = this.loggeduser.Profile;
this.selectedRecurringType = "-1";
@@ -62,12 +62,12 @@
<ion-label *ngIf="msg.delate == true">{{msg.msg}}</ion-label>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
{{last ? scrollToBottom() : ''}}
@@ -103,12 +103,12 @@
<img *ngIf="msg.attachments[0].image_url" src="{{msg.attachments[0].image_url}}" alt="image" >
<ion-icon *ngIf="msg.attachments[0].image_url == null" name="download-outline"></ion-icon>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
</div>
@@ -159,13 +159,13 @@
</ion-label>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()"> Tentar</div>
</ion-label>
</div>
</div>
@@ -60,12 +60,12 @@
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
</div>
@@ -99,12 +99,12 @@
<img *ngIf="msg.attachments[0].image_url" src="{{msg.attachments[0].image_url}}" alt="image">
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
@@ -165,12 +165,12 @@
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
@@ -81,9 +81,9 @@ export class AttendeesPageModal implements OnInit {
}
remove(itm: EventPerson){
remove(itm: EventPerson) {
if(this.adding == "intervenient"){
if(this.adding == "intervenient") {
this.taskParticipants = this.taskParticipants.filter((contact, index) =>{
@@ -135,10 +135,23 @@ export class AttendeesPageModal implements OnInit {
});
}
this.contacts = result;
this.contacts = this.sort(result as any);
this.showLoader = false;
}
);
}
sort(data: []) {
return data.sort(function (a: any, b: any) {
if (a.Name > b.Name) {
return -1;
}
if (b.Name > a.Name) {
return 1;
}
return 0;
}).reverse()
}
}
@@ -98,9 +98,9 @@ export class NewActionPage implements OnInit {
var validado: boolean;
if (window.innerWidth <= 800) {
if ((this.folder.DateBegin < this.folder.DateEnd) && (new Date(this.folder.DateBegin).getTime() > this.currentDate.getTime())) {
if ((this.folder.DateBegin < this.folder.DateEnd)) {
validado = true;
}else{
} else {
validado = false;
}
return validado == true ? ['ok']: [];
@@ -111,7 +111,7 @@ export class NewActionPage implements OnInit {
runValidation() {
this.validateFrom = true;
if(new Date(this.folder.DateBegin).toISOString() > new Date(this.folder.DateEnd).toISOString()){
if(new Date(this.folder.DateBegin).getTime() > new Date(this.folder.DateEnd).getTime()){
this.toastService._badRequest("A data de início não pode ser superior a data de fim");
}
}
@@ -15,7 +15,7 @@
<!-- Left -->
<div class="aside-left app-default-padding d-flex flex-grow-1 flex-column width-30 ">
<!-- Header -->
<ion-progress-bar type="indeterminate" *ngIf="showLoader || skeletonLoader"></ion-progress-bar>
<ion-progress-bar type="indeterminate" *ngIf="showLoader"></ion-progress-bar>
<ion-toolbar >
<div class="main-header">
@@ -24,7 +24,7 @@ import { PermissionService } from 'src/app/services/permission.service';
styleUrls: ['./publications.page.scss'],
})
export class PublicationsPage implements OnInit {
showLoader: boolean;
showLoader: boolean = false
publicationFolder: PublicationFolder;
publication: Publication;
@@ -57,7 +57,6 @@ export class PublicationsPage implements OnInit {
hideRefreshBtn = true;
showSlidingOptions = true;
idSelected: string;
skeletonLoader: boolean;
constructor(
private router: Router,
@@ -138,13 +137,10 @@ export class PublicationsPage implements OnInit {
return this.theDate.getDate() + " de " + (this.months[this.theDate.getMonth()]) + " de " + this.theDate.getFullYear()
}
loadList = false
getActions() {
if(this.loadList == false) {
this.loadList = true
if(this.showLoader == false) {
this.showLoader = true;
this.skeletonLoader = true;
this.publications.GetPublicationFolderList().subscribe(async res => {
const folders: PublicationFolder[] = this.getPublicationFolderMap(res)
@@ -162,13 +158,9 @@ export class PublicationsPage implements OnInit {
}
this.showLoader = false;
this.skeletonLoader = false;
this.loadList = false
}, (error) => {
this.showLoader = false;
this.skeletonLoader = false;
this.loadList = false
});
}
+2
View File
@@ -80,6 +80,8 @@ export class AuthService {
}
// async UpdateLogin() {}
SetSession(response: LoginUserRespose, user:UserForm) {
const session: UserSession = Object.assign(SessionStore.user, response)
+12 -8
View File
@@ -96,7 +96,7 @@ export class ChatSystemService {
}
loadChat() {
if(SessionStore.user.ChatData) {
if(SessionStore.user?.ChatData?.data) {
this.ReLoadChat()
}
}
@@ -184,14 +184,18 @@ export class ChatSystemService {
async getAllRooms () {
this.loadingWholeList = true
var rooms;
try {
rooms = await this.RochetChatConnectorService.getRooms();
} catch (error) {
console.error('chatgetrooms',error)
}
if(this.RochetChatConnectorService.isLogin) {
try {
await this.storage.remove('Rooms');
} catch(e) {}
rooms = await this.RochetChatConnectorService.getRooms();
} catch (error) {
this.loadingWholeList = false
console.error('chatgetrooms',error)
}
try {
await this.storage.remove('Rooms');
} catch(e) {}
}
let index = 0
-1
View File
@@ -11,7 +11,6 @@ import { SessionStore } from '../store/session.service';
export class FirstEnterService {
constructor(private router:Router,
private platform: Platform,
public p: PermissionService,
private alertController: AlertController) { }
+2 -7
View File
@@ -1,22 +1,17 @@
/* eslint-disable */
/* tslint:disable */
import { Injectable, NgZone } from '@angular/core';
import { ActivatedRoute } from '@angular/router'
import { HttpClient } from '@angular/common/http';
import { environment } from 'src/environments/environment';
import { StorageService } from 'src/app/services/storage.service';
import { AuthConnstants } from 'src/app/config/auth-constants';
import { Tokenn } from '../models/token.model';
import { ModalController, AlertController, AnimationController, Platform } from '@ionic/angular';
import { NavigationExtras, Router } from '@angular/router';
import { ToastService } from '../services/toast.service';
import { BackgroundService } from './background.service';
import { v4 as uuidv4 } from 'uuid';
import { AlertController, Platform } from '@ionic/angular';
import { Router } from '@angular/router';
import { EventTrigger } from '../services/eventTrigger.service';
import { SessionStore } from '../store/session.service';
import { ActionPerformed, PushNotificationSchema, PushNotifications, Token, } from '@capacitor/push-notifications';
import { notificationObject } from '../models/notifications';
/* import { Events } from 'ionic-angular' */
@Injectable({
providedIn: 'root'
@@ -59,12 +59,12 @@
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
{{last ? scrollToBottom() : ''}}
@@ -108,13 +108,13 @@
<ion-icon *ngIf="msg.attachments[0].image_url == null" name="download-outline"></ion-icon>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()"> Tentar</div>
</ion-label>
</div>
@@ -165,12 +165,12 @@
</ion-label>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
</div>
@@ -272,7 +272,7 @@
<ion-icon name="add"></ion-icon>
</ion-fab-button>
<ion-fab-list side="top">
<ion-fab-button title="Nova Reunião" (click)="bookMeeting()" color="light">
<ion-fab-button *ngIf="p.userPermission([p.permissionList.Agenda.access])" title="Nova Reunião" (click)="bookMeeting()" color="light">
<ion-icon name="calendar"></ion-icon>
</ion-fab-button>
<ion-fab-button title="Adicionar Documento" (click)="addFile()" color="light">
@@ -28,6 +28,7 @@ import { File } from '@awesome-cordova-plugins/file/ngx';
import { FileOpener } from '@awesome-cordova-plugins/file-opener/ngx';
import { SessionStore } from 'src/app/store/session.service';
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
import { PermissionService } from 'src/app/services/permission.service';
@Component({
selector: 'app-group-messages',
@@ -103,6 +104,7 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
private file: File,
private platform: Platform,
private fileOpener: FileOpener,
public p: PermissionService,
) {
this.loggedUserChat = SessionStore.user.ChatData['data'];
@@ -60,12 +60,12 @@
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
{{last ? scrollToBottom() : ''}}
@@ -106,12 +106,12 @@
<img *ngIf="msg.attachments[0].image_url" src={{msg.attachments[0].image_url}} alt="image">
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
</div>
@@ -174,13 +174,12 @@
</ion-label>
<ion-label class="float-status-all float-status" *ngIf="msg.u.username==sessionStore.user.UserName">
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado">Enviado</span>
<span *ngIf="msg.online == true && !msg.manualRetry && msg.viewed == 0" class="enviado"> Enviado</span>
<!-- <ion-icon *ngIf="msg.messageSend == false && !msg.manualRetry" src="assets/images/clock-regular.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend == true && msg.received.length == 0 && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.messageSend && msg.received.length >= 1 && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon> -->
<!-- <ion-icon *ngIf="msg.viewed.length >= 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon> -->
<span class="lido" *ngIf="msg.viewed.length >= 1" >Lido</span>
<span *ngIf="msg.viewed.length >= 1" >Lida</span>
<span class="lido" *ngIf="msg.viewed.length >= 1" > Lido</span>
<div *ngIf="msg.manualRetry" class="try" (click)="msg.send()">Tentar</div>
</ion-label>
</div>
@@ -254,7 +253,7 @@
<ion-icon name="add"></ion-icon>
</ion-fab-button>
<ion-fab-list side="top">
<ion-fab-button title="Nova Reunião" (click)="bookMeeting()" color="light">
<ion-fab-button *ngIf="p.userPermission([p.permissionList.Agenda.access])" title="Nova Reunião" (click)="bookMeeting()" color="light">
<ion-icon name="calendar"></ion-icon>
</ion-fab-button>
<ion-fab-button title="Adicionar Documento" (click)="addFile()" color="light">
@@ -34,6 +34,7 @@ import { SessionStore } from 'src/app/store/session.service';
import { Howl } from 'howler';
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
import { ChatMessageDebuggingPage } from 'src/app/shared/popover/chat-message-debugging/chat-message-debugging.page';
import { PermissionService } from 'src/app/services/permission.service';
const IMAGE_DIR = 'stored-images';
@@ -121,6 +122,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
private file: File,
private platform: Platform,
private fileOpener: FileOpener,
public p: PermissionService,
) {
// update
this.checkAudioPermission()
@@ -92,7 +92,7 @@ export class AttendeePage implements OnInit {
}
async selectContact(itm: EventPerson){
async selectContact(itm: EventPerson) {
if(this.adding == "intervenient") {
@@ -11,7 +11,7 @@
<button (click)="anexarFoto()" full class="btn-ok" shape="round" >Anexar Fotografia</button>
<button (click)="addDocGestaoDocumental()" class="btn-ok" shape="round" >Gestão Documental</button>
<div class="solid"></div>
<button (click)="bookMeeting()" class="btn-ok" shape="round" >Novo Evento</button>
<button *ngIf="p.userPermission([p.permissionList.Agenda.access])" (click)="bookMeeting()" class="btn-ok" shape="round" >Novo Evento</button>
<button (click)="close()" full class="btn-cancel" shape="round" >Cancelar</button>
</div>
@@ -6,6 +6,7 @@ import { NewEventPage } from 'src/app/pages/agenda/new-event/new-event.page';
import { SearchPage } from 'src/app/pages/search/search.page';
import { environment } from 'src/environments/environment';
import { ThemeService } from 'src/app/services/theme.service'
import { PermissionService } from 'src/app/services/permission.service';
@Component({
selector: 'app-chat-options-popover',
@@ -22,7 +23,8 @@ export class ChatOptionsPopoverPage implements OnInit {
private popoverController: PopoverController,
private modalController: ModalController,
private navParams: NavParams,
public ThemeService: ThemeService
public ThemeService: ThemeService,
public p: PermissionService,
) {
this.members = this.navParams.get('members');
@@ -3,7 +3,7 @@
<button *ngIf="p.userRole(['PR'])" (click)="openExpedientActionsModal('0')" class="btn-cancel" shape="round" >Efetuar Despacho</button>
<button *ngIf="!p.userRole(['PR'])" (click)="openExpedientActionsModal('0')" class="btn-cancel" shape="round" >Efetuar Despacho</button>
<div class="solid"></div>
<button (click)="openExpedientActionsModal('0')" class="btn-cancel" shape="round" >Solicitar Parecer</button>
<button (click)="openExpedientActionsModal('1')" class="btn-cancel" shape="round" >Solicitar Parecer</button>
<button *ngIf="!p.userRole(['PR'])" (click)="openExpedientActionsModal('2')" class="btn-cancel" shape="round" >Pedido de Deferimento</button>
<button (click)="openBookMeetingModal()" class="btn-cancel" shape="round" >Marcar Reunião</button>
<button class="btn-cancel" shape="round" (click)="close()">Cancelar</button>
+22
View File
@@ -10,6 +10,12 @@ export class LocalstoreService {
private prefix = environment.version.lastCommitNumber+"-";
private previewPrefix = 'v17-';
callbacks: {[key: string]: {
path: string,
funx: Function,
id: string
}} = {}
constructor() {
const key = SHA1('version').toString()
@@ -68,6 +74,22 @@ export class LocalstoreService {
localStorage.removeItem(keyName)
}
private async change(changeType: 'set' | 'delete') {
const currentPath = window.location.pathname
for (const [key, value] of Object.entries(this.callbacks)) {
if(currentPath.startsWith(value.path)) {}
const dontRepeat = await value.funx({event:{type: changeType}})
if(dontRepeat) {
delete this.callbacks[key]
}
}
}
listener() {}
}
export const localstoreService = new LocalstoreService()