Bug 16218 - printfeercpt.tt (and others) does not include jQuery
Summary: printfeercpt.tt (and others) does not include jQuery
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: master
Hardware: All All
: P5 - low trivial (vote)
Assignee: Marc Véron
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-04-06 20:34 UTC by Jesse Weaver
Modified: 2016-12-05 21:25 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 16218: printfeercpt.tt (and others) does not include jQuery (4.81 KB, patch)
2016-04-07 17:24 UTC, Marc Véron
Details | Diff | Splinter Review
[SIGNED-OFF]Bug 16218: printfeercpt.tt (and others) does not include jQuery (4.90 KB, patch)
2016-04-21 17:57 UTC, Héctor Eduardo Castro Avalos
Details | Diff | Splinter Review
[PASSED QA] Bug 16218: printfeercpt.tt (and others) does not include jQuery (4.95 KB, patch)
2016-04-25 09:11 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jesse Weaver 2016-04-06 20:34:58 UTC
Given that these slips can be customized with IntranetSlipPrinterJS, this is a bit of a hangup.
Comment 1 Marc Véron 2016-04-07 17:10:03 UTC
Verified for:

koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt
Comment 2 Marc Véron 2016-04-07 17:24:02 UTC Comment hidden (obsolete)
Comment 3 Marc Véron 2016-04-12 14:50:14 UTC
Applies cleanly on top of (but does not depend of) Bug 15883.
Comment 4 Héctor Eduardo Castro Avalos 2016-04-21 17:57:03 UTC Comment hidden (obsolete)
Comment 5 Katrin Fischer 2016-04-25 09:11:52 UTC
Created attachment 50621 [details] [review]
[PASSED QA] Bug 16218: printfeercpt.tt (and others) does not include jQuery

This patch adds [% INCLUDE 'doc-head-close.inc' %] to the following files
(to make them include jQuery):

koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt

To test:

1) Temporarily include the follwing lines in syspref IntranetSlipPrinterJS:

function printThenClose() {
  if (typeof jQuery != 'undefined') {
    // jQuery is loaded => print the version
    alert(jQuery.fn.jquery);
  }
  else {
    alert('jQuery not available');
  }
}

2) Go to a users page and print slips:
From the Print button in the tool bar:
- Print summary
- Print slip
- Print quick slip
From the "Fines" tab: Account
- 'Print' link in the table with paid transactions

Without patch, a JavaScript message 'jQuery not avaliable' appears.
With patch, the message displays the current jQuery version (1.7.2)

3) Remove IntranetSlipPrinterJS
- Verify that the slips above print as expected.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as expected

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 6 Kyle M Hall 2016-04-29 14:16:29 UTC
Pushed to master for the 16.05 release. Tesekkür ederim Marc!
Comment 7 Julian Maurice 2016-05-16 12:05:38 UTC
Patch pushed to 3.22.x, will be in 3.22.7