RSS Git Download  Clone
Raw Blame History
    [% META title="Fluidx XTR-96 Plate Reader Import" %]
<!-- BEGIN [% template.name %] -->

    <h2 class="header">FluidX XTR-96 plate reader data import</h2>
    
    <script type="text/javascript">
        function submitForm(s) {
            s.value = "Scanning plate, please wait ...";
            return true;
        }
    </script>

    [% BLOCK form_head %]
      <form action="[% app_url %]/storage/read_xtr_96" name="xtr-96" id="xtr-96"
        [% IF js %]onsubmit="return submitForm(this.scan);"[% END %] method="post">
    [% END %]

    [% IF data.size; # INCLUDE dumper.tt dump = data;
        USE format; concat = format('%s%02d');
    %]
        <p class="info indent"></p>
        <table class="indent">
            <tr>
                <th colspan="12">Plate ID :: [% rack_id %]</th>
            </tr>
            [% FOREACH row IN ['A' .. 'H']; # row; %]            
                <tr>
                    [% FOREACH col IN [1 .. 12]; # INCLUDE dumper.tt dump = [row, col];
                        cell = concat(row,col); # ie format('%s%02d')
                        class = data.item(cell).length < 10 ? 'red' : 'xtr-96-vial';
                    %]
                        <td>
                            <div class="xtr-96-cell">[% cell %]</div>
                            <div class="[% class %]">[% data.item(cell) %]</div>
                        </td>
                    [% END %]
                </tr>
            [% END %]
            <tr class="borderless">
                <td align="right" colspan="12">
                  [% INCLUDE form_head js = 1 %]
                    <input type="submit" class="scan-btn"
                        name="scan" value="RESCAN" /></form>
                </td>
            </tr>
        </table>

        [% INCLUDE form_head js = 0 %]
        <div class="indent">
            <input type="submit" class="import-btn"
                name="import" value="IMPORT" /></form>
        </div>
    [% ELSE; INCLUDE form_head js = 1 %]
        <p class="indent warning">Ensure rack is mounted on plate reader .....
            <input type="submit" class="button scan-btn" name="scan" value="GO" />
        </p>
      </form>
    [% END %]
<!-- END [% template.name %] -->