diff --git a/client/src/store/modules/system.js b/client/src/store/modules/system.js index b93e8136..b0c7bec6 100644 --- a/client/src/store/modules/system.js +++ b/client/src/store/modules/system.js @@ -25,6 +25,15 @@ export default { }, }, actions: { + async GET_AVAILABLE_SHOWS(context) { + const response = await fetch(`${makeURL('/api/v1/shows')}`); + if (response.ok) { + const shows = await response.json(); + context.commit('UPDATE_SHOWS', shows.shows); + } else { + log.error('Unable to get available shows'); + } + }, async GET_RAW_SETTINGS(context) { const response = await fetch(`${makeURL('/api/v1/settings/raw')}`); if (response.ok) { @@ -81,6 +90,9 @@ export default { }, }, getters: { + AVAILABLE_SHOWS(state) { + return state.availableShows; + }, SETTINGS(state) { return state.settings; }, diff --git a/client/src/views/config/ConfigView.vue b/client/src/views/config/ConfigView.vue index 6c3a226c..351d7461 100644 --- a/client/src/views/config/ConfigView.vue +++ b/client/src/views/config/ConfigView.vue @@ -4,7 +4,10 @@

DigiScript Config

- + + + + @@ -23,9 +26,10 @@ import ConfigSystem from '@/vue_components/config/ConfigSystem.vue'; import ConfigSettings from '@/vue_components/config/ConfigSettings.vue'; import ConfigUsers from '@/vue_components/config/ConfigUsers.vue'; +import ConfigShows from '@/vue_components/config/ConfigShows.vue'; export default { name: 'ConfigView', - components: { ConfigUsers, ConfigSettings, ConfigSystem }, + components: { ConfigShows, ConfigUsers, ConfigSettings, ConfigSystem }, }; diff --git a/client/src/vue_components/config/ConfigShows.vue b/client/src/vue_components/config/ConfigShows.vue new file mode 100644 index 00000000..991d1630 --- /dev/null +++ b/client/src/vue_components/config/ConfigShows.vue @@ -0,0 +1,296 @@ + + + diff --git a/client/src/vue_components/config/ConfigSystem.vue b/client/src/vue_components/config/ConfigSystem.vue index bbb3743b..4a826896 100644 --- a/client/src/vue_components/config/ConfigSystem.vue +++ b/client/src/vue_components/config/ConfigSystem.vue @@ -2,42 +2,6 @@
- - - Current Show - - -

- {{ $store.state.currentShow['name'] }} -

- No show loaded -
- - - - Load Show - - Setup New Show - - -
- - - Connected Clients - - - {{ connectedClients.length }} - - - - View Clients - - - Version @@ -77,118 +41,21 @@ + + + Connected Clients + + + {{ connectedClients.length }} + + + + View Clients + + +
- -
- - - - - - This is a required field and must be less than 100 characters. - - - - - - - This is a required field and must be before or the same as the end date. - - - - - - - This is a required field and must be after or the same as the start date. - - - -
-
-
- - Advanced Options - - - - - -

Change the type of script for this show.

-
- -
-
-
-
- -
- -
- - - - -
-
@@ -218,8 +85,6 @@