[Koha-patches] [PATCH] Bug 16682: Fix display if Batch patron modification tool does not get any patrons
Srdjan
srdjan at catalyst.net.nz
Fri Jul 8 04:18:45 CEST 2016
From: Marc Véron <veron at veron.ch>
To reproduce:
- Go to Tools->Batch patron modification
- Submit without filling any of "Use a file", "Or use a patron list",
"Or list card numbers..." or use a patron lists with zero members
Result: Screen without any information
To test:
- Apply patch
- Repeat steps above
- Verify that you get a nice message
- Verify that the tool works as before
- with invalid card numbers only
- with valid and invalid card numbers
- with valid card numbers only
Signed-off-by: Srdjan <srdjan at catalyst.net.nz>
---
koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt
index 8d50d70..fd79986 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt
@@ -172,6 +172,12 @@
</form>
[% END %]
+ [% IF ( op == 'show') && (!borrowers) && (!notfoundcardnumbers) # Alert if no patrons given%]
+ [% op = 'noshow' # Change op to prevent display in code below %]
+ <h1>Batch patrons modification</h1>
+ <div class="dialog alert">No patron card numbers given. <a href="/cgi-bin/koha/tools/modborrowers.pl" class="btn btn-mini">Back</a></div>
+ [% END #Alert if no patrons %]
+
[% IF ( op == 'show' or op == 'show_results' ) %]
[% IF ( op == 'show' ) %]
<h1>Batch patrons modification</h1>
--
2.7.4
More information about the Koha-patches
mailing list