Skip to content

Commit

Permalink
[#1117] Wrap validation tables in panels
Browse files Browse the repository at this point in the history
  • Loading branch information
Bjwebb committed Feb 27, 2019
1 parent e7f3399 commit d974282
Showing 1 changed file with 35 additions and 8 deletions.
43 changes: 35 additions & 8 deletions cove_360/templates/cove_360/explore.html
Original file line number Diff line number Diff line change
Expand Up @@ -149,22 +149,49 @@ <h3 class="panel-title panel-title-explore">
{% endif %}
<a href="http://www.threesixtygiving.org/standard/reference/#toc-360giving-json-schemas"> 360Giving JSON Package Schema</a>.
</p>
<div class="explore-help">Validation ensures that your data is compliant with the basic requirements of the <a href="http://www.threesixtygiving.org/standard/">360Giving Standard</a>. If your data validates then it can be used by any user or application who knows how to work with 360Giving data.</div>
<div class="explore-help">Validation ensures that your data is compliant with the basic requirements of the <a href="http://www.threesixtygiving.org/standard/">360Giving Standard</a>. If your data validates then it can be used by any user or application who knows how to work with 360Giving data.</diV>
{% if validation_errors %}
<br>
<p class="explanation">&nbsp;{% trans "There are some <strong>validation errors</strong> in your data, please check them in the table below." %}</p>
<p class="explanation">&nbsp;{% trans "There are some <strong>validation errors</strong> in your data, please check them in the table(s) below." %}</p>
<br>
<h4>Missing Fields</h4>
{% with validation_errors=validation_errors_grouped.required %}
{% include "validation_table.html" %}
{% if validation_errors %}
<div class="panel panel-default">
<div class="panel-heading">
<h4>Missing Fields</h4>
</div>
<div id="validation-body">
<p>Some or all of your entries were missing fields which are required by the 360Giving Standard.</p>
{% include "validation_table.html" %}
</div>
</div>
{% endif %}
{% endwith %}
<h4>Incorrect Formats</h4>
{% with validation_errors=validation_errors_grouped.format %}
{% include "validation_table.html" %}
{% if validation_errors %}
<div class="panel panel-default">
<div class="panel-heading">
<h4>Incorrect Formats</h4>
</div>
<div id="validation-body">
<p>Some or all of your entries have incorrectly formatted data.</p>
{% include "validation_table.html" %}
</div>
</div>
{% endif %}
{% endwith %}
<h4>Other</h4>
{% with validation_errors=validation_errors_grouped.other %}
{% include "validation_table.html" %}
{% if validation_errors %}
<div class="panel panel-default">
<div class="panel-heading">
<h4>Other</h4>
</div>
<div id="validation-body">
<p>Other validation errrors.</p>
{% include "validation_table.html" %}
</div>
</div>
{% endif %}
{% endwith %}
{% endif %}
</div>
Expand Down

0 comments on commit d974282

Please sign in to comment.