/** * */ var baseUrl = ''; var theme = ''; var viewAlarmType,pieAlarmType,statusType; var filterwin; var FilterWin; Ext.onReady(function(){ baseUrl = document.getElementById('basePath').value; theme = document.getElementById('theme').value; $("#V_LOGINNAME").val(sessionStorage.getItem('V_LOGINNAME')); $("#V_PASSWORD").val(sessionStorage.getItem('V_PASSWORD')); var queryJson = new Object(); // queryJson.V_LOGINNAME = $("#V_LOGINNAME").val(); // queryJson.V_PASSWORD = $("#V_PASSWORD").val(); var draw_confirm = function(start_data,end_data,project_date){ var start_data = start_data; var end_data = end_data; var project_date = project_date; var woker_talk = document.getElementById('woker_talk'); var div1 = document.createElement('div'); div1.width=580; div1.height=841; div1.setAttribute('id','div1_label1'); woker_talk.appendChild(div1); var title = document.createElement('h2'); title.id = 'device_list_status_title'; title.style.fontSize='14px'; title.style.textAlign='center'; title.style.fontWeight='bold'; title.innerHTML=ConfirmStore[0].company_name+'消防报警系统监测数据'; div1.appendChild(title); var title1 = document.createElement('h2'); title1.style.textAlign='center'; title1.style.fontSize='14px'; title1.style.fontWeight='bold'; title1.innerHTML=project_date+'月报表'; div1.appendChild(title1); var title2 = document.createElement('h3'); title2.style.textAlign='left'; title2.style.fontSize='14px'; title2.style.fontWeight='bold'; title2.innerHTML='1 基本情况'; div1.appendChild(title2); var title88 = document.createElement('h4'); title88.style.textAlign='left'; title88.style.fontSize='14px'; title88.style.fontWeight='bold'; title88.innerHTML='1.1 项目情况'; div1.appendChild(title88); var sta = document.createElement('table'); sta.style.marginTop='10px'; sta.width='100%'; sta.style.marginBottom='20px'; sta.style.borderRight ='1px solid #BEBEBE'; sta.style.borderBottom ='1px solid #BEBEBE'; div1.appendChild(sta); var tr = document.createElement('tr'); sta.appendChild(tr); var td = document.createElement('td'); td.width='20%'; td.style.borderLeft ='1px solid #BEBEBE'; td.style.borderTop ='1px solid #BEBEBE'; td.style.textAlign='center'; td.innerHTML='单位名称'; td.style.fontSize='14px'; tr.appendChild(td); var td1 = document.createElement('td'); td1.width='80%'; td1.colSpan='5'; td1.style.textAlign='center'; td1.style.borderLeft ='1px solid #BEBEBE'; td1.style.borderTop ='1px solid #BEBEBE'; td1.innerHTML=ConfirmStore[0].company_name; td1.style.fontSize='14px'; tr.appendChild(td1); var tr1 = document.createElement('tr'); sta.appendChild(tr1); var td2 = document.createElement('td'); td2.width='20%'; td2.style.textAlign='center'; td2.style.borderLeft ='1px solid #BEBEBE'; td2.style.borderTop ='1px solid #BEBEBE'; td2.innerHTML='进场日期'; td2.style.fontSize='14px'; tr1.appendChild(td2); var td3 = document.createElement('td'); td3.width='16%'; td3.style.textAlign='center'; td3.style.borderLeft ='1px solid #BEBEBE'; td3.style.borderTop ='1px solid #BEBEBE'; td3.innerHTML=ConfirmStore[0].approach_time; td3.style.fontSize='14px'; tr1.appendChild(td3); var td4 = document.createElement('td'); td4.width='16%'; td4.style.textAlign='center'; td4.innerHTML='完工日期'; td4.style.fontSize='14px'; td4.style.borderLeft ='1px solid #BEBEBE'; td4.style.borderTop ='1px solid #BEBEBE'; tr1.appendChild(td4); var td5 = document.createElement('td'); td5.width='16%'; td5.style.textAlign='center'; td5.innerHTML=ConfirmStore[0].complete_time; td5.style.fontSize='14px'; td5.style.borderLeft ='1px solid #BEBEBE'; td5.style.borderTop ='1px solid #BEBEBE'; tr1.appendChild(td5); var td6 = document.createElement('td'); td6.width='16%'; td6.style.textAlign='center'; td6.style.borderLeft ='1px solid #BEBEBE'; td6.style.borderTop ='1px solid #BEBEBE'; td6.innerHTML='验收日期'; td6.style.fontSize='14px'; tr1.appendChild(td6); var td7 = document.createElement('td'); td7.width='16%'; td7.style.textAlign='center'; td7.style.borderLeft ='1px solid #BEBEBE'; td7.style.borderTop ='1px solid #BEBEBE'; td7.innerHTML=ConfirmStore[0].check_time; td7.style.fontSize='14px'; tr1.appendChild(td7); var title3 = document.createElement('div'); title3.style.textAlign='center'; title3.style.fontSize='14px'; title3.style.marginBottom='20px'; title3.style.fontWeight='bold'; title3.innerHTML='表1 项目基本情况表'; div1.appendChild(title3); var title4 = document.createElement('h4'); title4.style.textAlign='left'; title4.style.fontSize='14px'; title4.style.fontWeight='bold'; title4.innerHTML='1.2 安装设备情况'; div1.appendChild(title4); var sta1 = document.createElement('table'); sta1.style.marginTop='10px'; sta1.width='100%'; sta1.style.marginBottom='20px'; sta1.style.borderRight ='1px solid #BEBEBE'; sta1.style.borderBottom ='1px solid #BEBEBE'; div1.appendChild(sta1); var tr12 = document.createElement('tr'); sta1.appendChild(tr12); var th = document.createElement('th'); th.width='10%'; th.style.borderLeft ='1px solid #BEBEBE'; th.style.borderTop ='1px solid #BEBEBE'; th.style.textAlign='center'; th.innerHTML='序号'; th.style.fontSize='14px'; tr12.appendChild(th); var th1 = document.createElement('th'); th1.width='25%'; th1.style.textAlign='center'; th1.innerHTML='设备名称'; th1.style.fontSize='14px'; th1.style.borderLeft ='1px solid #BEBEBE'; th1.style.borderTop ='1px solid #BEBEBE'; tr12.appendChild(th1); var th2 = document.createElement('th'); th2.width='25%'; th2.style.textAlign='center'; th2.innerHTML='规格型号'; th2.style.fontSize='14px'; th2.style.borderLeft ='1px solid #BEBEBE'; th2.style.borderTop ='1px solid #BEBEBE'; tr12.appendChild(th2); var th3 = document.createElement('th'); th3.width='10%'; th3.style.textAlign='center'; th3.innerHTML='数量'; th3.style.fontSize='14px'; th3.style.borderLeft ='1px solid #BEBEBE'; th3.style.borderTop ='1px solid #BEBEBE'; tr12.appendChild(th3); var th4 = document.createElement('th'); th4.width='30%'; th4.style.textAlign='center'; th4.innerHTML='备注'; th4.style.fontSize='14px'; th4.style.borderLeft ='1px solid #BEBEBE'; th4.style.borderTop ='1px solid #BEBEBE'; tr12.appendChild(th4); if(ConfirmStore1.length>0){ if(ConfirmStore1.length==1){ var tr13 = document.createElement('tr'); sta1.appendChild(tr13); var td_details_num = document.createElement('td'); td_details_num.width='5%'; td_details_num.style.textAlign='center'; td_details_num.innerHTML=1; td_details_num.style.fontSize='14px'; td_details_num.style.borderLeft ='1px solid #BEBEBE'; td_details_num.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_num); var td_details_name= document.createElement('td'); td_details_name.width='25%'; td_details_name.style.textAlign='center'; td_details_name.innerHTML= ConfirmStore1[0].device_name; td_details_name.style.borderLeft ='1px solid #BEBEBE'; td_details_name.style.borderTop ='1px solid #BEBEBE'; td_details_name.style.fontSize='14px'; tr13.appendChild(td_details_name); var td_details_specifications = document.createElement('td'); td_details_specifications.width='25%'; td_details_specifications.style.textAlign='center'; td_details_specifications.innerHTML=ConfirmStore1[0].specifications; td_details_specifications.style.fontSize='14px'; td_details_specifications.style.borderLeft ='1px solid #BEBEBE'; td_details_specifications.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_specifications); var td_details_device_num = document.createElement('td'); td_details_device_num.width='10%'; td_details_device_num.style.textAlign='center'; td_details_device_num.innerHTML=ConfirmStore1[0].device_num; td_details_device_num.style.fontSize='14px'; td_details_device_num.style.borderLeft ='1px solid #BEBEBE'; td_details_device_num.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_device_num); var td_details_data_info = document.createElement('td'); td_details_data_info.width='30%'; td_details_data_info.style.textAlign='center'; td_details_data_info.innerHTML=ConfirmStore1[0].data_info; td_details_data_info.style.fontSize='14px'; td_details_data_info.style.borderLeft ='1px solid #BEBEBE'; td_details_data_info.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_data_info); }else{ for(var i=0;i0){ if(ConfirmStore2.length==1){ var tr13 = document.createElement('tr'); sta2.appendChild(tr13); var td_details_num = document.createElement('td'); td_details_num.width='10%'; td_details_num.style.textAlign='center'; td_details_num.style.borderLeft ='1px solid #BEBEBE'; td_details_num.style.borderTop ='1px solid #BEBEBE'; td_details_num.innerHTML=1; td_details_num.style.fontSize='14px'; tr13.appendChild(td_details_num); var td_details_name= document.createElement('td'); td_details_name.width='25%'; td_details_name.style.textAlign='center'; td_details_name.innerHTML= ConfirmStore2[0].device_name; td_details_name.style.borderLeft ='1px solid #BEBEBE'; td_details_name.style.borderTop ='1px solid #BEBEBE'; td_details_name.style.fontSize='14px'; tr13.appendChild(td_details_name); var td_details_specifications = document.createElement('td'); td_details_specifications.width='25%'; td_details_specifications.style.textAlign='center'; td_details_specifications.innerHTML=ConfirmStore2[0].specifications; td_details_specifications.style.fontSize='14px'; td_details_specifications.style.borderLeft ='1px solid #BEBEBE'; td_details_specifications.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_specifications); var td_details_device_num = document.createElement('td'); td_details_device_num.width='10%'; td_details_device_num.style.textAlign='center'; td_details_device_num.innerHTML=ConfirmStore2[0].device_num; td_details_device_num.style.fontSize='14px'; td_details_device_num.style.borderLeft ='1px solid #BEBEBE'; td_details_device_num.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_device_num); var td_details_data_info = document.createElement('td'); td_details_data_info.width='30%'; td_details_data_info.style.textAlign='center'; td_details_data_info.innerHTML=ConfirmStore2[0].data_info; td_details_data_info.style.fontSize='14px'; td_details_data_info.style.borderLeft ='1px solid #BEBEBE'; td_details_data_info.style.borderTop ='1px solid #BEBEBE'; tr13.appendChild(td_details_data_info); }else{ for(var i=0;i0){ if(Number(hjresult)>0.5&&Number(ConfirmStore4[0].lxhjresult)>0.5){ // if(typeof(days3)=="undefined"){ title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查。'; // }else if(Number(days3)>=1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days3)<1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(hjresult)>0.5 && Number(ConfirmStore4[0].lxhjresult)<=0.5){ // if(typeof(days3)=="undefined"){ title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持。'; // }else if(Number(days3)>=1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days3)<1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量偏高。提示:火灾隐患极高或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(hjresult)<=0.5&&Number(ConfirmStore4[0].lxhjresult)>0.5){ // if(typeof(days3)=="undefined"){ title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查。'; // }else if(Number(days3)>=1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days3)<1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(hjresult)<=0.5&&Number(ConfirmStore4[0].lxhjresult)<=0.5){ // if(typeof(days3)=="undefined"){ title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持。'; // }else if(Number(days3)>=1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days3)<1){ // title20_p1.innerHTML='统计时段内火灾监测报告数量:'+hjtotalCount+'条。'+'报告平均发生:'+hjresult+'条/台/天。报告数量良好。提示:有一定的火灾隐患或存在系统故障,需要排查;离线记录中,报告数量:'+lxhjtotalCount+'条。报告平均发生:'+ConfirmStore4[0].lxhjresult+'条/台/天。提示:火灾监测设备通信状态良好,数据接收情况稳定,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } } }else{ title20_p1.innerHTML='未安装此设备'; } // title20_p1.setAttribute('class','title14_label1_p1'); title20_p1.style.paddingLeft='36px'; title20_p1.style.paddingRight='36px'; title20_p1.style.marginBottom='20px'; title20_p1.style.marginTop='20px'; title20_p1.style.lineHeight='150%'; title20_p1.style.fontSize='14px'; title20.appendChild(title20_p1); var title21 = document.createElement('h4'); title21.style.textAlign='left'; title21.style.fontSize='14px'; title21.style.fontWeight='bold'; title21.innerHTML='3.2 消防水系统监测数据分析'; woker_talk.appendChild(title21); var title21_highcharts = document.createElement('div'); // title20_highcharts.width='200!important'; // title20_highcharts.height='200!important'; title21_highcharts.style.marginTop='20px'; title21_highcharts.style.marginBottom='46px'; title21_highcharts.setAttribute('id','container1'); title21_highcharts.style.textAlign='center'; woker_talk.appendChild(title21_highcharts); var title22 = document.createElement('div'); // title22.setAttribute('class','title20_label1'); title22.style.border='1px solid #BEBEBE'; title22.width='100%'; title22.style.background='#AAAAAA'; // title22.style.minHeight='80px'; title22.style.textIndent='2em'; title22.style.marginBottom='20px'; woker_talk.appendChild(title22); var title22_p1 = document.createElement('p'); if(dwsjtotalCount>0){ if(Number(sjresult)>1&&Number(ConfirmStore4[0].lxsjresult)>0.5){ // if(typeof(days6)=="undefined"){ title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查。'; // }else if(Number(days6)>=1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days6)<1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(sjresult)>1 && Number(ConfirmStore4[0].lxsjresult)<=0.5){ // if(typeof(days6)=="undefined"){ title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持。'; // }else if(Number(days6)>=1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days6)<1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量偏高。提示:现场消防水压或液位存在隐患,需要排查;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(sjresult)<=1 && Number(ConfirmStore4[0].lxsjresult)>0.5){ // if(typeof(days6)=="undefined"){ title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查。'; // }else if(Number(days6)>=1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days6)<1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(sjresult)<=1 && Number(ConfirmStore4[0].lxsjresult)<=0.5){ // if(typeof(days6)=="undefined"){ title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持。'; // }else if(Number(days6)>=1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days6)<1){ // title22_p1.innerHTML='统计时段内消防水系统监测报告数量:'+sjtotalCount+'次。'+'报告平均发生:'+sjresult+'条/台/天。报告数量良好。提示:消防水设备状态良好,需要保持;离线记录中,报告数量:'+lxsjtotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxsjresult+'条/台/天。提示:消防水系统监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } } }else{ title22_p1.innerHTML='未安装此设备'; } // title22_p1.setAttribute('class','title14_label1_p1'); title22_p1.style.fontSize='14px'; title22_p1.style.paddingLeft='36px'; title22_p1.style.paddingRight='36px'; title22_p1.style.marginBottom='20px'; title22_p1.style.marginTop='20px'; title22_p1.style.lineHeight='150%'; title22.appendChild(title22_p1); var title23 = document.createElement('h4'); title23.style.textAlign='left'; title23.style.fontSize='14px'; title23.style.fontWeight='bold'; title23.innerHTML='3.3 RTU监测数据分析'; woker_talk.appendChild(title23); var title23_highcharts = document.createElement('div'); // title23_highcharts.style.width='300px'; // title23_highcharts.style.height='300px'; title23_highcharts.style.marginTop='20px'; title23_highcharts.style.marginBottom='20px'; title23_highcharts.setAttribute('id','container2'); title23_highcharts.style.textAlign='center'; woker_talk.appendChild(title23_highcharts); var title24 = document.createElement('div'); title24.style.border='1px solid #BEBEBE'; title24.width='100%'; title24.style.background='#AAAAAA'; // title22.style.minHeight='80px'; title24.style.textIndent='2em'; title24.style.marginBottom='20px'; woker_talk.appendChild(title24); var title24_p1 = document.createElement('p'); if(dwrtutotalCount>0){ if(Number(rturesult)>0.5&&Number(ConfirmStore4[0].lxrturesult)>0.5){ // if(typeof(days9)=="undefined"){ title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查。'; // }else if(Number(days9)>=1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days9)<1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(rturesult)>0.5 && Number(ConfirmStore4[0].lxrturesult)<=0.5){ // if(typeof(days9)=="undefined"){ title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持。'; // }else if(Number(days9)>=1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days9)<1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率异常;需要排查;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(rturesult)<=0.5 && Number(ConfirmStore4[0].lxrturesult)>0.5){ // if(typeof(days9)=="undefined"){ title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查。'; // }else if(Number(days9)>=1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days9)<1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态不稳定,需要排查;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } }else if(Number(rturesult)<=0.5 && Number(ConfirmStore4[0].lxrturesult)<=0.5){ // if(typeof(days9)=="undefined"){ title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持。'; // }else if(Number(days9)>=1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率较低或产品使用培训不足,需要增加使用培训和完善管理制度。'; // }else if(Number(days9)<1){ // title24_p1.innerHTML='统计时段内RTU监测报告数量:'+rtutotalCount+'次。'+'报告平均发生:'+rturesult+'条/台/天。'+'提示:控制柜状态切换频率良好;需要保持;离线记录中,报告数量:'+lxrtutotalCount+'次。报告平均发生:'+ConfirmStore4[0].lxrturesult+'条/台/天。提示:RTU监测设备通信状态良好,需要保持;以上两类的处置情况看,报告确认间隔时长为'+days9+'天,提示:用户使用监测平台(含手机客户端)频率正常,继续保持。'; // } } }else{ title24_p1.innerHTML='未安装此设备'; } // title24_p1.setAttribute('class','title14_label1_p1'); title24_p1.style.fontSize='14px'; title24_p1.style.paddingLeft='36px'; title24_p1.style.paddingRight='36px'; title24_p1.style.marginBottom='20px'; title24_p1.style.marginTop='20px'; title24_p1.style.lineHeight='150%'; title24.appendChild(title24_p1); var title25 = document.createElement('h3'); title25.style.textAlign='left'; title25.style.fontSize='14px'; title25.style.fontWeight='bold'; title25.innerHTML='4 分析结论'; woker_talk.appendChild(title25); var title26 = document.createElement('h4'); title26.style.textAlign='left'; title26.style.fontSize='14px'; title26.style.fontWeight='bold'; title26.innerHTML='4.1 存在问题或需要改进事项'; woker_talk.appendChild(title26); var title27 = document.createElement('ol'); // title27.setAttribute('class','title27_label1'); // title27.style.textAlign='center'; title27.style.border='1px solid #BEBEBE'; title27.width='100%'; title27.style.textAlign='left'; title27.style.background='#AAAAAA'; title27.style.minHeight='20px'; title27.style.paddingLeft='36px'; title27.style.marginBottom='20px'; woker_talk.appendChild(title27); if(dwhjtotalCount>0){ if(Number(hjresult)>0.5){ var title27_p1 = document.createElement('li'); title27_p1.innerHTML='系统数据分析提示:火灾隐患极高或存在系统故障,建议尽早进行系统排查;'; // title27_p1.setAttribute('class','title14_label1_p1'); title27_p1.style.fontSize='14px'; title27.appendChild(title27_p1); } if(Number(ConfirmStore4[0].lxhjresult)>0.5){ var title27_p3 = document.createElement('li'); title27_p3.innerHTML='系统数据分析提示:火灾监测设备通信情况不稳定,建议尽早进行系统排查;'; title27_p3.style.fontSize='14px'; title27.appendChild(title27_p3); } } if(dwsjtotalCount>0){ if(Number(sjresult)>1){ var title27_p2 = document.createElement('li'); title27_p2.innerHTML='系统数据分析提示:消防水系统隐患极高或存在系统故障,建议尽早进行系统排查;'; title27_p2.style.fontSize='14px'; title27.appendChild(title27_p2); } if(Number(ConfirmStore4[0].lxsjresult)>0.5){ var title27_p4 = document.createElement('li'); title27_p4.innerHTML='系统数据分析提示:消防水系统监测设备通信情况不稳定,建议尽早进行系统排查;'; title27_p4.style.fontSize='14px'; title27.appendChild(title27_p4); } } if(dwrtutotalCount>0){ if(Number(rturesult)>0.5){ var title27_p5 = document.createElement('li'); title27_p5.innerHTML='系统数据分析提示:RTU监测隐患极高或存在系统故障,建议尽早进行系统排查;'; title27_p5.style.fontSize='14px'; title27.appendChild(title27_p5); } if(Number(ConfirmStore4[0].lxrturesult)>0.5){ var title27_p6 = document.createElement('li'); title27_p6.innerHTML='系统数据分析提示:RTU监测监测设备通信情况不稳定,建议尽早进行系统排查;'; title27_p6.style.fontSize='14px'; title27.appendChild(title27_p6); } } if(Number(hjresult)<=0.5 && Number(ConfirmStore4[0].lxhjresult)<=0.5 && Number(sjresult)<=1 && Number(ConfirmStore4[0].lxsjresult)<=0.5 && Number(rturesult)<=0.5 && Number(ConfirmStore4[0].lxrturesult)<=0.5){ var title27_li7 = document.createElement('li'); title27_li7.innerHTML='暂无问题及需要改进事项。'; title27_li7.style.fontSize='14px'; title27.appendChild(title27_li7); } var title28 = document.createElement('h4'); title28.style.textAlign='left'; title28.style.fontSize='14px'; title28.style.fontWeight='bold'; title28.innerHTML='4.2 其他事宜'; woker_talk.appendChild(title28); var title29_ol1 = document.createElement('ol'); title29_ol1.style.border='1px solid #BEBEBE'; title29_ol1.width='100%'; title29_ol1.style.textAlign='left'; title29_ol1.style.background='#AAAAAA'; title29_ol1.style.minHeight='20px'; title29_ol1.style.paddingLeft='36px'; title29_ol1.style.marginBottom='20px'; woker_talk.appendChild(title29_ol1); if(dwhjtotalCount>0){ if(Number(hjresult)<=0.5){ var title29_li6 = document.createElement('li'); title29_li6.innerHTML='目前数据反映:火灾监测运行状态较好,需要保持;'; title29_li6.style.fontSize='14px'; title29_ol1.appendChild(title29_li6); } if(Number(ConfirmStore4[0].lxhjresult)<=0.5){ var title29_li1 = document.createElement('li'); title29_li1.innerHTML='目前数据反映:火灾监测设备通信情况较好,需要保持;'; title29_li1.style.fontSize='14px'; title29_ol1.appendChild(title29_li1); } } if(dwsjtotalCount>0){ if(Number(sjresult)<=1){ var title29_li2 = document.createElement('li'); title29_li2.innerHTML='目前数据反映:消防水系统监测运行状态较好,需要保持;'; title29_li2.style.fontSize='14px'; title29_ol1.appendChild(title29_li2); } if(Number(ConfirmStore4[0].lxsjresult)<=0.5){ var title29_li3 = document.createElement('li'); title29_li3.innerHTML='目前数据反映:消防水系统监测设备通信情况较好,需要保持;'; title29_li3.style.fontSize='14px'; title29_ol1.appendChild(title29_li3); } } if(dwrtutotalCount>0){ if(Number(rturesult)<=0.5){ var title29_li4 = document.createElement('li'); title29_li4.innerHTML='目前数据反映:RTU监测运行状态较好,需要保持;'; title29_li4.style.fontSize='14px'; title29_ol1.appendChild(title29_li4); } if(Number(ConfirmStore4[0].lxrturesult)<=0.5){ var title29_li5 = document.createElement('li'); title29_li5.innerHTML='目前数据反映:RTU监测设备通信情况较好,需要保持。'; title29_li5.style.fontSize='14px'; title29_ol1.appendChild(title29_li5); } } if(Number(hjresult)>0.5 && Number(ConfirmStore4[0].lxhjresult)>0.5 && Number(sjresult)>1 && Number(ConfirmStore4[0].lxsjresult)>0.5 && Number(rturesult)>0.5 && Number(ConfirmStore4[0].lxrturesult)>0.5){ var title29_li7 = document.createElement('li'); title29_li7.innerHTML='暂无其他事宜。'; title29_li7.style.fontSize='14px'; title29_ol1.appendChild(title29_li7); } } var funDownload = function (content, filename) { var eleLink = document.createElement('a'); eleLink.download = filename; eleLink.style.display = 'none'; // 字符内容转变成blob地址 var blob = new Blob([content]); eleLink.href = URL.createObjectURL(blob); // 触发点击 document.body.appendChild(eleLink); eleLink.click(); // 然后移除 document.body.removeChild(eleLink); } var highcharts = function () { var clhjbaifenbi = parseFloat(hjbaifenbi); $('#container').highcharts({ chart: { plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false, type: 'pie' }, credits: { enabled: false }, exporting: { enabled:false }, title: { text: '火灾告警处理情况饼图' }, tooltip: { pointFormat: '{series.name}: {point.percentage:.1f}%' }, plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', dataLabels: { enabled: true, format: '{point.name}: {point.percentage:.1f} %', style: { color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black' } }, showInLegend: true } }, series: [{ name: '百分比', colorByPoint: true, data: [{ name: '处理率', y: clhjbaifenbi, sliced: true, selected: true }, { name: '未处理', y: 100-clhjbaifenbi }] }] }); } var highcharts1 = function () { var clsjbaifenbi = parseFloat(sjbaifenbi); $('#container1').highcharts({ chart: { plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false, type: 'pie' }, credits: { enabled: false }, exporting: { enabled:false }, title: { text: '水系统告警处理情况饼图' }, tooltip: { pointFormat: '{series.name}: {point.percentage:.1f}%' }, plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', dataLabels: { enabled: true, format: '{point.name}: {point.percentage:.1f} %', style: { color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black' } }, showInLegend: true } }, series: [{ name: '百分比', colorByPoint: true, data: [{ name: '处理率', y: clsjbaifenbi, sliced: true, selected: true },{ name: '未处理', y: 100-clsjbaifenbi }] }] }); } var highcharts2 = function () { var clrtubaifenbi = parseFloat(rtubaifenbi); $('#container2').highcharts({ chart: { plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false, type: 'pie' }, credits: { enabled: false }, exporting: { enabled:false }, title: { text: 'RTU系统告警处理情况饼图' }, tooltip: { pointFormat: '{series.name}: {point.percentage:.1f}%' }, plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', dataLabels: { enabled: true, format: '{point.name}: {point.percentage:.1f} %', style: { color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black' } }, showInLegend: true } }, series: [{ name: '百分比', colorByPoint: true, data: [{ name: '处理率', y: clrtubaifenbi, sliced: true, selected: true },{ name: '未处理', y: 100-clrtubaifenbi }] }] }); } var highcharts3 = function () { var hjresult1 = parseFloat(result1); var sjresult2 = parseFloat(result2); var rturesult3 = parseFloat(result3); $('#container3').highcharts({ chart: { plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false, type: 'pie' }, credits: { enabled: false }, exporting: { enabled:false }, title: { text: '各类告警总数情况饼图' }, tooltip: { pointFormat: '{series.name}: {point.percentage:.1f}%' }, plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', dataLabels: { enabled: true, format: '{point.name}: {point.percentage:.1f} %', style: { color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black' } }, showInLegend: true } }, series: [{ name: '百分比', colorByPoint: true, data: [{ name: '火系统告警', y: hjresult1, sliced: true, selected: true },{ name: '水系统告警', y: sjresult2 },{ name: 'RTU系统告警', y: rturesult3 }] }] }); } // var daochu = function(){ // var woker_talk = document.getElementById('woker_talk'); // var eleTextarea = document.querySelector('#woker_talk'); // var aa = ''+ // ''+ // ''+ // ''+ // ''+ // ''+ // ''+ // 'Document'+ // ''+ // ''+ // eleTextarea.outerHTML+'' // funDownload(aa, 'project.html'); // } var daochu = function(){ var woker_talk = document.getElementById('woker_talk'); var eleTextarea = document.querySelector('#woker_talk'); html2canvas(woker_talk, { height: $("#woker_talk").outerHeight(), onrendered:function(canvas) { var contentWidth = canvas.width; var contentHeight = canvas.height; //一页pdf显示html页面生成的canvas高度; var pageHeight = contentWidth / 592.28 * 841.89; //未生成pdf的html页面高度 var leftHeight = contentHeight; //页面偏移 var position = 0; //a4纸的尺寸[595.28,841.89],html页面生成的canvas在pdf中图片的宽高 var imgWidth = 555.28; var imgHeight = 555.28/contentWidth * contentHeight; var pageData = canvas.toDataURL('image/jpeg', 1.0); var pdf = new jsPDF('', 'pt', 'a4'); //有两个高度需要区分,一个是html页面的实际高度,和生成pdf的页面高度(841.89) //当内容未超过pdf一页显示的范围,无需分页 if (leftHeight < pageHeight) { pdf.addImage(pageData, 'JPEG', 20, 0, imgWidth, imgHeight ); } else { while(leftHeight > 0) { pdf.addImage(pageData, 'JPEG', 20, position, imgWidth, imgHeight) leftHeight -= pageHeight; position -= 841.89; //避免添加空白页 if(leftHeight > 0) { pdf.addPage(); } } } pdf.save('content.pdf'); } }) } var print_detail = function (){ var div1_label1 = document.getElementById('woker_talk').innerHTML; var div2_label1 = document.getElementById('div2_label1').innerHTML; var hkey_key; var hkey_root = 'HKEY_CURRENT_USER'; var hkey_path = '\\Software\\Micorsoft\\Internet Explorer\\PageSetup\\'; var print_win = window.open('打印窗口','_blank'); var div = document.createElement('div'); div.setAttribute('width', '100%'); div.setAttribute('height', '100%'); var div_print = document.createElement('div'); div_print.setAttribute('style', 'width:595px;height:842px;padding:20px;margin:0px auto 0px auto'); div_print.innerHTML=div1_label1; div.appendChild(div_print); // var div_print1 = document.createElement('div'); // div_print1.setAttribute('style', 'width:595px;height:842px;padding:20px;margin:0px auto 0px auto'); // div_print1.innerHTML=div2_label1; // div.appendChild(div_print1); print_win.document.write(div.innerHTML); print_win.document.close(); try{ var RegWsh = new ActiveXObject('WScript.Shell'); hkey_key='header'; RegWsh.RegWrite(hkey_root+hkey_path+hkey_key,''); hkey_key='footer'; RegWsh.RegWrite(hkey_root+hkey_path+hkey_key,''); }catch(e){} print_win.print(); print_win.close(); } var show_detail_data = function(start_data,end_data,build_code,project_date){ var start_data = start_data; var end_data = end_data; var build_code = build_code; var project_date = project_date; Ext.create('Ext.window.Window', { id:'project_data_win', title: '
水系统隐患分析
', height: 841, width: 650, maximizable: true, layout: 'fit', modal:true, buttons:[ { text:'导出', handler : function () { print_detail(); } },{ text:'关闭', handler : function() { Ext.getCmp('project_data_win').destroy(); location.href=baseUrl+'view/index.jsp?&theme='+theme+'&company_code='+build_code; } } ], closeAction:'destroy', html:'
' }).show(); var query = new Object(); query.V_LOGINNAME = $("#V_LOGINNAME").val(); // query.V_PASSWORD = $("#V_PASSWORD").val(); query.start_data = start_data; query.end_data = end_data; query.build_code = build_code; Ext.MessageBox.wait('Loading', '生成中…'); $.ajax({ type:'POST', url: baseUrl+"iot/company/view/getProjectList", data: { queryJson : Ext.JSON.encode(query) }, success: function(result){ var json = eval('(' + result + ')'); if(json.action=='getVProjectNameList'){ ConfirmStore = json.RESULT; ConfirmStore1 = json.RESULT1; ConfirmStore2 = json.RESULT2; ConfirmStore4 = json.RESULT4; hjtotalCount = json.hjtotalCount; clhjtotalCount = json.clhjtotalCount; lxhjtotalCount = json.lxhjtotalCount; cllxhjtotalCount = json.cllxhjtotalCount; eftotalCount = json.eftotalCount; cleftotalCount = json.cleftotalCount; lxeftotalCount = json.lxeftotalCount; cllxeftotalCount = json.cllxeftotalCount; sjtotalCount = json.sjtotalCount; clsjtotalCount = json.clsjtotalCount; lxsjtotalCount = json.lxsjtotalCount; cllxsjtotalCount = json.cllxsjtotalCount; rtutotalCount = json.rtutotalCount; clrtutotalCount = json.clrtutotalCount; lxrtutotalCount = json.lxrtutotalCount; cllxrtutotalCount = json.cllxrtutotalCount; hjbaifenbi = json.hjbaifenbi; lxhjbaifenbi = json.lxhjbaifenbi; efbaifenbi = json.efbaifenbi; lxefbaifenbi = json.lxefbaifenbi; sjbaifenbi = json.sjbaifenbi; lxsjbaifenbi = json.lxsjbaifenbi; rtubaifenbi = json.rtubaifenbi; lxrtubaifenbi = json.lxrtubaifenbi; dwhjtotalCount = json.dwhjtotalCount; dwsjtotalCount = json.dwsjtotalCount; dwrtutotalCount = json.dwrtutotalCount; days = json.days; hjresult = json.hjresult; sjresult = json.sjresult; rturesult = json.rturesult; device_num1=json.device_num1; device_num2=json.device_num2; clhjbaifenbi = json.clhjbaifenbi; result1 = json.result1; result2 = json.result2; result3 = json.result3; days3 = json.days3; days6 = json.days6; days9 = json.days9; Ext.MessageBox.hide(); draw_confirm(query.start_data,query.end_data,project_date); highcharts(); highcharts1(); highcharts2(); highcharts3(); } } }); } Ext.define('CompanyComboStore1',{ extend:'Ext.data.Model', fields: [ {name:'owner_name', type:'string'}, {name:'owner_id',type:'string'} ] }); CompanyStory = Ext.create('Ext.data.Store',{ model: 'CompanyComboStore1', proxy: { type: 'ajax', actionMethods: { create : 'POST', read : 'POST', // by default GET update : 'POST', destroy: 'POST' }, url: baseUrl+'iot/company/view/getNameList', reader: { type: 'json', root: 'RESULT', totalProperty: 'totalCount' }, extraParams:{ queryJson:Ext.JSON.encode(queryJson) } } }); FilterWin = Ext.create('Ext.form.Panel', { id: 'PatrolPlanFilterForm', labelWidth: 55, defaultType: 'textfield', bodyPadding: 15, items: [{ xtype:'datefield', fieldLabel:"开始日期", minValue:'07/07/2017', minText:"当前日期选择应大于2017-07-07", format:"Y-m-d", value:Ext.util.Format.date(Ext.Date.add(new Date(),Ext.Date.MONTH,-1),"Y-m-01"), columnWidth:0.5, id: 'start_date', name:"start_date", editable:false,//只读约束 allowBlank:false, blankText:"不能为空", anchor:'95%' },{ xtype:'datefield', fieldLabel:"结束日期", minValue:'07/07/2017', minText:"当前日期选择应大于2017-07-07", format:"Y-m-d", value:Ext.util.Format.date(new Date(new Date(new Date().getUTCFullYear(), new Date().getMonth(), 1) - 86400000), "Y-m-d"), columnWidth:0.5, id: 'end_date', name:"end_date", editable:false,//只读约束 allowBlank:false, blankText:"不能为空", anchor:'95%' }, { xtype:'combo', fieldLabel:'建筑物名称', id: 'company_code', name:'company_code', displayField : 'owner_name', valueField : 'owner_id', allowBlank:false, blankText:"不能为空", editable : false, anchor:'80%', store:CompanyStory }, { id:'ff_queryJson', name:'queryJson', hidden:true }], buttons: [{ text: '下一步', iconCls:'ok_btn', handler: function() { var form = this.up('form').getForm(); if (form.isValid()) { var start_date=Ext.util.Format.date(Ext.getCmp('start_date').getValue(), 'Y-m-d'); var end_date=Ext.util.Format.date(Ext.getCmp('end_date').getValue(), 'Y-m-d'); var project_date=Ext.util.Format.date(Ext.getCmp('start_date').getValue(), 'Y-m'); var build_code = Ext.getCmp('company_code').getValue(); // show_detail_data(start_date,end_date,build_code,project_date); // this.up('window').hide(); alert("数据量有限,暂无法分析"); location.href=baseUrl+'view/index.jsp?&theme='+theme+'&company_code='+Ext.getCmp('company_code').getValue(); } } },{ text: '关闭', iconCls: 'cancel_btn', handler: function() { this.up('window').hide(); location.href=baseUrl+'view/index.jsp?&theme='+theme+'&company_code='+Ext.getCmp('company_code').getValue(); } }] }); var filterwin = function() { Ext.create('Ext.window.Window',{ title: '水系统隐患分析', height: 300, width: 350, layout: 'fit', items: FilterWin, closeAction: 'hide' }).show(); }(); });