luci-mod-system: fstab: fix table cell rendering without unmount button

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
This commit is contained in:
Anton Kikin 2018-11-16 21:13:14 +03:00
parent ee6e07217c
commit 677765705d

View file

@ -117,14 +117,14 @@ function used.cfgvalue(self, section)
end
unmount = v:option(Button, "unmount", translate("Unmount"))
function unmount.cfgvalue(self, section)
return non_system_mounts[section].umount
end
unmount.render = function(self, section, scope)
if non_system_mounts[section].umount then
self.title = translate("Unmount")
self.inputstyle = "remove"
Button.render(self, section, scope)
else
luci.http.write("&#160;")
end
end
unmount.write = function(self, section)