luci-base: ui.js: make "Apply unchecked" available from the changes dialog
Previously, "Apply unchecked" was only possible from the save action of CBI maps, allow to invoke it from the configuration change dialog as well. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
b6797821b8
commit
8583efb5a9
1 changed files with 10 additions and 4 deletions
|
@ -4399,10 +4399,16 @@ var UI = baseclass.extend(/** @lends LuCI.ui.prototype */ {
|
||||||
'class': 'btn',
|
'class': 'btn',
|
||||||
'click': UI.prototype.hideModal
|
'click': UI.prototype.hideModal
|
||||||
}, [ _('Close') ]), ' ',
|
}, [ _('Close') ]), ' ',
|
||||||
E('button', {
|
new UIComboButton('0', {
|
||||||
'class': 'cbi-button cbi-button-positive important',
|
0: [ _('Save & Apply') ],
|
||||||
'click': L.bind(this.apply, this, true)
|
1: [ _('Apply unchecked') ]
|
||||||
}, [ _('Save & Apply') ]), ' ',
|
}, {
|
||||||
|
classes: {
|
||||||
|
0: 'btn cbi-button cbi-button-positive important',
|
||||||
|
1: 'btn cbi-button cbi-button-negative important'
|
||||||
|
},
|
||||||
|
click: L.bind(function(ev, mode) { this.apply(mode == '0') }, this)
|
||||||
|
}).render(), ' ',
|
||||||
E('button', {
|
E('button', {
|
||||||
'class': 'cbi-button cbi-button-reset',
|
'class': 'cbi-button cbi-button-reset',
|
||||||
'click': L.bind(this.revert, this)
|
'click': L.bind(this.revert, this)
|
||||||
|
|
Loading…
Reference in a new issue