
# yyx 20200426
INSERT INTO `print_design` (`active`, `create_time`, `update_time`, `update_by`, `areacode`, `content`, `seq`,`type`)
VALUES
('1', '2020-04-21 18:03:30','2020-04-21 18:03:30', 'system', '110000', ' LODOP.PRINT_INITA("0mm","0mm","300mm","600mm","申请设立保安服务公司行政许可审批表");
			LODOP.SET_SHOW_MODE(''BKIMG_IN_PREVIEW'',1);
strHtml =''<html><head><meta charset="utf-8"><style type="text/css">''+
        ''table,td{text-align: center;vertical-align:middle;border-style: solid;}''+
        ''table,tr{height: 40px;}''+''</style> </head>''+
        ''<body>''+
        ''<table border="1" cellspacing="0" cellpadding="0" class="table3 table8-1 mb-40" style="width:100%;">''+
        ''<tbody>''+
        ''<tr style = "height: 50px"><td colspan="5">申请设立保安服务公司行政许可审批表</td></tr>''+
        ''<tr>''+
        ''<td style="width:16%;">公司名称</td>''+
        ''<td colspan="2" style="width:40%;">''+data.companyname+''</td>''+
        ''<td style="width:8%;">电话</td>''+
        ''<td style="width:24%;">''+(data.tel == null ? " ":data.tel)+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>公司地址</td>''+
        ''<td colspan="2">''+data.address+''</td>''+
        ''<td>邮编</td>''+
        ''<td>''+data.zipcode+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>经营范围</td>''+
        ''<td colspan="4">''+management+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>企业类型</td>''+
        ''<td>''+data.enterprisetype+''</td>''+
        ''<td style="width:16%;">注册资金</td>''+
        ''<td colspan="2">''+
        ''<strong>''+(data.regcapital == null ? " " : data.regcapital)+''（万元）</strong>''+
        ''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td rowspan="2">注册资本验资或评估机构</td>''+
        ''<td rowspan="2">''+(data.assessmentorg == null ? " " : data.assessmentorg)+''</td>''+
        ''<td>货币资本</td>''+
        ''<td colspan="2">''+(data.currency == null ? " " : data.currency)+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>资产评估价值</td>''+
        ''<td colspan="2">''+(data.currencyvalue == null ? " " : data.currencyvalue)+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>拟任法定代表人</td>''+
        ''<td>''+data.representative+''</td>''+
        ''<td>手机及固定电话</td>''+
        ''<td colspan="2">''+data.phone+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>公司管理人员数</td>''+
        ''<td>''+data.companymanger+''</td>''+
        ''<td>专业技术人员数</td>''+
        ''<td colspan="2">''+data.technologynum+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>公司用房面积</td>''+
        ''<td>''+data.areanum+''</td>''+
        ''<td>产权归属</td>''+
        ''<td colspan="2">''+data.ascription+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td>专用运输车辆数</td>''+
        ''<td>''+(data.ascriptionvehicle == null ? " " : data.ascriptionvehicle)+''</td>''+
        ''<td>防爆枪支数</td>''+
        ''<td colspan="2">''+(data.gunnum == null ? " " : data.gunnum)+''</td>''+
        ''</tr>''+
        ''<tr>''+
        ''<td style="width:16%;">提交办事区域</td>''+
        ''<td  colspan="4">''+(data.szss == null ? " " : data.szss)+''</td>''+
        ''</tr>''+
        ''</tbody>''+
        ''</table>''+
        ''</body>''+
        ''</html>'';
LODOP.ADD_PRINT_TABLE("2%","3%","120%","400%",strHtml);
	    LODOP.SET_PRINT_STYLEA(0,"FontName","宋体");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
		LODOP.SET_PRINT_STYLEA(0,"TableHeightScope",4);
		LODOP.PRINT_DESIGN();','1','BAFWXKSP'),
('1', '2020-04-24 10:12:27','2020-04-24 10:12:27', 'system', '110000', ' LODOP.PRINT_INITA("0mm","0mm","300mm","600mm","审批进度");
			LODOP.SET_SHOW_MODE(''BKIMG_IN_PREVIEW'',1);
strHtmlLog =''<html><head><meta charset="utf-8"><style type="text/css">''+
            ''<style type="text/css">''+
''.table-a table td{border-top:1px;}''+
''.table-a table{text-align: center;border:1px solid}''+
''.table-a table tr td{height: 40px;border:solid 1px;border-left: none;border-right: none;}''+

            ''</style>''+
						''</head>''+
            ''<body>''+
            ''<div class = "table-a">''+
            ''<table border="0" cellpadding="0" cellspacing="0"  style="width: 100%;">''+
            ''<thead>''+
            ''<tr style = "height: 50px"><td colspan="6">审批进度</td></tr>''+
            ''<tr>''+
            ''<td width="6%">序号</td>''+
            ''<td width="16%">审批日期</td>''+
            ''<td width="16%" >审批人</td>''+
            ''<td width="12%" >审批结果</td>''+
            ''<td width="16%">审批意见</td>''+
            ''<td width="16%">审批人所在机构</td>''+
            ''</tr>''+
            ''</thead>''+
            ''<tbody>'';
            if(data != null && data.length>0){
                for(var i = 0;i<data.length;i++){
                    if(data[i].approvalid != null){
                        strHtmlLog = strHtmlLog +''<tr>''+
                            ''<td>''+(i+1)+''</td>''+
                            ''<td>''+ new Date(data[i].approvaldate).format("yyyy-MM-dd hh:mm:ss")+''</td>''+
                            ''<td>''+(data[i].approvalperson == null?"没有配置下一级审批人员":data[i].approvalperson)+''</td>''+
                            ''<td>''+data[i].approvalstate+''</td>''+
                            ''<td>''+data[i].approvalreason+''</td>''+
                            ''<td>''+data[i].approvalorg+''</td>''+
                            ''</tr>'';
                    }
                }
            }else{
                strHtmlLog = strHtmlLog +''<tr>''+
                    ''<td colspan="6" class="text-center">暂无相关数据！</td>''+
                    ''</tr>'';
            }
            strHtmlLog = strHtmlLog +''</tbody>''+
                    ''</table>''+
                    ''</div>''
                    ''</body>''+
                    ''</html>'';
LODOP.ADD_PRINT_TABLE("1%","1%","124%","100%",strHtmlLog);
	    LODOP.SET_PRINT_STYLEA(0,"FontName","宋体");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
		LODOP.SET_PRINT_STYLEA(0,"TableHeightScope",4);
		LODOP.PRINT_DESIGN();','2','BAFWXKSP'),
		('1', now(),now(), 'system', '110000',' LODOP.PRINT_INITA("0mm","0mm","300mm","600mm","保安服务公司许可项目审检文件处理签打印");
			LODOP.SET_SHOW_MODE(''BKIMG_IN_PREVIEW'',1);
 var strHtmlTable ='''';
var tableMessage = data.tableMessage;
        var messageMap = data.messageMap;
        var companyDetail = data.companyDetail;
        var approvalMessage = data.approvalMessage;
        var logList = data.logList;
        strHtmlTable =''<html><head><meta charset="utf-8">''+
                ''<style type="text/css">'' +
                ''.tableDiv {font-size: 14px;line-height: 20px;text-align: center;}''+
                ''.tableDiv table {text-align: center;width: 100%;line-height: 28px; border-collapse: collapse;}''+
                ''#approvallog td, table tr, table {border: 1px solid #000;min-width: 20px;}''+
                ''.tableDiv table td, table tr, table {border: 1px solid #000;}''+
                ''.tableDiv .left-text {text-align: left;padding-left: 10px;}''+
                ''.tableDiv table p {padding: 0;margin: 5px 0;}''+
                ''.tableDiv .left{width:425px;float: left;}''+
                ''.create .tasks .task-body {margin-top: 30px;min-height: 485px;}''+
                ''.tableDiv table p {padding: 0;margin: 5px 0;}''+
                ''.tableDiv table .right {float: right;padding-right: 50px;padding-top:100px;}''+
                ''.bold-font {font-weight: bold;}''+
                ''</style></head><body>''+
                ''<div class="tableDiv" id="tableDiv">''+
                '' <h3 class="title">'' + tableMessage.title + ''</h3>'';
        if(companyDetail.businesstype == ''007''){
            strHtmlTable = strHtmlTable +
                ''<table>''+
                ''<tr >'' +
                ''<td rowspan="3" class="bold-font" style="width:20%;">单位<br/>基本<br/>情况</td>'' +
                ''<td class="bold-font bold-height" style="width:20%;">名称</td>'' +
                ''<td colspan="4" style="width:60%;">''+messageMap.oldcompanyname+''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font">许可证<br/>名称</td>'' +
                ''<td>保安服务许可</td>''+
                ''<td class="bold-font">''+tableMessage.certificate+''</td>'' +
                ''<td colspan="2">''+messageMap.licencenum+''</td>'' +
                ''</tr>'' +
                ''<tr class="bold-height">'' +
                ''<td class="bold-font" style="width:20%;">联系人</td>'' +
                ''<td style="width:20%;">''+messageMap.lxlegalname+''</td>'' +
                ''<td class="bold-font" style="width:20%;">联系电话</td>'' +
                ''<td colspan="2" style="width:20%;">''+messageMap.lxlegalphone+''</td>'' +
                ''</tr>'' +
                ''<tr class="bold-height" >'' +
                ''<td class="bold-font">变更项目</td>'' +
                ''<td colspan="2" class="bold-font">原登记内容</td>'' +
                ''<td colspan="3" class="bold-font">变更后登记内容</td>'' +
                ''</tr>'' ;
            if(messageMap.bgregisteredMoney != null){
                strHtmlTable = strHtmlTable+
                    ''<tr class="bold-height bold-font">'' +
                    ''<td>注册资本</td>'' +
                    ''<td colspan="2">''+messageMap.oldregisteredMoney+''</td>'' +
                    ''<td colspan="3">''+messageMap.bgregisteredMoney+''</td>'' +
                    ''</tr>'';
            }
            if(messageMap.address != null){
                strHtmlTable = strHtmlTable+
                    ''<tr class="bold-height bold-font">'' +
                    ''<td>地址变更</td>'' +
                    ''<td colspan="2">''+messageMap.oldaddress+''</td>'' +
                    ''<td colspan="3">''+messageMap.address+''</td>'' +
                    ''</tr>'';
            }
            if(messageMap.companyname != null){
                strHtmlTable = strHtmlTable+
                    ''<tr class="bold-height bold-font">'' +
                    ''<td>公司名称变更</td>'' +
                    ''<td colspan="2">''+messageMap.oldcompanyname+''</td>'' +
                    ''<td colspan="3">''+messageMap.companyname+''</td>'' +
                    ''</tr>'';
            }
            if(messageMap.securityScopes != null){
                strHtmlTable = strHtmlTable+
                    ''<tr class="bold-height bold-font">'' +
                    ''<td>服务范围变更</td>'' +
                    ''<td colspan="2" >''+messageMap.oldsecurityScopes+''</td>'' +
                    ''<td colspan="3">''+messageMap.securityScopes+''</td>'' +
                    ''</tr>'';
            }
            if(messageMap.ndlegalname != null){
                strHtmlTable = strHtmlTable+
                    ''<tr class="bold-height bold-font">'' +
                    ''<td>法人变更</td>'' +
                    ''<td colspan="2">''+messageMap.legalname+''</td>'' +
                    ''<td colspan="3">''+messageMap.ndlegalname+''</td>'' +
                    ''</tr>'';
            }
            strHtmlTable = strHtmlTable +
                ''<tr>'' +
                ''<td rowspan="10" class="bold-font">提供<br/>材料<br/>目录</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text" style="color: #f00;"><input type="checkbox" class="check-box">变更申请书（应当载明变更项目）。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安服务（培训）许可证副本。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">变更单位名称：保安服务公司、学校、职业培训机构更名的有效证明文件。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">变更单位住所：变更后住所的所有权或者使用权的有效证明文件，保安培训场所理论课教室、训练场地符合条件的证明材料。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安服务公司变更法定代表人：法定代表人变更证明文件、有效身份证件和保安师资格证书复印件、简历、相关工作经验证明。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安培训机构变更法定代表人：法定代表人变更证明文件、有效身份证复印件。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安服务公司变更服务范围：提供保安服务所需的有关设备、交通工具等材料，专业技术人员名单和法律、行政法规有资格要求的资格证明。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安培训机构变更培训内容：开展培训所需设施、设备等证明材料及相应师资人员的资格证明文件复印件。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">保安服务公司变更注册资本：注册资本验资证明、国有资产评估文件复印件。</td>'' +
                ''</tr>'' +
                ''<tr style="height: 200px;">'' +
                ''<td class="bold-font">申请单位法<br/>定代表人<br/>签名盖章</td>'' +
                ''<td colspan="5">'' +
                ''<div class="list-wrap">'' +
                ''<p class="bold-font">对上述填写和提交的材料真实有效性负责。</p><br>'' +
                ''<p class="left">法定代表人姓名：''+messageMap.lxlegalname+''</p>'' +
                ''<p class="right bold-font">''+messageMap.createTime+''</p>'' +
                ''</div>'' +
                ''</td>'' +
                ''</tr>'' +
                ''</table>'';
        }
        if(companyDetail.businesstype != ''007''){
            strHtmlTable = strHtmlTable +
                ''<table>'' +
                ''<tbody>'' +

                ''<tr>'' +
                ''<td rowspan="5" class="bold-font" style="width:20%;">拟设立<br/>公司<br/>（培训单位）<br/>基本情况</td>'' +
                ''<td class="bold-font bold-height" style="width:20%;">名称</td>''+
                ''<td colspan="4" style="width:60%;">''+messageMap.companyname+''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font bold-height">地址</td>'' +
                ''<td colspan="4">''+messageMap.address+''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font" style="width:20%;">法定代表人<br/>姓名</td>'' +
                ''<td style="width:20%;">''+messageMap.legalname+''</td>'' +
                ''<td class="bold-font" style="width:15%;">身份证号码</td>'' +
                ''<td colspan="2" style="width:25%;">''+messageMap.legalPersonNo+''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font bold-height">总经理姓名</td>'' +
                ''<td>''+messageMap.mangername+''</td>'' +
                ''<td class="bold-font">身份证号码</td>'' +
                ''<td colspan="2">''+messageMap.vmangerNo+''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font bold-height">副总经理姓名</td>'' +
                ''<td>''+messageMap.vmangername+''</td>'' +
                ''<td class="bold-font">身份证号码</td>'' +
                ''<td colspan="2">''+messageMap.mangerNo+''</td>'' +
                ''</tr>'' +
                ''<tr class="bold-height">'' +
                ''<td class="bold-font">认缴资金</td>'' +
                ''<td colspan="2" align="right">''+messageMap.regcapital+''（万元）</td>'' +
                ''<td class="bold-font">实地<br>核查人</td>'' +
                ''<td colspan="2"></td>'' +
                ''</tr>'' +
                ''<td class="bold-font">服务范围</td>'' +
                ''<td colspan="5">'' +
                ''<div class="list-wrap">'' +
                ''<p class="left-text">''+messageMap.management+''</p>'' +
                ''</div>'' +
                ''</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td rowspan="7" class="bold-font">提供材料<br/>目录</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"  ><input type="checkbox" class="check-box">设立申请书<span style="color: blue;margin-left: 0px" >（应当载明拟设立公司或培训机构的基本情况）。</span></td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"  ><input type="checkbox" class="check-box">拟任的保安服务公司法定代表人、总经理、副总经理等管理人员的有效身份证件、简历，''+
                ''保安师资格证书复印件，5年以上军队、公安、安全、审判、检察、司法行政或者治安保卫、保安经营管理工作经验证明。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text" style="color: blue;"><input type="checkbox" class="check-box">拟设保安服务公司住所的所有权或者使用权的有效证明文件和提供保安服务所需的有关设备、交通工具等材料；'' +
                ''<input type="checkbox" class="check-box">保安培训所需场所、设施等教学条件证明。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text" style="color: blue;"><input type="checkbox" class="check-box">专业技术人员名单及资格证明； <input type="checkbox" class="check-box">保安培训所需的师资力量。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                '' <td colspan="5" class="left-text" ><input type="checkbox" class="check-box">组织机构和保安服务管理制度、岗位责任制度、保安员管理制度材料。</td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td colspan="5" class="left-text"><input type="checkbox" class="check-box">企业名称预先核准通知书； <span style="color: blue;margin-left: 0;"><input type="checkbox" class="check-box">''+
                ''依法设立保安服务公司或依法设立的具有法人资格的学校、职业培训机构的证明材料。</span></td>'' +
                ''</tr>'' +
                ''<tr>'' +
                ''<td class="bold-font">申请单位法<br/>定代表人<br/>签名盖章</td>'' +
                ''<td colspan="5">'' +
                ''<div class="list-wrap">'' +
                ''<p class="bold-font">对上述填写和提交的材料真实有效性负责。</p>'' +
                ''<br>'' +
                ''<p class="left-text">法定代表人姓名：''+messageMap.legalname+''</p>'' +
                ''<p class="right bold-font">''+messageMap.createTime+''</p>'' +
                ''</div>'' +
                ''</td>'' +
                ''</tr>'' +
                ''</tbody>'' +
                ''</table>'';
        }
        strHtmlTable = strHtmlTable +
            ''<table style="page-break-after: always;" ></table>'' +
            ''<div class="create">'' +
            ''<div class="container tasks">'' +
            ''<div class="task-body">'' +
            ''<table style="top:100px;">'' +
            ''<tr>'' +
            ''<td class="bold-font approvalReason">''+tableMessage.approvalReason1+''</td>'' +
            ''<td colspan="5">'' +
            ''<div class="left">'' +
            ''<p>''+(approvalMessage.approvalPoliceStationReason == null ? " ":approvalMessage.approvalPoliceStationReason)+''</p>'' +
            ''</div>'' +
            ''<div class="right">'' +
            ''<p style="padding-left:5px;">签名：''+(approvalMessage.personPoliceStationName == null ? " ":approvalMessage.personPoliceStationName)+''</p>'' +
            ''<p>''+(approvalMessage.approvalPoliceStationDate == null ? " ":approvalMessage.approvalPoliceStationDate)+''</p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''<tr>'' +
            ''<td class="bold-font approvalReason">''+tableMessage.approvalReason2+''</td>'' +
            ''<td colspan="5">'' +
            ''<div class="left" style="padding-left: 10px;">'' +
            ''<p>''+(approvalMessage.approvalBranchLeaderReason == null ? " ":approvalMessage.approvalBranchLeaderReason)+''</p>'' +
            ''</div>'' +
            ''<div class="right" >'' +
            ''<p style="padding-left:5px;">签名：''+(approvalMessage.personBranchLeaderName == null ? " ":approvalMessage.personBranchLeaderName)+''</p>'' +
            ''<p>''+(approvalMessage.approvalBranchLeaderDate == null ? " ":approvalMessage.approvalBranchLeaderDate)+''</p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''<tr>'' +
            ''<td class="bold-font approvalReason">''+tableMessage.approvalReason3+''</td>'' +
            ''<td colspan="5">'' +
            ''<div class="left">'' +
            ''<p>''+(approvalMessage.approvalTeamLeaderReason == null ? " ":approvalMessage.approvalTeamLeaderReason)+''</p>'' +
            ''</div>'' +
            ''<div class="right">'' +
            ''<p style="padding-left:5px;">签名：''+(approvalMessage.personTeamLeaderName == null ? " ":approvalMessage.personTeamLeaderName)+''</p>'' +
            ''<p>''+(approvalMessage.approvalTeamLeaderDate == null ? " ":approvalMessage.approvalTeamLeaderDate)+''</p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''<tr>'' +
            ''<td class="bold-font approvalReason">''+tableMessage.approvalReason4+''</td>'' +
            ''<td colspan="5">'' +
            ''<div class="left">'' +
            ''<p>''+(approvalMessage.approvalTeamMainLeaderReason == null ? " ":approvalMessage.approvalTeamMainLeaderReason)+''</p>'' +
            ''</div>'' +
            ''<div class="right">'' +
            ''<p style="padding-left:5px;">签名：''+(approvalMessage.personTeamMainLeaderName == null ? " ":approvalMessage.personTeamMainLeaderName)+''</p>'' +
            ''<p>''+(approvalMessage.approvalTeamMainLeaderDate == null ? " ":approvalMessage.approvalTeamMainLeaderDate)+''</p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''<tr>'' +
            ''<td class="bold-font approvalReason">''+tableMessage.approvalReason5+''</td>'' +
            ''<td colspan="5">'' +
            ''<div class="left">'' +
            ''</div>'' +
            ''<div class="right" >'' +
            ''<p style="padding-left:5px;">签名：</p>'' +
            ''<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;年&nbsp;&nbsp;&nbsp;&nbsp;月&nbsp;&nbsp;&nbsp;&nbsp;日</p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''<tr >'' +
            ''<td class="bold-font " style="height: 40px;">备注</td>'' +
            ''<td colspan="5">'' +
            ''<div class="list-wrap">'' +
            ''<p class="left"></p>'' +
            ''</div>'' +
            ''</td>'' +
            ''</tr>'' +
            ''</table>'' +
            ''</div>'' +
            ''</div>'' +
            ''</div>'' +
            ''<table style="page-break-after: always;" ></table>'' +
            ''<div class="create">'' +
            ''<div class="container tasks">'' +
            ''<div class="task-body">'' +
            ''<table cellpadding="0" id="approvallog" cellspacing="0" class="task-con approval-con" style="width: 100%;overflow:auto;">'' +
            ''<thead>'' +
            ''<tr style="border-right: 1px solid #ddd;">'' +
            ''<td width="4%" align="center">序号</td>'' +
            ''<td width="18%" align="center">审批日期</td>'' +
            ''<td width="23%" align="center">审批人</td>'' +
            ''<td width="10%" align="center">审批结果</td>'' +
            ''<td width="15%" align="center">审批意见</td>'' +
            ''<td width="30%" align="center">审批人所在机构</td>'' +
            ''</tr>'' +
            ''</thead>'' +
            ''<tbody>'' ;
        if(logList != null && logList.length>0){
            for(var i = 0;i<logList.length;i++){
                if(logList[i].approvalperson != null || logList[i].approvalorg != null){
                    strHtmlTable = strHtmlTable +''<tr>''+
                        ''<td style="text-align:center">''+(i+1)+''</td>''+
                        ''<td style="text-align:center">''+ new Date(logList[i].approvaldate).format("yyyy-MM-dd hh:mm:ss")+''</td>''+
                        ''<td>''+(logList[i].approvalperson == null?"没有配置下一级审批人员":logList[i].approvalperson)+''</td>''+
                        ''<td style="text-align:center">''+logList[i].approvalstate+''</td>''+
                        ''<td style="text-align:center">''+logList[i].approvalreason+''</td>''+
                        ''<td style="text-align:center">''+logList[i].approvalorg+''</td>''+
                        ''</tr>'' ;

                }
            }
        }
        else{
            strHtmlTable = strHtmlTable +''<tr>''+
                ''<td colspan="6" class="text-center">暂无相关数据！</td>''+
                ''</tr>'';
        }
        strHtmlTable = strHtmlTable +''</tbody>''+
            ''</table>''+
            ''</div>''+
            ''<nav class="text-center pager-bottom" id="approvalcallBackPager" style="bottom:0"></nav>''+
            ''</div></div></div>''+
            ''</body>''+
            ''</html>'';
LODOP.ADD_PRINT_TABLE("1%","1%","124%","100%",strHtmlTable);
	    LODOP.SET_PRINT_STYLEA(0,"FontName","宋体");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
		LODOP.SET_PRINT_STYLEA(0,"TableHeightScope",4);
		LODOP.PRINT_DESIGN();','3','BAFWXKSP');



# yyx 20200426

delete from  operation where module_id in(191,192,193,194,195,196,197,198,199,200,201,202,203,204,205);
INSERT INTO `operation` (`id`, `native_code`, `code`, `name`, `module_id`, `active`, `create_time`, `update_time`, `update_by`)
VALUES
(null, null, 'export', '导出', '191', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '192', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '193', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '194', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '195', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '196', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '197', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '198', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '199', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '200', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '201', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '202', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '203', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '204', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'export', '导出', '205', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '191', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '192', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '193', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '194', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '195', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '196', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '197', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '198', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '199', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '200', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '201', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '202', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '203', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '204', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'query', '查询', '205', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '191', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '192', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '193', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '194', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '195', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '196', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '197', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '198', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '199', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '200', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '201', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '203', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '204', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'edit', '查看', '205', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '191', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '192', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '193', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '194', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '195', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '196', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '197', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '198', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '199', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '200', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '201', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '203', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '204', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system'),
(null, null, 'add', '新增', '205', b'1', '2020-02-28 10:13:20', '2020-02-28 10:13:20', 'system');


delete from  permission where module_id in(191,192,193,194,195,196,197,198,199,200,201,202,203,204,205);
INSERT INTO `permission`  (`role_id`, `module_id`, `operation_id`, `roletype`)
select pr.id,o.module_id,o.id,'2'
from police_role pr,police p,operation o,module m
where pr.active=true
and p.active=TRUE
and o.active=TRUE
and pr.orgid=p.id
and o.module_id=m.id
and m.id in(191,192,193,194,195,196,197,198,199,200,201,202,203,204,205);


#070 保安员资格证打印配置
delete from print_design where `type`='BAYZGZ';
INSERT INTO `print_design` (`active`, `create_time`, `update_time`, `update_by`, `areacode`, `content`, `seq`, `type`) VALUES (true, now(), now(), 'system', '610000', 'var printState = 0,LODOP = perCerPrintUtil.getLodop();\r\n        LODOP.PRINT_INITA(\"0mm\", 0, \"210mm\", \"297mm\", \"陕西保安员证书打印\");\r\n        LODOP.SET_PRINT_MODE(\"BKIMG_IN_PREVIEW\", 1);\r\n        LODOP.ADD_PRINT_SETUP_BKIMG(\"<img border=\'0\' src=\'\" + restHost +  securityPic + \"\'+>\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_LEFT\", 0);\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_TOP\", 0);\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_WIDTH\", \"210mm\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_HEIGHT\", \"297mm\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_IN_PREVIEW\", true);\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_PRINT\", true);\r\n        for (i = 0; i < detail.length; i += 2) {\r\n            if(detail[i] != null && typeof(detail[i] != \'undefined\')) {\r\n                LODOP.NewPage();\r\n                LODOP.ADD_PRINT_TEXT(260 + 36, 517, 133, 20, detail[i].xm);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.ADD_PRINT_TEXT(370, 518, 171, 56, detail[i].address == null ? \'\' : detail[i].address.substring(0, 9) + \"\\r\\n\" + detail[i].address.substring(9, detail[i].address.length));\r\n                LODOP.SET_PRINT_STYLEA(2,\"ReadOnly\",0);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LineSpacing\", 3);\r\n                LODOP.ADD_PRINT_TEXT(334, 517, 163, 20, changeBirthFormat(getBirthdayFromIDNo(detail[i].idnum)));\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(462, 541, 239, 20, detail[i].idnum);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(360, 223, 200, 20, (detail[i].fzrq == null ? \"\" : changeBirthFormat(detail[i].fzrq.substring(0, 10))));\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(462, 207, 186, 20, detail[i].zsbh);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -2);\r\n                LODOP.ADD_PRINT_TEXT(145, 168, 111, 20, detail[i].xm);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n                //照片\r\n                if(detail[i].photo != null && detail[i].photo !=\"\") {\r\n                    LODOP.ADD_PRINT_IMAGE(138, 488, \"26.00mm\", \"32.00mm\", \"data:image/jpg;base64,\" + detail[i].photo);//+1\r\n                }\r\n\r\n                LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n                //二维码50\r\n                LODOP.ADD_PRINT_IMAGE(182, 282, 99, 99,detail[i].qrcode);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n            }\r\n            if (detail[i + 1] != null && typeof(detail[i + 1] != \'undefined\')) {\r\n                LODOP.ADD_PRINT_TEXT(778, 517, 133, 20, detail[i + 1].xm);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.ADD_PRINT_TEXT(816, 518, 163, 20, changeBirthFormat(getBirthdayFromIDNo(detail[i + 1].idnum)));\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(852, 518, 171, 56, detail[i + 1].address == null ? \'\' : detail[i + 1].address.substring(0, 9) + \"\\r\\n\" + detail[i + 1].address.substring(9, detail[i + 1].address.length));\r\n                LODOP.SET_PRINT_STYLEA(12,\"ReadOnly\",0);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LineSpacing\", 3);\r\n                LODOP.ADD_PRINT_TEXT(945, 541, 239, 20, detail[i + 1].idnum);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(627, 168, 111, 20, detail[i + 1].xm);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.ADD_PRINT_TEXT(842, 223, 200, 20, (detail[i + 1].fzrq == null ? \"\" : changeBirthFormat(detail[i + 1].fzrq.substring(0, 10))));\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n                LODOP.ADD_PRINT_TEXT(945, 204, 186, 20, detail[i + 1].zsbh);\r\n                LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n                LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -2);\r\n                //照片\r\n                if(detail[i+1].photo != null && detail[i+1].photo !=\"\") {\r\n                    LODOP.ADD_PRINT_IMAGE(617, 488, \"26.00mm\", \"32.00mm\", \"data:image/jpg;base64,\" + detail[i + 1].photo);\r\n                }\r\n                LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);//二维码\r\n                //二维码50\r\n                LODOP.ADD_PRINT_IMAGE(666, 282, 99, 99,detail[i + 1].qrcode);\r\n                LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n            }\r\n        }\r\n\r\n        //直接打印返回逻辑真假结果（1或true代表真，false或0代表假），表示是否成功（关于进一步捕获打印状态参考样例45）；\r\n        //打印维护和打印预览返回打印次数，大于0表示打印成功的次数；\r\n        //谷歌浏览器\r\n        if (LODOP.CVERSION) {\r\n            CLODOP.On_Return = function (TaskID, Value) {\r\n                //打印状态\r\n                printState = Value;\r\n                if(printState >= 1){\r\n                    var snapshotIdArr=[];\r\n                    var idArr=[];\r\n                    for (i = 0; i < detail.length; i++) {\r\n                        idArr.push(detail[i].securitypersonid);\r\n                        snapshotIdArr.push(detail[i].snapshotId);\r\n                    }\r\n                    perCerPrintUtil.updatePrinted(idArr,snapshotIdArr);\r\n                    $(\'#dataTable\').datagrid(\'clearChecked\');\r\n                    //查询刷新\r\n                    setTimeout(\"refresh();\",1000);\r\n                    setTimeout(\"layer.closeAll();\",1500);\r\n                }\r\n            };\r\n        }\r\n        printState = LODOP.PRINT_SETUP();', '1', 'BAYZGZ');
INSERT INTO `print_design` (`active`, `create_time`, `update_time`, `update_by`, `areacode`, `content`, `seq`, `type`) VALUES (true, now(), now(), 'system', '640000', 'var printState = 0,LODOP = perCerPrintUtil.getLodop();\r\n        LODOP.PRINT_INITA(\"0mm\", 0, \"210mm\", \"148.51mm\", \"宁夏保安员证书打印\");\r\n        LODOP.SET_PRINT_MODE(\"BKIMG_IN_PREVIEW\", 1);\r\n        LODOP.PRINT_INITA(\"0mm\", 0, \"210mm\", \"148.51mm\", \"宁夏保安员证书打印\");\r\n        LODOP.SET_PRINT_MODE(\"PRINT_NOCOLLATE\", 1);\r\n        LODOP.ADD_PRINT_TEXT(219, 430, 133, 20, detail.xm);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.ADD_PRINT_TEXT(277, 428, 214, 56, detail.address == null ? \'\' : detail.address.substring(0, 9) + \"\\r\\n\" + detail.address.substring(9, detail.address.length));\r\n        LODOP.SET_PRINT_STYLEA(2, \"ReadOnly\", 0);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LineSpacing\", 3);\r\n        LODOP.ADD_PRINT_TEXT(248, 429, 163, 20, changeBirthFormat(getBirthdayFromIDNo(detail.idnum)));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(363, 450, 239, 20, detail.idnum);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(308, 183, 200, 20, (detail.fzrq == null ? \"\" : changeBirthFormatFZRQ(detail.fzrq.substring(0, 10))));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(365, 124, 186, 20, detail.zsbh);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -2);\r\n        LODOP.ADD_PRINT_TEXT(61, 107, 111, 20, detail.xm);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.ADD_PRINT_IMAGE(45, 419, \"26.01mm\", \"31.99mm\", detail.photo);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        LODOP.ADD_PRINT_IMAGE(136, 280, 99, 99, detail.qrcode);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        //谷歌浏览器\r\n        if (LODOP.CVERSION) {\r\n            CLODOP.On_Return = function (TaskID, Value) {\r\n                //打印状态\r\n                printState = Value;\r\n                if(printState >= 1){\r\n                    perCerPrintUtil.updatePrinted(detail.securitypersonid,detail.snapshotId);\r\n                    //查询刷新\r\n                    setTimeout(\"refresh();\",1000);\r\n                    setTimeout(\"layer.closeAll();\",1500);\r\n                }\r\n            };\r\n        }\r\n        printState = LODOP.PRINT_SETUP();', '1', 'BAYZGZ');
INSERT INTO `print_design` (`active`, `create_time`, `update_time`, `update_by`, `areacode`, `content`, `seq`, `type`) VALUES (true, now(), now(), 'system', '450000', 'var printState = 0,LODOP = perCerPrintUtil.getLodop();\r\n        LODOP.PRINT_INITA(\"0mm\", 0, \"210mm\", \"148.51mm\", \"广西保安员证书打印\");\r\n        LODOP.SET_PRINT_MODE(\"BKIMG_IN_PREVIEW\", 1);\r\n        LODOP.ADD_PRINT_TEXT(266, 459, 133, 20, detail.xm);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.ADD_PRINT_TEXT(325, 459, 171, 56, detail.address == null ? \'\' : detail.address.substring(0, 9) + \"\\r\\n\" + detail.address.substring(9, detail.address.length));\r\n        LODOP.SET_PRINT_STYLEA(2, \"ReadOnly\", 0);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LineSpacing\", 3);\r\n        LODOP.ADD_PRINT_TEXT(294, 459, 163, 20, changeBirthFormat(getBirthdayFromIDNo(detail.idnum)));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(379, 501, 239, 20, detail.idnum);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(304, 180, 200, 20, (detail.fzrq == null ? \"\" : changeBirthFormatFZRQ(detail.fzrq.substring(0, 10))));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        LODOP.ADD_PRINT_TEXT(359, 186, 186, 20, detail.zsbh.replace(\"桂\", \"\"));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -2);\r\n        LODOP.ADD_PRINT_TEXT(105, 112, 111, 20, detail.xm);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        //照片\r\n        LODOP.ADD_PRINT_IMAGE(45, 454, \"26.00mm\", \"32.00mm\", detail.photo);//+1\r\n        LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        //二维码50\r\n        LODOP.ADD_PRINT_IMAGE(142, 212, 99, 99, detail.qrcode);\r\n        LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        //谷歌浏览器\r\n        if (LODOP.CVERSION) {\r\n            CLODOP.On_Return = function (TaskID, Value) {\r\n                //打印状态\r\n                printState = Value;\r\n                if(printState >= 1) {\r\n                    perCerPrintUtil.updatePrinted(detail.securitypersonid, detail.snapshotId);\r\n                    //查询刷新\r\n                    setTimeout(\"refresh();\", 1000);\r\n                    setTimeout(\"layer.closeAll();\", 1500);\r\n                }\r\n            };\r\n        }\r\n        printState = LODOP.PRINT_SETUP();', '1', 'BAYZGZ');
INSERT INTO `print_design` (`active`, `create_time`, `update_time`, `update_by`, `areacode`, `content`, `seq`, `type`) VALUES (true, now(), now(), 'system', '110000', 'var printState = 0,LODOP = perCerPrintUtil.getLodop();\r\n        LODOP.PRINT_INITA(\"-2.38mm\", -7, \"169.99mm\", \"144.99mm\", \"北京保安员证书打印V3.5.1\");\r\n        LODOP.SET_PRINT_MODE(\"PRINT_NOCOLLATE\", 1);\r\n        LODOP.ADD_PRINT_SETUP_BKIMG(\"<img border=\'0\' src=\'\" + restHost + securityPic + \"\'+>\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_LEFT\", -50);\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_TOP\", -50);\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_WIDTH\", \"205.32mm\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_HEIGHT\", \"144.99mm\");\r\n        LODOP.SET_SHOW_MODE(\"BKIMG_PRINT\", true);\r\n        //照片\r\n        if (detail.photo) {\r\n            LODOP.ADD_PRINT_IMAGE(30, 104, \"26.01mm\", \"31.99mm\", detail.photo);//+1\r\n            LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        } else {\r\n            LODOP.ADD_PRINT_IMAGE(30, 104, \"26.01mm\", \"31.99mm\", \"\");//+1\r\n            LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        }\r\n        //二维码50\r\n        LODOP.ADD_PRINT_IMAGE(91, 501, 116, 111, detail.qrcode);\r\n\r\n        LODOP.SET_PRINT_STYLEA(0, \"Stretch\", 2);\r\n        //姓名\r\n        LODOP.ADD_PRINT_TEXT(193, 109, 133, 20, detail.xm);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        // LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        //地址\r\n        LODOP.ADD_PRINT_TEXT(300, 110, 171, 56, detail.address == null ? \'\' : detail.address.substring(0, 9) + \"\\r\\n\" + detail.address.substring(9, detail.address.length));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        //  LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LineSpacing\", 3);\r\n        //民族\r\n        LODOP.ADD_PRINT_TEXT(227, 110, 163, 20, detail.nation);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        //LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        //出生日期\r\n        LODOP.ADD_PRINT_TEXT(266, 110, 163, 20, changeBirthFormat(getBirthdayFromIDNo(detail.idnum)));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        //LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        //身份证号\r\n        LODOP.ADD_PRINT_TEXT(391, 111, 163, 20, detail.idnum);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        //LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n\r\n        //发证日期\r\n        LODOP.ADD_PRINT_TEXT(325, 461, 200, 20, (detail.fzrq == null ? \"\" : changeBirthFormatFZRQBJ(detail.fzrq.substring(0, 10))));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 12);\r\n        // LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -1);\r\n        //编号\r\n        LODOP.ADD_PRINT_TEXT(383, 496, 186, 20, detail.zsbh.replace(\"京\", \"\"));\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        // LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"LetterSpacing\", -2);\r\n        //姓名\r\n        LODOP.ADD_PRINT_TEXT(34, 432, 75, 20, detail.xm);\r\n        // LODOP.SET_PRINT_STYLEA(0, \"Bold\", 1);\r\n        LODOP.SET_PRINT_STYLEA(0, \"FontSize\", 16);\r\n        //谷歌浏览器\r\n        if (LODOP.CVERSION) {\r\n            CLODOP.On_Return = function (TaskID, Value) {\r\n                //打印状态\r\n                printState = Value;\r\n                if(printState >= 1) {\r\n                    perCerPrintUtil.updatePrinted(detail.securitypersonid, detail.snapshotId);\r\n                    //查询刷新\r\n                    setTimeout(\"refresh();\", 1000);\r\n                    setTimeout(\"layer.closeAll();\", 1500);\r\n                }\r\n            };\r\n        }\r\n        //打印维护\r\n        printState = LODOP.PRINT_SETUP();', '1', 'BAYZGZ');


delete from config where `key` like 'PERCERURL%';
INSERT INTO `config` (`key`, `value`, `name`, `active`, `create_time`, `update_time`, `update_by`)
VALUES ('PERCERURL450000', 'http://gx.baibaodun.cn/', '资格证地址', true,now(),now(), 'system'),
('PERCERURL610000', 'http://sn.baibaodun.cn/', '资格证地址', true,now(),now(), 'system'),
('PERCERURL640000', 'http://nx.baibaodun.cn/', '资格证地址', true,now(),now(), 'system'),
('PERCERURL110000', 'http://bj.baibaodun.cn:8801/ars-web/', '资格证地址', true,now(),now(), 'system');

delete from sys_dict where codeType='isolddata';
INSERT INTO `sys_dict` (`isActive`, `codeType`, `tableName`, `description`, `codeValue`, `label`, `seq`)
VALUES
('1', 'isolddata', NULL, '是否历史导入数据', '0', '否', '1'),
('1', 'isolddata', NULL, '是否历史导入数据', '1', '是', '2');


