From: Diane Trout Date: Thu, 15 Sep 2016 00:00:31 +0000 (-0700) Subject: Report no data found when collections empty X-Git-Url: http://woldlab.caltech.edu/gitweb/?p=htsworkflow.git;a=commitdiff_plain;h=0edfb2f68d4b568814ed2f109e33bd00b8830671 Report no data found when collections empty The xhtml validator caught a few cases where empty data generated some invalid html because some table or list bodies were missing. I thought it reasonable to include a message that nothing was found instead of leaving the table blank. --- diff --git a/htsworkflow/templates/sample_header.html b/htsworkflow/templates/sample_header.html index 651349f..ed9f8b1 100644 --- a/htsworkflow/templates/sample_header.html +++ b/htsworkflow/templates/sample_header.html @@ -17,6 +17,8 @@
  • {{ individual.name }} ( {{ individual.contact }} )
  • + {% empty %} +
  • None
  • {% endfor %} {% if lib.libraryaccession_set %} diff --git a/htsworkflow/templates/samples/library_detail.html b/htsworkflow/templates/samples/library_detail.html index 65747dc..4966393 100644 --- a/htsworkflow/templates/samples/library_detail.html +++ b/htsworkflow/templates/samples/library_detail.html @@ -131,7 +131,6 @@ Comment - {% if lib.lane_set.all %} {% for lane in lib.lane_set.all %} {{ lane.comment }} - {% endfor %} + {% empty %} + No data + {% endfor %} - {% endif %}

    diff --git a/htsworkflow/templates/samples/library_index.html b/htsworkflow/templates/samples/library_index.html index 4491a09..9884483 100644 --- a/htsworkflow/templates/samples/library_index.html +++ b/htsworkflow/templates/samples/library_index.html @@ -105,6 +105,8 @@ {% endif %} + {% empty %} + No results found {% endfor %}