|
4 | 4 | {% block dashboard_nav %} |
5 | 5 | <div class="u-bg-secondary u-spacer-bottom-double py-3"> |
6 | 6 | <div class="container"> |
7 | | - <nav class="breadcrumbs" aria-label="{% translate 'breadcrumbs' %}"> |
| 7 | + <nav class="breadcrumbs" aria-label="{% translate "breadcrumbs" %}"> |
8 | 8 | <ul> |
9 | 9 | <li> |
10 | 10 | <a href="{% url 'a4dashboard:project-list' organisation_slug=view.organisation.slug %}"> |
11 | 11 | <i class="fa fa-arrow-left" aria-hidden="true"></i> |
12 | | - {% translate 'All projects' %} |
| 12 | + {% translate "All projects" %} |
13 | 13 | </a> |
14 | 14 | </li> |
15 | 15 | </ul> |
16 | 16 | </nav> |
17 | 17 | </div> |
18 | 18 | </div> |
19 | | -{% endblock %} |
| 19 | +{% endblock dashboard_nav %} |
20 | 20 |
|
21 | 21 | {% block dashboard_content %} |
22 | 22 | {% closed_accordions project.id as closed_accordions %} |
23 | 23 | <div class="row"> |
24 | | - <nav class="col-md-3 js-selector-update-dashboard" aria-label="{% translate 'Project Settings' %}"> |
| 24 | + <nav class="col-md-3 js-selector-update-dashboard" aria-label="{% translate "Project Settings" %}"> |
25 | 25 | <div class="dashboard-nav"> |
26 | 26 | <div |
27 | 27 | class="dashboard-nav__dropdown{% if project.id in closed_accordions.0 %} collapsed{% endif %}" |
|
33 | 33 | data-bs-target="#dashboardCollapseProj" |
34 | 34 | > |
35 | 35 | {% if project_progress.project_is_complete %} |
36 | | - <i class="fas fa-check-circle text-info" title="{% translate 'Project ready for publication' %}" aria-label="{% translate 'Project ready for publication' %}"></i> |
| 36 | + <i class="fas fa-check-circle text-info" title="{% translate "Project ready for publication" %}" aria-label="{% translate "Project ready for publication" %}"></i> |
37 | 37 | {% else %} |
38 | | - <i class="fas fa-exclamation-circle text-danger" title="{% translate 'Project not ready for publication' %}" aria-label="{% translate 'Project not ready for publication' %}"></i> |
| 38 | + <i class="fas fa-exclamation-circle text-danger" title="{% translate "Project not ready for publication" %}" aria-label="{% translate "Project not ready for publication" %}"></i> |
39 | 39 | {% endif %} |
40 | 40 | {{ project.name }} |
41 | 41 | <i class="fa fa-chevron-up" aria-hidden="true"></i> |
42 | 42 | </div> |
43 | 43 | <ul class="dashboard-nav__pages collapse{% if not project.id in closed_accordions.0 %} show{% endif %}" id="dashboardCollapseProj" aria-hidden="false"> |
44 | 44 | {% for item in dashboard_menu.project %} |
45 | | - <li class="dashboard-nav__page"> |
46 | | - <a href="{{ item.url }}" |
47 | | - class="dashboard-nav__item dashboard-nav__item--interactive {{ item.is_active|yesno:"is-active," }}"> |
48 | | - {% if not item.is_complete %} |
49 | | - <i class="fa fa-exclamation-circle text-danger" title="{% translate 'Missing fields for publication' %}" aria-label="{% translate 'Missing fields for publication' %}"></i> |
50 | | - {% endif %} |
51 | | - {{ item.label }} |
52 | | - </a> |
53 | | - </li> |
| 45 | + {% if item.label != "Location" %} |
| 46 | + <li class="dashboard-nav__page"> |
| 47 | + <a href="{{ item.url }}" |
| 48 | + class="dashboard-nav__item dashboard-nav__item--interactive {{ item.is_active|yesno:"is-active," }}"> |
| 49 | + {% if not item.is_complete %} |
| 50 | + <i class="fa fa-exclamation-circle text-danger" title="{% translate "Missing fields for publication" %}" aria-label="{% translate "Missing fields for publication" %}"></i> |
| 51 | + {% endif %} |
| 52 | + {{ item.label }} |
| 53 | + </a> |
| 54 | + </li> |
| 55 | + {% else %} |
| 56 | + {% if project.organisation.enable_geolocation %} |
| 57 | + <li class="dashboard-nav__page"> |
| 58 | + <a href="{{ item.url }}" |
| 59 | + class="dashboard-nav__item dashboard-nav__item--interactive {{ item.is_active|yesno:"is-active," }}"> |
| 60 | + {% if not item.is_complete %} |
| 61 | + <i class="fa fa-exclamation-circle text-danger" title="{% translate "Missing fields for publication" %}" aria-label="{% translate "Missing fields for publication" %}"></i> |
| 62 | + {% endif %} |
| 63 | + {{ item.label }} |
| 64 | + </a> |
| 65 | + </li> |
| 66 | + {% endif %} |
| 67 | + {% endif %} |
54 | 68 | {% endfor %} |
55 | 69 | </ul> |
56 | 70 | </div> |
|
67 | 81 | <form enctype="multipart/form-data" action="{% url 'a4dashboard:module-delete' slug=module_menu.module.slug organisation_slug=project.organisation.slug %}" method="post"> |
68 | 82 | {% csrf_token %} |
69 | 83 | <input type="hidden" name="referrer" value="{{ request.path }}" /> |
70 | | - <button type="submit" class="btn btn--none" value="{% translate 'Delete' %}"> |
71 | | - {% translate 'Delete' %} |
| 84 | + <button type="submit" class="btn btn--none" value="{% translate "Delete" %}"> |
| 85 | + {% translate "Delete" %} |
72 | 86 | </button> |
73 | 87 | </form> |
74 | 88 | </a> |
|
86 | 100 | data-bs-target="#dashboardCollapse_{{ forloop.counter }}" |
87 | 101 | > |
88 | 102 | {% if module_menu.is_complete %} |
89 | | - <i class="fas fa-check-circle text-info" title="{% translate 'Module ready for addition' %}" aria-label="{% translate 'Module ready for addition' %}"></i> |
| 103 | + <i class="fas fa-check-circle text-info" title="{% translate "Module ready for addition" %}" aria-label="{% translate "Module ready for addition" %}"></i> |
90 | 104 | {% else %} |
91 | | - <i class="fas fa-exclamation-circle text-danger" title="{% translate 'Module not ready for addition' %}" aria-label="{% translate 'Module not ready for addition' %}"></i> |
| 105 | + <i class="fas fa-exclamation-circle text-danger" title="{% translate "Module not ready for addition" %}" aria-label="{% translate "Module not ready for addition" %}"></i> |
92 | 106 | {% endif %} |
93 | 107 | {{ module_menu.module.name }} |
94 | 108 | <i class="fa fa-chevron-up {% if module_menu.module.is_draft %}dashboard-nav-i-spacer{% endif %}" aria-hidden="true"></i> |
|
100 | 114 | <a href="{{ item.url }}" |
101 | 115 | class="dashboard-nav__item dashboard-nav__item--interactive {{ item.is_active|yesno:"is-active," }}"> |
102 | 116 | {% if not item.is_complete %} |
103 | | - <i class="fa fa-exclamation-circle text-danger" title="{% translate 'Missing fields for publication' %}" aria-label="{% translate 'Missing fields for publication' %}"></i> |
| 117 | + <i class="fa fa-exclamation-circle text-danger" title="{% translate "Missing fields for publication" %}" aria-label="{% translate "Missing fields for publication" %}"></i> |
104 | 118 | {% endif %} |
105 | 119 | {{ item.label }} |
106 | 120 | </a> |
|
129 | 143 | checked |
130 | 144 | {% if not project.is_draft %}disabled{% endif %}> |
131 | 145 | <label class="form-check-label dashboard-nav__toggle-label" for="dashboardToggle_{{ forloop.counter }}"> |
132 | | - {% translate 'Hide from project' %} |
| 146 | + {% translate "Hide from project" %} |
133 | 147 | </label> |
134 | 148 | {% else %} |
135 | 149 | <button name="action" value="publish" class="btn btn--none p-0 btn--none-reset"></button> |
|
139 | 153 | id="dashboardToggle_{{ forloop.counter }}" |
140 | 154 | {% if not module_menu.is_complete %}disabled{% endif %}> |
141 | 155 | <label class="form-check-label dashboard-nav__toggle-label" for="dashboardToggle_{{ forloop.counter }}"> |
142 | | - {% translate 'Add to project' %} |
| 156 | + {% translate "Add to project" %} |
143 | 157 | </label> |
144 | 158 | {% endif %} |
145 | 159 |
|
|
154 | 168 |
|
155 | 169 | {% has_perm 'a4projects.change_project' request.user view.project as user_may_add %} |
156 | 170 | {% if user_may_add %} |
157 | | - <a class="btn btn--light btn--full" href="{% url 'a4dashboard:module-blueprint-list' organisation_slug=project.organisation.slug project_slug=project.slug %}">{% translate 'Add Module' %}</a> |
| 171 | + <a class="btn btn--light btn--full" href="{% url 'a4dashboard:module-blueprint-list' organisation_slug=project.organisation.slug project_slug=project.slug %}">{% translate "Add Module" %}</a> |
158 | 172 | {% endif %} |
159 | 173 | </nav> |
160 | 174 |
|
161 | 175 | <div class="mb-5 col-md-6"> |
162 | | - {% block dashboard_project_content %}{% endblock %} |
| 176 | + {% block dashboard_project_content %}{% endblock dashboard_project_content %} |
163 | 177 | </div> |
164 | 178 |
|
165 | 179 | <div class="col-md-3"> |
|
168 | 182 | {% include "a4dashboard/includes/preview.html" with project=project %} |
169 | 183 | </div> |
170 | 184 | </div> |
171 | | -{% endblock %} |
| 185 | +{% endblock dashboard_content %} |
0 commit comments