Koha/koha-tmpl/intranet-tmpl/prog/en/modules/serials/routing-preview-slip.tt
Owen Leonard 512c5f0c0d Bug 19761: Move template JavaScript to the footer: Serials, part 2
This patch modifies more staff client serials templates so
that JavaScript is included in the footer instead of the header.

To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.

 - Serials -> Subscription detail -> Edit routing list
   - Add recipients
   - Save
     - "Save and preview routing slip" should trigger preview
       - In preview popup: Print and Close buttons should work correctly

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-14 16:58:13 -03:00

58 lines
1.6 KiB
Text

[% SET footerjs = 1 %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha &rsaquo; Serials &rsaquo; Routing slip preview</title>
[% INCLUDE 'doc-head-close.inc' %]
<style type="text/css">
#custom-doc { width:38.46em;*width:37.53em;min-width:500px; margin:auto; text-align:left; }
</style>
<style type="text/css" media="print">
.yui-t7, #custom-doc { min-width:0; width:auto; }
</style>
</head>
<body id="ser_routing-preview-slip" class="ser">
<div id="custom-doc" class="yui-t7">
<div id="bd">
<table>
<tr>
<td colspan="2"><h3>[% libraryname %]</h3></td>
</tr>
<tr>
<td colspan="2"><b>Title:</b> [% title |html %]<br />[% issue %]</td>
</tr>
<tr>
<td><b>Name</b></td>
<td><b>Date due</b></td>
</tr>
[% FOREACH memberloo IN memberloop %]
<tr>
<td>[% memberloo.name %]</td>
<td>&nbsp;</td>
</tr>
[% END %]
</table>
<div id="routingnotes">
<p id="generalroutingnote">[% generalroutingnote %]</p>
<p id="routingnote">[% routingnotes %]</p>
</div>
<div id="closewindow" class="noprint"><a class="btn btn-default btn-default" id="print_slip" href="#"><i class="fa fa-print"></i> Print</a> <a class="btn btn-default btn-default close" href="#">Close</a></div>
</div>
[% MACRO jsinclude BLOCK %]
<script type="text/javascript">
$(document).ready(function(){
$("#print_slip").on("click",function(e){
e.preventDefault();
window.print();
self.close();
});
});
</script>
[% END %]
[% INCLUDE 'intranet-bottom.inc' %]