mirror of
https://github.com/openwrt/luci
synced 2025-01-09 04:28:37 +08:00
luci-mod-network: Correctly assign dnsmasq instance: name not number
Closes #7199 Signed-off-by: Paul Donald <newtwen+github@gmail.com>
This commit is contained in:
parent
e55f9d967a
commit
5ab0cb1f15
@ -101,7 +101,7 @@ function generateDnsmasqInstanceEntry(data) {
|
||||
}
|
||||
formatString += ')';
|
||||
|
||||
return nameValueMap.get('.name'), formatString;
|
||||
return [nameValueMap.get('.name'), formatString];
|
||||
}
|
||||
|
||||
function getDHCPPools() {
|
||||
@ -830,8 +830,8 @@ return view.extend({
|
||||
so.optional = true;
|
||||
|
||||
Object.values(L.uci.sections('dhcp', 'dnsmasq')).forEach(function(val, index) {
|
||||
var name, display_str = generateDnsmasqInstanceEntry(val);
|
||||
so.value(index, display_str);
|
||||
var [name, display_str] = generateDnsmasqInstanceEntry(val);
|
||||
so.value(name, display_str);
|
||||
});
|
||||
|
||||
o = s.taboption('dnsrecords', form.SectionValue, '__dnsrecords__', form.TypedSection, '__dnsrecords__');
|
||||
@ -1125,8 +1125,8 @@ return view.extend({
|
||||
so.optional = true;
|
||||
|
||||
Object.values(L.uci.sections('dhcp', 'dnsmasq')).forEach(function(val, index) {
|
||||
var name, display_str = generateDnsmasqInstanceEntry(val);
|
||||
so.value(index, display_str);
|
||||
var [name, display_str] = generateDnsmasqInstanceEntry(val);
|
||||
so.value(name, display_str);
|
||||
});
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user