mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
add book meeting in desktop component
This commit is contained in:
@@ -23,6 +23,9 @@ import * as Rx from "rxjs/Rx";
|
||||
import { Message } from 'src/app/models/message.model';
|
||||
import { Observable, Subject } from "rxjs/Rx";
|
||||
import { Router } from '@angular/router';
|
||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
||||
import { removeDuplicate } from 'src/plugin/removeDuplicate.js'
|
||||
import { environment } from 'src/environments/environment';
|
||||
|
||||
@Component({
|
||||
selector: 'app-chat',
|
||||
@@ -70,6 +73,8 @@ export class ChatPage implements OnInit {
|
||||
showEditGroup=false;
|
||||
showGroupMessages=false;
|
||||
showGroupContacts=false;
|
||||
showNewEvent=false;
|
||||
showAttendees=false;
|
||||
emptyTextDescription = 'Sem conversa selecionada';
|
||||
|
||||
@Output() getRoomInfo;
|
||||
@@ -95,6 +100,14 @@ export class ChatPage implements OnInit {
|
||||
loggedUserChat:any;
|
||||
hideRefreshBtn = true;
|
||||
|
||||
taskParticipants: any = [];
|
||||
taskParticipantsCc: any = [];
|
||||
adding: "intervenient" | "CC" = "intervenient";
|
||||
profile:'mdgpr' | 'pr';
|
||||
eventSelectedDate: Date = new Date();
|
||||
contacts: EventPerson[];
|
||||
showEventEditOrOpen: "edit" | "add" | "" | "eventoToApprove" = ""
|
||||
|
||||
constructor(
|
||||
private http:HttpClient,
|
||||
private chatService: ChatService,
|
||||
@@ -164,8 +177,11 @@ hideRefreshButton(){
|
||||
this.showGroupMessages=false;
|
||||
this.showEmptyComponent=false;
|
||||
this.showGroupContacts=false;
|
||||
this.showNewEvent=false;
|
||||
this.showAttendees=false;
|
||||
console.log('All components closed!');
|
||||
}
|
||||
|
||||
showEmptyContainer(){
|
||||
this.showEmptyComponent=true;
|
||||
}
|
||||
@@ -240,6 +256,57 @@ hideRefreshButton(){
|
||||
}
|
||||
}
|
||||
|
||||
openNewEventPage(data:any){
|
||||
this.taskParticipants = data.members.map((val) =>{
|
||||
return {
|
||||
Name: val.name,
|
||||
EmailAddress: val.username+"@"+environment.domain,
|
||||
IsRequired: "true",
|
||||
}
|
||||
});
|
||||
this.closeAllDesktopComponents();
|
||||
if(window.innerWidth < 801){
|
||||
console.log('Mobile');
|
||||
}
|
||||
else{
|
||||
this.showNewEvent=true;
|
||||
}
|
||||
}
|
||||
|
||||
async openAttendeesComponent(data) {
|
||||
this.adding = data.type
|
||||
this.closeAllDesktopComponents();
|
||||
this.showAttendees = true;
|
||||
}
|
||||
|
||||
async clearContact() {
|
||||
this.contacts = [];
|
||||
}
|
||||
|
||||
async setContact(data:EventPerson[]) {
|
||||
this.contacts = data;
|
||||
}
|
||||
|
||||
async setIntervenient(data) {
|
||||
this.taskParticipants = removeDuplicate(data)
|
||||
|
||||
}
|
||||
|
||||
async setIntervenientCC(data) {
|
||||
this.taskParticipantsCc = removeDuplicate(data)
|
||||
}
|
||||
|
||||
async closeAttendeesComponent() {
|
||||
this.closeAllDesktopComponents();
|
||||
this.showNewEvent = true;
|
||||
}
|
||||
|
||||
async closeNewEventComponent() {
|
||||
this.closeAllDesktopComponents();
|
||||
this.showEmptyComponent = true;
|
||||
this.idSelected = "";
|
||||
}
|
||||
|
||||
onSegmentChange(){
|
||||
this.load();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user