<!-- BEGIN [% template.name %] -->
    [% META title = 'Chimerism data' %]

    [% # PROCESS dumper.tt dump = data %]
    
    [% IF data.failure %]
    <h3>The following records failed to update:</h3>
    <table class="indent">
        <tr>
            <td class="borderless"></td>
            <th scope="col">LabNo</th>
            <th scope="col">Message</th>
        </tr>
        [% FOREACH entry IN data.failure %]
        <tr>
            <td>[% loop.count %]</td>
            <td>[% entry.key %]</td>
            <td>[% entry.value %]</td>
        </tr>
        [% END %]
    </table>
    [% END %]

    [% IF data.success %]
    <h3>The following records successfully updated:</h3>
    <table class="indent">
        <tr>
            <td class="borderless"></td>
            <th scope="col">LabNo</th>
            <th scope="col">Result</th>
        </tr>
       [% FOREACH entry IN data.success %]
        <tr>
            <td>[% loop.count %]</td>
            <td>[% lab_number = entry.key %]
                <a href="[% app_url %]/search/do_search?lab_number=[% lab_number
                    %];_return=1">[% lab_number %]</a>
            <td>[% entry.value | html_line_break %]</td>
        </tr>
        [% END %]
    </table>
    [% END %]
<!-- END [% template.name %] -->