summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua
diff options
context:
space:
mode:
authorHannu Nyman <hannu.nyman@iki.fi>2018-01-10 23:45:50 +0200
committerGitHub <noreply@github.com>2018-01-10 23:45:50 +0200
commit8b39d9a76b6efcf618fe3ca527ca3e593deacaf0 (patch)
tree1ed622676efa38d23dae9c99a571b474f0520472 /applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua
parent5d0f0b997df1dba7652b4a8ee425f947b262c651 (diff)
parent2b200cfa792ab159247243dc2d7e961c10cb1a4d (diff)
Merge pull request #1524 from dibdot/travelmate
luci-app-travelmate: sync with travelmate 1.0.2
Diffstat (limited to 'applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua')
-rw-r--r--applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua14
1 files changed, 9 insertions, 5 deletions
diff --git a/applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua b/applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua
index e715a2ba0..1ea2d6672 100644
--- a/applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua
+++ b/applications/luci-app-travelmate/luasrc/model/cbi/travelmate/overview_tab.lua
@@ -1,4 +1,4 @@
--- 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")
@@ -113,17 +113,21 @@ end
ds = m:section(NamedSection, "global", "travelmate", translate("Runtime Information"))
-dv1 = ds:option(DummyValue, "status", translate("Online Status"))
+dv1 = ds:option(DummyValue, "status", translate("Travelmate Status"))
dv1.template = "travelmate/runtime"
if parse == nil then
dv1.value = translate("n/a")
-elseif parse.data.station_connection == "true" then
+elseif parse.data.travelmate_status == "connected" then
dv1.value = translate("connected")
-else
+elseif parse.data.travelmate_status == "not connected" then
dv1.value = translate("not connected")
+elseif parse.data.travelmate_status == "running" then
+ dv1.value = translate("running")
+elseif parse.data.travelmate_status == "error" then
+ dv1.value = translate("error")
end
-dv2 = ds:option(DummyValue, "travelmate_version", translate("Travelmate version"))
+dv2 = ds:option(DummyValue, "travelmate_version", translate("Travelmate Version"))
dv2.template = "travelmate/runtime"
if parse ~= nil then
dv2.value = parse.data.travelmate_version or translate("n/a")