diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-08-06 09:10:42 +0200 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-08-06 09:10:42 +0200 |
commit | 7e91c6a59858325593093c046c213c6bd4e7e4f3 (patch) | |
tree | 0a5765a048fd3910caf2fc396d113ef2ef5ea753 /gui/api | |
parent | 08705c0399240f984cf54294a369cb3a896e089a (diff) | |
download | dabmod-7e91c6a59858325593093c046c213c6bd4e7e4f3.tar.gz dabmod-7e91c6a59858325593093c046c213c6bd4e7e4f3.tar.bz2 dabmod-7e91c6a59858325593093c046c213c6bd4e7e4f3.zip |
Some GUI changes
Diffstat (limited to 'gui/api')
-rwxr-xr-x | gui/api/__init__.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gui/api/__init__.py b/gui/api/__init__.py index 959dedc..6c04a64 100755 --- a/gui/api/__init__.py +++ b/gui/api/__init__.py @@ -71,3 +71,8 @@ class API: cherrypy.response.headers["Content-Type"] = "text/plain" cherrypy.response.status = 400 return "POST only" + + @cherrypy.expose + def dpd_status(self, **kwargs): + cherrypy.response.headers["Content-Type"] = "application/json" + return json.dumps(self.dpd.status()).encode() |