Writer and manager updates.

This commit is contained in:
lwark
2025-07-22 13:15:24 -05:00
parent 53c6668ce1
commit b9ca9586ec
21 changed files with 661 additions and 329 deletions

View File

@@ -11,27 +11,24 @@
<h2><u>Submission Details for {{ clientsubmission['name'] }}</u></h2>
{{ super() }}
<p>{% for key, value in clientsubmission.items() if key not in clientsubmission['excluded'] %}
&nbsp;&nbsp;&nbsp;&nbsp;<b>{{ key | replace("_", " ") | title | replace("Id", "ID") }}: </b>{% if key=='cost' %}{% if clientsubmission['cost'] %} {{ "${:,.2f}".format(value) }}{% endif %}{% else %}{{ value }}{% endif %}<br>
&nbsp;&nbsp;&nbsp;&nbsp;<b>{{ key | replace("_", " ") | title | replace("Id", "ID") }}:</b> {% if key=='cost' %}{% if clientsubmission['cost'] %} {{ "${:,.2f}".format(value) }}{% endif %}{% else %}{{ value }}{% endif %}<br/>
{% endfor %}
</p>
{% if clientsubmission['sample'] %}
<button type="button"><h3><u>Client Submitted Samples:</u></h3></button>
<!-- <div class="nested">-->
<p>{% for sample in clientsubmission['sample'] %}
&nbsp;&nbsp;&nbsp;&nbsp;<a class="data-link sample" id="{{ sample['sample_id'] }}">{{ sample['sample_id'] }}</a><br>
{% endfor %}</p>
<!-- </div>-->
{% endif %}
{% if clientsubmission['run'] %}
<button type="button"><h3><u>Runs:</u></h3></button>
<!-- <div class="nested">-->
<div class="nested">
{% for run in clientsubmission['run'] %}
{% with run=run, child=True %}
{% include "run_details.html" %}
{% endwith %}
{% endfor %}
<!-- </div>-->
</div>
{% endif %}
{% endblock %}
</body>

View File

@@ -150,9 +150,15 @@ ul.no-bullets {
.nested {
margin-left: 50px;
padding: 0 18px;
display: none;
overflow: hidden;
background-color: #f1f1f1;
.nested {
background-color: #ffffff;
}
}
.hidden_input {
display: none;
}
/* Style the button that is used to open and close the collapsible content */

View File

@@ -21,6 +21,24 @@ for(let i = 0; i < formtexts.length; i++) {
})
};
var repeat_box = document.getElementById("repeat");
repeat_box.addEventListener("input", function() {
backend.check_toggle("repeat", repeat_box.checked)
var repeat_str = document.getElementById("repeat_of");
if (repeat_box.checked) {
repeat_str.classList.remove("hidden_input");
} else {
repeat_str.classList.add("hidden_input");
}
})
var repeat_of = document.getElementById("repeat_of");
repeat_of.addEventListener("change", function() {
backend.text_changed("repeat_of", repeat_of.value)
})
var changed_it = new Event('change');
var reagentRoles = document.getElementsByClassName("reagentrole");

View File

@@ -23,7 +23,12 @@
<label for="technician">Technician:</label><br>
<input type="text" class="form_text full" id="technician" name="technician" width="100%" value="{{ procedure['technician']['value'] }}" background-color="{{ procedure['technician']['colour'] }}"><br><br>
<label for="repeat">Repeat:</label>
<input type="checkbox" class="form_check" id="repeat" name="repeat" value="{{ procedure['repeat'] }}"><br><br>
<input type="checkbox" id="repeat" name="repeat" value="{{ procedure['repeat'] }}"><br>
<select class="dropdown hidden_input" id="repeat_of">
{% for previous in proceduretype['previous'] %}
<option value="{{ previous }}">{{ previous }}</option>
{% endfor %}
</select><br><br>
<label>Kit Type:</label><br>
<select class="dropdown" id="kittype" background-colour="{{ procedure['kittype']['colour'] }}">
{% for kittype in procedure['possible_kits'] %}

View File

@@ -1,6 +1,5 @@
{% extends "details.html" %}
{% if not child %}
<head>
{% block head %}
{{ super() }}
@@ -17,7 +16,7 @@
{% endfor %}</p>
{% if procedure['reagent'] %}
<button type="button"><h3><u>Reagents:</u></h3></button>
&nbsp;&nbsp;&nbsp;&nbsp;<table style="border: 1px solid black; width: 100%; text-align: center">
<table style="border: 1px solid black; width: 100%; text-align: center">
<tr>
<th style="border: 1px solid black;">Reagent Role</th>
<th style="border: 1px solid black;">Reagent Name</th>
@@ -28,12 +27,12 @@
{% with reagent=reg, child=True %}
{% include "support/reagent_list.html" %}
{% endwith %}
{% endfor %}</p>
{% endfor %}
</table><br/>
{% endif %}
{% if procedure['equipment'] %}
<button type="button"><h3><u>Equipment:</u></h3></button>
&nbsp;&nbsp;&nbsp;&nbsp;<table style="border: 1px solid black; width: 100%; text-align: center">
<table style="border: 1px solid black; width: 100%; text-align: center">
<tr>
<th style="border: 1px solid black;">Equipment Role</th>
<th style="border: 1px solid black;">Equipment Name</th>
@@ -61,6 +60,7 @@
&nbsp;&nbsp;&nbsp;&nbsp;<a class="{% if sample['active'] %}data-link {% else %}unused {% endif %}sample" id="{{ sample['sample_id'] }}">{{ sample['sample_id']}}</a><br>
{% endfor %}</p>
{% endif %}
{% endblock %}
{% if not child %}
</body>
{% endif %}

View File

@@ -1,4 +1,5 @@
{% extends "details.html" %}
{% if not child %}
<head>
{% block head %}
@@ -7,7 +8,7 @@
{% endblock %}
</head>
<body>
{% endif %}
{% block body %}
<h2><u>Run Details for {{ run['rsl_plate_number'] }}</u></h2>
{{ super() }}
@@ -22,11 +23,13 @@
{% endif %}
{% if run['procedure'] %}
<button type="button"><h3><u>Procedures:</u></h3></button>
<div class="nested">
{% for procedure in run['procedure'] %}
{% with procedure=procedure, child=True %}
{% include "procedure_details.html" %}
{% endwith %}
{% endfor %}
</div>
{% endif %}
{% endblock %}
{% block signing_button %}
@@ -34,7 +37,9 @@
{% endblock %}
<br>
{% if not child %}
</body>
{% endif %}
{% block script %}
{{ super() }}

View File

@@ -0,0 +1,10 @@
<tr>
<td style="border: 1px solid black;">{{ equipment['equipmentrole'] }}</td>
<td style="border: 1px solid black;">{{ equipment['name'] }}</td>
<td style="border: 1px solid black;">{{ equipment['process']['name'] }}</td>
{% if equipment['tips'] %}
<td style="border: 1px solid black;">{{ equipment['tips']['name'] }}</td>
{% else %}
<td style="border: 1px solid black;"></td>
{% endif %}
</tr>