From 2da79f8364653941c59c3a6f5aec261ab9ea22ac Mon Sep 17 00:00:00 2001 From: luxiaotao1123 <t1341870251@163.com> Date: 星期四, 02 七月 2020 15:36:01 +0800 Subject: [PATCH] # --- src/main/webapp/static/js/trayCode/trayCode.js | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/src/main/webapp/static/js/trayCode/trayCode.js b/src/main/webapp/static/js/trayCode/trayCode.js index 6119f5c..91b56e2 100644 --- a/src/main/webapp/static/js/trayCode/trayCode.js +++ b/src/main/webapp/static/js/trayCode/trayCode.js @@ -297,6 +297,17 @@ }); +function printPreview(content) { + var tpl = $('#trayCodeTemplate').html(); + var template = Handlebars.compile(tpl); + var html = template(content); + let box = $("#printBox"); + box.html(html); + box.show(); + box.print(); + box.hide(); +} + // 鍏抽棴鍔ㄤ綔 $(document).on('click','#data-detail-close', function () { parent.layer.closeAll(); -- Gitblit v1.9.1