mirror of
https://git.proxmox.com/git/proxmox-widget-toolkit
synced 2025-05-29 09:50:59 +00:00
notification: add gui for gotify notification endpoints
The GUI is based on the 'plugin-based' dialog window EndpointEditBase that was introduced in an earlier commit. Signed-off-by: Lukas Wagner <l.wagner@proxmox.com> Reviewed-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
84f70dfaad
commit
6669a59fd1
@ -66,6 +66,7 @@ JSSRC= \
|
|||||||
panel/PruneKeepPanel.js \
|
panel/PruneKeepPanel.js \
|
||||||
panel/RRDChart.js \
|
panel/RRDChart.js \
|
||||||
panel/GaugeWidget.js \
|
panel/GaugeWidget.js \
|
||||||
|
panel/GotifyEditPanel.js \
|
||||||
panel/Certificates.js \
|
panel/Certificates.js \
|
||||||
panel/ACMEAccount.js \
|
panel/ACMEAccount.js \
|
||||||
panel/ACMEPlugin.js \
|
panel/ACMEPlugin.js \
|
||||||
|
@ -43,6 +43,11 @@ Ext.define('Proxmox.Schema', { // a singleton
|
|||||||
ipanel: 'pmxSendmailEditPanel',
|
ipanel: 'pmxSendmailEditPanel',
|
||||||
iconCls: 'fa-envelope-o',
|
iconCls: 'fa-envelope-o',
|
||||||
},
|
},
|
||||||
|
gotify: {
|
||||||
|
name: gettext('Gotify'),
|
||||||
|
ipanel: 'pmxGotifyEditPanel',
|
||||||
|
iconCls: 'fa-bell-o',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
pxarFileTypes: {
|
pxarFileTypes: {
|
||||||
|
44
src/panel/GotifyEditPanel.js
Normal file
44
src/panel/GotifyEditPanel.js
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
Ext.define('Proxmox.panel.GotifyEditPanel', {
|
||||||
|
extend: 'Proxmox.panel.InputPanel',
|
||||||
|
xtype: 'pmxGotifyEditPanel',
|
||||||
|
mixins: ['Proxmox.Mixin.CBind'],
|
||||||
|
|
||||||
|
type: 'gotify',
|
||||||
|
|
||||||
|
items: [
|
||||||
|
{
|
||||||
|
xtype: 'pmxDisplayEditField',
|
||||||
|
name: 'name',
|
||||||
|
cbind: {
|
||||||
|
value: '{name}',
|
||||||
|
editable: '{isCreate}',
|
||||||
|
},
|
||||||
|
fieldLabel: gettext('Endpoint Name'),
|
||||||
|
allowBlank: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
xtype: 'proxmoxtextfield',
|
||||||
|
fieldLabel: gettext('Server URL'),
|
||||||
|
name: 'server',
|
||||||
|
allowBlank: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
xtype: 'proxmoxtextfield',
|
||||||
|
inputType: 'password',
|
||||||
|
fieldLabel: gettext('API Token'),
|
||||||
|
name: 'token',
|
||||||
|
cbind: {
|
||||||
|
emptyText: get => !get('isCreate') ? gettext('Unchanged') : '',
|
||||||
|
allowBlank: '{!isCreate}',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
xtype: 'proxmoxtextfield',
|
||||||
|
name: 'comment',
|
||||||
|
fieldLabel: gettext('Comment'),
|
||||||
|
cbind: {
|
||||||
|
deleteEmpty: '{!isCreate}',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
});
|
Loading…
Reference in New Issue
Block a user