Merge branch 'feature/viewer-attachment' of https://bitbucket.org/equilibriumito/gabinete-digital-fo into feature/viewer-attachment

This commit is contained in:
Eudes Inácio
2024-03-07 12:01:23 +01:00
9 changed files with 67 additions and 79 deletions
@@ -46,7 +46,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
documents: SearchList[] = [];
room: any = new Array();
roomName: any;
members: any;
capturedImage: any;
@@ -58,8 +57,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
currentPosition: any;
startPosition: number;
scrollToBottomBtn = false;
roomCountDownDate: string;
roomCountDownTime: string;
isAdmin = false;
@Input() roomId: string;
@@ -112,8 +109,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
this.ChatSystemService.getUser()
this.loggedUserChat = SessionStore.user.ChatData['data'];
this.isGroupCreated = true;
this.roomCountDownDate = "";
this.roomCountDownTime = "";
}
ngOnChanges(changes: SimpleChanges): void {
@@ -151,10 +146,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
return this.timeService.showDateDuration(start);
}
countDownDate() {
return this.timeService.countDownDateTimer(this.roomCountDownDate, this.roomId);
}
setStatus(status: string) {
let body = {
message: '',
@@ -377,28 +368,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
this.ChatSystemService.getGroupRoom(this.roomId).loadHistory({});
}
let room = await this.chatService.getRoomInfo(this.roomId).toPromise();
this.room = room['room'];
if (this.room.name) {
try {
this.roomName = this.room.name.split('-').join(' ');
} catch (error) {
this.roomName = this.room.name;
}
}
if(SessionStore.user.ChatData.data.userId == this.room.u._id){
this.isAdmin = true
} else {
this.isAdmin = false
}
if (this.room.customFields.countDownDate) {
this.roomCountDownDate = this.room.customFields.countDownDate;
}
this.getGroupContacts(this.room);
}
@@ -536,14 +505,6 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
}
else {
if(res?.data?.name) {
try {
this.roomName = res.data.name.split('-').join(' ');
} catch (error) {
this.roomName = res.data.name
}
}
};