Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions client-v3/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion client-v3/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "client-v3",
"version": "0.30.7",
"version": "0.30.8",
"description": "DigiScript front end (Vue 3)",
"author": "DreamTeamProd",
"private": true,
Expand Down
4 changes: 2 additions & 2 deletions client-v3/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,8 @@
ref="goToPageModal"
title="Go to Page"
size="sm"
:hide-header-close="changingPage"
:hide-footer="changingPage"
:no-header-close="changingPage"
:no-footer="changingPage"
:no-close-on-backdrop="changingPage"
:no-close-on-esc="changingPage"
@ok.prevent="goToLivePage"
Expand Down
8 changes: 4 additions & 4 deletions client-v3/src/components/config/ConfigUsers.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,23 +52,23 @@
</BCol>
</BRow>

<BModal ref="newUserModal" title="Add New User" size="md" hide-footer>
<BModal ref="newUserModal" title="Add New User" size="md" no-footer>
<CreateUser :is-first-admin="false" @created_user="handleUserCreated(newUserModal)" />
</BModal>

<BModal ref="newAdminModal" title="Add New Admin" size="md" hide-footer>
<BModal ref="newAdminModal" title="Add New Admin" size="md" no-footer>
<CreateUser
:is-first-admin="false"
:is-admin="true"
@created_user="handleUserCreated(newAdminModal)"
/>
</BModal>

<BModal ref="rbacModal" title="User RBAC Config" size="xl" hide-footer>
<BModal ref="rbacModal" title="User RBAC Config" size="xl" no-footer>
<ConfigRbac v-if="selectedUserId != null" :user-id="selectedUserId" />
</BModal>

