Implement basic support for connecting to wings console via websocket rather than socketio

This commit is contained in:
Dane Everitt 2019-05-01 20:12:20 -07:00
parent 0757d8856b
commit e87c5f6657
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
12 changed files with 122 additions and 117 deletions

View file

@ -3,7 +3,7 @@
<div v-if="connected">
<transition name="slide-fade" mode="out-in">
<button class="btn btn-green uppercase text-xs px-4 py-2"
v-if="status === statuses.STATUS_OFF"
v-if="status === 'offline'"
v-on:click.prevent="sendPowerAction('start')"
>Start
</button>
@ -45,7 +45,7 @@
methods: {
sendPowerAction: function (action: string) {
this.$socket().instance().emit('set status', action)
this.$socket().emit('set state', action)
},
},
});