Bug 14399: Results form also needs a few interface changes

Currently, the value of compareinv2barcd is used to determine if the
Seen column, the Select/Clear all buttons and the Mark seen buttons are
displayed. But if we scanned barcodes, we already marked items as seen.
So we should only display these buttons when we did not upload barcodes.

Test plan:
[1] Upload a barcode file. Check that the result form does not show
    the buttons.
[2] Generate an inventory list, so do not upload a barcode file. Verify
    that you still see the buttons.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
Marcel de Rooy 2017-04-12 16:06:29 +02:00 committed by Kyle M Hall
parent 35b73aa3c6
commit af89df12e7
2 changed files with 5 additions and 4 deletions

View File

@ -269,14 +269,14 @@ $(document).ready(function(){
<input type="hidden" name="branchcode" value="[% branchcode %]" />
<input type="hidden" name="datelastseen" value="[% datelastseen %]" />
[% UNLESS compareinv2barcd %]
[% UNLESS uploadedbarcodesflag %]
<div><a href="#" class="checkall"><i class="fa fa-check"></i> Select all</a> <a href="#" class="clearall"><i class="fa fa-remove"></i> Clear all</a></div>
[% END %]
<table id="inventoryt">
<thead>
<tr>
[% UNLESS compareinv2barcd %]<th>Seen</th>[% END %]
[% UNLESS uploadedbarcodesflag %]<th>Seen</th>[% END %]
<th>Barcode</th>
<th>Call number</th>
<th>Library</th>
@ -292,7 +292,7 @@ $(document).ready(function(){
<tbody>
[% FOREACH result IN loop %]
<tr>
[% UNLESS compareinv2barcd %]
[% UNLESS uploadedbarcodesflag %]
<td>
<input type="checkbox" name="SEEN-[% result.itemnumber %]" value="1" />
</td>
@ -344,7 +344,7 @@ $(document).ready(function(){
</tbody>
</table>
<div class="spacer"></div>
[% UNLESS compareinv2barcd %]
[% UNLESS uploadedbarcodesflag %]
<div style="padding : .3em 0"><a href="#" class="checkall"><i class="fa fa-check"></i> Select all</a> <a href="#" class="clearall"><i class="fa fa-remove"></i> Clear all</a></div>
<input type="submit" id="markseenandquit" value="Mark seen and quit" />
<input type="submit" value="Mark seen and continue &gt;&gt;" id="markseenandcontinuebutton" />

View File

@ -123,6 +123,7 @@ $template->param(
branch => $branch,
datelastseen => $datelastseen,
compareinv2barcd => $compareinv2barcd,
uploadedbarcodesflag => $uploadbarcodes ? 1 : 0,
);
# Walk through uploaded barcodes, report errors, mark as seen, check in