diff options
author | Andrea Lepori <alepori@student.ethz.ch> | 2020-07-30 12:33:01 +0200 |
---|---|---|
committer | Andrea Lepori <alepori@student.ethz.ch> | 2020-07-30 12:33:01 +0200 |
commit | f3fb72eee5a6ffe94990d4d97c1e9aed35575433 (patch) | |
tree | 2750bc8b8c16bb8e67742e81b7c25ca2f67153b7 /server/views.py | |
parent | squash migrations (diff) | |
download | scout-subs-f3fb72eee5a6ffe94990d4d97c1e9aed35575433.tar.gz scout-subs-f3fb72eee5a6ffe94990d4d97c1e9aed35575433.zip |
block debug actions and confirm for approve doc
Diffstat (limited to 'server/views.py')
-rw-r--r-- | server/views.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/views.py b/server/views.py index b230d51..c23e8c8 100644 --- a/server/views.py +++ b/server/views.py @@ -455,9 +455,9 @@ def doclist(request): selected.append(docc) for i in selected: - if request.POST["action"] == 'delete': + if request.POST["action"] == 'delete' and settings.DEBUG: i.delete() - elif request.POST["action"] == 'approve': + elif request.POST["action"] == 'approve' and settings.DEBUG: i.status = 'ok' i.save() elif request.POST["action"] == 'archive': |