mirror of
https://github.com/itdoginfo/podkop.git
synced 2025-12-08 12:36:50 +03:00
fix: add enable/disable button for Podkop service
This commit is contained in:
@@ -587,6 +587,10 @@ return view.extend({
|
|||||||
'class': 'btn cbi-button-apply',
|
'class': 'btn cbi-button-apply',
|
||||||
'click': () => fs.exec('/etc/init.d/podkop', ['restart']).then(() => location.reload())
|
'click': () => fs.exec('/etc/init.d/podkop', ['restart']).then(() => location.reload())
|
||||||
}, _('Restart Podkop')),
|
}, _('Restart Podkop')),
|
||||||
|
E('button', {
|
||||||
|
'class': 'btn cbi-button-' + (podkopStatus.enabled ? 'remove' : 'apply'),
|
||||||
|
'click': () => fs.exec('/etc/init.d/podkop', [podkopStatus.enabled ? 'disable' : 'enable']).then(() => location.reload())
|
||||||
|
}, podkopStatus.enabled ? _('Disable Podkop') : _('Enable Podkop')),
|
||||||
E('button', {
|
E('button', {
|
||||||
'class': 'btn',
|
'class': 'btn',
|
||||||
'click': () => fs.exec('/etc/init.d/podkop', ['show_config']).then(res => {
|
'click': () => fs.exec('/etc/init.d/podkop', ['show_config']).then(res => {
|
||||||
|
|||||||
Reference in New Issue
Block a user