Add button to send test notification
This commit is contained in:
parent
6e2511bee7
commit
585ee35c59
2 changed files with 8 additions and 1 deletions
5
internal/web/public/js/notify.js
Normal file
5
internal/web/public/js/notify.js
Normal file
|
|
@ -0,0 +1,5 @@
|
||||||
|
async function testNotifications() {
|
||||||
|
|
||||||
|
const url = '/api/test_notify'
|
||||||
|
await fetch(url, { method: 'post' })
|
||||||
|
}
|
||||||
|
|
@ -44,6 +44,7 @@
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><button type="submit" class="btn btn-primary">Save</button></td>
|
<td><button type="submit" class="btn btn-primary">Save</button></td>
|
||||||
|
<td><button type="button" style="float: right;" class="btn btn-success" onclick="testNotifications()">Test notifications</button></td>
|
||||||
<td></td>
|
<td></td>
|
||||||
</tr>
|
</tr>
|
||||||
</form>
|
</form>
|
||||||
|
|
@ -199,6 +200,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<script src="/fs/public/js/notify.js"></script>
|
||||||
|
|
||||||
{{ template "footer.html" }}
|
{{ template "footer.html" }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
Loading…
Reference in a new issue