submit advanced
This commit is contained in:
parent
18c5b3c742
commit
7900ad5e09
@ -65,11 +65,11 @@ function setTitle(input: string): string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function onSubmitAdvanced() {
|
async function onSubmitAdvanced() {
|
||||||
const update = await configStore.setPlayoutConfig(configStore.playout)
|
const update = await configStore.setAdvancedConfig()
|
||||||
configStore.onetimeInfo = true
|
configStore.onetimeInfo = true
|
||||||
|
|
||||||
if (update.status === 200) {
|
if (update.status === 200) {
|
||||||
indexStore.msgAlert('success', t('config.updatePlayoutSuccess'), 2)
|
indexStore.msgAlert('success', t('advanced.updateSuccess'), 2)
|
||||||
|
|
||||||
const channel = configStore.configChannel[configStore.configID].id
|
const channel = configStore.configChannel[configStore.configID].id
|
||||||
|
|
||||||
@ -83,7 +83,7 @@ async function onSubmitAdvanced() {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
indexStore.msgAlert('error', t('config.updatePlayoutFailed'), 2)
|
indexStore.msgAlert('error', t('advanced.updateFailed'), 2)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -143,6 +143,8 @@ export default {
|
|||||||
encoder: 'Encoder',
|
encoder: 'Encoder',
|
||||||
filter: 'Filter',
|
filter: 'Filter',
|
||||||
ingest: 'Ingest',
|
ingest: 'Ingest',
|
||||||
|
updateSuccess: 'Update advanced config success!',
|
||||||
|
updateFailed: 'Update advanced config failed!',
|
||||||
},
|
},
|
||||||
config: {
|
config: {
|
||||||
channel: 'Kanal',
|
channel: 'Kanal',
|
||||||
|
@ -143,6 +143,8 @@ export default {
|
|||||||
encoder: 'Encoder',
|
encoder: 'Encoder',
|
||||||
filter: 'Filter',
|
filter: 'Filter',
|
||||||
ingest: 'Ingest',
|
ingest: 'Ingest',
|
||||||
|
updateSuccess: 'Update advanced config success!',
|
||||||
|
updateFailed: 'Update advanced config failed!',
|
||||||
},
|
},
|
||||||
config: {
|
config: {
|
||||||
channel: 'Channel',
|
channel: 'Channel',
|
||||||
|
@ -143,6 +143,8 @@ export default {
|
|||||||
encoder: 'Encoder',
|
encoder: 'Encoder',
|
||||||
filter: 'Filter',
|
filter: 'Filter',
|
||||||
ingest: 'Ingest',
|
ingest: 'Ingest',
|
||||||
|
updateSuccess: 'Update advanced config success!',
|
||||||
|
updateFailed: 'Update advanced config failed!',
|
||||||
},
|
},
|
||||||
config: {
|
config: {
|
||||||
channel: 'Canal',
|
channel: 'Canal',
|
||||||
|
@ -143,6 +143,8 @@ export default {
|
|||||||
encoder: 'Encoder',
|
encoder: 'Encoder',
|
||||||
filter: 'Filter',
|
filter: 'Filter',
|
||||||
ingest: 'Ingest',
|
ingest: 'Ingest',
|
||||||
|
updateSuccess: 'Update advanced config success!',
|
||||||
|
updateFailed: 'Update advanced config failed!',
|
||||||
},
|
},
|
||||||
config: {
|
config: {
|
||||||
channel: 'Канал',
|
channel: 'Канал',
|
||||||
|
@ -187,6 +187,19 @@ export const useConfig = defineStore('config', {
|
|||||||
return update
|
return update
|
||||||
},
|
},
|
||||||
|
|
||||||
|
async setAdvancedConfig() {
|
||||||
|
const authStore = useAuth()
|
||||||
|
const channel = this.configChannel[this.configID].id
|
||||||
|
|
||||||
|
const update = await fetch(`/api/playout/advanced/${channel}`, {
|
||||||
|
method: 'PUT',
|
||||||
|
headers: { ...this.contentType, ...authStore.authHeader },
|
||||||
|
body: JSON.stringify(this.advanced),
|
||||||
|
})
|
||||||
|
|
||||||
|
return update
|
||||||
|
},
|
||||||
|
|
||||||
async getUserConfig() {
|
async getUserConfig() {
|
||||||
const authStore = useAuth()
|
const authStore = useAuth()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user