From 81cc612e695faee60e9ea4458ed004a643472bf5 Mon Sep 17 00:00:00 2001 From: jebus Date: Fri, 6 Mar 2026 03:15:44 +1300 Subject: [PATCH] [Feature] Populate Batch Predict Table by CSV (#339) Co-authored-by: Tim Lorsbach Reviewed-on: https://git.envipath.com/enviPath/enviPy/pulls/339 --- epdb/views.py | 2 +- templates/batch_predict_pathway.html | 179 ++++++++++++++++++++++++++- 2 files changed, 174 insertions(+), 7 deletions(-) diff --git a/epdb/views.py b/epdb/views.py index 56884492..0cf559a2 100644 --- a/epdb/views.py +++ b/epdb/views.py @@ -2967,7 +2967,7 @@ def jobs(request): raise BadRequest(f"Couldn't standardize SMILES {parts[0]}!") # name is optional - name = parts[1] if len(parts) > 1 else None + name = ",".join(parts[1:]) if len(parts) > 1 else None pred_data.append([smiles, name]) max_tps = 50 diff --git a/templates/batch_predict_pathway.html b/templates/batch_predict_pathway.html index b9e5412c..ed9f351c 100644 --- a/templates/batch_predict_pathway.html +++ b/templates/batch_predict_pathway.html @@ -9,6 +9,39 @@
+ +
+
+
+
+

+ Load from CSV +

+

+ Upload a CSV file with SMILES and name columns, or insert + manually in the table below +

+
+
+ +
+
+
+ Format: First column = SMILES, Second column = + Name (headers optional) • Maximum 30 rows +
+
+
+ @@ -113,10 +146,16 @@