diff --git a/packages/nc-gui-v2/components/webhook/Editor.vue b/packages/nc-gui-v2/components/webhook/Editor.vue index 80b0ca6195..d6595d60a8 100644 --- a/packages/nc-gui-v2/components/webhook/Editor.vue +++ b/packages/nc-gui-v2/components/webhook/Editor.vue @@ -14,18 +14,36 @@ import MdiChatIcon from '~icons/mdi/chat' import MdiWhatsAppIcon from '~icons/mdi/whatsapp' import MdiCellPhoneMessageIcon from '~icons/mdi/cellphone-message' +interface Option { + label: string + value: string +} + const meta = inject(MetaInj) + const { views, loadViews } = useViews(meta as Ref) const useForm = Form.useForm + const formState = reactive({ title: '', notification: { type: 'URL', + channel: '', }, method: 'GET', }) + +const slackChannels = ref() + +const teamsChannels = ref() + +const discordChannels = ref() + +const mattermostChannels = ref() + const filters = [] + const formInput = ref({ 'Email': [ { @@ -119,6 +137,7 @@ const formInput = ref({ }, ], }) + const notification = ref({ method: 'POST', body: '{{ json data }}', @@ -173,6 +192,10 @@ function onNotTypeChange() { // TODO } +function filterOption(input: string, option: Option) { + return option.value.toUpperCase().includes(input.toUpperCase()) +} + onMounted(() => { loadViews() }) @@ -251,7 +274,19 @@ onMounted(() => { - TODO: Slack + + + + + + + TODO: Microsoft Teams TODO: Discord TODO: Mattermost