From: Dirk Brenken Date: Sun, 31 May 2026 16:42:29 +0000 (+0200) Subject: luci-app-banip: update 1.8.8-5 X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=1bffbf4d78fcd804330095275619a93225f6216e;p=openwrt-luci.git luci-app-banip: update 1.8.8-5 * fix minor code issues Signed-off-by: Dirk Brenken --- diff --git a/applications/luci-app-banip/Makefile b/applications/luci-app-banip/Makefile index b5a7f8a851..74d83aa2dd 100644 --- a/applications/luci-app-banip/Makefile +++ b/applications/luci-app-banip/Makefile @@ -7,7 +7,7 @@ LUCI_TITLE:=LuCI support for banIP LUCI_DEPENDS:=+luci-base +banip PKG_VERSION:=1.8.8 -PKG_RELEASE:=4 +PKG_RELEASE:=5 PKG_LICENSE:=Apache-2.0 PKG_MAINTAINER:=Dirk Brenken diff --git a/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/feeds.js b/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/feeds.js index fbd31f8b7c..e49cafd3e3 100644 --- a/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/feeds.js +++ b/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/feeds.js @@ -22,14 +22,19 @@ let fileSize = 0; button state helper */ function updateButtons() { - const buttons = document.querySelectorAll('#btnClear, #btnCreate, #btnSave, #btnUpload, #btnDownload'); + const enable = function (id) { + const btn = document.getElementById(id); + if (btn) { + btn.removeAttribute('disabled'); + } + }; if (fileSize === 0) { - if (buttons[1]) buttons[1].removeAttribute('disabled'); - if (buttons[2]) buttons[2].removeAttribute('disabled'); + enable('btnCreate'); + enable('btnUpload'); } else { - if (buttons[0]) buttons[0].removeAttribute('disabled'); - if (buttons[3]) buttons[3].removeAttribute('disabled'); - if (buttons[4]) buttons[4].removeAttribute('disabled'); + enable('btnDownload'); + enable('btnClear'); + enable('btnSave'); } } diff --git a/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/overview.js b/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/overview.js index f3d84db032..832ac7c6f5 100644 --- a/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/overview.js +++ b/applications/luci-app-banip/htdocs/luci-static/resources/view/banip/overview.js @@ -140,7 +140,7 @@ return view.extend({ runtime information and buttons */ s = m.section(form.NamedSection, 'global'); - s.render = L.bind(function (view, section_id) { + s.render = function (view, section_id) { return E('div', { 'class': 'cbi-section' }, [ E('h3', _('Information')), E('div', { 'class': 'cbi-value' }, [ @@ -184,7 +184,7 @@ return view.extend({ E('div', { 'class': 'cbi-value-field', 'id': 'sys', 'style': 'margin-bottom:-5px;color:#37c;' }, '-') ]) ]); - }, o, this); + }; /* tabbed config section