diff --git a/resources/assets/scripts/components/server/Server.vue b/resources/assets/scripts/components/server/Server.vue
index 1b8f07da4..3026a7320 100644
--- a/resources/assets/scripts/components/server/Server.vue
+++ b/resources/assets/scripts/components/server/Server.vue
@@ -25,7 +25,7 @@
-
+
Console
@@ -67,13 +67,12 @@
import Navigation from '../core/Navigation';
import ProgressBar from './components/ProgressBar';
import {mapState} from 'vuex';
- import { ConsolePage } from './subpages/ConsolePage';
import io from 'socket.io-client';
export default {
components: {
- ProgressBar, Navigation, ConsolePage, TerminalIcon, FolderIcon, UsersIcon,
+ ProgressBar, Navigation, TerminalIcon, FolderIcon, UsersIcon,
CalendarIcon, DatabaseIcon, GlobeIcon, SettingsIcon
},
@@ -87,6 +86,10 @@
this.$on('send-command', data => {
this.socket.emit('send command', data);
});
+
+ this.$on('send-initial-log', () => {
+ this.socket.emit('send server log');
+ })
},
data: function () {
@@ -126,14 +129,15 @@
},
_socket_error: function (err) {
- console.error('there was a socket error:', err);
+ this.$emit('socket-error', {err});
},
_socket_connect: function () {
- this.socket.emit('send server log');
+ this.$emit('socket-connected');
},
_socket_status: function (data) {
+ this.$emit('socket-status', {data});
},
_socket_serverLog: function (data) {
diff --git a/resources/assets/scripts/components/server/subpages/ConsolePage.vue b/resources/assets/scripts/components/server/subpages/ConsolePage.vue
index f8a1eb8cf..cf3356158 100644
--- a/resources/assets/scripts/components/server/subpages/ConsolePage.vue
+++ b/resources/assets/scripts/components/server/subpages/ConsolePage.vue
@@ -2,6 +2,9 @@