.
This commit is contained in:
@@ -2,14 +2,38 @@
|
||||
|
||||
{% block content %}
|
||||
<h3>Cases</h3>
|
||||
<ol id="full-question-list" class="sortable">
|
||||
{% for case in cases %}
|
||||
<li data-question_pk={{case.pk}}>Case {{forloop.counter}}: {{case.title}}
|
||||
<details class="help-text">
|
||||
<summary>Instructions</summary>
|
||||
<p>Click on the 'Show' button to view the case in the viewer. Click on the 'Open' button to open the case in a new window.</p>
|
||||
<p>Opening a second case will replace the first case in the viewer or window.</p>
|
||||
</details>
|
||||
|
||||
aoeu
|
||||
<button class="show-case no-padding" data-title="{{case.title}}" data-target="/ohif/viewer/dicomjson?url=https://www.penracourses.org.uk{% url 'atlas:case_dicom_json' case.pk %}">Show</button>
|
||||
<ol id="" class="sortable">
|
||||
{% for case in cases %}
|
||||
<li data-question_pk={{case.pk}}>
|
||||
<div>Case {{forloop.counter}}: {{case.title}}
|
||||
<button class="show-case no-padding" data-title="{{case.title}}" data-target="/ohif/viewer/dicomjson?url=https://www.penracourses.org.uk{% url 'atlas:case_dicom_json' case.pk %}">Show</button>
|
||||
{% comment %} <button class="send-message no-padding" data-title="{{case.title}}" data-target="/ohif/viewer/dicomjson?url=https://www.penracourses.org.uk{% url 'atlas:case_dicom_json' case.pk %}">Open</button> {% endcomment %}
|
||||
<button class="open-case no-padding" data-title="{{case.title}}" data-target="{% url 'atlas:collection_viva_case' collection.pk forloop.counter0 %}">Case</button>
|
||||
<button class="open-case no-padding" data-title="{{case.title}}" data-target="{% url 'atlas:collection_viva_case' collection.pk forloop.counter0 %}">Open</button>
|
||||
<br />
|
||||
<div class="pre-whitespace multi-image-block"><b>Series:</b>
|
||||
{% for series in case.series.all %}
|
||||
<span class="series-block">
|
||||
<span>
|
||||
<span class="series-block-series-number">Series {{ forloop.counter }}:</span><br>
|
||||
{{series.get_block}}
|
||||
<button class="show-series" data-target="/ohif/viewer/dicomjson?url=https://www.penracourses.org.uk{% url 'atlas:series_dicom_json' series.pk %}">
|
||||
show
|
||||
</button>
|
||||
<button class="open-series" data-target="{% url 'atlas:collection_viva_series' collection.pk series.pk %}">
|
||||
show
|
||||
</button>
|
||||
<br>
|
||||
</span>
|
||||
</span>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
{% endfor %}
|
||||
@@ -34,6 +58,12 @@
|
||||
$('#case-title').text($(this).data('title'));
|
||||
$('#viewer').attr('src', url)
|
||||
});
|
||||
$('.show-series').click(function() {
|
||||
var url = $(this).data('target');
|
||||
console.log('clicked', url)
|
||||
$('#case-title').text("Series: " + $(this).data('title'));
|
||||
$('#viewer').attr('src', url)
|
||||
});
|
||||
$('.open-case').click(function() {
|
||||
var url = $(this).data('target');
|
||||
bc.postMessage(url);
|
||||
|
||||
Reference in New Issue
Block a user