Add alert

This commit is contained in:
brunosimon
2017-08-15 18:13:14 +02:00
parent 4b4977cc1b
commit 0ff61b0c99
14 changed files with 93 additions and 9 deletions
+15 -1
View File
@@ -19,6 +19,11 @@ export default
pendingMessage()
{
return this.$store.state.chat.pendingMessage
},
pendingAlert()
{
return this.$store.state.chat.pendingAlert
}
},
@@ -26,7 +31,8 @@ export default
{
project: 'onProjectChange',
pendingUser: 'onPendingUser',
pendingMessage: 'onPendingMessage'
pendingMessage: 'onPendingMessage',
pendingAlert: 'onPendingAlert'
},
created()
@@ -119,6 +125,14 @@ export default
{
this.chatSocket.emit('message', value)
}
},
onPendingAlert(value)
{
if(value)
{
this.chatSocket.emit('alert')
}
}
}
}