diff options
author | Jo-Philipp Wich <jo@mein.io> | 2018-08-04 22:09:49 +0200 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2018-08-13 09:23:22 +0200 |
commit | 849d153851db2fc193c1c82648dbe719463d3a38 (patch) | |
tree | d88b4e4332938f8451be33aaa502e5dbce798b73 /themes/luci-theme-material | |
parent | c2d36ba280c50d81a5d6e6cfa30b995008c1a98e (diff) |
treewide: rework uci change display
- Use native rpcd uci changes format instead of incompletely converting
back and forth between the old and the new format
- Rework uci changelog template to print the equivalent uci commands
for the various changes
- Rework theme headers to properly count the uncomitted changes
- Rework theme CSS to properly style new changelog
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'themes/luci-theme-material')
-rw-r--r-- | themes/luci-theme-material/luasrc/view/themes/material/header.htm | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/themes/luci-theme-material/luasrc/view/themes/material/header.htm b/themes/luci-theme-material/luasrc/view/themes/material/header.htm index e6047614f6..c070b1a617 100644 --- a/themes/luci-theme-material/luasrc/view/themes/material/header.htm +++ b/themes/luci-theme-material/luasrc/view/themes/material/header.htm @@ -160,13 +160,9 @@ -- calculate the number of unsaved changes if tree.nodes[category] and tree.nodes[category].ucidata then local ucichanges = 0 - + local i, j for i, j in pairs(require("luci.model.uci").cursor():changes()) do - for k, l in pairs(j) do - for m, n in pairs(l) do - ucichanges = ucichanges + 1; - end - end + ucichanges = ucichanges + #j end if ucichanges > 0 then |