]> git.evergreen-ils.org Git - working/Evergreen.git/commit
Remove in-template javascript, add script files
authorThomas Berezansky <tsbere@mvlc.org>
Wed, 24 Aug 2011 15:31:59 +0000 (11:31 -0400)
committerJason Etheridge <jason@esilibrary.com>
Tue, 4 Oct 2011 17:18:42 +0000 (13:18 -0400)
commit865c23330a9e891024e2df3696dfe5a827ed545c
tree79654c3f35355dce56555c9dd56ea87631bdcf74
parent3891ba9abdf39dd079472e5213e7db1407e47b8d
Remove in-template javascript, add script files

Adds support for a print_custom.js file and an org unit specified file.

If either exists and contains a print_custom function it will be called
before printing to allow for DOM manipulation.

If neither exists the print_win.js file will call all functions it has
defined.

In addition, if any code sets do_print to false the window will close
instead of attempting to print.

The print_custom function will receive the type of template used, if any.
This only applies to "Receipt Template" based print jobs, and the type in
question is the "Type" that shows in the template editor.

Functions defined in print_win.js:

print_init
    Main function, checks for print_custom and does final printing

print_do_sums
    Does summing of values.

print_check_alt
    Does swapping out of template blocks with display:none styling.

print_check_noprint
    Disables printing under certain circumstances.

For more information about usage of the print_do_sums, print_check_alt,
and print_check_noprint functions check the comments in print_win.js.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Open-ILS/src/sql/Pg/950.data.seed-values.sql
Open-ILS/xul/staff_client/chrome/content/util/print.js
Open-ILS/xul/staff_client/chrome/content/util/print_win.js [new file with mode: 0644]