From 461e7375cd9841f6d43e11c273998c3006f04abf Mon Sep 17 00:00:00 2001 From: Aleisha Amohia Date: Wed, 6 Jun 2018 01:48:33 +0000 Subject: [PATCH] Bug 15766: (follow-up) Fixing layout of description button This patch moves the 'Save' button to the toolbar as suggested. The description textbox and 'Save' button are hidden if the batch is new and appears when items are added. Signed-off-by: Owen Leonard Signed-off-by: Katrin Fischer Signed-off-by: Nick Clemens --- .../prog/en/modules/labels/label-edit-batch.tt | 12 +++++++----- .../prog/en/modules/patroncards/edit-batch.tt | 12 +++++++----- svc/creator_batches | 0 3 files changed, 14 insertions(+), 10 deletions(-) mode change 100644 => 100755 svc/creator_batches diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-batch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-batch.tt index 6bbb1839df..adf187924c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-batch.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-batch.tt @@ -16,8 +16,10 @@ ToolsLabel creatorBatches › - [% IF batch_id %] - Edit ([% batch_id | html %]) + [% IF description %] + Edit [% description | html %] + [% ELSIF batch_id %] + Edit ([% batch_id | html %]) [% ELSE %] New [% END %] @@ -64,8 +66,7 @@ - - Save description +
  • @@ -85,6 +86,7 @@
    Add item(s)[% IF ( table_loop ) %] + Save description Remove selected items Delete batch Remove duplicates @@ -329,7 +331,7 @@ }); $("#savedesc").click(function(event){ event.preventDefault(); // prevent form submission - var newdescription = $(this).siblings('input[name="description"]').val(); + var newdescription = $('input[name="description"]').val(); var batch_id = $(this).data('batch_id'); var ajaxData = { 'newdescription': newdescription, diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt index 740c663c83..99616a869c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt @@ -15,8 +15,10 @@ ToolsPatron card creatorBatches › - [% IF batch_id %] - Edit ([% batch_id | html %]) + [% IF description %] + Edit [% description | html %] + [% ELSIF batch_id %] + Edit ([% batch_id | html %]) [% ELSE %] New [% END %] @@ -48,8 +50,7 @@ - - Save description +