You've already forked uptime-kuma
mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-07-07 01:16:26 +02:00
implement discord
This commit is contained in:
@ -93,11 +93,14 @@
|
||||
<input type="number" class="form-control" id="port" v-model="notification.smtpPort" required min="0" max="65535" step="1">
|
||||
</div>
|
||||
|
||||
<div class="form-check mb-3">
|
||||
<input class="form-check-input" type="checkbox" value="" id="secure" v-model="notification.smtpSecure">
|
||||
<label class="form-check-label" for="secure">
|
||||
Secure
|
||||
</label>
|
||||
<div class="mb-3">
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" value="" id="secure" v-model="notification.smtpSecure">
|
||||
<label class="form-check-label" for="secure">
|
||||
Secure
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-text">Generally, true for 465, false for other ports.</div>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
@ -105,7 +108,6 @@
|
||||
<input type="text" class="form-control" id="username" required v-model="notification.smtpUsername" autocomplete="false">
|
||||
</div>
|
||||
|
||||
|
||||
<div class="mb-3">
|
||||
<label for="password" class="form-label">Password</label>
|
||||
<input type="password" class="form-control" id="password" required v-model="notification.smtpPassword" autocomplete="false">
|
||||
@ -123,6 +125,24 @@
|
||||
|
||||
</template>
|
||||
|
||||
<template v-if="notification.type === 'discord'">
|
||||
<div class="mb-3">
|
||||
<label for="discord-token" class="form-label">Discord Bot Token</label>
|
||||
<input type="text" class="form-control" id="discord-token" required v-model="notification.discordToken" autocomplete="false">
|
||||
<div class="form-text">You should create a Discord app and create a bot from <a href="https://discord.com/developers/applications" target="_blank">here</a>.</div>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<label for="discordChannelID" class="form-label">Channel ID</label>
|
||||
<input type="text" class="form-control" id="discordChannelID" required v-model="notification.discordChannelID" autocomplete="false">
|
||||
<div class="form-text">
|
||||
You should add the bot to your channel. <br />
|
||||
<a href="https://support.discord.com/hc/en-us/articles/206346498-Where-can-I-find-my-User-Server-Message-ID-" target="_blank">Where can I find the channel id?</a><br />
|
||||
<a href="https://discordapi.com/permissions.html#8" target="_blank">How to add a bot to your channel?</a>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-danger" @click="deleteConfirm" :disabled="processing" v-if="id">Delete</button>
|
||||
|
Reference in New Issue
Block a user