[% META title="Initial Screen" %]
<!-- BEGIN screen/load_data.tt -->
[% # PROCESS dumper.tt dump = request_audit %]
[% IF dfv_errors %]
<p class="error">[% c.config('msg').dfv_errors %]</p>
[% END %]
<h2>Screen record:</h2>
<div class="indent">
[% PROCESS request/summary_display.tt # expects 'data' object %]
</div>
[% initial_screen_dfv_js %]
[% INCLUDE site/previous_cases.tt # 'PROCESS' clobbers 'data' %]
<span class="spacer"> </span>
<form method="post" action="[% app_url %]/screen/do_initial_screen/[% data.id %]"
[% initial_screen_onsubmit %] name="_update" id="_update">
<table class="indent">
<tr>
<td class="label">Initial screen:</td>
<td class="content">
<select name="screen_id">
<option value=""> </option>
[% FOREACH group IN [ 'fresh' 'fixed'] %]
<optgroup label="[% group | upper %] TISSUE">
[% FOREACH screen IN screen_terms %]
[% NEXT UNLESS screen.sample_type.match(group) %]
<option value="[% screen.id %]">
[% screen.description %]
</option>
[% END %]
</optgroup>
[% END %]
</select>
[% error_screen_id %]
</td>
</tr>
<tr>
<td class="label">Reason for request:</td>
<td class="content">
<select name="option_id">
<option value=""> </option>
[% FOREACH group IN categories %]
<optgroup label="[% group.description | upper %]">
[% FOREACH item IN request_audit %]
[% NEXT UNLESS
item.category.description.match(group.description) %]
<option value="[% item.id %]">
[% item.description %]
</option>
[% END %]
</optgroup>
[% END %]
</select>
[% error_option_id %]
</td>
</tr>
<tr>
<td colspan="2" align="center" class="borderless">
[% site.html.submit %] [% site.html.reset %]
</td>
</tr>
</table>
</form>
<!-- BEGIN screen/load_data.tt -->