diff --git a/packages/nc-gui-v2/components/webhook/Editor.vue b/packages/nc-gui-v2/components/webhook/Editor.vue
index d77a0c5599..da9c262a3f 100644
--- a/packages/nc-gui-v2/components/webhook/Editor.vue
+++ b/packages/nc-gui-v2/components/webhook/Editor.vue
@@ -13,6 +13,7 @@ import MdiDiscordIcon from '~icons/mdi/discord'
import MdiChatIcon from '~icons/mdi/chat'
import MdiWhatsAppIcon from '~icons/mdi/whatsapp'
import MdiCellPhoneMessageIcon from '~icons/mdi/cellphone-message'
+import { fieldRequiredValidator } from '~/utils/validation'
interface Option {
label: string
@@ -29,7 +30,7 @@ const formState = reactive({
title: '',
notification: {
type: 'URL',
- channel: '',
+ channels: '',
},
method: 'GET',
})
@@ -180,10 +181,12 @@ const methodList = ref([
const validators = computed(() => {
return {
- 'title': [],
- 'event': [],
- 'notification.type': [],
- 'method': [],
+ 'title': [fieldRequiredValidator],
+ 'event': [fieldRequiredValidator],
+ 'notification.type': [fieldRequiredValidator],
+ 'notification.url': [fieldRequiredValidator],
+ 'notification.channels': [fieldRequiredValidator],
+ 'method': [fieldRequiredValidator],
}
})
const { resetFields, validate, validateInfos } = useForm(formState, validators)
@@ -224,8 +227,12 @@ onMounted(() => {
-
-
+
+
+
+
+
+
@@ -270,7 +277,7 @@ onMounted(() => {
-
+
@@ -278,7 +285,7 @@ onMounted(() => {
{
{
{
{
-
+
+
-
+
+