mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-18 15:10:03 +00:00
Further setup for websocket handler
This commit is contained in:
@@ -9,13 +9,8 @@ import { WebsocketHandlerService } from './../../services/websocket-handler/webs
|
||||
export class ChatbuttonComponent implements OnInit {
|
||||
|
||||
constructor(private chatService: WebsocketHandlerService) {
|
||||
chatService.messages.subscribe(msg => {
|
||||
if(msg.Event === 'orderbook_update') {
|
||||
console.log("Response from websocket: " + JSON.stringify(msg));
|
||||
} else {
|
||||
console.log("recieved unsubscribed event of type: " + msg.Event)
|
||||
}
|
||||
});
|
||||
chatService.messages.subscribe(msg => {
|
||||
});
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -27,7 +22,7 @@ export class ChatbuttonComponent implements OnInit {
|
||||
}
|
||||
private authenticateMessage = {
|
||||
Event:'auth',
|
||||
data:{"username":"username","password":"5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8"},
|
||||
data:{"username":"Username","password":"16f78a7d6317f102bbd95fc9a4f3ff2e3249287690b8bdad6b7810f82b34ace3"},
|
||||
}
|
||||
|
||||
authenticate():void {
|
||||
|
||||
Reference in New Issue
Block a user