|
Lines 38-53
$(document).ready(function() {
Link Here
|
| 38 |
text-align: left; |
38 |
text-align: left; |
| 39 |
} |
39 |
} |
| 40 |
</style> |
40 |
</style> |
| 41 |
`) |
41 |
`); |
| 42 |
win.document.write( title ); |
42 |
win.document.write( title ); |
| 43 |
win.document.write( contents ); |
43 |
win.document.write( contents ); |
| 44 |
win.document.close(); |
44 |
win.document.close(); |
| 45 |
win.focus(); |
45 |
win.addEventListener( 'afterprint', function () { |
| 46 |
win.print(); |
46 |
win.addEventListener( 'focus', function () { |
| 47 |
win.onafterprint = function () { |
47 |
win.close(); |
|
|
48 |
}); |
| 48 |
win.close(); |
49 |
win.close(); |
| 49 |
} |
50 |
}); |
| 50 |
setTimeout('window.close()', 1000); //Hack from Chrome < 63 |
51 |
win.print(); |
| 51 |
} |
52 |
} |
| 52 |
|
53 |
|
| 53 |
// Set focused on printable modals on open and autoprint if required |
54 |
// Set focused on printable modals on open and autoprint if required |
| 54 |
- |
|
|