mirror of
https://github.com/remittor/zapret-openwrt.git
synced 2025-12-06 11:36:48 +03:00
luci: Add link to help page for NFQWS_OPT
This commit is contained in:
@@ -105,10 +105,13 @@ return view.extend({
|
|||||||
tabname = 'nfqws_params';
|
tabname = 'nfqws_params';
|
||||||
s.tab(tabname, _('NFQWS options'));
|
s.tab(tabname, _('NFQWS options'));
|
||||||
|
|
||||||
let add_delim = function(sec) {
|
let add_delim = function(sec, url = null) {
|
||||||
let o = sec.taboption(tabname, form.DummyValue, '_hr');
|
let o = sec.taboption(tabname, form.DummyValue, '_hr');
|
||||||
o.rawhtml = true;
|
o.rawhtml = true;
|
||||||
o.default = '<hr style="width: 620px; height: 1px; margin: 1px 0 1px; border-top: 1px solid;">';
|
o.default = '<hr style="width: 620px; height: 1px; margin: 1px 0 1px; border-top: 1px solid;">';
|
||||||
|
if (url) {
|
||||||
|
o.default += '<br/>' + _('Help') + ': <a href=%s>%s</a>'.format(url);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
let add_param = function(sec, param, locname = null, rows = 10, multiline = false) {
|
let add_param = function(sec, param, locname = null, rows = 10, multiline = false) {
|
||||||
@@ -140,7 +143,11 @@ return view.extend({
|
|||||||
val.validate = function(section_id, value) {
|
val.validate = function(section_id, value) {
|
||||||
return (value) ? value.trim() : "";
|
return (value) ? value.trim() : "";
|
||||||
};
|
};
|
||||||
btn.onclick = () => new tools.longstrEditDialog('config', param, param, locname, rows, multiline).show();
|
let desc = locname;
|
||||||
|
if (multiline == 2) {
|
||||||
|
desc += '<br/>' + _('Example') + ': <a href=%s>%s</a>'.format(tools.nfqws_opt_url);
|
||||||
|
}
|
||||||
|
btn.onclick = () => new tools.longstrEditDialog('config', param, param, desc, rows, multiline).show();
|
||||||
};
|
};
|
||||||
|
|
||||||
o = s.taboption(tabname, form.Flag, 'NFQWS_ENABLE', _('NFQWS_ENABLE'));
|
o = s.taboption(tabname, form.Flag, 'NFQWS_ENABLE', _('NFQWS_ENABLE'));
|
||||||
@@ -189,7 +196,7 @@ return view.extend({
|
|||||||
o.rmempty = false;
|
o.rmempty = false;
|
||||||
o.datatype = 'uinteger';
|
o.datatype = 'uinteger';
|
||||||
|
|
||||||
add_delim(s);
|
add_delim(s, tools.nfqws_opt_url);
|
||||||
add_param(s, 'NFQWS_OPT', null, 21, 2);
|
add_param(s, 'NFQWS_OPT', null, 21, 2);
|
||||||
|
|
||||||
/* AutoHostList settings */
|
/* AutoHostList settings */
|
||||||
|
|||||||
@@ -53,6 +53,7 @@ return baseclass.extend({
|
|||||||
customdFileFormat : '/opt/zapret/init.d/openwrt/custom.d/%s-script.sh',
|
customdFileFormat : '/opt/zapret/init.d/openwrt/custom.d/%s-script.sh',
|
||||||
discord_num : 50,
|
discord_num : 50,
|
||||||
discord_url : 'https://github.com/bol-van/zapret/blob/4e8e3a9ed9dbeb1156db68dfaa7b353051c13797/init.d/custom.d.examples.linux/50-discord',
|
discord_url : 'https://github.com/bol-van/zapret/blob/4e8e3a9ed9dbeb1156db68dfaa7b353051c13797/init.d/custom.d.examples.linux/50-discord',
|
||||||
|
nfqws_opt_url : 'https://github.com/remittor/zapret-openwrt/discussions/168',
|
||||||
|
|
||||||
autoHostListFN : '/opt/zapret/ipset/zapret-hosts-auto.txt',
|
autoHostListFN : '/opt/zapret/ipset/zapret-hosts-auto.txt',
|
||||||
autoHostListDbgFN : '/opt/zapret/ipset/zapret-hosts-auto-debug.log',
|
autoHostListDbgFN : '/opt/zapret/ipset/zapret-hosts-auto-debug.log',
|
||||||
|
|||||||
Reference in New Issue
Block a user