diff options
Diffstat (limited to 'ppp-model.lua')
-rw-r--r-- | ppp-model.lua | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/ppp-model.lua b/ppp-model.lua index 0260533..31f7365 100644 --- a/ppp-model.lua +++ b/ppp-model.lua @@ -31,8 +31,14 @@ function getstatus() errtxt=errtxt, name=packagename }) - - status.status = modelfunctions.getenabled(processname) + + status.status = cfe({ label = "Program status", name=processname }) + local t = processinfo.pidof(processname) + if (t) and (#t > 0) then + status.status.value = "Started" + else + status.status.value = "Stopped" + end return cfe({ type="group", value=status, label="PPP Status" }) end |