diff options
Diffstat (limited to 'cgi')
-rw-r--r-- | cgi/modapi.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cgi/modapi.py b/cgi/modapi.py index 82770ec..00b4beb 100644 --- a/cgi/modapi.py +++ b/cgi/modapi.py @@ -60,6 +60,11 @@ def api_process(self, path_split): news = FetchAll( "SELECT * FROM `news` WHERE type = 1 ORDER BY `timestamp` DESC") values['news'] = news + elif method == 'reports': + reports = FetchAll( + "SELECT * FROM `reports` ORDER BY `timestamp` DESC") + values['reports'] = reports + values['keys'] = reports[0].keys() elif method == 'login': # testing username = formdata.get('username') |