From 0716da922eb867603a500f6c6b67b1d00652d964 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Wed, 1 Jun 2016 10:54:09 -0400 Subject: [PATCH] Bug 16778: Replace usage of Greybox modals with Bootstrap modals This patch is a proof-of-concept for replacing Greybox modals in situations where in-modal page transitions happen. This one addresses patron card export from the patron lists page. To test you must have at least one patron lists containing patrons. - Apply the patch and go to Patrons -> Patron lists. - In the 'Actions' menu associated with your list, choose 'Print patron cards.' A modal window should be triggered. - In the modal window, change settings as necessary and click the "Export" button. - The modal should reload and display a link to download a PDF. Confirm that the PDF download works correctly and that the correct patron batch was processed. - Repeat the process and confirm at each step that clicking the 'X' button or the 'Cancel' link dismisses the modal window. To confirm that changes to the patron card print template has not adversely affected printing patron cards from the patron card creator page: - Go to Tools -> Patron card creator. - Choose Manage -> Card batches. - Click 'Export' for any batch. - Confirm that the Greybox modal still works correctly for patron card export. Signed-off-by: Hector Castro Works as advertised Signed-off-by: Kyle M Hall Signed-off-by: Kyle M Hall --- .../prog/en/modules/patron_lists/lists.tt | 46 +++++++++++++++++-- .../prog/en/modules/patroncards/print.tt | 4 +- 2 files changed, 44 insertions(+), 6 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/lists.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/lists.tt index f8c0a03a69..a3d886658b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/lists.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/lists.tt @@ -8,6 +8,9 @@ @@ -76,7 +100,9 @@
  • Delete list
  • [% IF ( l.patron_list_patrons_rs.count ) %]
  • -
  • Print patron cards
  • +
  • + Print patron cards +
  • [% IF CAN_user_tools_edit_patrons %]
  • @@ -99,6 +125,18 @@ [% END %] + + + + [% ELSE %]
    There are no patron lists.
    [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/print.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/print.tt index c6619ab435..2691254828 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/print.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/print.tt @@ -16,7 +16,7 @@ -
    +
    [% IF ( batches ) %]
    @@ -62,7 +62,7 @@ [% IF ( multi_batch_count == 1 ) %][% multi_batch_count %] batch to export[% ELSE %][% multi_batch_count %] batches to export[% END %] [% END %] - + [% FOREACH batch_id IN batch_ids %]