.
This commit is contained in:
@@ -1,16 +1,16 @@
|
||||
<div class="atlas {% if question.scrapped %}atlas-scrapped{% endif %}">
|
||||
<div class="atlas {% if case.scrapped %}atlas-scrapped{% endif %}">
|
||||
<div class="date">
|
||||
{{ question.created_date|date:"d/m/Y" }}
|
||||
{{ case.created_date|date:"d/m/Y" }}
|
||||
</div>
|
||||
<div class="id">
|
||||
ID: {{ question.id }}
|
||||
ID: {{ case.id }}
|
||||
</div>
|
||||
<p class="pre-whitespace"><b>Description:</b> {{ question.description }}</p>
|
||||
<p class="pre-whitespace"><b>Description:</b> {{ case.description }}</p>
|
||||
|
||||
<p class="pre-whitespace"><b>History:</b> {{ question.history }}</p>
|
||||
<p class="pre-whitespace"><b>History:</b> {{ case.history }}</p>
|
||||
|
||||
<div class="pre-whitespace multi-image-block"><b>Series:</b>
|
||||
{% for series in question.series.all %}
|
||||
{% for series in case.series.all %}
|
||||
<span class="series-block">
|
||||
<span>
|
||||
Series {{ forloop.counter }}:
|
||||
@@ -23,25 +23,25 @@
|
||||
</span>
|
||||
</span>
|
||||
{% endfor %}
|
||||
<a href="{% url 'atlas:atlas_series_id_create' pk=question.pk %}">Add new series</a><br />
|
||||
<a href="{% url 'atlas:atlas_series_id_create' pk=case.pk %}">Add new series</a><br />
|
||||
</div>
|
||||
<p><b>Author(s):</b> {% for author in question.author.all %} <a
|
||||
<p><b>Author(s):</b> {% for author in case.author.all %} <a
|
||||
href="{% url 'atlas:author_detail' pk=author.pk %}">{{author}}</a>, {% endfor %}</p>
|
||||
<p><b>Checked by:</b> {% for verified in question.verified.all %} <a
|
||||
<p><b>Checked by:</b> {% for verified in case.verified.all %} <a
|
||||
href="{% url 'atlas:verified_detail' pk=verified.pk %}">{{verified}}</a>, {% endfor %}</p>
|
||||
{% comment %} <p><b>Scrapped:</b> {{ question.scrapped }} <a
|
||||
href="{% url 'atlas:atlas_scrap' pk=question.pk %}">(toggle)</a> {% endcomment %}
|
||||
{% comment %} <p><b>Scrapped:</b> {{ case.scrapped }} <a
|
||||
href="{% url 'atlas:atlas_scrap' pk=case.pk %}">(toggle)</a> {% endcomment %}
|
||||
|
||||
<div class="atlas-answer">
|
||||
<p class="pre-whitespace">
|
||||
<details>
|
||||
<summary><b>Findings</b></summary>
|
||||
<pre>{{ question.findings | safe}}</pre>
|
||||
<pre>{{ case.findings | safe}}</pre>
|
||||
</details>
|
||||
</p>
|
||||
</div>
|
||||
</p>
|
||||
<div>
|
||||
{% include 'question_notes.html' %}
|
||||
{% include 'case_notes.html' %}
|
||||
|
||||
</div>
|
||||
@@ -1,9 +1,9 @@
|
||||
<div>{{ series.modality}}, {{ series.examination }}, {{ series.plane }}, {{ series.contrast }}</div>
|
||||
|
||||
{% if series.atlas %}
|
||||
{% if series.case %}
|
||||
Associated case:
|
||||
{% for atlas in series.atlas.all %}
|
||||
<a href="{% url 'atlas:case_detail' pk=atlas.pk %}">{{atlas}}</a>
|
||||
{% for case in series.case.all %}
|
||||
<a href="{% url 'atlas:case_detail' pk=case.pk %}">{{case}}</a>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
This series is not associated with any cases.
|
||||
|
||||
+2
-2
@@ -96,13 +96,13 @@ class AuthorOrCheckerRequiredMixin(object):
|
||||
@login_required
|
||||
@user_is_author_or_atlas_checker_or_atlas_marker
|
||||
def case_detail(request, pk):
|
||||
atlas = get_object_or_404(Case, pk=pk)
|
||||
case = get_object_or_404(Case, pk=pk)
|
||||
|
||||
# if request.user not in atlas.author.all():
|
||||
# raise PermissionDenied
|
||||
|
||||
# logging.debug(atlas.subspecialty.first().name.all())
|
||||
return render(request, "atlas/case_detail.html", {"question": atlas})
|
||||
return render(request, "atlas/case_detail.html", {"case": case})
|
||||
|
||||
|
||||
@login_required
|
||||
|
||||
Reference in New Issue
Block a user