<BModal ref="resetPasswordModal" title="Reset User Password" size="md" hide-footer>
<BModal ref="resetPasswordModal" title="Reset User Password" size="md" no-footer>
<ResetPassword
v-if="selectedUser"
:user-id="selectedUser.id"
Expand Down
4 changes: 2 additions & 2 deletions client-v3/src/components/show/config/cues/CueEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
ref="goToPageModal"
title="Go to Page"
size="sm"
:hide-header-close="changingPage"
:hide-footer="changingPage"
:no-header-close="changingPage"
:no-footer="changingPage"
:no-close-on-backdrop="changingPage"
:no-close-on-esc="changingPage"
:ok-disabled="pageV$.pageInputFormState.$invalid"
Expand Down
4 changes: 2 additions & 2 deletions client-v3/src/components/show/config/cues/JumpToCueModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<BModal
ref="modal"
title="Jump to Cue"
:hide-header-close="searching || showResults"
:no-header-close="searching || showResults"
:no-close-on-backdrop="searching || showResults"
:no-close-on-esc="searching || showResults"
:ok-disabled="v$.cueSearchForm.$invalid"
:ok-title="showResults ? undefined : 'Search'"
:hide-footer="showResults"
:no-footer="showResults"
@ok.prevent="performCueSearch"
@hidden="resetCueSearch"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
ref="modalRef"
size="xl"
title="Auto-Populate Microphones"
:hide-footer="true"
no-footer
@show="resetState"
@hidden="resetState"
>
Expand Down
9 changes: 5 additions & 4 deletions client-v3/src/components/show/config/script/ScriptEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,9 @@
ref="saveModal"
title="Saving Script"
size="md"
:hide-header-close="savingInProgress"
:hide-footer="savingInProgress"
:no-header-close="savingInProgress"
:no-footer="savingInProgress"
:ok-disabled="savingInProgress"
:no-close-on-backdrop="savingInProgress"
:no-close-on-esc="savingInProgress"
ok-only
Expand Down Expand Up @@ -174,8 +175,8 @@
ref="goToPageModal"
title="Go to Page"
size="sm"
:hide-header-close="changingPage"
:hide-footer="changingPage"
:no-header-close="changingPage"
:no-footer="changingPage"
:no-close-on-backdrop="changingPage"
:no-close-on-esc="changingPage"
@ok.prevent="goToPage"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
ref="importTagModal"
title="Import Session Tag"
size="xl"
hide-footer
no-footer
@hide="resetImportState"
>
<div v-if="isLoadingImport" class="text-center">
Expand Down
12 changes: 12 additions & 0 deletions client-v3/src/stores/script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { defineStore } from 'pinia';
import log from 'loglevel';
import { makeURL } from '@/js/utils';
import { toast } from '@/js/toast';
import { useScriptConfigStore } from '@/stores/scriptConfig';
import type {
ScriptLine,
StageDirectionStyle,
Expand Down Expand Up @@ -47,6 +48,17 @@ export const useScriptStore = defineStore('script', {
}
},

async scriptPageChanged(data: { page: number }): Promise<void> {
const pageStr = String(data.page);
if (Object.hasOwn(this.script, pageStr)) {
await this.loadScriptPage(data.page);
const scriptConfigStore = useScriptConfigStore();
if (Object.hasOwn(scriptConfigStore.tmpScript, pageStr)) {
scriptConfigStore.addPage(data.page, this.getScriptPage(data.page));
}
}
},

async saveNewPage(page: number, lines: ScriptLine[]): Promise<boolean> {
const params = new URLSearchParams({ page: String(page) });
const response = await fetch(`${makeURL('/api/v1/show/script')}?${params}`, {
Expand Down
2 changes: 1 addition & 1 deletion client-v3/src/views/show/config/ConfigCues.vue
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@
ref="importCueTypeModal"
title="Import Cue Type"
size="xl"
hide-footer
no-footer
@hide="resetImportState"
>
<div v-if="isLoadingImport" class="text-center">
Expand Down
4 changes: 2 additions & 2 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "client",
"version": "0.30.7",
"version": "0.30.8",
"description": "DigiScript front end",
"author": "DreamTeamProd",
"private": true,
Expand Down
7 changes: 7 additions & 0 deletions client/src/store/modules/script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,13 @@ const module: Module<ScriptState, RootState> = {
await context.dispatch('LOAD_CUES');
await context.dispatch('GET_CUTS');
},
async SCRIPT_PAGE_CHANGED(context, msg: { DATA: { page: number } }) {
const page = String(msg.DATA.page);
if (Object.hasOwn(context.state.script, page)) {
await context.dispatch('LOAD_SCRIPT_PAGE', page);
await context.dispatch('ADD_BLANK_PAGE', page);
}
},
async LOAD_SCRIPT_PAGE(context, page: string | number) {
const searchParams = new URLSearchParams({ page: String(page) });
const response = await fetch(`${makeURL('/api/v1/show/script')}?${searchParams}`, {
Expand Down
4 changes: 2 additions & 2 deletions electron/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion electron/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "digiscript-electron",
"version": "0.30.7",
"version": "0.30.8",
"description": "DigiScript Electron Desktop Application",
"author": "DreamTeamProd",
"license": "GPL-3.0",
Expand Down
7 changes: 7 additions & 0 deletions server/controllers/api/show/script/script.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ async def post(self):
CompiledScript.compile_script, self.application, revision.id
)
)
await self.application.ws_send_to_all(
"NOOP", "SCRIPT_PAGE_CHANGED", {"page": page}
)
else:
self.set_status(404)
await self.finish({"message": ERROR_SHOW_NOT_FOUND})
Expand Down Expand Up @@ -663,11 +666,15 @@ async def patch(self):
(revision.id, line["id"]),
)
# Spawn a callback to create a compiled version of the script
session.commit()
IOLoop.current().add_callback(
partial(
CompiledScript.compile_script, self.application, revision.id
)
)
await self.application.ws_send_to_all(
"NOOP", "SCRIPT_PAGE_CHANGED", {"page": page}
)
else:
self.set_status(404)
await self.finish({"message": ERROR_SHOW_NOT_FOUND})
Expand Down
2 changes: 1 addition & 1 deletion server/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "digiscript-server"
version = "0.30.7"
version = "0.30.8"
description = "DigiScript server - Digital script management for theatrical shows"
readme = "../README.md"
requires-python = ">=3.13"
Expand Down
Loading