This commit is contained in:
tiago.kayaya
2021-08-06 09:02:51 +01:00
parent a14ca7366d
commit 2c28abbf12
8 changed files with 57 additions and 23 deletions
+32 -1
View File
@@ -8,7 +8,38 @@
<ion-content>
<div class="ion-input-class-no-height">
<ion-textarea [(ngModel)]="note" placeholder="Detalhes" rows="6" cols="20"></ion-textarea>
<ion-textarea *ngIf="!hideThisFeature" [(ngModel)]="note" placeholder="Detalhes" rows="6" cols="20"></ion-textarea>
<ion-textarea *ngIf="hideThisFeature" [(ngModel)]="note" placeholder="Detalhes" rows="4" cols="20"></ion-textarea>
</div>
<div *ngIf="hideThisFeature" class="ion-item-container-no-border" (click)="getDoc()">
<ion-label class="d-flex align-center">
<button class="btn-no-color">
<div class="attach-icon">
<ion-icon src="assets/images/icons-attach-doc.svg"></ion-icon>
</div>
<div class="attach-document pl-10">
<ion-label>Anexar Documentos</ion-label>
</div>
</button>
</ion-label>
</div>
<div class="list " *ngFor="let document of documents; let i = index" >
<ion-list>
<ion-item>
<ion-label>
<p class="d-flex ion-justify-content-between">
<span class="attach-title-item">{{document.Assunto}}</span>
<span class="app-name">{{document.appName}}</span>
<span class="close-button text-black cursor-pointer" (click)="removeAttachment(i)" >
<ion-icon class="font-20" src="assets/images/icons-delete-25.svg"></ion-icon>
</span>
</p>
<p><span class="span-left">{{document.EntidadeOrganicaNome}}</span><span class="span-right"> {{document.Data | date: 'dd-MM-yy'}} </span></p>
</ion-label>
</ion-item>
</ion-list>
</div>
<!-- <div class="main-content d-flex height-100">
@@ -26,6 +26,7 @@ float: left;
margin: 0px auto;
padding: 0 !important;
overflow: auto;
border: 1px solid red;
}
.container-div{
margin-bottom: 15px;
@@ -77,11 +78,13 @@ float: left;
margin: 5px 5px 5px 10px;
padding: 5px;
float: left;
border: 1px solid red !important;
}
.attach-icon{
width: 37px;
font-size: 35px;
float: left;
border: 1px solid red !important;
}
.attach-title-item{
width: 100%;
+9 -1
View File
@@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { AnimationController, ModalController } from '@ionic/angular';
import { AnimationController, ModalController, NavParams } from '@ionic/angular';
import { SearchDocument } from 'src/app/models/search-document';
import { SearchPage } from 'src/app/pages/search/search.page';
import { BadRequestPage } from 'src/app/shared/popover/bad-request/bad-request.page';
@@ -19,15 +19,23 @@ export class AddNotePage implements OnInit {
constructor(
private modalController: ModalController,
private animationController: AnimationController,
private navParams: NavParams,
) {
this.note = '';
this.hideThisFeature = this.navParams.get('showAttachmentBtn');
}
ngOnInit() {
console.log( this.navParams);
console.log(this.hideThisFeature);
}
close(){
this.modalController.dismiss('');
}
save(){
let body = {
"note":this.note,
@@ -356,9 +356,10 @@ export class ExpedientePrPage implements OnInit {
const modal = await this.modalController.create({
component: AddNotePage,
componentProps:{
showAttachmentBtn: false,
},
cssClass: classs,
backdropDismiss: true
//backdropDismiss: true
});
await modal.present();
@@ -457,6 +457,7 @@ export class PedidoPage implements OnInit {
const modal = await this.modalController.create({
component: AddNotePage,
componentProps:{
showAttachmentBtn: true,
},
cssClass: classs,
backdropDismiss: true
@@ -69,9 +69,9 @@ constructor (
const pathname = location.pathname + location.search
this.LoadList();
this.router.events.forEach((event) => {
if (event instanceof NavigationStart &&
if (event instanceof NavigationStart &&
event.url.startsWith('/home/gabinete-digital?despachospr=true')) {
if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) {
this.refreshing()
@@ -111,7 +111,7 @@ constructor (
let result = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise();
this.despachoList = [];
let despachosPr;
switch (this.loggeduser.Profile) {
case 'MDGPR':
@@ -168,7 +168,7 @@ constructor (
}
doRefresh() {
setTimeout(() => {
this.LoadList();
@@ -177,12 +177,7 @@ doRefresh() {
}
goToDespacho(serialNumber:any){
let navigationExtras: NavigationExtras = {
queryParams: {
"serialNumber": serialNumber,
}
};
this.router.navigate(['/home/gabinete-digital/despachos-pr/despacho-pr'], navigationExtras);
this.router.navigate(['/home/gabinete-digital/despachos-pr',serialNumber,'gabinete-digital']);
}
async viewExpedientDetail(serialNumber:any) {
@@ -72,7 +72,7 @@ export class DespachosPage implements OnInit {
this.LoadList();
this.router.events.forEach((event) => {
if (event instanceof NavigationStart &&
if (event instanceof NavigationStart &&
event.url.startsWith('/home/gabinete-digital?despachos=true')) {
if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) {
this.doRefresh()
@@ -105,7 +105,7 @@ export class DespachosPage implements OnInit {
this.skeletonLoader = true
let result = await this.processes.GetTasksList("Despacho", false).toPromise();
this.despachoList = new Array();
await result.filter(data => data.workflowInstanceDataFields.Status == "Active").forEach( (element, index) => {
@@ -136,7 +136,7 @@ export class DespachosPage implements OnInit {
this.despachoList = this.sortArrayISODate(this.despachoList).reverse();
this.despachoStore.reset(this.despachoList);
this.skeletonLoader = false
}
sortArrayISODate(myArray: any){
@@ -146,7 +146,7 @@ export class DespachosPage implements OnInit {
}
doRefresh() {
setTimeout(() => {
this.LoadList();
}, 1000);
@@ -48,12 +48,7 @@ skeletonLoader = true
}
goToDiploma(serialNumber:any){
let navigationExtras: NavigationExtras = {
queryParams: {
"serialNumber": serialNumber,
}
};
this.router.navigate(['/home/gabinete-digital/diplomas-assinar/diploma-assinar'], navigationExtras);
this.router.navigate(['/home/gabinete-digital/diplomas-assinar',serialNumber,'gabinete-digital']);
}
doRefresh() {