pull made

This commit is contained in:
Eudes Inácio
2023-08-04 10:13:06 +01:00
6 changed files with 57 additions and 68 deletions
@@ -591,7 +591,7 @@
<!-- List -->
<div *ngIf="!p.userPermission([p.permissionList.Gabinete.pr_tasks])"
[class.active]="selectedElement == 'Dispatches'"
class="box-hover exp-card d-flex flex-column justify-center"
class="box-hover exp-card d-flex flex-column justify-center cypress-despacho-item"
(click)="openDespachosPage(); selectedElement='Dispatches'">
<div class="d-flex justify-center">
<ion-icon *ngIf="ThemeService.currentTheme == 'default' "
+2 -2
View File
@@ -20,11 +20,11 @@
<form class="form">
<p class="form-label">Email</p>
<ion-item class="form-input">
<ion-input type="text" [(ngModel)]="username" name="input-username"></ion-input>
<ion-input class="cy-email" type="text" [(ngModel)]="username" name="input-username"></ion-input>
</ion-item>
<p class="form-label">Palavra-passe</p>
<ion-item class="form-input">
<ion-input (keyup.enter)="Login()" [type]="showPassword ? 'text' : 'password' " [(ngModel)]="password" name="input-password" ></ion-input>
<ion-input class="cy-password" (keyup.enter)="Login()" [type]="showPassword ? 'text' : 'password' " [(ngModel)]="password" name="input-password" ></ion-input>
<div (click)="togglePassword()">
<ion-icon slot="end" [name]="passwordIcon" ></ion-icon>
</div>
+45 -56
View File
@@ -111,12 +111,12 @@ export class SearchPage implements OnInit {
if(this.type == null || this.type == undefined) {
if(this.currentPath == '/home/agenda') {
if(this.currentPath.includes('/home/agenda')) {
this.type = "Agenda"
} else if (this.currentPath =='/home/gabinete-digital') {
} else if (this.currentPath.includes('/home/gabinete-digital')) {
this.type = "AccoesPresidenciais & ArquivoDespachoElect"
} else if (this.currentPath == '/home/publications') {
} else if (this.currentPath.includes('/home/publications')) {
this.type = "AccoesPresidenciais"
} else {
@@ -461,7 +461,7 @@ export class SearchPage implements OnInit {
} else {
let counter = 0;
this.search.searchForDoc(this.searchSubject, searchDocumentDate, this.searchSender
this.search.basicSearch(this.searchSubject, searchDocumentDate, this.searchSender
,this.searchOrganicEntiry, this.searchDocTypeId, '8').subscribe(res => {
res.Categories.forEach( e => {
e['Active'] = false;
@@ -594,7 +594,7 @@ export class SearchPage implements OnInit {
} else {
let counter = 0;
this.search.searchForDoc(this.searchSubject, searchDocumentDate, this.searchSender
this.search.basicSearch(this.searchSubject, searchDocumentDate, this.searchSender
,this.searchOrganicEntiry, this.searchDocTypeId, '8').subscribe(res=>{
res.Categories.forEach( e => {
@@ -645,54 +645,50 @@ export class SearchPage implements OnInit {
this.searchCategories = []
this.searchDocuments = []
this.search.basicSearch(this.searchSubject, searchDocumentDate, this.searchSender
,this.searchOrganicEntiry, this.searchDocTypeId, '386').subscribe(res=>{
// this.search.basicSearchPublication(this.searchSubject, searchDocumentDate, this.searchSender
// ,this.searchOrganicEntiry, this.searchDocTypeId, '386').subscribe(res=>{
res.Categories.forEach( e => {
e['Active'] = false;
if(!environment.presidential) {
e['Name'] = "Publicações"
}
});
// res.Categories.forEach( e => {
// e['Active'] = false;
// e['Name'] = "Publicações"
// });
// bind respose
for ( const a of res.Categories) {
this.searchCategories.push(a);
}
// // bind respose
// for ( const a of res.Categories) {
// this.searchCategories.push(a);
// }
for ( const a of this.sortArrayISODate(res.Documents)) {
if(!environment.presidential) {
a.DocTypeDesc = "Publicações"
}
this.searchDocuments.push(a);
}
// for ( const a of this.sortArrayISODate(res.Documents)) {
// a.DocTypeDesc = "Publicações"
// this.searchDocuments.push(a);
// }
this.reorderList(this.ordinance);
// this.reorderList(this.ordinance);
// hide show document
if(this.searchDocuments.length >= 1){
this.showDocuments = true;
} else {
this.showDocuments = false
}
// // hide show document
// if(this.searchDocuments.length >= 1){
// this.showDocuments = true;
// } else {
// this.showDocuments = false
// }
counter++;
// counter++;
if(counter ==2){
this.showLoader = false;
}
// if(counter ==2){
// this.showLoader = false;
// }
this.loadWordCloud();
}, error => {
counter++;
// this.loadWordCloud();
// }, error => {
// counter++;
if(counter == 2) {
this.showLoader = false;
}
this.searchResult = "Registo não encontrado"
console.log(error)
});
// if(counter == 2) {
// this.showLoader = false;
// }
// this.searchResult = "Registo não encontrado"
// console.log(error)
// });
@@ -702,9 +698,7 @@ export class SearchPage implements OnInit {
res.Categories.forEach( e => {
e['Active'] = false;
if(!environment.presidential) {
e['Name'] = "Acções"
}
e['Name'] = "Acções"
});
if(!environment.presidential) {
@@ -717,10 +711,8 @@ export class SearchPage implements OnInit {
for ( const a of this.sortArrayISODate(res.Documents)) {
if(!environment.presidential) {
a.DocTypeDesc = "Acções"
this.searchDocuments.push(a);
}
a.DocTypeDesc = "Acções"
this.searchDocuments.push(a);
}
this.reorderList(this.ordinance);
@@ -734,16 +726,13 @@ export class SearchPage implements OnInit {
counter++;
if(counter ==2) {
this.showLoader = false;
}
this.showLoader = false;
this.loadWordCloud();
}, error => {
counter++;
if(counter ==2) {
this.showLoader = false;
}
this.showLoader = false;
this.searchResult = "Registo não encontrado"
console.log(error)
});