Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
155 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
function showVariantCarrierModal(obj, release, chromosome, start, reference, alternative) { | ||
const box = $(`#variantcarriermodal-${release}-${chromosome}-${start}-${reference}-${alternative}`).find('.variant-carrier-results'); | ||
box.html('<div class="text-center"><i class="iconify spin" data-icon="fa-solid:spinner"></i></div>'); | ||
$.ajax({ | ||
type: 'GET', | ||
url: `${variant_carriers_url}?release=${release}&chromosome=${chromosome}&position=${start}` + | ||
`&reference=${reference}&alternative=${alternative}`, | ||
success: function (response) { | ||
// icon.removeClass('spin').attr('data-icon', 'fa-solid:cloud-upload'); | ||
box.html(response); | ||
}, | ||
error: function (jqXHR, textStatus, errorThrown) { | ||
alert("Error during AJAX call:", textStatus, + errorThrown); | ||
console.log("Error during AJAX call: ", jqXHR, textStatus, errorThrown); | ||
}, | ||
timeout: 0 | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
47 changes: 47 additions & 0 deletions
47
variants/templates/variants/filter_result/variant_carriers_result.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
{% load dict %} | ||
{% load variants_tags %} | ||
|
||
<div> | ||
<p> | ||
A total of {{ count_total }} carriers were found for variant <code>{{ small_var.human_readable }}</code>. | ||
{% if count_total == count_noaccess %} | ||
You do not have access to any of them, though. | ||
{% elif count_noaccess == 0 %} | ||
They are displayed below (you have access to all of them). | ||
{% else %} | ||
You do not have access to {{ count_noaccess }} but the remaining {{ count_access }} are displayed below. | ||
{% endif %} | ||
</p> | ||
|
||
<table class="table-sm table-striped"> | ||
<thead> | ||
<tr> | ||
<th style="width: 20%;">case</th> | ||
<th style="width: 60%;">project</th> | ||
<th style="width: 20%;">genotype</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{% for case, var in case_vars %} | ||
{% for name, genotype in var.genotype.items %} | ||
<tr> | ||
<td> | ||
<a href="{% url 'variants:case-detail' case.project.sodar_uuid case.sodar_uuid %}"> | ||
{{ case.name }} | ||
</a> | ||
</td> | ||
<td> | ||
<a href="{% url 'projectroles:detail' case.project.sodar_uuid %}"> | ||
{{ case.project.title }} | ||
</a> | ||
</td> | ||
<td> | ||
<span class="small">{{ name|strip_sample_suffix }}</span> | ||
<strong>{{ genotype|keyvalue:"gt" }}</strong> | ||
</td> | ||
</tr> | ||
{% endfor %} | ||
{% endfor %} | ||
</tbody> | ||
</table> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters