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

This commit is contained in:
tiago.kayaya
2022-01-12 12:51:08 +01:00
19 changed files with 188 additions and 322 deletions
+2 -13
View File
@@ -26,7 +26,7 @@ import { ScreenOrientation } from '@ionic-native/screen-orientation/ngx';
import { SqliteService } from 'src/app/services/sqlite.service';
import { Device } from '@capacitor/device';
import { RouteService } from 'src/app/services/route.service';
import { RocketChatClientService } from 'src/app/services/socket/rocket-chat-client.service';
import { WsChatService } from 'src/app/services/chat/ws-chat.service';
import { environment } from 'src/environments/environment';
import { v4 as uuidv4 } from 'uuid'
@@ -100,19 +100,8 @@ export class HomePage implements OnInit {
private screenOrientation: ScreenOrientation,
private sqliteservice: SqliteService,
private RouteService: RouteService,
private RocketChatClientService: RocketChatClientService) {
window['jj'] = ()=> {
//send message // roomId // Message
//this.RocketChatClientService.send('fsMwcNdufWvdnChj7ya9nF9cX2HizxxWAM', 'Mensagem enviada programaticamente.'+ new Date().toISOString())
}
private WsChatService: WsChatService) {
this.RocketChatClientService.registerCallback({type:'Onmessage',requestId:'asdfasdfasdf',funx:(message)=>{
// console.log('message', message)
}})
// this.RocketChatClientService.send()
/* this.webNotificationPopupService.askNotificationPermission() */
this.router.events.subscribe((val) => {