Browse Source

refactor(nc-gui): revise hook sample data structure

pull/5349/head
Wing-Kam Wong 2 years ago
parent
commit
316779b810
  1. 8
      packages/nc-gui/components/webhook/Test.vue

8
packages/nc-gui/components/webhook/Test.vue

@ -14,9 +14,7 @@ const { $api } = useNuxtApp()
const meta = inject(MetaInj, ref()) const meta = inject(MetaInj, ref())
const sampleData = ref({ const sampleData = ref()
data: {},
})
watch( watch(
() => hook?.operation, () => hook?.operation,
@ -26,9 +24,7 @@ watch(
) )
async function loadSampleData() { async function loadSampleData() {
sampleData.value = { sampleData.value = await $api.dbTableWebhook.samplePayloadGet(meta?.value?.id as string, hook?.operation || 'insert')
data: await $api.dbTableWebhook.samplePayloadGet(meta?.value?.id as string, hook?.operation || 'insert'),
}
} }
async function testWebhook() { async function testWebhook() {

Loading…
Cancel
Save