Merge branch 'developer' of https://bitbucket.org/equilibriumito/gabinete-digital into release/softlaunch

This commit is contained in:
tiago.kayaya
2022-02-25 11:56:07 +01:00
58 changed files with 516 additions and 221 deletions
+9 -4
View File
@@ -16457,11 +16457,11 @@
"integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw="
},
"ng-lazyload-image": {
"version": "9.1.0",
"resolved": "https://registry.npmjs.org/ng-lazyload-image/-/ng-lazyload-image-9.1.0.tgz",
"integrity": "sha512-ZdfCXMTaehfzxcSRRThpz9YZbEA+8LPA086Od6JiylrGj0yNM7Aq830A1x6NE/M8o2VuVq93emH9m8T6SFBHlA==",
"version": "9.1.2",
"resolved": "https://registry.npmjs.org/ng-lazyload-image/-/ng-lazyload-image-9.1.2.tgz",
"integrity": "sha512-E5oz5HdTRtYW/TH+jceT4VMcRXKdX9Ut82eEwt2K0/bFAXKU14HluCFa8cMidPBgSa08Mlf+gmoKCTvAfUPgag==",
"requires": {
"tslib": "^2.0.0"
"tslib": "^2.3.0"
}
},
"ng2-pdf-viewer": {
@@ -16504,6 +16504,11 @@
"tslib": "^2.0.0"
}
},
"ngx-letters-avatar": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/ngx-letters-avatar/-/ngx-letters-avatar-1.0.2.tgz",
"integrity": "sha512-mCQtMCAM+r+emSruczu3EKGzZuGxvHU0TRcx3P9RQ9at/BWd6cTz2bkz3uJm0T5TwaXRNwTe/NNySx+/NqD2Mw=="
},
"ngx-socket-io": {
"version": "3.4.0",
"resolved": "https://registry.npmjs.org/ngx-socket-io/-/ngx-socket-io-3.4.0.tgz",
+2 -1
View File
@@ -132,11 +132,12 @@
"jetifier": "^1.6.8",
"lite-server": "^2.6.1",
"moment": "^2.29.1",
"ng-lazyload-image": "^9.1.0",
"ng-lazyload-image": "^9.1.2",
"ng2-pdf-viewer": "^7.0.1",
"ngx-cookie-service": "^12.0.3",
"ngx-image-compress": "^11.0.3",
"ngx-image-cropper": "^5.0.1",
"ngx-letters-avatar": "^1.0.2",
"ngx-socket-io": "^3.2.0",
"pdfjs": "^2.4.6",
"pdfjs-dist": "^2.9.359",
+1 -1
View File
@@ -29,7 +29,7 @@ export class AuthGuard implements CanActivate {
this.router.navigate(['/']);
return false
} else {
//this.authService.loginChat();
this.authService.loginChat();
return true;
}
}
+2 -1
View File
@@ -5,7 +5,7 @@ import { FormsModule } from '@angular/forms';
import { IonicModule } from '@ionic/angular';
import { HomePageRoutingModule } from './home-routing.module';
import { LazyLoadImageModule } from 'ng-lazyload-image';
import { HomePage } from './home.page';
/* import { IonicSelectableModule } from 'ionic-selectable'; */
@@ -15,6 +15,7 @@ import { HomePage } from './home.page';
FormsModule,
IonicModule,
HomePageRoutingModule,
LazyLoadImageModule
],
declarations: [HomePage],
})
+10 -10
View File
@@ -24,7 +24,7 @@ export class DarParecerPage implements OnInit {
private animationController: AnimationController,
private toastService: ToastService,
public ThemeService: ThemeService
) {
) {
this.serialNumber = this.navParams.get('serialNumber');
this.instanceId = this.navParams.get('ProcessInstanceID');
}
@@ -32,15 +32,15 @@ export class DarParecerPage implements OnInit {
ngOnInit() {
console.log(this.serialNumber
);
}
cancel() {
this.modalController.dismiss();
}
async save() {
const DocumentToSave = this.documents.map((e) => {
return {
ApplicationId: e.ApplicationType,
@@ -53,8 +53,8 @@ export class DarParecerPage implements OnInit {
Attachments: DocumentToSave,
}
let body = {
"serialNumber": this.serialNumber,
let body = {
"serialNumber": this.serialNumber,
"action": "Registar",
"ActionTypeId": 104,
"dataFields": {
@@ -68,7 +68,7 @@ export class DarParecerPage implements OnInit {
try {
await this.processes.CompleteTask(body).toPromise();
this.modalController.dismiss();
this.modalController.dismiss('sucess');
this.toastService._successMessage('Parecer enviado');
} catch (error) {
this.toastService._badRequest("Parecer não solicitado");
@@ -81,7 +81,7 @@ export class DarParecerPage implements OnInit {
removeAttachment(index: number){
this.documents = this.documents.filter( (e, i) => index != i);
}
async getDoc() {
const modal = await this.modalController.create({
component: SearchPage,
@@ -102,5 +102,5 @@ export class DarParecerPage implements OnInit {
}
}
+2 -2
View File
@@ -69,7 +69,7 @@
<div *ngIf="room.lastMessage" class="item-description" [class.item-description-active]="room.id == idSelected">
<ion-label *ngIf="room.lastMessage && room.otherUserType == false">{{room.lastMessage.msg}}</ion-label>
<ion-label *ngIf="room.otherUserType == true">A escrever...</ion-label>
<ion-label *ngIf="room.otherUserType == true">está escrever...</ion-label>
<!-- <ion-label *ngIf="room.lastMessage.file">
<fa-icon *ngIf="room.lastMessage.file.type != 'application/meeting'" icon="file-alt" class="file-icon" [class.set-active-item-font-to-white]="room.id == idSelected"></fa-icon>
</ion-label> -->
@@ -131,7 +131,7 @@
</div>
<div *ngIf="group.lastMessage" class="item-description d-flex align-items-center" [class.item-description-active]="group.id ==idSelected">
<div class="item-message" *ngIf="group.otherUserType == false">{{group.lastMessage.u.name}}: {{group.lastMessage.msg}} </div>
<div *ngIf="group.otherUserType == true">{{group.userThatIsTyping}} A escrever ...</div>
<div *ngIf="group.otherUserType == true">{{group.userThatIsTyping}} está escrever ...</div>
<div class="item-files add-ellipsis" *ngIf="group.file">
<fa-icon *ngIf="group.lastMessage.file.type != 'application/meeting'" icon="file-alt" class="file-icon" [class.set-active-item-font-to-white]="group.id == idSelected"></fa-icon>
@@ -15,6 +15,7 @@ import { BtnModalDismissPageModule } from 'src/app/shared/btn-modal-dismiss/btn-
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
import { ImageCropperModule } from 'ngx-image-cropper';
import { AngularCropperjsModule } from 'angular-cropperjs';
import { LettersAvatarModule } from "ngx-letters-avatar";
@NgModule({
imports: [
@@ -25,6 +26,7 @@ import { AngularCropperjsModule } from 'angular-cropperjs';
GroupMessagesPageRoutingModule,
ChatPopoverPageModule,
BtnModalDismissPageModule,
LettersAvatarModule
/* ImageCropperModule,
AngularCropperjsModule */
@@ -187,6 +187,14 @@
</ion-content>
<ion-footer>
<div class="typing" >
<ngx-letters-avatar
[avatarName]= "wsChatMethodsService.getGroupRoom(roomId).name"
[width]="30"
[circular]="true"
fontFamily="Roboto"></ngx-letters-avatar>
{{ wsChatMethodsService.getGroupRoom(roomId).userThatIsTyping }} está a escrever...
</div>
<div class="container width-100 d-flex">
<div>
<button class="btn-no-color" (click)="openChatOptions()">
@@ -342,3 +342,20 @@
position: absolute;
z-index: 10;
}
.typing {
position: relative;
top: -25px;
height: 0px;
left: 0px;
margin-left: 22px;
display: flex;
font-size: 12px;
align-items: center;
}
.typing ngx-letters-avatar {
padding-right: 5px;
}
@@ -11,7 +11,7 @@ import { SharedModule } from 'src/app/shared/shared.module';
import { BtnModalDismissPage } from 'src/app/shared/btn-modal-dismiss/btn-modal-dismiss.page';
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
import { MatMenuModule } from '@angular/material/menu';
import { LettersAvatarModule } from "ngx-letters-avatar";
@NgModule({
imports: [
@@ -21,6 +21,7 @@ import { MatMenuModule } from '@angular/material/menu';
FontAwesomeModule,
MessagesPageRoutingModule,
MatMenuModule,
LettersAvatarModule
],
declarations: [MessagesPage]
})
@@ -163,6 +163,17 @@
</ion-footer> -->
<ion-footer>
<div class="typing" *ngIf="wsChatMethodsService.getDmRoom(roomId).otherUserType == true">
<ngx-letters-avatar
[avatarName]= "wsChatMethodsService.getGroupRoom(roomId).name"
[width]="30"
[circular]="true"
fontFamily="Roboto"></ngx-letters-avatar>
está a escrever ...
</div>
<ion-list hidden>
<ion-item (click)="playFile(storedFileNames)">
{{storedFileNames}}
@@ -303,3 +303,20 @@ display: block;
float: left;
padding-left: 10px;
}
.typing {
position: relative;
top: -25px;
height: 0px;
left: 0px;
margin-left: 22px;
display: flex;
font-size: 12px;
align-items: center;
}
.typing ngx-letters-avatar {
padding-right: 5px;
}
+2 -2
View File
@@ -32,7 +32,7 @@
<ion-icon class="icon" slot="end" src="assets/images/icons-default-agenda.svg" ></ion-icon>
<div class="text">A sua Agenda</div>
</div>
<button class="btn-no-color" [routerLink]="['/home/agenda']">
<button title="Ir para a sua Agenda" class="btn-no-color" [routerLink]="['/home/agenda']">
<ion-icon
*ngIf="ThemeService.currentTheme == 'default' "
class="icon-next"
@@ -100,7 +100,7 @@
<ion-icon class="icon" slot="end" src="assets/images/icons-correspondencias.svg"></ion-icon>
<div class="text">Correspondência por ler</div>
</div>
<button (click)="viewExpedientListPage()" class="btn-no-color cursor-pointer">
<button title="Ir para o Gabinete Digital" (click)="viewExpedientListPage()" class="btn-no-color cursor-pointer">
<ion-icon
*ngIf="ThemeService.currentTheme == 'default' "
class="icon-next"
@@ -1,98 +1,109 @@
<ion-header class="ion-no-border">
<app-header></app-header>
</ion-header>
<ion-content id="main-content" class="container-wrapper">
<div class="main-content d-flex height-100" *ngIf="loadedEvent" >
<div class="content d-flex flex-column width-100" *ngIf="loadedEvent.workflowInstanceDataFields">
<div class="header-content width-100 d-flex justify-space-between">
<div (click)="goBack()" class="header-icon-left cursor-pointer">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-arrow-arrow-left.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " slot="end" src='assets/images/theme/gov/icons-calendar-arrow-left.svg'></ion-icon>
</div>
<div class="header-title flex-grow-1 cursor-pointer" *ngIf="loadedEvent.workflowInstanceDataFields.Subject">
<label>{{loadedEvent.workflowInstanceDataFields.Subject}}</label>
</div>
<div (click)="editar(loadedEvent.serialNumber)" class="header-icon-right display-none-true">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-edit.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="edit" slot="end" src="assets/images/theme/gov/icons-edit.svg" ></ion-icon>
</div>
<div class="menu-ptions">
<button class="btn-no-color" (click)="openOptions(loadedEvent)">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-menu.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " src="assets/images/theme/gov/icons-menu.svg"></ion-icon>
</button>
</div>
</div>
<div class="upper-content d-flex flex-column">
<div class="content-location">
<p>
<span class="location">{{loadedEvent.workflowInstanceDataFields.Location}}</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Oficial MDGPR' " style="background-color: #ffb703;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Pessoal MDGPR' " style="background-color: #f05d5e;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Oficial PR' " style="background-color: #99e47b;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Pessoal PR' " style="background-color: #958bfc;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
</p>
</div>
<div class="content-details">
<ion-label>
<p>{{customDate}}</p>
<p *ngIf="toDateString(loadedEvent.workflowInstanceDataFields.StartDate) == toDateString(loadedEvent.workflowInstanceDataFields.EndDate)">das {{loadedEvent.workflowInstanceDataFields.StartDate | date: 'HH:mm'}} às {{loadedEvent.workflowInstanceDataFields.EndDate | date: 'HH:mm'}}</p>
<p *ngIf="toDateString(loadedEvent.workflowInstanceDataFields.StartDate) != toDateString(loadedEvent.workflowInstanceDataFields.EndDate)">{{loadedEvent.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} - {{ loadedEvent.workflowInstanceDataFields.StartDate | date: 'dd/M/yy'}} </p>
<p *ngIf="loadedEvent.workflowInstanceDataFields.OccurrenceType == '-1'">(Não se repete)</p>
<p *ngIf="loadedEvent.workflowInstanceDataFields.OccurrenceType != '-1'">Repete</p>
</ion-label>
</div>
</div>
<div class="line"></div>
<div class="overflow-y-auto">
<div class="middle-content">
<div *ngIf="loadedEvent.workflowInstanceDataFields.ParticipantsList">
<h5>Intervenientes</h5>
<div *ngFor="let att of loadedEvent.workflowInstanceDataFields.ParticipantsList">
<ion-label>{{att.Name}}</ion-label>
</div>
<div class="line"></div>
</div>
<div *ngIf="loadedEvent.workflowInstanceDataFields.Body">
<h5>Detalhes</h5>
<ion-item lines="none" class="ion-no-margin ion-no-padding">
<p [innerHTML]="loadedEvent.workflowInstanceDataFields.Body"></p>
</ion-item>
<div class="line"></div>
</div>
</div>
<div *ngIf="loadedEvent.Documents" class="bottom-content width-100">
<ion-list>
<h5>Documentos Anexados</h5>
<ion-item class="ion-no-margin ion-no-padding cursor-pointer"
*ngFor="let attachment of loadedEvent.Documents"
(click)="viewDocument(attachment.DocId, attachment)">
<ion-label>
<p *ngIf="attachment.Assunto" class="attach-title-item">{{ attachment.Assunto }}<span class="span-right color-red btn-size"><ion-icon hidden name="close"></ion-icon></span></p>
<p *ngIf="!attachment.Assunto" class="attach-title-item">{{ attachment.DocNumber }}<span class="span-right color-red btn-size"><ion-icon hidden name="close"></ion-icon></span></p>
<p><span class="span-left">{{attachment.Sender}}</span><span class="span-right">{{ attachment.DocDate | date: 'dd/MM/yy' }}</span></p>
</ion-label>
</ion-item>
</ion-list>
<div class="main-content height-100" *ngIf="loadedEvent" >
<div class="d-flex width-100">
<div class="pl-20 pr-20 text-center d-flex justify-center align-center" style="width:100%; height: 30px; background-color: var(--Event-approve-header-color); border-top-right-radius: 25px;border-top-left-radius: 25px;">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="right-icons font-28" src="assets/images/icons-received-event.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov'" class="right-icons font-28" src="assets/images/theme/gov/icons-received-event.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " class="right-icons font-28" src="assets/images/theme/tribunal/icons-received-event.svg"></ion-icon>
<div style="color: white;">
Evento Pendente de Aprovação
</div>
</div>
</div>
<div class="d-flex width-100">
<div class="content d-flex flex-column width-100" *ngIf="loadedEvent.workflowInstanceDataFields">
<div class="header-content width-100 d-flex justify-space-between">
<div (click)="goBack()" class="header-icon-left cursor-pointer">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-arrow-arrow-left.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " slot="end" src='assets/images/theme/gov/icons-calendar-arrow-left.svg'></ion-icon>
</div>
<div class="header-title flex-grow-1 cursor-pointer" *ngIf="loadedEvent.workflowInstanceDataFields.Subject">
<label>{{loadedEvent.workflowInstanceDataFields.Subject}}</label>
</div>
<div (click)="editar(loadedEvent.serialNumber)" class="header-icon-right display-none-true">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-edit.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="edit" slot="end" src="assets/images/theme/gov/icons-edit.svg" ></ion-icon>
</div>
<div class="menu-ptions">
<button class="btn-no-color" (click)="openOptions(loadedEvent)">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-menu.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " src="assets/images/theme/gov/icons-menu.svg"></ion-icon>
</button>
</div>
</div>
<div class="upper-content d-flex flex-column">
<div class="content-location">
<p>
<span class="location">{{loadedEvent.workflowInstanceDataFields.Location}}</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Oficial MDGPR' " style="background-color: #ffb703;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Pessoal MDGPR' " style="background-color: #f05d5e;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Oficial PR' " style="background-color: #99e47b;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
<span class="event-type-{{loadedEvent.workflowInstanceDataFields.Agenda}}" *ngIf="loadedEvent.workflowDisplayName == 'Agenda Pessoal PR' " style="background-color: #958bfc;">
{{loadedEvent.workflowInstanceDataFields.Agenda}}
</span>
</p>
</div>
<div class="content-details">
<ion-label>
<p>{{customDate}}</p>
<p *ngIf="toDateString(loadedEvent.workflowInstanceDataFields.StartDate) == toDateString(loadedEvent.workflowInstanceDataFields.EndDate)">das {{loadedEvent.workflowInstanceDataFields.StartDate | date: 'HH:mm'}} às {{loadedEvent.workflowInstanceDataFields.EndDate | date: 'HH:mm'}}</p>
<p *ngIf="toDateString(loadedEvent.workflowInstanceDataFields.StartDate) != toDateString(loadedEvent.workflowInstanceDataFields.EndDate)">{{loadedEvent.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} - {{ loadedEvent.workflowInstanceDataFields.StartDate | date: 'dd/M/yy'}} </p>
<p *ngIf="!loadedEvent.workflowInstanceDataFields.IsRecurring">(Não se repete)</p>
<p *ngIf="loadedEvent.workflowInstanceDataFields.IsRecurring">Repete</p>
</ion-label>
</div>
</div>
<div class="line"></div>
<div class="overflow-y-auto">
<div class="middle-content">
<div *ngIf="loadedEvent.workflowInstanceDataFields.ParticipantsList">
<h5>Intervenientes</h5>
<div *ngFor="let att of loadedEvent.workflowInstanceDataFields.ParticipantsList">
<ion-label>{{att.Name}}</ion-label>
</div>
<div class="line"></div>
</div>
<div *ngIf="loadedEvent.workflowInstanceDataFields.Body">
<h5>Detalhes</h5>
<ion-item lines="none" class="ion-no-margin ion-no-padding">
<p [innerHTML]="loadedEvent.workflowInstanceDataFields.Body"></p>
</ion-item>
<div class="line"></div>
</div>
</div>
<div *ngIf="loadedEvent.Documents" class="bottom-content width-100">
<ion-list>
<h5>Documentos Anexados</h5>
<ion-item class="ion-no-margin ion-no-padding cursor-pointer"
*ngFor="let attachment of loadedEvent.Documents"
(click)="viewDocument(attachment.DocId, attachment)">
<ion-label>
<p *ngIf="attachment.Assunto" class="attach-title-item">{{ attachment.Assunto }}<span class="span-right color-red btn-size"><ion-icon hidden name="close"></ion-icon></span></p>
<p *ngIf="!attachment.Assunto" class="attach-title-item">{{ attachment.DocNumber }}<span class="span-right color-red btn-size"><ion-icon hidden name="close"></ion-icon></span></p>
<p><span class="span-left">{{attachment.Sender}}</span><span class="span-right">{{ attachment.DocDate | date: 'dd/MM/yy' }}</span></p>
</ion-label>
</ion-item>
</ion-list>
</div>
</div>
</div>
<div *ngIf="loadedEvent" class="aside-right flex-column height-100">
<div class="aside-buttons">
<button hidden full class="btn-cancel" shape="round" >Editar evento</button>
@@ -103,6 +114,7 @@
<button (click)="rejeitar(loadedEvent.serialNumber)" full class="btn-delete" shape="round" >Rejeitar</button>
</div>
</div>
</div>
</div>
</ion-content>
@@ -27,8 +27,8 @@ export class EventListPage implements OnInit {
profile: string;
segment: string;
showLoader: boolean;
eventsPRList: any = []
eventsMDGPRList: any = []
eventsPRList: any = [];
eventsMDGPRList: any = [];
eventPerson: EventPerson;
eventBody: EventBody;
categories: string[];
@@ -76,7 +76,7 @@ export class EventListPage implements OnInit {
window.onresize = (event) => {
// if not mobile remove all component
if (window.innerWidth <= 800) {
if (window.innerWidth < 701) {
this.modalController.dismiss();
}
};
@@ -85,13 +85,13 @@ export class EventListPage implements OnInit {
getEventToAproveFromDB() {
if (this.platform.is('desktop') || this.platform.is('mobileweb')) {
this.storage.get('event-to-aproveMD').then((events) => {
this.eventsMDGPRList = events
})
this.storage.get('event-to-aprovePR').then((events) => {
this.eventsPRList = events
})
@@ -99,17 +99,17 @@ export class EventListPage implements OnInit {
this.platform.ready().then(() => {
this.sqliteservice.getListOfEventAprove('Agenda Oficial MDGPR', 'Agenda Pessoal MDGPR').then((event: any[]) => {
this.eventsMDGPRList = this.sortService.sortDate(this.transformaDataDB(event), 'taskStartDate')
//this.eventsMDGPRList = this.eventsMDGPRList.filter(element => element.interveners != null)
console.log('MD event to aprove', this.eventsMDGPRList)
})
this.sqliteservice.getListOfEventAprove('Agenda Oficial PR', 'Agenda Pessoal PR').then((event: any[]) => {
this.eventsPRList = this.sortService.sortDate(this.transformaDataDB(event), 'taskStartDate')
console.log('PR event to aprove', this.eventsPRList)
})
})
@@ -17,7 +17,7 @@
<div class="title">
<ion-label>Gabinete Digital</ion-label>
</div>
<button *ngIf="hideRefreshBtn" class="btn-no-color btn-refresh" (click)="doRefresh($event)">
<button title="Atualizar" *ngIf="hideRefreshBtn" class="btn-no-color btn-refresh" (click)="doRefresh($event)">
<ion-icon class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
<div *ngIf="!hideRefreshBtn" class="title-icons">
@@ -602,7 +602,7 @@ export class PedidoPage implements OnInit {
console.log(task);
let classs;
if (window.innerWidth <= 800) {
if (window.innerWidth < 701) {
classs = 'book-meeting-modal modal modal-desktop'
} else {
classs = 'add-note-modal-no-height showAsideOptions'
@@ -618,7 +618,9 @@ export class PedidoPage implements OnInit {
});
await modal.present();
modal.onDidDismiss().then(res => {
this.goBack();
if(res.data == 'sucess'){
this.goBack();
}
});
}
+4 -4
View File
@@ -102,8 +102,8 @@ export class LoginPage implements OnInit {
if (attempt) {
if (attempt.UserId == SessionStore.user.UserId) {
await this.authService.SetSession(attempt, this.userattempt);
// await this.authService.loginChat();
// await this.authService.loginToChatWs()
await this.authService.loginChat();
await this.authService.loginToChatWs()
this.getToken();
SessionStore.setInativity(true);
@@ -117,8 +117,8 @@ export class LoginPage implements OnInit {
await this.authService.SetSession(attempt, this.userattempt);
this.changeProfileService.run()
// await this.authService.loginChat();
// await this.authService.loginToChatWs()
await this.authService.loginChat();
await this.authService.loginToChatWs()
this.getToken();
this.router.navigateByUrl('/pin', { replaceUrl: true });
}
@@ -25,11 +25,11 @@
<ion-label class="title ">Acções Presidenciais</ion-label>
</div>
<div class="div-icon">
<button class="btn-no-color" (click)="AddPublicationFolder()">
<button title="Adicionar nova ação presidencial" class="btn-no-color" (click)="AddPublicationFolder()">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " slot="icon-only" src='assets/images/icons-add.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " slot="icon-only" src='assets/images/theme/gov/icons-add.svg'></ion-icon>
</button>
<button *ngIf="hideRefreshBtn" class="btn-no-color" (click)="refreshing()">
<button title="Atualizar" *ngIf="hideRefreshBtn" class="btn-no-color" (click)="refreshing()">
<ion-icon slot="icon-only" class="title-icon font-awesome" name="reload-circle" title="Actualizar"></ion-icon>
</button>
</div>
@@ -10,8 +10,16 @@ import { ViewPublicationsPage } from './view-publications.page';
import { HeaderPageModule } from 'src/app/shared/header/header.module';
import { LazyLoadImageModule } from 'ng-lazyload-image'; // <-- import it
import { Attributes, IntersectionObserverHooks, LazyLoadImageModule, LAZYLOAD_IMAGE_HOOKS } from 'ng-lazyload-image'; // <-- import it
export class LazyLoadImageHooks extends IntersectionObserverHooks {
setup(attributes: Attributes) {
attributes.offset = 10;
attributes.defaultImagePath = "/assets/icon/icon-no-image.svg";
attributes.errorImagePath = "/assets/icon/icon-no-image.svg";
return super.setup(attributes);
}
}
@NgModule({
imports: [
@@ -24,6 +32,7 @@ import { LazyLoadImageModule } from 'ng-lazyload-image'; // <-- import it
LazyLoadImageModule
],
exports: [ViewPublicationsPage],
declarations: [ViewPublicationsPage]
declarations: [ViewPublicationsPage],
providers: [{provide: LAZYLOAD_IMAGE_HOOKS, useClass: LazyLoadImageHooks}]
})
export class ViewPublicationsPageModule {}
@@ -26,25 +26,44 @@
</ion-header>
<ion-content class="background-white">
<ion-refresher name="refresher" slot="fixed" (ionRefresh)="doRefresh($event)">
<!-- <ion-refresher name="refresher" slot="fixed" (ionRefresh)="doRefresh($event)">
<ion-progress-bar type="indeterminate" *ngIf="showLoader"></ion-progress-bar>
<ion-refresher-content>
</ion-refresher-content>
</ion-refresher>
<div class="main-container background-white height-100 overflow-y-auto">
<ion-list>
<!-- [routerLink]="['/home/publications/view-publications/publication-detail', publication.publicationId]" -->
</ion-refresher> -->
<div class="main-container background-white height-100 overflow-y-auto">
<ion-content>
<ion-card *ngFor="let publication of getpublication let i = index">
<ion-card-content>
<div class="post-img">
<img [lazyLoad]="publication.FileBase64">
</div>
<div class="post-content px-20">
<div class="post-title-time">
<div class="post-title">
<ion-label>{{publication.Title}}</ion-label>
</div>
<div class="post-data">{{publication.DatePublication | date: 'dd-MM-yy | HH:mm'}}</div>
</div>
<div class="post-description">
<p>{{publication.Message}}</p>
</div>
</div>
</ion-card-content>
</ion-card>
</ion-content>
<!-- <ion-list>
<div class="post-item cursor-pointer"
*ngFor="let publication of getpublication"
(click)="goToPublicationDetail(publication.DocumentId)"
>
<div *ngIf="publication.FileBase64 != null">
<div *ngIf="publication.FileBase64.length < 30; else imageLoaded" class="post-img">
<img src="/assets/icon/icon-no-image.svg">
</div>
<div class="post-img">
<img [defaultImage]=defaultImage [lazyLoad]="publication.FileBase64">
<ng-template #imageLoaded>
<div *ngIf="publication.FileBase64.length > 30" class="post-img">
<img src="{{publication.FileBase64}}" alt="">
<img [defaultImage]=defaultImage [lazyLoad]="publication.FileBase64">
</div>
</ng-template>
</div>
@@ -92,6 +111,6 @@
</div>
</div>
</div>
</ion-list>
</ion-list> -->
</div>
</ion-content>
@@ -11,6 +11,7 @@ import { SqliteService } from 'src/app/services/sqlite.service';
import { BackgroundService } from 'src/app/services/background.service';
import { ThemeService } from 'src/app/services/theme.service'
import { forkJoin } from 'rxjs';
import { ToastService } from 'src/app/services/toast.service';
@Component({
selector: 'app-view-publications',
@@ -23,7 +24,7 @@ export class ViewPublicationsPage implements OnInit {
publicationList: Publication[] = new Array();
item: PublicationFolder;
defaultImage = "https://governo.gov.ao/ao/noticias/presidente-joao-lourenco-ouviu-a-voz-da-igreja/"
defaultImage = "/assets/icon/icon-no-image.svg";
folderId: string;
id: string;
error: any;
@@ -40,7 +41,8 @@ export class ViewPublicationsPage implements OnInit {
private router: Router,
private sqliteservice: SqliteService,
private backgroundservice: BackgroundService,
public ThemeService: ThemeService) {
public ThemeService: ThemeService,
private toastService: ToastService,) {
this.item = new PublicationFolder();
this.activatedRoute.paramMap.subscribe(params => {
@@ -64,7 +66,7 @@ export class ViewPublicationsPage implements OnInit {
this.getPublicationDetail();
this.getPublicationsIds();
/* setTimeout(() => {
this.getPublicationsIds();
this.getPublications();
}, 1000); */
this.backgroundservice.registerBackService('Online', () => {
@@ -86,7 +88,7 @@ export class ViewPublicationsPage implements OnInit {
// }
//this.testForkJoin()
//this.getPublicationDetail();
// this.getPublicationsIds();
// this.getPublications();
}
doRefresh = (event) => {
@@ -258,7 +260,7 @@ export class ViewPublicationsPage implements OnInit {
});
this.getpublication = publicationArray;
this.publicationList = publicationArray;
})
}
+6 -6
View File
@@ -56,9 +56,9 @@ export class AuthService {
}
/* if (localStorage.getItem("userChat") != null) {
if (localStorage.getItem("userChat") != null) {
this.ValidatedUserChat = JSON.parse(localStorage.getItem('userChat'));
} */
}
}
@@ -112,7 +112,7 @@ export class AuthService {
//user: UserForm
async loginChat() {
/* const expirationMinutes = 30;
const expirationMinutes = 30;
let date = new Date().getTime();
let expirationDate = new Date(new Date().getTime() + expirationMinutes*60*1000);
@@ -135,7 +135,7 @@ export class AuthService {
this.presentAlert('Network error');
}
this.autoLoginChat(expirationDate.getTime() - date); */
this.autoLoginChat(expirationDate.getTime() - date);
}
async autoLoginChat(expirationDate:number){
@@ -145,7 +145,7 @@ export class AuthService {
}
loginToChatWs() {
/* setTimeout(()=>{
setTimeout(()=>{
this.WsChatService.connect();
this.WsChatService.login().then((message) => {
@@ -225,7 +225,7 @@ export class AuthService {
return false
}
};
}, 1) */
}, 1)
}
autologout(expirationDate:number) {
+2 -2
View File
@@ -32,13 +32,13 @@ export class ChatService {
private storageService:StorageService,
)
{
/* this.loggedUserChat = authService.ValidatedUserChat;
this.loggedUserChat = authService.ValidatedUserChat;
this.headers = new HttpHeaders();
this.headers = this.headers.set('X-User-Id', this.loggedUserChat['data'].userId);
this.headers = this.headers.set('X-Auth-Token', this.loggedUserChat['data'].authToken);
this.options = {
headers: this.headers,
}; */
};
}
+8 -3
View File
@@ -49,7 +49,7 @@ export class MessageService {
private WsChatService: WsChatService) {
}
setData({customFields, channels, mentions, msg ,rid ,ts, u, t, _id, _updatedAt, file, attachments, temporaryData, localReference}:Message) {
setData({customFields = {}, channels, mentions, msg ,rid ,ts, u, t, _id, _updatedAt, file, attachments, temporaryData, localReference}:Message) {
this.customFields = customFields
this.channels = channels || []
this.mentions = mentions || []
@@ -79,6 +79,10 @@ export class MessageService {
}
}
// if(typeof(this.file?.type)) {
// this.hasFile = true
// }
if(this.hasFile) {
this.getFileFromDb()
if(this.file.type != 'application/webtrix') {
@@ -120,7 +124,7 @@ export class MessageService {
if (environment.chatOffline) {
this.redefinedMessage(ChatMessage)
// this.redefinedMessage(ChatMessage)
this.offline = false
}
@@ -151,7 +155,7 @@ export class MessageService {
let ChatMessage = message.result
if (environment.chatOffline) {
this.redefinedMessage(ChatMessage)
// this.redefinedMessage(ChatMessage)
this.offline = false
}
@@ -178,6 +182,7 @@ export class MessageService {
}
}
}
redefinedMessage(ChatMessage) {
+2 -2
View File
@@ -11,9 +11,9 @@ export class NfService {
downloadFileMsg = async (message: MessageService, room?: RoomService): Promise<boolean> => new Promise ((resolve, reject)=> (resolve(true)));
fix_updatedAt(message) {
if (message.result) {
if (message?.result) {
message.result._updatedAt = message.result._updatedAt['$date']
} else if(message._updatedAt) {
} else if(message?._updatedAt) {
if(message._updatedAt.hasOwnProperty('$date')) {
message._updatedAt = message._updatedAt['$date']
}
+3 -2
View File
@@ -71,7 +71,7 @@ export class RoomService {
this.NativeNotificationService.askForPermission()
}
setData({ customFields, id, name, t, lastMessage = new MessageService(this.storage, this.NfService, this.WsChatService), _updatedAt }) {
setData({ customFields = {}, id, name, t, lastMessage = new MessageService(this.storage, this.NfService, this.WsChatService), _updatedAt }) {
this.customFields = customFields
this.id = id
this.name = name
@@ -184,7 +184,7 @@ export class RoomService {
let index;
const find = messages.find((message, _index)=> {
if(message.localReference) {
if(message.localReference == ChatMessage.localReference) {
if(message?.localReference == ChatMessage?.localReference) {
index = _index
return true
}
@@ -294,6 +294,7 @@ export class RoomService {
this.lastMessage = previousLastMessage;
this.calDateDuration(previousLastMessage._updatedAt)
this.sortRoomList()
}
})
@@ -300,6 +300,7 @@ export class WsChatMethodsService {
}
} else {
console.log('have!!!')
// in this case room is already present, therefor it will only be necessary,
// to redefine
@@ -313,7 +314,7 @@ export class WsChatMethodsService {
}
roomExist(roomId) {
return this.dm[roomId] && this.group[roomId]
return this.dm[roomId]?.id || this.group[roomId]?.id
}
getReceptorName(roomData) {
+5 -3
View File
@@ -39,11 +39,13 @@ export class RouteService {
* @param url [string] incase no history to go back */
goBack(url = null) {
if(this.history.length >= 2) {
console.log(this.history);
this.history.pop();
const url = this.history.pop();
this.goTo(url)
} else if(url) {
this.goTo(url)
}
@@ -70,9 +72,9 @@ export class RouteService {
queryParams(url) {
const urlObject = new URL('http://localhost:8100'+url);
const paramsString = urlObject.search;
let searchParams: any = new URLSearchParams(paramsString);
let params = {}
@@ -14,8 +14,21 @@
<ion-content id="main-content">
<div class="main-content d-flex height-100" *ngIf="loadedEvent">
<div class="main-content d-flex flex-column height-100" *ngIf="loadedEvent">
<div class="pl-20 pr-20 text-center d-flex justify-center align-center" style="width:100%; height: 30px; background-color: var(--Event-approve-header-color); border-top-right-radius: 25px;">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="right-icons font-28" src="assets/images/icons-received-event.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov'" class="right-icons font-28" src="assets/images/theme/gov/icons-received-event.svg"></ion-icon>
<!-- <ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="right-icons" src="assets/images/theme/gov/icons-received-event-selected.svg"></ion-icon> -->
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " class="right-icons font-28" src="assets/images/theme/tribunal/icons-received-event.svg"></ion-icon>
<div style="color: white;">
Evento Pendente de Aprovação
</div>
</div>
<div class="content d-flex flex-column">
<div class="header-content width-100 d-flex justify-space-between">
<div (click)="close()" class="header-icon-left cursor-pointer">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " src="assets/images/icons-arrow-arrow-left.svg"></ion-icon>
@@ -111,7 +124,6 @@
</div>
<div *ngIf="showAside" class="aside-right flex-column height-100 cursor-pointer">
<div class="aside-buttons">
<button hidden full class="btn-ok" shape="round" >Editar evento</button>
@@ -3,7 +3,7 @@
<div class="header-title d-flex align-center justify-between width-100">
<div class="flex-grow-1">Eventos para Aprovação</div>
<div (click)="refreshing()">
<button class="btn-no-color" >
<button title="Atualizar" class="btn-no-color" >
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -70,7 +70,7 @@ export class EventListPage implements OnInit {
async LoadToApproveEvents() {
this.showLoader = true;
console.log(this.segment);
if(this.segment == 'MDGPR'){
if(this.segment == 'MDGPR') {
let mdEventsOficial = await this.processes.GetTasksList('Agenda Oficial MDGPR', false).toPromise();
let mdEventsPessoal = await this.processes.GetTasksList('Agenda Pessoal MDGPR', false).toPromise();
@@ -80,7 +80,7 @@ export class EventListPage implements OnInit {
}
this.showLoader = false;
}
else if(this.segment == 'PR'){
else if(this.segment == 'PR') {
let prEventsOficial = await this.processes.GetTasksList('Agenda Oficial PR', false).toPromise();
let prEventsPessoal = await this.processes.GetTasksList('Agenda Pessoal PR', false).toPromise();
let allEvents = prEventsOficial.concat(prEventsPessoal);
@@ -14,6 +14,7 @@ import { NewEventPageModule } from '../../agenda/new-event/new-event.module';
import { PdfViewerModule } from 'ng2-pdf-viewer';
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
import {MatMenuModule} from '@angular/material/menu';
import { LettersAvatarModule } from "ngx-letters-avatar";
@NgModule({
imports: [
@@ -24,7 +25,8 @@ import {MatMenuModule} from '@angular/material/menu';
PdfViewerModule,
ChatPopoverPageModule,
GroupMessagesPageRoutingModule,
MatMenuModule
MatMenuModule,
LettersAvatarModule
//
],
exports: [GroupMessagesPage],
@@ -203,6 +203,18 @@
</ion-content>
<ion-footer>
<!-- <div class="typing" *ngIf="wsChatMethodsService.getGroupRoom(roomId).otherUserType == true" >A escrever...</div> -->
<div class="typing" *ngIf="wsChatMethodsService.getGroupRoom(roomId).otherUserType == true">
<ngx-letters-avatar *ngIf="showAvatar"
[avatarName]= "wsChatMethodsService.getGroupRoom(roomId).name"
[width]="30"
[circular]="true"
fontFamily="Roboto"></ngx-letters-avatar>
{{ wsChatMethodsService.getGroupRoom(roomId).userThatIsTyping }} está a escrever...
</div>
<div class="container width-100 d-flex">
<div>
<!-- <button class="btn-no-color" (click)="openSendGroupMessageOptions()">
@@ -272,3 +272,20 @@
}
}
.typing {
position: relative;
top: -25px;
height: 0px;
left: 0px;
margin-left: 22px;
display: flex;
font-size: 12px;
align-items: center;
}
.typing ngx-letters-avatar {
padding-right: 5px;
}
@@ -85,6 +85,7 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
pdfurl = "http://www.africau.edu/images/default/sample.pdf";
downloadFile: any;
showAvatar = false
constructor(
public wsChatMethodsService: WsChatMethodsService,
@@ -126,8 +127,11 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
this.wsChatMethodsService.openRoom(this.roomId)
this.wsChatMethodsService.getGroupRoom(this.roomId).scrollDown = this.scrollToBottomClicked
this.showAvatar = false
setTimeout(()=>{
this.scrollToBottomClicked()
this.showAvatar = true
}, 50)
}
@@ -11,6 +11,7 @@ import { SharedModule } from 'src/app/shared/shared.module';
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
import { MatButtonModule } from '@angular/material/button';
import {MatMenuModule} from '@angular/material/menu';
import { LettersAvatarModule } from "ngx-letters-avatar";
@NgModule({
imports: [
@@ -20,7 +21,8 @@ import {MatMenuModule} from '@angular/material/menu';
FontAwesomeModule,
MessagesPageRoutingModule,
MatButtonModule,
MatMenuModule
MatMenuModule,
LettersAvatarModule
],
exports: [MessagesPage],
@@ -52,12 +52,12 @@
<span class="time">{{msg.duration}}</span>
</div>
<div class="d-flex justify-space-between">
<ion-label class="flex-0">{{msg.msg}}</ion-label>
<ion-label class="float-status-all float-status" >
<ion-label class="flex-0">{{msg.msg}}</ion-label>
<!-- <ion-label class="float-status-all float-status" >
<ion-icon *ngIf="!msg.offline && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.offline && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.viewed.length == 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon>
</ion-label>
</ion-label> -->
{{last ? scrollToBottom() : ''}}
</div>
</div>
@@ -80,11 +80,11 @@
<div *ngFor="let file of msg.attachments">
<div *ngIf="msg.file.type == 'application/img'" (click)="openPreview(msg)" dfsdvsvs>
<img src={{msg.attachments[0].image_url}} alt="image">
<ion-label class="float-status-image float-status-all">
<!-- <ion-label class="float-status-image float-status-all">
<ion-icon *ngIf="!msg.offline && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.offline && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.viewed.length == 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon>
</ion-label>
</ion-label> -->
</div>
<div *ngIf="msg.file.type != 'application/img'">
<div class="file">
@@ -109,11 +109,11 @@
<span
*ngIf="msg.file.type != 'application/webtrix'">{{msg.displayType}}</span>
</ion-label>
<ion-label class="float-status-webtrix float-status-all">
<!-- <ion-label class="float-status-webtrix float-status-all">
<ion-icon *ngIf="!msg.offline && msg.viewed.length == 0" src="assets/images/check-double-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.offline && msg.viewed.length == 0" src="assets/images/check-solid.svg"></ion-icon>
<ion-icon *ngIf="msg.viewed.length == 1" src="assets/images/check-double-solid -viewed.svg"></ion-icon>
</ion-label>
</ion-label> -->
</div>
</div>
</div>
@@ -197,6 +197,16 @@
<ion-footer>
<div class="typing" *ngIf="wsChatMethodsService.getDmRoom(roomId).otherUserType == true" >
<ngx-letters-avatar *ngIf="showAvatar"
[avatarName]= "wsChatMethodsService.getDmRoom(roomId).name"
[width]="30"
[circular]="true"
fontFamily="Roboto"></ngx-letters-avatar>
está a escrever...
</div>
<div class="container width-100 d-flex">
<div>
<!-- <button class="btn-no-color" (click)="openSendMessageOptions()">
@@ -231,7 +241,7 @@
<ion-item class="ion-no-padding type-message" lines="none">
<ion-textarea (keyup.enter)="sendMessage()" clearOnEdit="true" placeholder="Escrever uma mensagem"
class="message-input" rows="1" [(ngModel)]="wsChatMethodsService.getDmRoom(roomId).message" (ionChange)="wsChatMethodsService.getDmRoom(roomId).sendTyping()"></ion-textarea>
<button hidden class="btn-no-color" (click)="notImplemented()">
<button hidden class="btn-no-color" >
<ion-icon slot="end" src="assets/icon/icons-chat-mic.svg"></ion-icon>
</button>
</ion-item>
@@ -312,4 +312,20 @@ display: block;
.float-status-all {
font-size: 10pt !important;
}
.typing {
position: relative;
top: -25px;
height: 0px;
left: 0px;
margin-left: 22px;
display: flex;
font-size: 12px;
align-items: center;
}
.typing ngx-letters-avatar {
padding-right: 5px;
}
@@ -78,6 +78,8 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
downloadFile: any;
massages: MessageService[] = []
showAvatar = true
constructor(
public popoverController: PopoverController,
private modalController: ModalController,
@@ -121,8 +123,11 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
let guid: any = await this.AttachmentsService.uploadFile(formData).toPromise()
}
this.showAvatar = false
setTimeout(() => {
this.scrollToBottomClicked()
this.showAvatar = true
}, 150)
}
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Todas as tarefas</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="refreshing()">
<button title="Atualizar" class="btn-no-color" (click)="refreshing()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -6,7 +6,7 @@
<ion-label *ngIf="loggeduser.Profile =='PR'" >Despachos</ion-label>
</div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Despachos</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="refreshing()">
<button title="Atualizar" class="btn-no-color" (click)="refreshing()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Diplomas</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Diplomas</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title width-100">
<div class="title-container d-flex justify-space-between">
<span class="text-center mt-0 aside-title px-20"><label>Eventos para Aprovação</label></span>
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -84,7 +84,7 @@ export class EventsToApprovePage implements OnInit {
let prEventsPessoal = await this.processes.GetTasksList('Agenda Pessoal PR', false).toPromise();
this.eventsPRList = prEventsOficial.concat(prEventsPessoal);
this.eventsPRList = this.sortService.sortArrayByDate(this.eventsPRList)
this.storage.set('event-to-aprovePR',this.eventsPRList).then(() => {
console.log(' EVENTPR TO APROVE SAVED')
})
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Expediente</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="refreshing()">
<button title="Atualizar" class="btn-no-color" (click)="refreshing()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Expediente</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Pedidos</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
@@ -3,7 +3,7 @@
<div class="title">
<div class="thetitle"><ion-label >Pendentes</ion-label></div>
<div class="theicon">
<button class="btn-no-color" (click)="doRefresh()">
<button title="Atualizar" class="btn-no-color" (click)="doRefresh()">
<ion-icon slot="end" class="title-icon font-awesome" name="reload-circle"></ion-icon>
</button>
</div>
+41 -18
View File
@@ -2,20 +2,36 @@
<div class="main-tab pb-10 ion-toolbar header-color">
<div class="mobile d-flex div-top-header justify-space-between">
<div *ngIf="!hideSearchBtn" class="div-search">
<div class="mobile pt-20 d-flex div-top-header justify-space-between">
<div title="Pesquisa" *ngIf="!hideSearchBtn" class="div-search">
<div (click)="openSearch()">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="font-45" src='assets/images/icons-search.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="font-45" src='assets/images/theme/gov/icons-search.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " class="font-45" src='assets/images/theme/tribunal/icons-search.svg'></ion-icon>
</div>
</div>
<div class="div-logo height-fit-content">
<!-- <div class="div-logo align-center justify-center">
<img *ngIf="ThemeService.currentTheme == 'default' " src='assets/images/logo-no-bg.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'gov' " src='assets/images/theme/gov/gabinetedigital_logo.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'tribunal' " src='assets/images/theme/tribunal/tribunal-constitucional.png' alt='logo'>
</div> -->
<div class="div-logo align-center justify-center">
<div class="logo-icon">
<img *ngIf="ThemeService.currentTheme == 'default' " src='assets/images/logo-no-bg.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'gov' " src='assets/images/theme/gov/governoangola_A.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'tribunal' " src='assets/images/theme/tribunal/tribunal-constitucional.png' alt='logo'>
</div>
<div class="logo-description d-flex align-center justify-content-center">
<div class="logo-description-content">
<p class="logo-description-text">Presidente da República</p>
<div class="add-line"></div>
<p class="logo-description-text tp-5">GABINETE DIGITAL</p>
</div>
</div>
</div>
<div class="div-profile cursor-pointer" (click)="openProfile()">
<div title="Perfil" class="div-profile cursor-pointer" (click)="openProfile()">
<div *ngIf="this.notificationLength > 0" class="icon-badge">{{notificationLength}}</div>
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="icon" src='assets/images/icons-profile.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="icon" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
@@ -27,11 +43,18 @@
<div class="desktop mx-20">
<div class="d-flex justify-space-between align-center">
<div tab="events" class="div-logo height-fit-content">
<img *ngIf="ThemeService.currentTheme == 'default' " src='assets/images/logo-no-bg.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'gov' " src='assets/images/theme/gov/gabinetedigital_logo.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'tribunal' " src='assets/images/theme/tribunal/tribunal-constitucional.png' alt='logo'>
<div class="logo-icon">
<img *ngIf="ThemeService.currentTheme == 'default' " src='assets/images/logo-no-bg.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'gov' " src='assets/images/theme/gov/governoangola_A.png' alt='logo'>
<img *ngIf="ThemeService.currentTheme == 'tribunal' " src='assets/images/theme/tribunal/tribunal-constitucional.png' alt='logo'>
</div>
<div class="logo-description d-flex align-center justify-content-center">
<div class="logo-description-content">
<p class="logo-description-text">Presidente da República</p>
<div class="add-line"></div>
<p class="logo-description-text">GABINETE DIGITAL</p>
</div>
</div>
</div>
<div class="d-flex flex-1 pr-20 pl-50">
@@ -83,13 +106,13 @@
</div>
<div class="header-btns d-flex">
<div *ngIf="!hideSearchBtn" class="mr-10 d-flex align-center cursor-pointer">
<div title="Pesquisa" *ngIf="!hideSearchBtn" class="mr-20 d-flex align-center cursor-pointer">
<div style="padding-top: 5px;" (click)="openSearch();showSearch=true" *ngIf="!showSearch">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="font-45" src='assets/images/icons-search.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="font-45" src='assets/images/theme/gov/icons-search.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " class="font-45" src='assets/images/theme/tribunal/icons-search.svg'></ion-icon>
<ion-icon title="Perfil" *ngIf="ThemeService.currentTheme == 'default' " class="font-45" src='assets/images/icons-search.svg'></ion-icon>
<ion-icon title="Perfil" *ngIf="ThemeService.currentTheme == 'gov' " class="font-45" src='assets/images/theme/gov/icons-search.svg'></ion-icon>
<ion-icon title="Perfil" *ngIf="ThemeService.currentTheme == 'tribunal' " class="font-45" src='assets/images/theme/tribunal/icons-search.svg'></ion-icon>
</div>
<button class="btn-no-color" (click)="closeSearch();showSearch=false;searchSubject=''" *ngIf="showSearch">
<button title="Fechar" class="btn-no-color" (click)="closeSearch();showSearch=false;searchSubject=''" *ngIf="showSearch">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="font-40" name="restaurant-outline" src="assets/images/icons-search-close.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="font-40" name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " class="font-40" name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
@@ -105,15 +128,15 @@
class="search-input text-black" type="search" placeholder="Pesquisar"></ion-input>
</div>
<div class="icon" (click)="clearSearchInput()">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' "name="restaurant-outline" src="assets/images/icons-search-close.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'tribunal' " name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
<ion-icon title="Limpar" *ngIf="ThemeService.currentTheme == 'default' "name="restaurant-outline" src="assets/images/icons-search-close.svg"></ion-icon>
<ion-icon title="Limpar" *ngIf="ThemeService.currentTheme == 'gov' " name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
<ion-icon title="Limpar" *ngIf="ThemeService.currentTheme == 'tribunal' " name="restaurant-outline" src="assets/images/theme/gov/icons-search-close.svg"></ion-icon>
</div>
</div>
</div>
</div>
<div class="div-profile d-flex cursor-pointer" (click)="openProfile()">
<div title="Perfil" class="div-profile d-flex cursor-pointer" (click)="openProfile()">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="icon" src='assets/images/icons-profile.svg'></ion-icon>
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="icon" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
+44 -6
View File
@@ -12,10 +12,50 @@
width: em(140px);
justify-content: center;
display: flex;
}
.div-logo img{
width: 100%;
margin: 0px auto;
color: black;
overflow: auto;
.logo-icon{
width: 25.33%;
overflow: auto;
img{
width: 100%;
margin: 0px auto;
}
}
.logo-description{
width: 74.67%;
margin: 0 auto;
overflow: auto;
font-size: 8.5px;
font-family: Bahnschrift;
.logo-description-content{
width: 100%;
.logo-description-text{
font-weight: 700;
text-align: center;
width: 100%;
margin: 0 !important;
padding: 0 !important;
}
.add-line{
width: 100%;
border-bottom: 1px solid #000;
margin-bottom: 2.5px !important;
padding: 0 !important;
}
}
.add-botton-border{
border-bottom: 1px solid #000;
}
}
}
.header-btns{
@@ -24,7 +64,6 @@
}
.div-profile{
width: 90px;
height: fit-content;
font-size: 45px;
justify-content: flex-end;
@@ -64,7 +103,6 @@
//border: 1px solid red;
}
.desktop{
display: none;
}
@@ -6,15 +6,27 @@ import { IonicModule } from '@ionic/angular';
import { ViewPublicationsPageRoutingModule } from './view-publications-routing.module';
import { ViewPublicationsPage } from './view-publications.page';
import { Attributes, IntersectionObserverHooks, LazyLoadImageModule, LAZYLOAD_IMAGE_HOOKS } from 'ng-lazyload-image';
export class LazyLoadImageHooks extends IntersectionObserverHooks {
setup(attributes: Attributes) {
attributes.offset = 10;
attributes.defaultImagePath = "/assets/icon/icon-no-image.svg";
attributes.errorImagePath = "/assets/icon/icon-no-image.svg";
return super.setup(attributes);
}
}
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
ViewPublicationsPageRoutingModule
ViewPublicationsPageRoutingModule,
LazyLoadImageModule
],
exports: [ViewPublicationsPage],
declarations: [ViewPublicationsPage]
declarations: [ViewPublicationsPage],
providers: [{provide: LAZYLOAD_IMAGE_HOOKS, useClass: LazyLoadImageHooks}]
})
export class ViewPublicationsPageModule {}
@@ -39,7 +39,27 @@
</ion-refresher-content>
</ion-refresher>
<div class="main-container px-20">
<ion-list>
<ion-content>
<ion-card *ngFor="let publication of publicationList let i = index">
<ion-card-content>
<div class="post-img">
<img [lazyLoad]="publication.FileBase64">
</div>
<div class="post-content px-20">
<div class="post-title-time">
<div class="post-title">
<ion-label>{{publication.Title}}</ion-label>
</div>
<div class="post-data">{{publication.DatePublication | date: 'dd-MM-yy | HH:mm'}}</div>
</div>
<div class="post-description">
<p>{{publication.Message}}</p>
</div>
</div>
</ion-card-content>
</ion-card>
</ion-content>
<!-- <ion-list>
<div class="post-item d-md-block mb-10 cursor-pointer"
*ngFor="let publication of publicationList"
(click)="viewPublicationDetail(publication.DocumentId)">
@@ -65,7 +85,7 @@
<div class="center height-100" *ngIf="!publicationList">
<p>{{error}}</p>
</div>
</ion-list>
</ion-list> -->
</div>
<!-- fab placed to the bottom end -->
<ion-fab vertical="bottom" horizontal="end">
@@ -137,7 +137,7 @@ export class ViewPublicationsPage implements OnInit {
getFromDB() {
this.storage.get('view_publications').then((viewPublications) => {
this.getpublication = viewPublications;
this.publicationList = viewPublications;
})
}
+2 -2
View File
@@ -6,8 +6,8 @@ export const environment = {
production: false,
apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
// apiURL: 'http://gpr-dev-01.gabinetedigital.local/GabineteDigital.Services/V5/api/',
apiChatUrl: 'https://gpr-dev-01.gabinetedigital.local/api/v1/',
apiWsChatUrl: 'ws://gpr-dev-01.gabinetedigital.local/websocket',
apiChatUrl: 'https://gabinetedigitalchat.dyndns.info/api/v1/',
apiWsChatUrl: 'wss://gabinetedigitalchat.dyndns.info/websocket',
//apiChatUrl: 'https://www.tabularium.pt/api/v1/',
/* apiChatUrl: 'http://chat.gabinetedigital.local:3000/api/v1/', */
domain: 'gabinetedigital.local', //gabinetedigital.local
+6
View File
@@ -116,6 +116,7 @@ $app-theme: mat-light-theme(
--ion-color-expediente: #dae3f3;
}
// dark-mode
@media (prefers-color-scheme: dark) {
/*
* Dark Colors
@@ -662,6 +663,8 @@ body {
--PinCircleBackground: url(/auth.svg);
--PinBackground: #e1e7eb;
--PinTextColor: #44b5ea;
--Event-approve-header-color: #c63527;
--color: #97cae631;
--color2: #97cae631;
@@ -754,6 +757,7 @@ body {
--PinDots: #c63527;
--PinTextColor: black;
--PinCircleBackground: url(/auth.svg);
--Event-approve-header-color: #ffb81c;
--color: #d9d9d9;
--color2: #f0f0f0;
@@ -833,6 +837,8 @@ body {
--PinTextColor: #44b5ea;
--PinCircleBackground: url(/assets/background/auth.svg);
--PinBackground: white !important;
--Event-approve-header-color: #42b9fe;
--header-container-background: linear-gradient(
270deg,