From b95d68141d696164eca73fbba0f6e59d003fd088 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Mon, 12 Aug 2013 08:36:09 -0400 Subject: [PATCH] [SIGNED-OFF] Bug 10614 - have add order form at top and bottom If a basket has a lot of items it may be inconvenient to scroll to the bottom of the patch to reach the "add to basket" form. This patch adds as "Add to basket" button to the toolbar which uses JavaScript to copy the form into a modal dialog for quick access. To test, apply the patch and view an open basket. You should be able to click the "Add to basket" button to trigger a modal dialog with the full "Add to basket" list of options. All options in the list should function normally. If you view a closed basket the new button should not appear. Signed-off-by: Nicole C. Engard All tests pass and I love it :) --- .../intranet-tmpl/prog/en/modules/acqui/basket.tt | 15 +++++++++++++++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt index 84df886..8cbc46e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt @@ -28,6 +28,11 @@ $("#show_all_details").attr('checked', false); updateColumnsVisibility(false); + [% UNLESS ( closedate ) %] + $('#addtoBasket').on('show', function () { + $(this).find(".modal-body").html($("#acqui_basket_add")[0].outerHTML); + }); + [% END %] }); //]]> @@ -137,6 +142,7 @@ [% UNLESS ( selectbasketg ) %] [% UNLESS ( closedate ) %]
+ [% IF ( unclosable ) %] @@ -451,6 +457,15 @@ [% END %]
[% UNLESS ( closedate ) %] + + + + [% INCLUDE 'acquisitions-add-to-basket.inc' %] [% END %] [% END %] -- 1.7.2.3