Skip to content

Commit

Permalink
CellRanger improve license checkbox
Browse files Browse the repository at this point in the history
  • Loading branch information
neoformit committed Aug 29, 2023
1 parent 4021193 commit 3235f90
Showing 1 changed file with 20 additions and 8 deletions.
28 changes: 20 additions & 8 deletions webapp/home/templates/home/requests/access/cellranger.html
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,19 @@ <h2> Galaxy Australia CellRanger Access Request </h2>
must be read and acknowledged prior to access being provisioned.
</p>
{{ form.agree_terms.errors }}
<input
class="form-check-input"
id="termsInput"
name="agree_terms"
type="checkbox"
{% if form.agree_terms.value %}checked{% endif %}
/>
<label for="termsInput" class="form-check-label">I accept the terms of the license agreement</label>
<button type="button" class="ga-btn" onclick="showAcceptLicense(this);">
I have read the license agreement
</button>
<div class="form-check mt-2" style="display: none;">
<input
class="form-check-input"
id="termsInput"
name="agree_terms"
type="checkbox"
{% if form.agree_terms.value %}checked{% endif %}
/>
<label for="termsInput" class="form-check-label">I accept the terms of the license agreement</label>
</div>
</div>

<div class="col-sm-12">
Expand Down Expand Up @@ -122,6 +127,13 @@ <h2> Galaxy Australia CellRanger Access Request </h2>

{% block script %}
<script src="{% static 'home/js/forms.js' %}"></script>
<script>
function showAcceptLicense(acceptLicenseBtn) {
console.log("Button:")
console.log(acceptLicenseBtn);
$(acceptLicenseBtn).siblings('.form-check').show();
}
</script>
{% endblock %}


Expand Down

0 comments on commit 3235f90

Please sign in to comment.