Skip to content

Commit

Permalink
Migrate new incident button to a link, replace inline clear:both
Browse files Browse the repository at this point in the history
  • Loading branch information
Augustin-FL committed Dec 28, 2024
1 parent 7931562 commit 3de99e3
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 36 deletions.
2 changes: 1 addition & 1 deletion fir_todos/templates/fir_todos/plugins/followup_main.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% load i18n %}
<div id='fir_todos' data-url="{% url 'todos:list' incident.id %}">
<h2>{% trans "To-Do List" %}</h2>
<br style='clear:both'/>
<br class="separator" />
<div id='fir_todos_followup'>
{% trans "Loading ..." %}
</div>
Expand Down
4 changes: 2 additions & 2 deletions incidents/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@
{% if request.session.can_report_event %}
<li class="nav-item">
<div class="btn-group navbar-btn">
<button class="btn btn-outline-danger" onclick="javascript:location.href='{% url 'events:new' %}'">
<a class="btn btn-outline-danger" href="{% url 'events:new' %}">
{% trans "New event" %} <span class="bi bi-fire"></span>
</button>
</a>
{% if request.session.has_incident_templates %}
<button type="button" class="btn btn-outline-danger dropdown-toggle" data-bs-toggle="dropdown">
<span class="caret"></span>
Expand Down
10 changes: 5 additions & 5 deletions incidents/templates/incidents/followup.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@

<div class='header'>
<img src="{% static "img/logo.jpg" %}" />
<br style='clear:both' />
<br class="separator" />
<div class='title'>
<h1 class='float'>{% if incident.is_incident %}{% trans "Incident followup" %}{%else%}{% trans "Event followup" %}{%endif%} [C{{incident.confidentiality}}] [{{incident.category}}] - {{incident.subject}}</h1>
<br style='clear:both' />
<br class="separator" />
{% trans "someone" as someone %}
<p>{% blocktrans with date=incident.date opened_by=incident.opened_by|default:someone %}Opened on {{ date }} by {{ opened_by }}{% endblocktrans %}</p>
</div>
Expand All @@ -43,15 +43,15 @@ <h1 class='float'>{% if incident.is_incident %}{% trans "Incident followup" %}{%
</table>


<br style='clear:both' />
<br class="separator" />


<div class='description'>
<h3>{% trans "Summary" %}</h3>
<p class='artifacts'>{{ incident.description|markdown }}</p>
</div>

<br style='clear:both' />
<br class="separator" />

<h2>{% trans "Incident timeline" %} ({{ incident.comments_set.count }})</h2>

Expand Down Expand Up @@ -80,7 +80,7 @@ <h2>{% trans "Incident timeline" %} ({{ incident.comments_set.count }})</h2>
<div class='files'>

<h2>{% trans "Related files" %}</h2>
<br style='clear:both'/>
<br class="separator" />
{%if incident.file_set.count > 0 %}
<table class='table table-condensed files' style='width:auto'>
{% for file in incident.file_set.all %}
Expand Down
4 changes: 2 additions & 2 deletions incidents/templates/stats/quarterly.html
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@ <h4>{% trans "Incident Management by incident leader (Business Line or CERT)" %}
</div>
</div>

<p class='separator' style='clear:both'>&nbsp;</p>
<br style='clear:both' />
<p class="separator">&nbsp;</p>
<br class="separator" />

<div style='float:left'>
<h4>{% trans "Monitored domains" %}</h4><br />
Expand Down
25 changes: 12 additions & 13 deletions incidents/templates/stats/sandbox.html
Original file line number Diff line number Diff line change
Expand Up @@ -290,23 +290,23 @@ <h1>{% trans "Sandbox" %}</h1>

</form>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "Overlapping years" %}</h4>
<div class='graph' id="incidents_evolution">
</div>
</div>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% blocktrans %}By category <span class='smaller'>comparison</span>{% endblocktrans %}</h4>
<div class='graph' id="incidents_evolution_by_category">
</div>
</div>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "By category" %}</h4>
Expand All @@ -316,15 +316,15 @@ <h4>{% trans "By category" %}</h4>
</div>
</div>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "By month" %}</h4>
<div class='graph' id="by_month">
</div>
</div>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "By subentity" %}</h4>
Expand All @@ -335,8 +335,7 @@ <h4>{% trans "By subentity" %}</h4>
</div>



