Bug 16566

Summary: 'Print slip' button formatting inconsistent
Product: Koha Reporter: Nick Clemens <nick>
Component: CirculationAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: boutrosboutrosboutros, f.demians, gmcharlt, katrin.fischer, kyle.m.hall, kyle, lisettepalouse+koha, veron
Version: master   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 16566 - 'Print slip' button formatting inconsistent
Bug 16566 - 'Print slip' button formatting inconsistent
Screenshot: Please return item to: Midway
Bug 16566 [Revised] 'Print slip' button formatting inconsistent
Bug 16566 [Revised] 'Print slip' button formatting inconsistent

Description Nick Clemens 2016-05-23 13:24:54 UTC
At item checkin the transfer item to' and 'return item to'prompts have different formatting for printing a slip.  

https://snag.gy/YOlr50.jpg

Holds use a button+icon for print and confirm:

https://snag.gy/HRqNrL.jpg

It would be nice to be consistent among these links
Comment 1 Owen Leonard 2016-05-23 13:53:49 UTC
(In reply to Nick Clemens from comment #0)
>
> https://snag.gy/YOlr50.jpg

We obviously have another problem here too: Two transfer messages? Shouldn't the rotating collection transfer message supersede the "normal" one?
Comment 2 Owen Leonard 2016-05-25 15:32:23 UTC Comment hidden (obsolete)
Comment 3 Marc Véron 2016-05-28 18:58:34 UTC
(In reply to Owen Leonard from comment #1)
> (In reply to Nick Clemens from comment #0)
> >
> > https://snag.gy/YOlr50.jpg
> 
> We obviously have another problem here too: Two transfer messages? Shouldn't
> the rotating collection transfer message supersede the "normal" one?

Same opinion. I think this should be covered by another bug.
Comment 4 Marc Véron 2016-05-28 18:59:47 UTC Comment hidden (obsolete)
Comment 5 Katrin Fischer 2016-06-19 15:51:53 UTC
Created attachment 52551 [details]
Screenshot: Please return item to: Midway

First test I did: Return a checked out item at another branch than it's been checked out from. The button shown doesn't work for me - no visible Javascript error.
Comment 6 Marc Véron 2016-06-19 16:26:25 UTC
In the browser's page source, the url provided is:
data-url="transfer-slip.pl?transferitem=298&amp;branchcode=CPL&amp;op=slip"

If I copy it in the browser's address field I have to replace &amp; with & to make it work.
Comment 7 Owen Leonard 2016-06-22 15:00:17 UTC Comment hidden (obsolete)
Comment 8 Kyle M Hall 2016-06-24 18:07:20 UTC
Created attachment 52860 [details] [review]
Bug 16566 [Revised] 'Print slip' button formatting inconsistent

This patch modifies the style of some "print slip" links on the checkin
page to make them consistent with other buttons shown in dialogs.

This patch also removes the use of "onclick" in some places in favor of
defining events in the JavaScript.

To test apply the patch and go to Circulation -> Check in.

- Check in an item which belongs at another branch. You should see a
  dialog which asks the user to transfer the item. Confirm that the
  "Print slip" button looks correct and works correctly.

- Check in the same item again. You should see a different dialog which
  has both a "Print transfer slip" and "Cancel transfer" button. The
  "Print transfer slip" button should look correct and work correctly.

- Check in an item which is part of a rotating collection. (Or, if Bug
  16570 is still open, check in any item) You should see a dialog which
  notifies you that the item is part of a rotating collection. The
  "Print slip" button in this dialog should look correct and work
  correctly.

Followed test plan. Buttons appear as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Revision following QA: Removed redundant class attribute from the print
button tested in step 1.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 9 Kyle M Hall 2016-07-08 14:27:09 UTC
Pushed to master for 16.11, thanks Owen!
Comment 10 Frédéric Demians 2016-08-01 13:34:38 UTC
Pushed in 16.05. Will be in 16.05.02.
Comment 11 Petter Goksøyr Åsen 2016-09-21 07:35:01 UTC
This patch creates another bug:
When confirming transfer and print slip, the print-slip popup winwod appears, but when it returns, the transfer is not effected. (because of e.preventDefault(), the form event is never processed)
Comment 12 Kyle M Hall 2016-09-26 17:22:49 UTC
(In reply to Petter Goksøyr Åsen from comment #11)
> This patch creates another bug:
> When confirming transfer and print slip, the print-slip popup winwod
> appears, but when it returns, the transfer is not effected. (because of
> e.preventDefault(), the form event is never processed)

As this has been pushed to stable, I would recommend you file a new bug report detailing the issue.