mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 21:35:50 +00:00
fix change folder path
This commit is contained in:
@@ -25,6 +25,9 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "../sqlCliente"
|
"path": "../sqlCliente"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "../sentry"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"settings": {
|
"settings": {
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ const routes = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'empty-chat',
|
path: 'empty-chat',
|
||||||
loadChildren: () => import('./shared/chat/empty-chat/empty-chat.module').then( m => m.EmptyChatPageModule)
|
loadChildren: () => import('./ui/chat/component/empty-chat/empty-chat.module').then( m => m.EmptyChatPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'empty-container',
|
path: 'empty-container',
|
||||||
@@ -32,7 +32,7 @@ const routes = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'edit-group',
|
path: 'edit-group',
|
||||||
loadChildren: () => import('./shared/chat/edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
loadChildren: () => import('./ui/chat/component/edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'pedidos',
|
path: 'pedidos',
|
||||||
@@ -256,7 +256,7 @@ const routes = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'add-user',
|
path: 'add-user',
|
||||||
loadChildren: () => import('./shared/chat/add-user/add-user.module').then( m => m.AddUserPageModule)
|
loadChildren: () => import('./ui/chat/component/add-user/add-user.module').then( m => m.AddUserPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: 'information',
|
path: 'information',
|
||||||
@@ -309,7 +309,8 @@ const routes = [
|
|||||||
{
|
{
|
||||||
path: 'crop-image',
|
path: 'crop-image',
|
||||||
loadChildren: () => import('./modals/crop-image/crop-image.module').then( m => m.CropImagePageModule)
|
loadChildren: () => import('./modals/crop-image/crop-image.module').then( m => m.CropImagePageModule)
|
||||||
},
|
},
|
||||||
|
{
|
||||||
path: 'edit-message',
|
path: 'edit-message',
|
||||||
loadChildren: () => import('./modals/edit-message/edit-message.module').then( m => m.EditMessagePageModule)
|
loadChildren: () => import('./modals/edit-message/edit-message.module').then( m => m.EditMessagePageModule)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,11 +3,11 @@ import { Routes, RouterModule } from '@angular/router';
|
|||||||
import { AuthGuard } from '../guards/auth.guard';
|
import { AuthGuard } from '../guards/auth.guard';
|
||||||
import { InactivityGuard } from '../guards/inactivity.guard';
|
import { InactivityGuard } from '../guards/inactivity.guard';
|
||||||
import { AgendaPageModule } from '../pages/agenda/agenda.module';
|
import { AgendaPageModule } from '../pages/agenda/agenda.module';
|
||||||
import { ChatPageModule } from '../pages/chat/chat.module';
|
|
||||||
import { EventsPageModule } from '../pages/events/events.module';
|
import { EventsPageModule } from '../pages/events/events.module';
|
||||||
import { GabineteDigitalPageModule } from '../pages/gabinete-digital/gabinete-digital.module';
|
import { GabineteDigitalPageModule } from '../pages/gabinete-digital/gabinete-digital.module';
|
||||||
import { PublicationsPageModule } from '../pages/publications/publications.module';
|
import { PublicationsPageModule } from '../pages/publications/publications.module';
|
||||||
import { HomePage } from './home.page';
|
import { HomePage } from './home.page';
|
||||||
|
import { ChatPageModule } from '../ui/chat/chat.module';
|
||||||
|
|
||||||
const routes: Routes = [
|
const routes: Routes = [
|
||||||
{
|
{
|
||||||
@@ -331,15 +331,15 @@ const routes: Routes = [
|
|||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path:':roomId',
|
path:':roomId',
|
||||||
loadChildren: ()=> import('../pages/chat/messages/messages.module').then(m => m.MessagesPageModule)
|
loadChildren: ()=> import('../ui/chat/modal/messages/messages.module').then(m => m.MessagesPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path:'contacts',
|
path:'contacts',
|
||||||
loadChildren: ()=> import('../shared/chat/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
|
loadChildren: ()=> import('../ui/chat/component/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path:'contacts',
|
path:'contacts',
|
||||||
loadChildren: ()=> import('../pages/chat/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
|
loadChildren: ()=> import('../ui/chat/modal/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -348,15 +348,15 @@ const routes: Routes = [
|
|||||||
children:[
|
children:[
|
||||||
{
|
{
|
||||||
path:'',
|
path:'',
|
||||||
loadChildren: ()=> import('../pages/chat/group-messages/group-messages.module').then(m => m.GroupMessagesPageModule)
|
loadChildren: ()=> import('../ui/chat/modal/group-messages/group-messages.module').then(m => m.GroupMessagesPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path:'group-contacts',
|
path:'group-contacts',
|
||||||
loadChildren: ()=> import('../shared/chat/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
|
loadChildren: ()=> import('../ui/chat/component/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path:'group-contacts',
|
path:'group-contacts',
|
||||||
loadChildren: ()=> import('../pages/chat/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
|
loadChildren: ()=> import('../ui/chat/modal/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -99,6 +99,7 @@ export class DexieRepository<T> {
|
|||||||
const document = await this.table.where(filter).first();
|
const document = await this.table.where(filter).first();
|
||||||
return ok(document);
|
return ok(document);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
console.log(filter)
|
||||||
return err(new Error('Failed to find document: ' + error.message));
|
return err(new Error('Failed to find document: ' + error.message));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,8 +23,8 @@ export class MessageMapper {
|
|||||||
source: e.source,
|
source: e.source,
|
||||||
file: e.file,
|
file: e.file,
|
||||||
fileName: e.fileName,
|
fileName: e.fileName,
|
||||||
applicationId: e.applicationId,
|
applicationId: e.applicationId || 0,
|
||||||
docId: Number(e.docId),
|
docId: Number(e.docId) || 0,
|
||||||
mimeType: e.mimeType
|
mimeType: e.mimeType
|
||||||
}))[0]
|
}))[0]
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { MessageEntity, MessageEntitySchema, } from '../entity/message';
|
import { MessageEntity, MessageEntitySchema, } from '../entity/message';
|
||||||
import { MessageRepositoryService } from "src/app/module/chat/data/repository/message-respository.service"
|
import { MessageRepositoryService } from "src/app/module/chat/data/repository/message-respository.service";
|
||||||
import { AttachmentRepositoryService } from "src/app/module/chat/data/repository/attachment-repository.service"
|
import { AttachmentRepositoryService } from "src/app/module/chat/data/repository/attachment-repository.service";
|
||||||
import { z, ZodError } from 'zod';
|
import { z } from 'zod';
|
||||||
import { v4 as uuidv4 } from 'uuid'
|
import { v4 as uuidv4 } from 'uuid';
|
||||||
import { InstanceId } from '../chat-service.service';
|
import { InstanceId } from '../chat-service.service';
|
||||||
import { createDataURL } from 'src/app/utils/ToBase64';
|
import { createDataURL } from 'src/app/utils/ToBase64';
|
||||||
import { DomSanitizer } from '@angular/platform-browser';
|
|
||||||
import { zodSafeValidation } from 'src/app/utils/zodValidation';
|
import { zodSafeValidation } from 'src/app/utils/zodValidation';
|
||||||
import { Logger } from 'src/app/services/logger/main/service';
|
import { Logger } from 'src/app/services/logger/main/service';
|
||||||
import { MessageAttachmentSource } from '../../data/dto/message/messageOutputDTO';
|
import { MessageAttachmentSource } from '../../data/dto/message/messageOutputDTO';
|
||||||
@@ -46,7 +45,6 @@ export class MessageCreateUseCaseService {
|
|||||||
|
|
||||||
for (const attachment of message.attachments) {
|
for (const attachment of message.attachments) {
|
||||||
|
|
||||||
console.log(attachment)
|
|
||||||
if(attachment.source != MessageAttachmentSource.Webtrix) {
|
if(attachment.source != MessageAttachmentSource.Webtrix) {
|
||||||
|
|
||||||
this.AttachmentRepositoryService.create({
|
this.AttachmentRepositoryService.create({
|
||||||
|
|||||||
@@ -1,37 +0,0 @@
|
|||||||
import { NgModule } from '@angular/core';
|
|
||||||
import { Routes, RouterModule } from '@angular/router';
|
|
||||||
|
|
||||||
import { ChatPage } from './chat.page';
|
|
||||||
import { GroupMessagesPage } from './group-messages/group-messages.page';
|
|
||||||
import { MessagesPage } from './messages/messages.page';
|
|
||||||
|
|
||||||
const routes: Routes = [
|
|
||||||
{
|
|
||||||
path: '',
|
|
||||||
component: ChatPage,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'new-group',
|
|
||||||
loadChildren: () => import('./new-group/new-group.module').then( m => m.NewGroupPageModule)
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'group-messages',
|
|
||||||
loadChildren: () => import('./group-messages/group-messages.module').then( m => m.GroupMessagesPageModule)
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'messages',
|
|
||||||
outlet:'message',
|
|
||||||
loadChildren: () => import('./messages/messages.module').then( m => m.MessagesPageModule)
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'edit-group',
|
|
||||||
loadChildren: () => import('./edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
|
||||||
}
|
|
||||||
|
|
||||||
];
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [RouterModule.forChild(routes)],
|
|
||||||
exports: [RouterModule],
|
|
||||||
})
|
|
||||||
export class ChatPageRoutingModule {}
|
|
||||||
+1
-1
@@ -22,7 +22,7 @@ import { ThemeService } from 'src/app/services/theme.service'
|
|||||||
import { EventTrigger } from 'src/app/services/eventTrigger.service';
|
import { EventTrigger } from 'src/app/services/eventTrigger.service';
|
||||||
import { Platform } from '@ionic/angular';
|
import { Platform } from '@ionic/angular';
|
||||||
import { BackgroundService } from 'src/app/services/background.service';
|
import { BackgroundService } from 'src/app/services/background.service';
|
||||||
import { NewGroupPage } from 'src/app/pages/chat/new-group/new-group.page';
|
import { NewGroupPage } from 'src/app/ui/chat/modal/new-group/new-group.page';
|
||||||
import { DataService } from 'src/app/services/data.service';
|
import { DataService } from 'src/app/services/data.service';
|
||||||
import { RouteService } from 'src/app/services/route.service';
|
import { RouteService } from 'src/app/services/route.service';
|
||||||
import { Storage } from '@ionic/storage';
|
import { Storage } from '@ionic/storage';
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ import { PermissionService } from 'src/app/services/permission.service';
|
|||||||
import { ViewDocumentPage } from 'src/app/modals/view-document/view-document.page';
|
import { ViewDocumentPage } from 'src/app/modals/view-document/view-document.page';
|
||||||
import { ThemeService } from 'src/app/services/theme.service'
|
import { ThemeService } from 'src/app/services/theme.service'
|
||||||
import { DataService } from 'src/app/services/data.service';
|
import { DataService } from 'src/app/services/data.service';
|
||||||
import { NewGroupPage } from 'src/app/pages/chat/new-group/new-group.page';
|
import { NewGroupPage } from 'src/app/ui/chat/modal/new-group/new-group.page';
|
||||||
import { RouteService } from 'src/app/services/route.service';
|
import { RouteService } from 'src/app/services/route.service';
|
||||||
import { SessionStore } from 'src/app/store/session.service';
|
import { SessionStore } from 'src/app/store/session.service';
|
||||||
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ import { ToastService } from 'src/app/services/toast.service';
|
|||||||
import { ExpedienteService } from 'src/app/Rules/expediente.service';
|
import { ExpedienteService } from 'src/app/Rules/expediente.service';
|
||||||
import { PermissionService } from 'src/app/services/permission.service';
|
import { PermissionService } from 'src/app/services/permission.service';
|
||||||
import { ThemeService } from 'src/app/services/theme.service'
|
import { ThemeService } from 'src/app/services/theme.service'
|
||||||
import { NewGroupPage } from 'src/app/pages/chat/new-group/new-group.page';
|
import { NewGroupPage } from 'src/app/ui/chat/modal/new-group/new-group.page';
|
||||||
import { RouteService } from 'src/app/services/route.service';
|
import { RouteService } from 'src/app/services/route.service';
|
||||||
import { SessionStore } from 'src/app/store/session.service';
|
import { SessionStore } from 'src/app/store/session.service';
|
||||||
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import { ProcessesService } from 'src/app/services/processes.service';
|
|||||||
import { ToastService } from 'src/app/services/toast.service';
|
import { ToastService } from 'src/app/services/toast.service';
|
||||||
import { PedidoService } from 'src/app/Rules/pedido.service';
|
import { PedidoService } from 'src/app/Rules/pedido.service';
|
||||||
import { PermissionService } from 'src/app/services/permission.service';
|
import { PermissionService } from 'src/app/services/permission.service';
|
||||||
import { NewGroupPage } from 'src/app/pages/chat/new-group/new-group.page';
|
import { NewGroupPage } from 'src/app/ui/chat/modal/new-group/new-group.page';
|
||||||
import { ForwardPage } from 'src/app/modals/forward/forward.page';
|
import { ForwardPage } from 'src/app/modals/forward/forward.page';
|
||||||
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
import { HttpErrorHandle } from 'src/app/services/http-error-handle.service';
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,34 @@
|
|||||||
|
import { NgModule } from '@angular/core';
|
||||||
|
import { Routes, RouterModule } from '@angular/router';
|
||||||
|
|
||||||
|
import { ChatPage } from './chat.page';
|
||||||
|
const routes: Routes = [
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: ChatPage,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'new-group',
|
||||||
|
loadChildren: () => import('./modal/new-group/new-group.module').then( m => m.NewGroupPageModule)
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'group-messages',
|
||||||
|
loadChildren: () => import('./modal/group-messages/group-messages.module').then( m => m.GroupMessagesPageModule)
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'messages',
|
||||||
|
outlet:'message',
|
||||||
|
loadChildren: () => import('./modal/messages/messages.module').then( m => m.MessagesPageModule)
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'edit-group',
|
||||||
|
loadChildren: () => import('./modal/edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
||||||
|
}
|
||||||
|
|
||||||
|
];
|
||||||
|
|
||||||
|
@NgModule({
|
||||||
|
imports: [RouterModule.forChild(routes)],
|
||||||
|
exports: [RouterModule],
|
||||||
|
})
|
||||||
|
export class ChatPageRoutingModule {}
|
||||||
@@ -9,18 +9,17 @@ import { ChatPageRoutingModule } from './chat-routing.module';
|
|||||||
import { ChatPage } from './chat.page';
|
import { ChatPage } from './chat.page';
|
||||||
import { RouterModule } from '@angular/router';
|
import { RouterModule } from '@angular/router';
|
||||||
import { PipesModule } from 'src/app/pipes/pipes.module';
|
import { PipesModule } from 'src/app/pipes/pipes.module';
|
||||||
|
|
||||||
import { ContactsPageModule } from 'src/app/shared/chat/messages/contacts/contacts.module';
|
|
||||||
import { GroupMessagesPageModule } from 'src/app/shared/chat/group-messages/group-messages.module';
|
|
||||||
import { NewGroupPageModule } from 'src/app/shared/chat/new-group/new-group.module';
|
|
||||||
import { EditGroupPageModule } from 'src/app/shared/chat/edit-group/edit-group.module';
|
|
||||||
import { GroupContactsPageModule } from 'src/app/shared/chat/group-messages/group-contacts/group-contacts.module';
|
|
||||||
import { MessagesPageModule } from 'src/app/shared/chat/messages/messages.module';
|
|
||||||
import { EmptyChatPageModule } from 'src/app/shared/chat/empty-chat/empty-chat.module';
|
|
||||||
import { NewEventPageModule } from 'src/app/shared/agenda/new-event/new-event.module';
|
import { NewEventPageModule } from 'src/app/shared/agenda/new-event/new-event.module';
|
||||||
import { AttendeeModalPageModule } from 'src/app/shared/event/attendee-modal/attendee-modal.module';
|
import { AttendeeModalPageModule } from 'src/app/shared/event/attendee-modal/attendee-modal.module';
|
||||||
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
||||||
import { ImageCropperModule } from 'ngx-image-cropper';
|
import { ImageCropperModule } from 'ngx-image-cropper';
|
||||||
|
import { EmptyChatPageModule } from './component/empty-chat/empty-chat.module';
|
||||||
|
import { EditGroupPageModule } from './component/edit-group/edit-group.module';
|
||||||
|
import { GroupContactsPageModule } from './component/group-messages/group-contacts/group-contacts.module';
|
||||||
|
import { GroupMessagesPageModule } from './component/group-messages/group-messages.module';
|
||||||
|
import { MessagesPageModule } from './component/messages/messages.module';
|
||||||
|
import { ContactsPageModule } from './component/new-group/contacts/contacts.module';
|
||||||
|
import { NewGroupPageModule } from './component/new-group/new-group.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
imports: [
|
imports: [
|
||||||
@@ -129,7 +129,6 @@
|
|||||||
(closeAllDesktopComponents)="closeAllDesktopComponents()"
|
(closeAllDesktopComponents)="closeAllDesktopComponents()"
|
||||||
(showEmptyContainer)="showEmptyContainer()"
|
(showEmptyContainer)="showEmptyContainer()"
|
||||||
(showEmptyContainer)="showEmptyContainer()"
|
(showEmptyContainer)="showEmptyContainer()"
|
||||||
(openNewEventPage)="openNewEventPage($event)"
|
|
||||||
|
|
||||||
(openGroupContacts)="openGroupContactsPage($event)"
|
(openGroupContacts)="openGroupContactsPage($event)"
|
||||||
(openEditGroupPage)="openEditGroupPage($event)"
|
(openEditGroupPage)="openEditGroupPage($event)"
|
||||||
@@ -1,23 +1,15 @@
|
|||||||
import { HttpHeaders, HttpParams } from '@angular/common/http';
|
|
||||||
import {
|
import {
|
||||||
Component,
|
Component,
|
||||||
OnInit,
|
OnInit,
|
||||||
ViewChild,
|
|
||||||
ViewContainerRef,
|
|
||||||
Output,
|
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { ModalController } from '@ionic/angular';
|
import { ModalController } from '@ionic/angular';
|
||||||
import { ChatService } from 'src/app/services/chat.service';
|
import { ChatService } from 'src/app/services/chat.service';
|
||||||
import { GroupMessagesPage } from './group-messages/group-messages.page';
|
import { GroupMessagesPage } from './modal/group-messages/group-messages.page';
|
||||||
import { ContactsPage } from './messages/contacts/contacts.page';
|
import { ContactsPage } from './modal/./messages/contacts/contacts.page';
|
||||||
import { MessagesPage } from './messages/messages.page';
|
import { MessagesPage } from './modal/./messages/messages.page';
|
||||||
import { NewGroupPage } from './new-group/new-group.page';
|
import { NewGroupPage } from './modal/./new-group/new-group.page';
|
||||||
import { EditGroupPage } from 'src/app/shared/chat/edit-group/edit-group.page';
|
|
||||||
import { Observable, Subject } from "rxjs/Rx";
|
import { Observable, Subject } from "rxjs/Rx";
|
||||||
import { Router, NavigationEnd } from '@angular/router';
|
import { Router, NavigationEnd } from '@angular/router';
|
||||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
|
||||||
import { removeDuplicate } from 'src/plugin/removeDuplicate.js'
|
|
||||||
import { environment } from 'src/environments/environment';
|
|
||||||
import { TimeService } from 'src/app/services/functions/time.service';
|
import { TimeService } from 'src/app/services/functions/time.service';
|
||||||
import { ThemeService } from 'src/app/services/theme.service'
|
import { ThemeService } from 'src/app/services/theme.service'
|
||||||
import { DataService } from 'src/app/services/data.service';
|
import { DataService } from 'src/app/services/data.service';
|
||||||
@@ -26,7 +18,7 @@ import { RoomRemoteDataSourceState } from 'src/app/module/chat/data/data-source/
|
|||||||
import { RoomListOutPutDTO } from 'src/app/module/chat/data/dto/room/roomListOutputDTO';
|
import { RoomListOutPutDTO } from 'src/app/module/chat/data/dto/room/roomListOutputDTO';
|
||||||
import { RoomRepositoryService } from 'src/app/module/chat/data/repository/room-repository.service'
|
import { RoomRepositoryService } from 'src/app/module/chat/data/repository/room-repository.service'
|
||||||
import { Observable as DexieObservable } from 'Dexie';
|
import { Observable as DexieObservable } from 'Dexie';
|
||||||
import { Logger } from 'src/app/services/logger/main/service';
|
import { EditGroupPage } from './modal/edit-group/edit-group.page';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-chat',
|
selector: 'app-chat',
|
||||||
@@ -36,34 +28,10 @@ import { Logger } from 'src/app/services/logger/main/service';
|
|||||||
export class ChatPage implements OnInit {
|
export class ChatPage implements OnInit {
|
||||||
|
|
||||||
showLoader: boolean;
|
showLoader: boolean;
|
||||||
|
|
||||||
headers: HttpHeaders;
|
|
||||||
options: any;
|
|
||||||
X_User_Id: any;
|
|
||||||
X_Auth_Token: any;
|
|
||||||
|
|
||||||
loggedUser: any;
|
|
||||||
segment: string = 'Grupos'
|
segment: string = 'Grupos'
|
||||||
allGroups: any[];
|
|
||||||
privateGroups: any[];
|
|
||||||
userConnectedList: any[];
|
|
||||||
userRooms: any[];
|
|
||||||
userChannels: any[];
|
|
||||||
userDirectMessages: any[];
|
|
||||||
result: any;
|
|
||||||
dmUsers: any[] = [];
|
|
||||||
idSelected: string;
|
idSelected: string;
|
||||||
|
|
||||||
desktopComponent: any = {
|
|
||||||
showMessages: false,
|
|
||||||
showGroupMessages: false,
|
|
||||||
}
|
|
||||||
|
|
||||||
@ViewChild('messagecontainer', { read: ViewContainerRef }) entry: ViewContainerRef;
|
|
||||||
componentRef: any;
|
|
||||||
|
|
||||||
roomId: any;
|
roomId: any;
|
||||||
task: any;
|
|
||||||
groupRoomId: any;
|
groupRoomId: any;
|
||||||
showEmptyComponent = true;
|
showEmptyComponent = true;
|
||||||
showMessages = false;
|
showMessages = false;
|
||||||
@@ -76,36 +44,15 @@ export class ChatPage implements OnInit {
|
|||||||
showAttendees = false;
|
showAttendees = false;
|
||||||
emptyTextDescription = 'Sem conversa selecionada';
|
emptyTextDescription = 'Sem conversa selecionada';
|
||||||
|
|
||||||
@Output() getRoomInfo;
|
|
||||||
|
|
||||||
|
|
||||||
subject: any;
|
subject: any;
|
||||||
public messages: Subject<any>;
|
public messages: Subject<any>;
|
||||||
|
|
||||||
message = {
|
|
||||||
"msg": "connect",
|
|
||||||
"version": "1",
|
|
||||||
"support": ["1"]
|
|
||||||
};
|
|
||||||
|
|
||||||
loggedUserChat: any;
|
|
||||||
hideRefreshBtn = true;
|
hideRefreshBtn = true;
|
||||||
|
|
||||||
taskParticipants: any = [];
|
|
||||||
taskParticipantsCc: any = [];
|
|
||||||
adding: "intervenient" | "CC" = "intervenient";
|
|
||||||
profile: 'mdgpr' | 'pr';
|
|
||||||
eventSelectedDate: Date = new Date();
|
|
||||||
contacts: EventPerson[];
|
|
||||||
showEventEditOrOpen: "edit" | "add" | "" | "eventoToApprove" = ""
|
|
||||||
socket: WebSocket;
|
|
||||||
receivedData: any;
|
|
||||||
routerSubscription
|
routerSubscription
|
||||||
|
|
||||||
count$: Observable<RoomRemoteDataSourceState>;
|
count$: Observable<RoomRemoteDataSourceState>;
|
||||||
items$!: DexieObservable<RoomListOutPutDTO[]>;
|
items$!: DexieObservable<RoomListOutPutDTO[]>;
|
||||||
|
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private chatService: ChatService,
|
private chatService: ChatService,
|
||||||
private modalController: ModalController,
|
private modalController: ModalController,
|
||||||
@@ -117,7 +64,7 @@ export class ChatPage implements OnInit {
|
|||||||
private RoomRepositoryService: RoomRepositoryService,
|
private RoomRepositoryService: RoomRepositoryService,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
this.headers = new HttpHeaders();
|
|
||||||
window.onresize = (event) => {
|
window.onresize = (event) => {
|
||||||
if (window.innerWidth > 701) {
|
if (window.innerWidth > 701) {
|
||||||
this.modalController.dismiss();
|
this.modalController.dismiss();
|
||||||
@@ -367,65 +314,6 @@ export class ChatPage implements OnInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
openNewEventPage(data?) {
|
|
||||||
|
|
||||||
if (data) {
|
|
||||||
this.taskParticipants = data.members.map((val) => {
|
|
||||||
return {
|
|
||||||
Name: val.name,
|
|
||||||
EmailAddress: val.username + "@" + environment.domain,
|
|
||||||
IsRequired: "true",
|
|
||||||
}
|
|
||||||
});
|
|
||||||
this.groupRoomId = data.roomId;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.closeAllDesktopComponents();
|
|
||||||
if (window.innerWidth < 701) {
|
|
||||||
|
|
||||||
}
|
|
||||||
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 = "";
|
|
||||||
}
|
|
||||||
|
|
||||||
async closeNewEventComponentAndOpenChat({ roomId }) {
|
|
||||||
this.closeAllDesktopComponents();
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
doRefresh(event) {
|
doRefresh(event) {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
@@ -435,14 +323,6 @@ export class ChatPage implements OnInit {
|
|||||||
}, 1000);
|
}, 1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
customRoom() {
|
|
||||||
let params = new HttpParams();
|
|
||||||
params = params.set("types", "c");
|
|
||||||
this.chatService.customsRooms(params).subscribe(res => {
|
|
||||||
//
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
showDateDuration(start: any) {
|
showDateDuration(start: any) {
|
||||||
return this.timeService.showDateDuration(start);
|
return this.timeService.showDateDuration(start);
|
||||||
+1
-3
@@ -7,9 +7,7 @@ import { IonicModule } from '@ionic/angular';
|
|||||||
import { EditGroupPageRoutingModule } from './edit-group-routing.module';
|
import { EditGroupPageRoutingModule } from './edit-group-routing.module';
|
||||||
|
|
||||||
import { EditGroupPage } from './edit-group.page';
|
import { EditGroupPage } from './edit-group.page';
|
||||||
import { SharedModule } from '../../shared.module';
|
import { BtnSeguintePageModule } from 'src/app/shared/btn-seguinte/btn-seguinte.module';
|
||||||
|
|
||||||
import { BtnSeguintePageModule } from '../../btn-seguinte/btn-seguinte.module';
|
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
imports: [
|
imports: [
|
||||||
+1
-2
@@ -9,13 +9,12 @@ import { GroupMessagesPageRoutingModule } from './group-messages-routing.module'
|
|||||||
import { GroupMessagesPage } from './group-messages.page';
|
import { GroupMessagesPage } from './group-messages.page';
|
||||||
import { SharedModule } from 'src/app/shared/shared.module';
|
import { SharedModule } from 'src/app/shared/shared.module';
|
||||||
|
|
||||||
import { ChatPopoverPageModule } from '../../popover/chat-popover/chat-popover.module';
|
|
||||||
import { NewEventPageModule } from '../../agenda/new-event/new-event.module';
|
|
||||||
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
||||||
import {MatMenuModule} from '@angular/material/menu';
|
import {MatMenuModule} from '@angular/material/menu';
|
||||||
import { LettersAvatarModule } from "ngx-letters-avatar";
|
import { LettersAvatarModule } from "ngx-letters-avatar";
|
||||||
import { PipesModule } from 'src/app/pipes/pipes.module';
|
import { PipesModule } from 'src/app/pipes/pipes.module';
|
||||||
import { SafehtmlPipe } from 'src/app/pipes/safehtml.pipe';
|
import { SafehtmlPipe } from 'src/app/pipes/safehtml.pipe';
|
||||||
|
import { ChatPopoverPageModule } from 'src/app/shared/popover/chat-popover/chat-popover.module';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
imports: [
|
imports: [
|
||||||
+1
-1
@@ -4,7 +4,6 @@ import { AlertService } from 'src/app/services/alert.service';
|
|||||||
import { ChatService } from 'src/app/services/chat.service';
|
import { ChatService } from 'src/app/services/chat.service';
|
||||||
import { ChatPopoverPage } from 'src/app/shared/popover/chat-popover/chat-popover.page';
|
import { ChatPopoverPage } from 'src/app/shared/popover/chat-popover/chat-popover.page';
|
||||||
import { GroupContactsPage } from './group-contacts/group-contacts.page';
|
import { GroupContactsPage } from './group-contacts/group-contacts.page';
|
||||||
import { ChatOptionsPopoverPage } from '../../popover/chat-options-popover/chat-options-popover.page';
|
|
||||||
import { ChatOptionsFeaturesPage } from 'src/app/modals/chat-options-features/chat-options-features.page';
|
import { ChatOptionsFeaturesPage } from 'src/app/modals/chat-options-features/chat-options-features.page';
|
||||||
import { TimeService } from 'src/app/services/functions/time.service';
|
import { TimeService } from 'src/app/services/functions/time.service';
|
||||||
import { SearchPage } from 'src/app/pages/search/search.page';
|
import { SearchPage } from 'src/app/pages/search/search.page';
|
||||||
@@ -30,6 +29,7 @@ import { SessionStore } from 'src/app/store/session.service';
|
|||||||
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
|
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
|
||||||
import { PermissionService } from 'src/app/services/permission.service';
|
import { PermissionService } from 'src/app/services/permission.service';
|
||||||
import { FileValidatorService } from "src/app/services/file/file-validator.service"
|
import { FileValidatorService } from "src/app/services/file/file-validator.service"
|
||||||
|
import { ChatOptionsPopoverPage } from 'src/app/shared/popover/chat-options-popover/chat-options-popover.page';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-group-messages',
|
selector: 'app-group-messages',
|
||||||
templateUrl: './group-messages.page.html',
|
templateUrl: './group-messages.page.html',
|
||||||
+2
-2
@@ -22,7 +22,6 @@ import { SessionStore } from 'src/app/store/session.service';
|
|||||||
import { Howl } from 'howler';
|
import { Howl } from 'howler';
|
||||||
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
|
import { ViewMediaPage } from 'src/app/modals/view-media/view-media.page';
|
||||||
import { PermissionService } from 'src/app/services/permission.service';
|
import { PermissionService } from 'src/app/services/permission.service';
|
||||||
import { ChatPopoverPage } from '../../popover/chat-popover/chat-popover.page';
|
|
||||||
import { Observable as DexieObservable } from 'Dexie';
|
import { Observable as DexieObservable } from 'Dexie';
|
||||||
import { Subscription } from 'rxjs';
|
import { Subscription } from 'rxjs';
|
||||||
import { MessageRepositoryService } from 'src/app/module/chat/data/repository/message-respository.service'
|
import { MessageRepositoryService } from 'src/app/module/chat/data/repository/message-respository.service'
|
||||||
@@ -38,11 +37,12 @@ import { TypingTable } from 'src/app/module/chat/infra/database/dexie/schema/typ
|
|||||||
import { MessageAttachmentFileType, MessageAttachmentSource } from 'src/app/module/chat/data/dto/message/messageOutputDTO';
|
import { MessageAttachmentFileType, MessageAttachmentSource } from 'src/app/module/chat/data/dto/message/messageOutputDTO';
|
||||||
import { JSFileToDataUrl } from 'src/app/utils/ToBase64';
|
import { JSFileToDataUrl } from 'src/app/utils/ToBase64';
|
||||||
import { CameraService } from 'src/app/infra/camera/camera.service'
|
import { CameraService } from 'src/app/infra/camera/camera.service'
|
||||||
import { compressImageBase64 } from '../../../utils/imageCompressore';
|
|
||||||
import { FilePickerWebService } from 'src/app/infra/file-picker/web/file-picker-web.service'
|
import { FilePickerWebService } from 'src/app/infra/file-picker/web/file-picker-web.service'
|
||||||
import { FilePickerService } from 'src/app/infra/file-picker/file-picker.service'
|
import { FilePickerService } from 'src/app/infra/file-picker/file-picker.service'
|
||||||
import { allowedDocExtension } from 'src/app/utils/allowedDocExtension';
|
import { allowedDocExtension } from 'src/app/utils/allowedDocExtension';
|
||||||
import { SpeakerService, StartRecordingResultError, StopRecordingResultError } from 'src/app/infra/speaker/speaker.service'
|
import { SpeakerService, StartRecordingResultError, StopRecordingResultError } from 'src/app/infra/speaker/speaker.service'
|
||||||
|
import { ChatPopoverPage } from 'src/app/shared/popover/chat-popover/chat-popover.page';
|
||||||
|
import { compressImageBase64 } from 'src/app/utils/imageCompressore';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-messages',
|
selector: 'app-messages',
|
||||||
+1
-1
@@ -11,7 +11,6 @@ import { TimeService } from 'src/app/services/functions/time.service';
|
|||||||
import { FileService } from 'src/app/services/functions/file.service';
|
import { FileService } from 'src/app/services/functions/file.service';
|
||||||
import { ToastService } from 'src/app/services/toast.service';
|
import { ToastService } from 'src/app/services/toast.service';
|
||||||
import { environment } from 'src/environments/environment';
|
import { environment } from 'src/environments/environment';
|
||||||
import { NewEventPage } from '../../agenda/new-event/new-event.page';
|
|
||||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
import { EventPerson } from 'src/app/models/eventperson.model';
|
||||||
import { ViewDocumentPage } from 'src/app/modals/view-document/view-document.page';
|
import { ViewDocumentPage } from 'src/app/modals/view-document/view-document.page';
|
||||||
import { ThemeService } from 'src/app/services/theme.service'
|
import { ThemeService } from 'src/app/services/theme.service'
|
||||||
@@ -36,6 +35,7 @@ import { FileValidatorService } from "src/app/services/file/file-validator.servi
|
|||||||
import { sanitize } from "sanitize-filename-ts";
|
import { sanitize } from "sanitize-filename-ts";
|
||||||
import { FilePicker } from '@capawesome/capacitor-file-picker';
|
import { FilePicker } from '@capawesome/capacitor-file-picker';
|
||||||
import { ViewDocumentSecondOptionsPage } from 'src/app/modals/view-document-second-options/view-document-second-options.page';
|
import { ViewDocumentSecondOptionsPage } from 'src/app/modals/view-document-second-options/view-document-second-options.page';
|
||||||
|
import { NewEventPage } from 'src/app/pages/agenda/new-event/new-event.page';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-group-messages',
|
selector: 'app-group-messages',
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user