--- Copyright 2017 Dirk Brenken (dev@brenken.org)
+-- Copyright 2017-2018 Dirk Brenken (dev@brenken.org)
-- This is free software, licensed under the Apache License, Version 2.0
module("luci.controller.travelmate", package.seeall)
local logfile
if nixio.fs.access("/var/log/messages") then
- logfile = util.trim(util.exec("cat /var/log/messages | grep 'travelmate'"))
+ logfile = util.trim(util.exec("cat /var/log/messages | grep 'travelmate-'"))
else
- logfile = util.trim(util.exec("logread -e 'travelmate'"))
+ logfile = util.trim(util.exec("logread -e 'travelmate-'"))
end
templ.render("travelmate/logread", {title = i18n.translate("Travelmate Logfile"), content = logfile})
end
--- Copyright 2017 Dirk Brenken (dev@brenken.org)
+-- Copyright 2017-2018 Dirk Brenken (dev@brenken.org)
-- This is free software, licensed under the Apache License, Version 2.0
local fs = require("nixio.fs")
wssid = m:field(Value, "ssid", translate("SSID (hidden)"))
end
+nobssid = m:field(Flag, "no_bssid", translate("Ignore BSSID"))
+nobssid.default = nobssid.enabled
+
bssid = m:field(Value, "bssid", translate("BSSID"))
+bssid:depends("no_bssid", 0)
bssid.datatype = "macaddr"
bssid.default = m.hidden.bssid or ""
<%#
-Copyright 2017 Dirk Brenken (dev@brenken.org)
+Copyright 2017-2018 Dirk Brenken (dev@brenken.org)
This is free software, licensed under the Apache License, Version 2.0
-%>
</fieldset>
</div>
+<script type="text/javascript">
+ var textarea = document.getElementById('logread_id');
+ textarea.scrollTop = textarea.scrollHeight;
+</script>
+
<%+footer%>