Edit D:\rfid\libsystem\page\export\js\exportlabelresult.js
var paramjson=null;var LODOP;var printWidth,printHeight;function setLabelDisplayArea(w,p,c,z){var o=w.rows[0];paramjson=JSON.parse(o.paramjson);var v=paramjson.grid;var m=paramjson.propertygrid;var a,b,k,d,y,h;if(paramjson.propertygrid){for(var t=0;t<m.length;t++){if(m[t].code=="pageRows"){a=parseInt(m[t].value)}if(m[t].code=="pageCols"){b=parseInt(m[t].value)}if(m[t].code=="pageFontSize"){k=parseInt(m[t].value)}if(m[t].code=="pageAlignType"){d=m[t].value}if(m[t].code=="labelHeight"){y=parseInt(m[t].value)}if(m[t].code=="labelWidth"){h=parseInt(m[t].value)}}}else{if(paramjson.pageRows){a=parseInt(paramjson.pageRows)}if(paramjson.pageCols){b=parseInt(paramjson.pageCols)}if(paramjson.pageFontSize){k=parseInt(paramjson.pageFontSize)}if(paramjson.pageAlignType){d=paramjson.pageAlignType}if(paramjson.labelHeight){y=parseInt(paramjson.labelHeight)}if(paramjson.labelWidth){h=parseInt(paramjson.labelWidth)}}var s=p.rows.length;var x=p.rows;var g=a*b;var e=parseInt(s%g==0?s/g:(s/g)+1);printHeight=(y*a)*10;printWidth=(h*b)*10;var n="";$(".labelDisplayArea").html(n);var r=true;var l=0;for(var t=0;t<e;t++){r=true;if(d){d="center;"}n+="<div style='page-break-after:always; padding: 0px;font-size:"+k+";text-align:"+d+";'>";n+="<ul class ='label-row-ul' style='width:"+h*b+"mm;height:"+y+"mm;'>";for(var q=t*g;q<(g*(t+1));q++){var u="#eee";r=false;if(q%b==0){if(q>t*g){l++;n+="</ul>";n+="<ul class ='label-row-ul' style='width:"+h*b+"mm;height:"+y+"mm;'>"}}if(l%2==0){u="#ddd";if(q%2==0){u="#f5f5f5"}}else{u="#ccc";if(q%2==0){u="#eee"}}if(c){u="#fff"}var f=x[q];if(f){n+="<li class ='label-row-li-col' >";n+="<ul class ='label-box-data' style = 'width:"+h+"mm;height:"+y+"mm;background:"+u+";'>";n+=getLabelDataByIndex(x[q],v);n+="</ul>";n+="</li>"}else{if(!r){n+="<li class ='label-row-li-col' >";n+="<ul class ='label-box-data' style = 'width:"+h+"mm;height:"+y+"mm;background:"+u+";'>";n+="";n+="</ul>";n+="</li>"}}}l++;n+="</ul>";n+="</div>"}$(".labelDisplayArea").html(n);if(c){if(z&&z==1){printDataBox(c)}else{printPerviewBox(c)}}}function getLabelDataByIndex(r,h){var g="";if(r){for(var e=0;e<h.length;e++){var q=r[h[e].code];if(!q){continue}var b=parseInt(h[e].fldpad);var a="";var l="";var p="";if(parseInt(h[e].fldx)>0){a+="margin-left:"+parseInt(h[e].fldx)+"mm;";l+="margin-left:"+parseInt(h[e].fldx)+"mm;"}if(parseInt(h[e].fldy)>0){a+="margin-top:"+h[e].fldy+"mm;";l+="margin-top:0mm;"}if(parseInt(h[e].fszie)>0){a+="font-size:"+parseInt(h[e].fszie)+"px;";l+="font-size:"+parseInt(h[e].fszie)+"px;"}if(h[e].aligntype){a+="text-align:"+h[e].aligntype+";";l+="text-align:"+h[e].aligntype+";"}if(h[e].fweight){a+="font-weight:"+h[e].fweight+";";l+="font-weight:"+h[e].fweight+";"}if(b>0){l+="margin-top:"+b+"mm;"}var n=h[e].flds;var o=parseInt(h[e].fldn);if(q){if(n.length>0){var f=q.split(n);if(o>0){for(var d=0;d<f.length;d++){if(d==0&&d<o){g+="<li style='"+a+"'>"+f[d]+"</li>"}else{if(d>0&&d<o){g+="<li style='"+l+"'>"+f[d]+"</li>"}else{if(d>0&&d==o){var m="";for(var c=d;c<f.length;c++){m+=f[c];if(c<f.length-1){m+=n}}if(f.length-1==o){m=f[d]}g+="<li style='"+l+"'>"+m+"</li>"}}}}}else{for(var d=0;d<f.length;d++){if(d==0){g+=bulidQrcode(h,e,r,a,f[d])}if(d>0){g+="<li style='"+l+"'>"+f[d]+"</li>"}}}}else{g+=bulidQrcode(h,e,r,a,q)}}else{g+=bulidQrcode(h,e,r,a,q)}}}return g}function bulidQrcode(f,d,j,a,h){var e="";if(f[d].code=="barcode"){var c=j.barcode;if(c&&parseInt(f[d].qrcode)>0){if(paramjson.barcodefs){a+="font-size: "+paramjson.barcodefs+"mm"}e+="<li style='"+a+";text-align: center;'>";if(paramjson.barcodeName){e+="<div>"+paramjson.barcodeName+"</div>"}var g="";if(paramjson.barcodePadding){g="padding:"+paramjson.barcodePadding+";"}var b=2;if(paramjson.barcodewidth){b=paramjson.barcodewidth}e+="<div style='"+g+"'><img id=\"barcode"+c+'"/ ></div>';e+='<script>JsBarcode("#barcode'+c+'","'+c+'",{displayValue:false,margin:0,height:'+f[d].qrcode+",width:"+b+",});<\/script>";e+="<div>"+c+"</div>";e+="</li>"}else{e+="<li style='"+a+"'>"+h+"</li>"}}else{e+="<li style='"+a+"'>"+h+"</li>"}return e}function printPerviewBox(a){CreateOneFormPage();if(LODOP.SET_PRINTER_INDEX(a)){LODOP.PREVIEW()}}function printDataBox(a){CreateOneFormPage();if(LODOP.SET_PRINTER_INDEX(a)){LODOP.PRINT()}}function CreateOneFormPage(){LODOP=getLodop();var c=$(".labelDisplayArea");var a="<style>"+document.getElementById("printstyle1").innerHTML+"</style>";var b=a+"<body>"+c.html()+"</body>";LODOP.SET_LICENSES("??????????????????????????","82FC053A6737263D896A28FB9FD8EE9B","","");LODOP.ADD_PRINT_HTM(0,0,printWidth,printHeight,b);LODOP.SET_PRINT_PAGESIZE(0,printWidth,printHeight+10,"??????")};
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de