-
-
Notifications
You must be signed in to change notification settings - Fork 191
Expand file tree
/
Copy pathproject_summary_level.html
More file actions
101 lines (101 loc) · 4.29 KB
/
project_summary_level.html
File metadata and controls
101 lines (101 loc) · 4.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
{% load humanize %}
<nav class="level mx-5 mb-3">
{% url 'project_packages' project.slug as project_packages_url %}
<div class="level-item has-text-centered">
<div>
<p class="heading">
<a href="{{ project_packages_url }}">
Packages
</a>
</p>
<p class="title is-flex is-align-items-center is-justify-content-center">
{% if project.package_count %}
<a href="{{ project_packages_url }}">
{{ project.package_count|intcomma }}
</a>
{% if project.vulnerable_package_count %}
<a href="{{ project_packages_url }}?is_vulnerable=yes" class="has-text-danger is-size-5 ml-3">
<i class="fa-solid fa-bug is-size-6"></i>
{{ project.vulnerable_package_count|intcomma }}
</a>
{% endif %}
{% if project.package_compliance_alert_count %}
<a href="{% url 'project_packages' project.slug %}?compliance_alert=error" class="has-text-danger is-size-5 ml-2">
{{ project.package_compliance_alert_count|intcomma }}
<i class="fa-solid fa-scale-balanced is-size-6"></i>
</a>
{% endif %}
{% else %}
<span class="has-text-grey">0</span>
{% endif %}
</p>
</div>
</div>
{% url 'project_dependencies' project.slug as project_dependencies_url %}
<div class="level-item has-text-centered">
<div>
<p class="heading">
<a href="{{ project_dependencies_url }}">
Dependencies
</a>
</p>
<p class="title is-flex is-align-items-center is-justify-content-center">
{% if project.dependency_count %}
<a href="{{ project_dependencies_url }}">
{{ project.dependency_count|intcomma }}
</a>
{% if project.vulnerable_dependency_count %}
<a href="{{ project_dependencies_url }}?is_vulnerable=yes" class="has-text-danger is-size-5 ml-3">
<i class="fa-solid fa-bug is-size-6"></i>
{{ project.vulnerable_dependency_count|intcomma }}
</a>
{% endif %}
<a href="{% url 'project_dependency_tree' project.slug %}" class="ml-2">
<span class="icon">
<i class="fa-solid fa-sitemap is-size-6"></i>
</span>
</a>
{% else %}
<span>0</span>
{% endif %}
</p>
</div>
</div>
<div class="level-item has-text-centered">
<div>
<p class="heading"><a href="{% url 'project_resources' project.slug %}">Resources</a></p>
<p class="title is-flex is-align-items-center is-justify-content-center">
{% if project.resource_count %}
<a href="{{ project_resources_url }}">
{{ project.resource_count|intcomma }}
</a>
{% if project.resource_count > 1 %}
<a href="{% url 'project_resource_tree' project.slug %}" class="ml-2">
<span class="icon">
<i class="fa-solid fa-folder-tree is-size-6"></i>
</span>
</a>
{% endif %}
{% if project.resource_compliance_alert_count %}
<a href="{% url 'project_resources' project.slug %}?compliance_alert=error" class="has-text-danger is-size-5 ml-2">
{{ project.resource_compliance_alert_count|intcomma }}
<i class="fa-solid fa-scale-balanced is-size-6"></i>
</a>
{% endif %}
{% else %}
<span class="has-text-grey">0</span>
{% endif %}
</p>
</div>
</div>
{% if project.relation_count %}
{% url 'project_relations' project.slug as project_relations_url %}
{% include "scanpipe/includes/project_summary_level_item.html" with label="Relations" count=project.relation_count url=project_relations_url only %}
{% endif %}
{% url 'project_messages' project.slug as project_messages_url %}
{% include "scanpipe/includes/project_summary_level_item.html" with label="Messages" count=project.message_count url=project_messages_url only %}
{% if project.vulnerability_count %}
{% url 'project_vulnerabilities' project.slug as project_vulnerabilities_url %}
{% include "scanpipe/includes/project_summary_level_item.html" with label="Vulnerabilities" count=project.vulnerability_count url=project_vulnerabilities_url only %}
{% endif %}
</nav>