Skip to content

Commit

Permalink
luci-mod-network: dhcp: separate actual value and display string
Browse files Browse the repository at this point in the history
saved value will now be only an integer.

Signed-off-by: Paul Donald <newtwen@gmail.com>
  • Loading branch information
systemcrash committed Feb 15, 2024
1 parent 2841d28 commit 5b955f1
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -800,7 +800,8 @@ return view.extend({
so.optional = true;

Object.values(L.uci.sections('dhcp', 'dnsmasq')).forEach(function(val, index) {
so.value(generateDnsmasqInstanceEntry(val));
var name, display_str = generateDnsmasqInstanceEntry(val);
so.value(index, display_str);
});

o = s.taboption('srvhosts', form.SectionValue, '__srvhosts__', form.TableSection, 'srvhost', null,
Expand Down Expand Up @@ -1078,7 +1079,8 @@ return view.extend({
so.optional = true;

Object.values(L.uci.sections('dhcp', 'dnsmasq')).forEach(function(val, index) {
so.value(generateDnsmasqInstanceEntry(val));
var name, display_str = generateDnsmasqInstanceEntry(val);
so.value(index, display_str);
});


Expand Down

0 comments on commit 5b955f1

Please sign in to comment.