add error for username/email containing html. Removed checks for SMILES/SMARTS. Updated html to use the nh_safe template tag. #72

This commit is contained in:
Liam Brydon
2025-10-22 10:47:35 +13:00
parent 61346c4097
commit ec0fc8cdc1
44 changed files with 168 additions and 125 deletions

View File

@ -1,4 +1,5 @@
{% extends "framework.html" %}
{% load envipytags %}
{% block content %}
@ -12,7 +13,7 @@
<div class="panel-group" id="edge-detail">
<div class="panel panel-default">
<div class="panel-heading" id="headingPanel" style="font-size:2rem;height: 46px">
{{ edge.edge_label.name }}
{{ edge.edge_label.name|nh_safe }}
<div id="actionsButton"
style="float: right;font-weight: normal;font-size: medium;position: relative; top: 50%; transform: translateY(-50%);z-index:100;display: none;"
class="dropdown"><a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
@ -36,7 +37,7 @@
</div>
<div id="edge-desc" class="panel-collapse collapse in">
<div class="panel-body list-group-item">
{{ edge.description }}
{{ edge.description|nh_safe }}
</div>
</div>
@ -82,12 +83,12 @@
<div id="edge-description-smiles" class="panel-collapse collapse in">
<div class="panel-body list-group-item">
{% for educt in edge.start_nodes.all %}
<a class="btn btn-default" href="{{ educt.url }}">{{ educt.name }}</a>
<a class="btn btn-default" href="{{ educt.url }}">{{ educt.name|nh_safe }}</a>
{% endfor %}
<span class="glyphicon glyphicon-arrow-right" style="margin-left:5em;margin-right:5em;"
aria-hidden="true"></span>
{% for product in edge.end_nodes.all %}
<a class="btn btn-default" href="{{ product.url }}">{{ product.name }}</a>
<a class="btn btn-default" href="{{ product.url }}">{{ product.name|nh_safe }}</a>
{% endfor %}
</div>
</div>
@ -116,7 +117,7 @@
<div id="edge-rules" class="panel-collapse collapse in">
<div class="panel-body list-group-item">
{% for r in edge.edge_label.rules.all %}
<a class="list-group-item" href="{{ r.url }}">{{ r.name }}</a>
<a class="list-group-item" href="{{ r.url }}">{{ r.name|nh_safe }}</a>
{% endfor %}
</div>
</div>
@ -132,7 +133,7 @@
<div id="edge-scenario" class="panel-collapse collapse in">
<div class="panel-body list-group-item">
{% for s in edge.scenarios.all %}
<a class="list-group-item" href="{{ s.url }}">{{ s.name }} <i>({{ s.package.name }})</i></a>
<a class="list-group-item" href="{{ s.url }}">{{ s.name|nh_safe }} <i>({{ s.package.name|nh_safe }})</i></a>
{% endfor %}
</div>
</div>