From f3011690fc24dae2c39c2afd4d13afb43ebaecc4 Mon Sep 17 00:00:00 2001 From: Aleisha Date: Tue, 19 Jul 2016 05:03:45 +0000 Subject: [PATCH] Bug 16939: Making all 'add to basket' actions buttons MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Edit: Fixing 'clas' typo in addorderiso2709.tt Edit: Adding actions class to td Edit: Fixing js error Edit: circ/reserveratios.tt updated so that the plus icon doesn't show if there is no link Edit: fixing logic in circ/reserveratios.tt Edit: merge conflicts Edit: updating buttons to bootstrap 3, which i believe fixes the problem in comment 16 To test: 1) Go to Acqui -> find a vendor -> view a basket 2) Click add to basket -> fill in 'for an existing record' and hit search 3) 'View MARC' and 'Order' buttons should show under an Actions column with appropriate icons 4) Click Order 5) Click add item when you are redirected to the New order page (no need to fill in any details) 6) Confirm that 'Edit' and 'Delete' buttons now show under an Actions column with appropriate icons 7) Go back to your basket and click add to basket -> from a subscription (we are skipping from a suggestion because this already has a button before my patch) 8) Confirm that 'Order' shows as a button with appropriate icon 9) Go back to your basket and click add to basket -> from an external source 10) fill in any fields and click search to bring up results 11) 'Order' should now show as a button with appropriate icons. MARC and Card preview have been moved into a dropdown menu - confirm this works as expected. Links have not been changed when clicking on a row 12) Go back to your basket and click add to basket -> from a staged file 13) 'Add orders' should now show as a button with appropriate icon 14) Go back to your basket and click add to basket -> from titles with highest hold ratios 15) 'X to order' should now show as a button with appropriate icon Sponsored-by: Catalyst IT Signed-off-by: Nicole C Engard Followed test plan, works as expected. Signed-off-by: Marc Véron Signed-off-by: Owen Leonard Signed-off-by: Jonathan Druart Signed-off-by: Nick Clemens --- .../prog/en/modules/acqui/addorderiso2709.tt | 4 ++- .../prog/en/modules/acqui/neworderbiblio.tt | 13 +++------ .../prog/en/modules/acqui/neworderempty.tt | 3 +- .../en/modules/acqui/newordersubscription.tt | 8 ++--- .../prog/en/modules/acqui/z3950_search.tt | 29 ++++++++++++------- .../prog/en/modules/circ/reserveratios.tt | 16 ++++++++-- koha-tmpl/intranet-tmpl/prog/js/additem.js | 7 ++--- 7 files changed, 48 insertions(+), 32 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt index 54a701103f..70efcad42e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt @@ -413,7 +413,9 @@ [% batch_lis.staged_date | $KohaDates with_hours => 1 | html %] [% batch_lis.num_records | html %] - Add orders + + Add orders + [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt index ae5ba5fa03..0c7772384e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt @@ -43,8 +43,7 @@ Summary Publisher Copyright -   -   + Actions @@ -67,13 +66,9 @@ [% biblio.copyrightdate | html %] - - View MARC - - - - Order - + + View MARC + Order [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt index 33bc36a74e..c11a8e3567 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt @@ -256,8 +256,7 @@ - - + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersubscription.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersubscription.tt index fbb2142aac..0d21ecd573 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersubscription.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersubscription.tt @@ -68,13 +68,13 @@ [% END %] -
  Actions Barcode Home library Holding library + [% IF (sub.alreadyOnOrder) %] Outstanding order [% END %] - [% IF not sub.aqbooksellerid || booksellerid == sub.aqbooksellerid%] - - Place order + [% IF not sub.aqbooksellerid || booksellerid == sub.aqbooksellerid %] + + Order [% ELSE %] Cannot be ordered diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tt index e42087c054..9a14ac3d66 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tt @@ -100,30 +100,30 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color : [% IF ( breeding_loop ) %] - + - [% IF Koha.Preference('AdditionalFieldsInZ3950ResultSearch') != '' %] - + [% IF ( Koha.Preference('AdditionalFieldsInZ3950ResultSearch') != '' ) %] + [% END %] - + [% FOREACH breeding_loo IN breeding_loop %] [% IF ( breeding_loo.breedingid ) %] - + - [% IF Koha.Preference('AdditionalFieldsInZ3950ResultSearch') != '' %] + [% IF ( Koha.Preference('AdditionalFieldsInZ3950ResultSearch') != '' %] [% END %] - - - + + [% END %] [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/reserveratios.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/reserveratios.tt index 5073850d50..17143a7dce 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/reserveratios.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/reserveratios.tt @@ -92,8 +92,20 @@ [% END %] - + [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/js/additem.js b/koha-tmpl/intranet-tmpl/prog/js/additem.js index 78b5780a7b..a7e93a566e 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/additem.js +++ b/koha-tmpl/intranet-tmpl/prog/js/additem.js @@ -87,13 +87,12 @@ function constructTrNode(index, unique_item_fields) { 'stocknumber', 'ccode', 'itype', 'materials', 'itemnotes']; var result = ""; - var edit_link = "" + var edit_link = " " + (window.MSG_ADDITEM_JS_EDIT || "Edit") + ""; var del_link = "" + + "onclick='deleteItemBlock(this, \"" + index + "\", \"" + unique_item_fields + "\");' class='btn btn-default btn-xs'> " + (window.MSG_ADDITEM_JS_DELETE || "Delete") + ""; - result += ""; - result += ""; + result += ""; for(i in fields) { var field = fields[i]; var field_elt = $("#" + index) -- 2.39.5
Server Title Author ISBN LCCNAdditional fieldsAdditional fieldsPreview  
[% breeding_loo.server | html %] [% breeding_loo.server | html %] [% breeding_loo.title | html %] [% breeding_loo.author | html %] [% breeding_loo.isbn | html %] [% breeding_loo.lccn | html %] -
+
[% FOREACH addnumberfield IN breeding_loo.addnumberfields %] [% FOREACH string IN breeding_loo.$addnumberfield %]
[% addnumberfield | html %]:
@@ -133,9 +133,18 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
MARC | CardOrder + + Order
[% IF ( reserveloo.thisratio_atleast1 ) %]

[% IF ( CAN_user_acquisition && basketno && booksellerid ) %][% END %][% reserveloo.ratiocalc | html %] to order[% IF ( CAN_user_acquisition && basketno && booksellerid ) %][% END %] - [% IF ( reserveloo.pendingorders ) %]
[% reserveloo.pendingorders | html %] pending[% END %]

[% END %]
+

+ [% IF ( reserveloo.thisratio_atleast1 ) %] + [% IF ( CAN_user_acquisition && basketno && booksellerid ) %] + [% reserveloo.ratiocalc | html %] to order + [% ELSE %] + [% reserveloo.ratiocalc | html %] to order + [% END %] + [% IF ( reserveloo.pendingorders ) %]
[% reserveloo.pendingorders | html %] pending[% END %] + [% ELSE %] + 0 to order + [% END %] +

+
" + edit_link + "" + del_link + "" + edit_link + " " + del_link + "