Commit 4922e5a5 by 肖康

打印调整

parent 2053e8ab
......@@ -438,6 +438,9 @@ var tag={
$(".edit-con .gezi").remove();
$(".edit-con .huabuitem").removeClass("act");
$(".edit-con").removeClass("init-border");
if(!$(".tag-border").val()){
$(".edit-con").css({"border":"0px"})
}
obj.htmlp=String($(".edit-box").html());
obj.designName=$(".designName").val();
if($("#templateid").val()){
......
......@@ -22,7 +22,7 @@
<div class="seclect-group fl">
<span>标签大小:</span>
<select class="tag-size">
<option value="440*300">90*60</option>
<option value="440*280">90*60</option>
</select>
</div>
<div class="seclect-group fl">
......@@ -51,7 +51,7 @@
</div>
</div>
<div class="fztip">格子区域为画图区域,每个辅助格子20px*20px,从左上角开始,横向为X轴,纵向为Y轴,标尺每个刻度10px,标尺实际像素需要刻度值*10</div>
<div class="fztip">格子区域为画图区域,每个辅助格子20px*20px,从左上角开始,横向为X轴,纵向为Y轴,标尺每个刻度10px</div>
<div class="fztip" style="color:red;">双击删除编辑区域内标签工具!!!!!!</div>
<div class="fztip" ><span style="color:red;">颜色选择器,复制此处颜色可用 </span><input type="text" id="colorpicker" /></div>
......
......@@ -3,7 +3,8 @@
<style>
body{background:#fff;margin:0px;}
.edit-con{margin:10px;}
/* .edit-con{height:307px!important;} */
.print{padding-top:20px;padding-left:15px;}
.layui-btn{
display: inline-block;
height: 38px;
......@@ -19,23 +20,27 @@
cursor: pointer;
}
</style>
<div class="dybox">
@foreach($html as $item)
<div class="print">
{!! $item !!}
@endforeach
</div>
@endforeach
<script src="../../../../js/jquery-2.2.1.js"></script>
<script type="text/javascript">
$(function(){
$(".print").width($(".edit-con").width());
if($(".edit-con").height()==280){
$(".edit-con").css({"height":"307px"})
}
$(".huabuitem[type='6'],.huabuitem[type='7']").each(function(){
var urlo_=$(this).css("backgroundImage").replace('url(','').replace(')','');
$(this).css({"background":""})
$(this).html("<img src='"+urlo_.substring(1,urlo_.length-1)+"' />");
$(this).find("img").css({width:"100%",height:"100%"})
})
// setTimeout(function(){
// window.print();
// }, 100);
setTimeout(function(){
window.print();
}, 100);
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment