about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--uploader/phenotypes/views.py8
-rw-r--r--uploader/templates/phenotypes/confirm-delete-phenotypes.html6
2 files changed, 10 insertions, 4 deletions
diff --git a/uploader/phenotypes/views.py b/uploader/phenotypes/views.py
index 9b635e2..549412b 100644
--- a/uploader/phenotypes/views.py
+++ b/uploader/phenotypes/views.py
@@ -1260,10 +1260,14 @@ def delete_phenotypes(# pylint: disable=[unused-argument]
                         loglevel=_loglevel)
                 ).either(__handle_error__, proceed_to_job_status)
             case _:
+                _phenos = tuple()
+                if len(xref_ids) > 0:
+                    _phenos = dataset_phenotypes(
+                        conn, population["Id"], dataset["Id"], xref_ids=xref_ids)
+
                 return render_template(
                     "phenotypes/confirm-delete-phenotypes.html",
                     species=species,
                     population=population,
                     dataset=dataset,
-                    phenotypes=[{"xref_id": xref_id}
-                                for xref_id in xref_ids])
+                    phenotypes=_phenos)
diff --git a/uploader/templates/phenotypes/confirm-delete-phenotypes.html b/uploader/templates/phenotypes/confirm-delete-phenotypes.html
index 3b16698..e6d67c7 100644
--- a/uploader/templates/phenotypes/confirm-delete-phenotypes.html
+++ b/uploader/templates/phenotypes/confirm-delete-phenotypes.html
@@ -62,8 +62,10 @@
                  value="{{phenotype.xref_id}}"
                  class="chk-row-select" />
         </td>
-        <td>{{phenotype}}</td>
-        <td>{{phenotype}} — Description</td>
+        <td>{{phenotype.xref_id}}</td>
+        <td>{{phenotype.Post_publication_description or
+          phenotype.Pre_publication_description or
+          phenotype.original_description}}</td>
       </tr>
       {%endfor%}
     </tbody>