<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "By severity" %}</h4>
Expand All @@ -346,7 +345,7 @@ <h4>{% trans "By severity" %}</h4>
</div>
</div>

<br style='clear:both'>
<br class="separator" />

<div class='graph'>
<h4>{% trans "By Incident Leader" %}</h4>
Expand All @@ -356,31 +355,31 @@ <h4>{% trans "By Incident Leader" %}</h4>
</div>
</div>

<br style='clear:both' />
<br class="separator" />

<div class='graph'>
<h4>{% trans "Monitored domains" %}</h4>
<div class='graph' id="monitoring">
</div>
</div>

<br style='clear:both' />
<br class="separator" />

<div class='graph'>
<h4>{% trans "Open incidents" %}</h4>
<div class='graph' id="open">
</div>
</div>

<br style='clear:both' />
<br class="separator" />

<div class='graph'>
<h4>{% trans "Blocked incidents" %}</h4>
<div class='graph' id="blocked">
</div>
</div>

<br style='clear:both' />
<br class="separator" />

<h2>{% trans "Matching incidents" %}</h2>
<div>Export to <a download="incidents.tsv" class="export-link" href="#" data-table="incident_table">TSV</a> or <a download="incidents.csv" class="export-link" href="#" data-table="incident_table" data-delimiter=",">CSV</a></div><br />
Expand All @@ -403,5 +402,5 @@ <h2>{% trans "Matching incidents" %}</h2>
</tr>
</thead>
</table>
<br style='clear:both' />
<br class="separator" />
{% endblock %}
21 changes: 10 additions & 11 deletions incidents/templates/stats/yearly.html
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ <h1>{% trans "Yearly stats" %}</h1>
}

.separator {
clear:both;
margin:30px 0 30px 0;
}

Expand Down Expand Up @@ -97,7 +96,7 @@ <h4>{% trans "Entire Group - by severity" %}</h4>
</div>


<p class='separator'>&nbsp;</p>
<p class="separator">&nbsp;</p>

<div class='graph'>
<h4>{% trans "Business Line by detection" %}</h4>
Expand All @@ -111,25 +110,25 @@ <h4>{% trans "Incidents by business line" %}</h4>
</div>
</div>

<p class='separator'>&nbsp;</p>
<p class="separator">&nbsp;</p>

<div class='graph'>
<h4>{% trans "Business Line by incident severity" %}</h4>
<div class='graph' id="bl_severity" style='clear:both'></div>
<div class='graph' id="bl_severity_bar"></div>
<div class="graph separator" id="bl_severity"></div>
<div class="graph" id="bl_severity_bar"></div>
</div>

<p class='separator'>&nbsp;</p>
<p class="separator">&nbsp;</p>
<div class='graph'>
<h4>{% trans "Business Line incident category" %}</h4>
<div class='graph' id="bl_category" style='clear:both'></div>
<div class='graph' id="bl_category_bar"></div>
<div class="graph separator" id="bl_category"></div>
<div class="graph" id="bl_category_bar"></div>
</div>

<br style='clear:both' />
<br class="separator" />

<br style='clear:both' />
<br style='clear:both' />
<br class="separator" />
<br class="separator" />

<script>

Expand Down
4 changes: 2 additions & 2 deletions incidents/templates/stats/yearly_compare.html
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ <h4>{% trans "Events by business line" %} ({{year}})</h4>
</div>


<br style='clear:both' />
<br style='clear:both' />
<br class="separator" />
<br class="separator" />

<script>

Expand Down

0 comments on commit 3de99e3

Please sign in to comment.