aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBonfaceKilz2021-07-29 23:12:51 +0300
committerBonfaceKilz2021-08-03 15:49:50 +0300
commit52d53eb90aa0a4fbaab713704f4894e652cb91f3 (patch)
treec119826d1f88a92820b7d8300bbd407732d7c949
parentcf278e6c119871d08f68c13e07b190b8c14e0414 (diff)
downloadgenenetwork2-52d53eb90aa0a4fbaab713704f4894e652cb91f3.tar.gz
wqflask: views: Filter out approved/ rejected files during display
* wqflask/wqflask/views.py (approve_data): Only show files that have not been approved/ rejected.
-rw-r--r--wqflask/wqflask/views.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/wqflask/wqflask/views.py b/wqflask/wqflask/views.py
index 4746fcc2..9a961f26 100644
--- a/wqflask/wqflask/views.py
+++ b/wqflask/wqflask/views.py
@@ -1383,8 +1383,9 @@ def display_diffs_admin():
DIFF_DIR = "/tmp/sample-data/diffs"
files = []
if os.path.exists(DIFF_DIR):
+ files = os.listdir(DIFF_DIR)
files = filter(lambda x: not(x.endswith((".approved", ".rejected"))),
- os.listdir(DIFF_DIR))
+ files)
return render_template("display_files.html",
files=files)