diff options
Diffstat (limited to 'packages/client/src')
| -rw-r--r-- | packages/client/src/pages/settings/webhook.edit.vue | 6 | ||||
| -rw-r--r-- | packages/client/src/pages/settings/webhook.vue | 2 | ||||
| -rw-r--r-- | packages/client/src/router.ts | 16 |
3 files changed, 22 insertions, 2 deletions
diff --git a/packages/client/src/pages/settings/webhook.edit.vue b/packages/client/src/pages/settings/webhook.edit.vue index 618250958b..e36e1d7540 100644 --- a/packages/client/src/pages/settings/webhook.edit.vue +++ b/packages/client/src/pages/settings/webhook.edit.vue @@ -43,8 +43,12 @@ import * as os from '@/os'; import { i18n } from '@/i18n'; import { definePageMetadata } from '@/scripts/page-metadata'; +const props = defineProps<{ + webhookId: string; +}>(); + const webhook = await os.api('i/webhooks/show', { - webhookId: new URLSearchParams(window.location.search).get('id'), + webhookId: props.webhookId, }); let name = $ref(webhook.name); diff --git a/packages/client/src/pages/settings/webhook.vue b/packages/client/src/pages/settings/webhook.vue index ef9b9b56f7..868d273ce4 100644 --- a/packages/client/src/pages/settings/webhook.vue +++ b/packages/client/src/pages/settings/webhook.vue @@ -9,7 +9,7 @@ <FormSection> <MkPagination :pagination="pagination"> <template #default="{items}"> - <FormLink v-for="webhook in items" :key="webhook.id" :to="`/settings/webhook/edit?id=${webhook.id}`" class="_formBlock"> + <FormLink v-for="webhook in items" :key="webhook.id" :to="`/settings/webhook/edit/${webhook.id}`" class="_formBlock"> <template #icon> <i v-if="webhook.active === false" class="fas fa-circle-pause"></i> <i v-else-if="webhook.latestStatus === null" class="far fa-circle"></i> diff --git a/packages/client/src/router.ts b/packages/client/src/router.ts index f3ca521832..573403c229 100644 --- a/packages/client/src/router.ts +++ b/packages/client/src/router.ts @@ -82,6 +82,14 @@ export const routes = [{ name: 'general', component: page(() => import('./pages/settings/general.vue')), }, { + path: '/theme/install', + name: 'theme', + component: page(() => import('./pages/settings/theme.install.vue')), + }, { + path: '/theme/manage', + name: 'theme', + component: page(() => import('./pages/settings/theme.manage.vue')), + }, { path: '/theme', name: 'theme', component: page(() => import('./pages/settings/theme.vue')), @@ -122,6 +130,14 @@ export const routes = [{ name: 'api', component: page(() => import('./pages/settings/api.vue')), }, { + path: '/webhook/edit/:webhookId', + name: 'webhook', + component: page(() => import('./pages/settings/webhook.edit.vue')), + }, { + path: '/webhook/new', + name: 'webhook', + component: page(() => import('./pages/settings/webhook.new.vue')), + }, { path: '/webhook', name: 'webhook', component: page(() => import('./pages/settings/webhook.vue')), |