prepare for presantation

This commit is contained in:
Eudes Inácio
2023-08-24 18:39:31 +01:00
28 changed files with 105 additions and 211 deletions
@@ -144,7 +144,7 @@ export class ApproveEventPage implements OnInit {
componentProps: {
trustedUrl: '',
file: {
title: Document.Assunto,
title: Document.Description,
url: '',
title_link: '',
},
@@ -63,9 +63,10 @@
<p>{{event.workflowInstanceDataFields.EndDate | date: 'HH:mm'}}</p>
</div>
<div class="approve-event-detail">
<h3>{{event.workflowInstanceDataFields.Subject}}</h3>
<p *ngIf="toDateString(event.workflowInstanceDataFields.StartDate) != toDateString(event.workflowInstanceDataFields.EndDate)">{{event.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} - {{ event.workflowInstanceDataFields.EndDate | date: 'dd/M/yy'}} | {{event.workflowInstanceDataFields.Location}}</p>
<p *ngIf="toDateString(event.workflowInstanceDataFields.StartDate) == toDateString(event.workflowInstanceDataFields.EndDate)">{{event.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} | {{event.workflowInstanceDataFields.Location}}</p>
<h3>{{event.workflowInstanceDataFields.Subject}}</h3>
<div *ngIf="event.activityInstanceName">
<div class="label-event-type font-13-rem"> {{ event.activityInstanceName }} </div>
</div>
@@ -38,9 +38,9 @@
<div class="members" *ngIf="members">
<ion-label class="members-label">Contactos selecção:</ion-label>
<ion-list class="members-list" *ngFor="let user of members">
<div class="members-checkbox">
<div class="members-checkbox" [class.inactive]="sessionStore.user.UserName == user.username">
<ion-checkbox disabled checked color="primary"></ion-checkbox>
<p class="ma-0">{{user.name}}</p>
<p class="ma-0">{{user.name }}</p>
<ion-icon class="{{user.status}}" name="ellipse"></ion-icon>
<button (click)="deleteMember(user)" class="btn-no-color detele-item-icon">
<ion-icon color="danger" name="close"></ion-icon>
@@ -49,7 +49,6 @@
</ion-list>
</div>
<div *ngFor="let userContainer of userContainer | keyvalue;" >
<div class="item-divider">
@@ -176,4 +176,9 @@
}
}
.inactive {
opacity: 0.7;
button {
display: none !important;
}
}
@@ -39,7 +39,7 @@ export class GroupContactsPage implements OnInit {
objectUserSingleStone = []
userContainer = {}
constructor(
private modalController: ModalController,
private chatService: ChatService,
@@ -1,17 +0,0 @@
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { GroupContactsPage } from './group-contacts.page';
const routes: Routes = [
{
path: '',
component: GroupContactsPage
}
];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule],
})
export class GroupContactsPageRoutingModule {}
@@ -1,20 +0,0 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { IonicModule } from '@ionic/angular';
import { GroupContactsPageRoutingModule } from './group-contacts-routing.module';
import { GroupContactsPage } from './group-contacts.page';
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
GroupContactsPageRoutingModule
],
declarations: [GroupContactsPage]
})
export class GroupContactsPageModule {}
@@ -1,9 +0,0 @@
<ion-header>
<ion-toolbar>
<ion-title>group-contacts</ion-title>
</ion-toolbar>
</ion-header>
<ion-content>
</ion-content>
@@ -1,24 +0,0 @@
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { IonicModule } from '@ionic/angular';
import { GroupContactsPage } from './group-contacts.page';
describe('GroupContactsPage', () => {
let component: GroupContactsPage;
let fixture: ComponentFixture<GroupContactsPage>;
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [ GroupContactsPage ],
imports: [IonicModule.forRoot()]
}).compileComponents();
fixture = TestBed.createComponent(GroupContactsPage);
component = fixture.componentInstance;
fixture.detectChanges();
}));
it('should create', () => {
expect(component).toBeTruthy();
});
});
@@ -1,15 +0,0 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-group-contacts',
templateUrl: './group-contacts.page.html',
styleUrls: ['./group-contacts.page.scss'],
})
export class GroupContactsPage implements OnInit {
constructor() { }
ngOnInit() {
}
}
@@ -11,12 +11,7 @@ const routes: Routes = [
{
path: 'contacts',
loadChildren: () => import('./contacts/contacts.module').then( m => m.ContactsPageModule)
},
{
path: 'group-contacts',
loadChildren: () => import('./group-contacts/group-contacts.module').then( m => m.GroupContactsPageModule)
}
];
@NgModule({
@@ -112,9 +112,9 @@
<p>{{event.workflowInstanceDataFields.EndDate | date: 'HH:mm'}}</p>
</div>
<div class="approve-event-detail">
<div class="h3">{{event.workflowInstanceDataFields.Subject}}</div>
<div class="p" *ngIf="toDateString(event.workflowInstanceDataFields.StartDate) != toDateString(event.workflowInstanceDataFields.EndDate)">{{event.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} - {{ event.workflowInstanceDataFields.EndDate | date: 'dd/M/yy'}} | {{event.workflowInstanceDataFields.Location}}</div>
<div class="p" *ngIf="toDateString(event.workflowInstanceDataFields.StartDate) == toDateString(event.workflowInstanceDataFields.EndDate)">{{event.workflowInstanceDataFields.StartDate | date: 'd/M/yy' }} | {{event.workflowInstanceDataFields.Location}}</div>
<div class="h3">{{event.workflowInstanceDataFields.Subject}}</div>
</div>
<div>
<span class="dead-line ml-10" *ngIf="TaskService.deadlineIsToday(event.deadline)">Para hoje</span>
@@ -10,7 +10,7 @@
<div class="buttons">
<button *ngIf="isAdmin" (click)="addUser()" class="btn-cancel" shape="round">Adicionar</button>
<button (click)="leaveGroup()" class="btn-cancel" shape="round">Sair do Grupo</button>
<button *ngIf="isAdmin" (click)="openChangeGroupName()" class="btn-cancel btn-cancel mt-10" shape="round">Alterar
<button *ngIf="isAdmin" (click)="openChangeGroupName()" class="btn-cancel btn-cancel mt-10" shape="round" style="min-width: 192px;">Alterar
nome do grupo</button>
<div class="solid"></div>
<button (click)="close('cancel')" full class="btn-cancel mobile-only" shape="round">Cancelar</button>
@@ -167,6 +167,7 @@ export class NewPublicationPage implements OnInit {
}
if(this.publicationType == '3') {
const loader = this.toastService.loading()
if(this.capturedImage != '') {
@@ -181,23 +182,6 @@ export class NewPublicationPage implements OnInit {
FileBase64: this.capturedImage,
FileExtension: 'jpeg',
}
const loader = this.toastService.loading()
try {
const response = await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise()
this.httpErroHandle.httpsSucessMessagge('Criar publicação')
console.log({response})
this.goBack();
} catch (error) {
this.httpErroHandle.httpStatusHandle(error)
} finally {
loader.remove()
}
}
else if (!this.PublicationFolderService.PublicationHasImage(this.publication)) { //
@@ -212,21 +196,6 @@ export class NewPublicationPage implements OnInit {
FileBase64: "",
FileExtension: this.publication.FileExtension,
}
const loader = this.toastService.loading()
try {
const response = await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise()
this.httpErroHandle.httpsSucessMessagge('Criar publicação')
console.log({response})
this.goBack();
} catch (error) {
this.httpErroHandle.httpStatusHandle(error)
} finally {
loader.remove()
}
} else {
this.publication = {
@@ -241,28 +210,29 @@ export class NewPublicationPage implements OnInit {
FileExtension: 'jpeg',
}
const loader = this.toastService.loading()
try {
const response =await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise()
this.httpErroHandle.httpsSucessMessagge('Criar publicação')
console.log({response})
this.goBack();
} catch (error) {
this.httpErroHandle.httpStatusHandle(error)
} finally {
loader.remove()
}
}
try {
const response = await this.publications.CreatePublication(this.publication.ProcessId, this.publication).toPromise()
try {
await this.publications.DeletePublication(this.folderId, this.publication.DocumentId).toPromise();
} catch(error) {}
this.httpErroHandle.httpsSucessMessagge('Editar publicação')
console.log({response})
this.goBack();
} catch (error) {
this.httpErroHandle.httpStatusHandle(error)
} finally {
loader.remove()
}
this.PublicationFolderService.deletePost(this.publication.ProcessId, this.publication.DocumentId)
this.PublicationFolderService.deletePost(this.publication.DocumentId, this.publication.ProcessId)
}
else {
@@ -134,6 +134,7 @@ export class PublicationDetailPage implements OnInit {
if(error.status == 404) {
this.publicationFolderService.deletePost(this.folderId, this.publicationId)
this.goBackToViewPublications.emit();
}
this.httpErrorHandle.httpStatusHandle(error)