📄 stati_num.jsp
字号:
Iterator hqi = hqc.iterator(); while(hqi.hasNext()) { officeUnitStruct ofus = (officeUnitStruct)hqi.next(); if(ofus.upunitid.intValue()==1) { hqname.addElement(ofus.processname); hqid.addElement(ofus.unitid); } } int hbeiyong=0; int hshiyong=0; int hweixiu=0; int hdaibaofei=0; int hyibaofei=0; int hheji=0; for(int l=0;l<hqid.size();l++) { String haiqun=(String)hqname.elementAt(l); Vector devmod = new Vector(); cc = handtakeController.getCheckAll(); Iterator i = cc.iterator(); while(i.hasNext()) { crj = (CheckReportJBean)i.next(); Judge jd = new Judge(); if(jd.decide((Integer)hqid.elementAt(l),crj.unitid)) if(crj.dev_type.intValue()==devtype.intValue()) devmod.addElement(crj.dev_model); } ec = eqController.getEqdDetailsAll(); i.remove(); i=ec.iterator(); while(i.hasNext()) { eqd = (EquipmentDetailsStruct)i.next(); Judge jd = new Judge(); if(jd.decide((Integer)hqid.elementAt(l),eqd.getUnitid())) if(eqd.getType().intValue()==devtype.intValue()) devmod.addElement(eqd.getModel()); } for(int p=0;p<devmod.size()-1;p++) for(int k=p+1;k<devmod.size();k++) { if(devmod.elementAt(p).equals(devmod.elementAt(k))) { devmod.remove(k); k--; } } if(!devmode.equals("")) { String devname=""; Integer det = new Integer(-1);cc=handtakeController.getCheckByModel(devmode);Iterator ii=cc.iterator();if(ii.hasNext()) { crj = (CheckReportJBean)ii.next(); devname=crj.dev_name; det = crj.dev_type; }if(devname.equals("")){ec = eqController.getEqdetailsByModel(devmode);Iterator iii=ec.iterator();if(iii.hasNext()){eqd = (EquipmentDetailsStruct)iii.next();devname=eqd.getName();det = eqd.getType();}}String devty="";if(det.intValue()!=-1){if(det.intValue()==1) devty="VTS备件";if(det.intValue()==2) devty="航标设备及备件";if(det.intValue()==3) devty="AIS系统及备件";if(det.intValue()==4) devty="测绘设备及备件";if(det.intValue()==5) devty="其他";}Integer beiyong=new Integer(0);Integer shiyong=new Integer(0);Integer weixiu=new Integer(0);Integer daibaofei=new Integer(0);Integer yibaofei=new Integer(0);Integer heji = new Integer(0);Collection ect = new ArrayList();EquipmentJBean eqj = new EquipmentJBean();ect = eqController.getEqdetailsByModel(devmode);Iterator equipi = ect.iterator();while(equipi.hasNext()){eqd = (EquipmentDetailsStruct)equipi.next();eqj = eqController.getEquipmentByDeviceid(eqd.getDeviceid());Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),eqj.getUnitid())){if(eqj.getStatus().intValue()==1) {beiyong=new Integer(beiyong.intValue()+1);}if(eqj.getStatus().intValue()==2) {shiyong=new Integer(shiyong.intValue()+1);}if(eqj.getStatus().intValue()==3) {weixiu=new Integer(weixiu.intValue()+1);}if(eqj.getStatus().intValue()==4) {daibaofei=new Integer(daibaofei.intValue()+1);}if(eqj.getStatus().intValue()==5) {yibaofei=new Integer(yibaofei.intValue()+1);}}}Collection crc = new ArrayList();crc = handtakeController.getCheckByModel(devmode);Iterator cri = crc.iterator();while(cri.hasNext()){crj = (CheckReportJBean)cri.next();Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),crj.unitid)){beiyong=new Integer(beiyong.intValue()+crj.lastamount.intValue());}}Collection htc = new ArrayList();htc = handtakeController.getHandByModel(devmode);Iterator hti = htc.iterator();while(hti.hasNext()){hjb = (HandtakeJBean)hti.next();Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),hjb.unitid)){beiyong=new Integer(beiyong.intValue()+hjb.hamount.intValue());}} Collection rcc = new ArrayList(); rechangeStruct rcs = new rechangeStruct(); rcc = handtakeController.getRechangeByModel(devmode); Iterator rci = rcc.iterator(); while(rci.hasNext()) { rcs = (rechangeStruct)rci.next(); Judge jd = new Judge(); if(jd.decide((Integer)hqid.elementAt(l),rcs.unitid)) { beiyong = new Integer(beiyong.intValue()+rcs.hamount.intValue()); } }/*Connection con=DriverManager.getConnection(url,name,pass);Statement stmt=con.createStatement();ResultSet rs=null;String sqls="select HAMOUNT from RECHANGE where DEV_MODEL='"+devmode+"'";rs=stmt.executeQuery(sqls);while(rs.next()){int hamount=rs.getInt("HAMOUNT");beiyong = new Integer(beiyong.intValue()+hamount);}*/heji = new Integer(beiyong.intValue()+shiyong.intValue()+weixiu.intValue()+daibaofei.intValue()+yibaofei.intValue());hbeiyong = hbeiyong+beiyong.intValue();hshiyong = hshiyong+shiyong.intValue();hweixiu = hweixiu+weixiu.intValue();hdaibaofei = hdaibaofei+daibaofei.intValue();hyibaofei = hyibaofei+yibaofei.intValue();hheji = hheji+heji.intValue();%><tr bgcolor="#fafafa"><td><%=hqname.elementAt(l)%><td><%=devty%><td><%=devmode%><td><%=devname%><td><%=beiyong%><td><%=shiyong%><td><%=weixiu%><td><%=daibaofei%><td><%=yibaofei%><td><%=heji%><tr> <% } else{ for(int p=0;p<devmod.size();p++) { String devname=""; Integer det = new Integer(-1); cc=handtakeController.getCheckByModel((String)devmod.elementAt(p)); Iterator ii=cc.iterator(); if(ii.hasNext()) { crj = (CheckReportJBean)ii.next(); devname=crj.dev_name; det = crj.dev_type; } if(devname.equals("")) { ec = eqController.getEqdetailsByModel((String)devmod.elementAt(p)); Iterator iii=ec.iterator(); if(iii.hasNext()) { eqd = (EquipmentDetailsStruct)iii.next(); devname=eqd.getName(); det = eqd.getType(); } } String devty=""; if(det.intValue()!=-1){ if(det.intValue()==1) devty="VTS备件"; if(det.intValue()==2) devty="航标设备及备件"; if(det.intValue()==3) devty="AIS系统及备件"; if(det.intValue()==4) devty="测绘设备及备件"; if(det.intValue()==5) devty="其他"; } Integer beiyong=new Integer(0); Integer shiyong=new Integer(0); Integer weixiu=new Integer(0); Integer daibaofei=new Integer(0); Integer yibaofei=new Integer(0); Integer heji = new Integer(0); Collection ect = new ArrayList(); EquipmentJBean eqj = new EquipmentJBean(); ect = eqController.getEqdetailsByModel((String)devmod.elementAt(p)); Iterator equipi = ect.iterator(); while(equipi.hasNext()) { eqd = (EquipmentDetailsStruct)equipi.next(); eqj = eqController.getEquipmentByDeviceid(eqd.getDeviceid()); Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),eqj.getUnitid())){ if(eqj.getStatus().intValue()==1) { beiyong=new Integer(beiyong.intValue()+1); } if(eqj.getStatus().intValue()==2) { shiyong=new Integer(shiyong.intValue()+1); } if(eqj.getStatus().intValue()==3) { weixiu=new Integer(weixiu.intValue()+1); } if(eqj.getStatus().intValue()==4) { daibaofei=new Integer(daibaofei.intValue()+1); } if(eqj.getStatus().intValue()==5) { yibaofei=new Integer(yibaofei.intValue()+1); } } } Collection crc = new ArrayList(); crc = handtakeController.getCheckByModel((String)devmod.elementAt(p)); Iterator cri = crc.iterator(); while(cri.hasNext()) { crj = (CheckReportJBean)cri.next(); Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),crj.unitid)){ beiyong=new Integer(beiyong.intValue()+crj.lastamount.intValue()); } } Collection htc = new ArrayList(); htc = handtakeController.getHandByModel((String)devmod.elementAt(p)); Iterator hti = htc.iterator(); while(hti.hasNext()) { hjb = (HandtakeJBean)hti.next(); Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),hjb.unitid)){ beiyong=new Integer(beiyong.intValue()+hjb.hamount.intValue()); } } Collection rcc = new ArrayList();rechangeStruct rcs = new rechangeStruct();rcc = handtakeController.getRechangeByModel((String)devmod.elementAt(p));Iterator rci = rcc.iterator();while(rci.hasNext()){rcs = (rechangeStruct)rci.next();Judge jd = new Judge();if(jd.decide((Integer)hqid.elementAt(l),rcs.unitid)){beiyong = new Integer(beiyong.intValue()+rcs.hamount.intValue());} }/* Connection con=DriverManager.getConnection(url,name,pass); Statement stmt=con.createStatement(); ResultSet rs=null; String sqls="select HAMOUNT from RECHANGE where DEV_MODEL='"+(String)devmod.elementAt(p)+"'"; rs=stmt.executeQuery(sqls); while(rs.next()) { int hamount=rs.getInt("HAMOUNT"); beiyong = new Integer(beiyong.intValue()+hamount); }*/ heji = new Integer(beiyong.intValue()+shiyong.intValue()+weixiu.intValue()+daibaofei.intValue()+yibaofei.intValue()); hbeiyong = hbeiyong+beiyong.intValue(); hshiyong = hshiyong+shiyong.intValue(); hweixiu = hweixiu+weixiu.intValue(); hdaibaofei = hdaibaofei+daibaofei.intValue(); hyibaofei = hyibaofei+yibaofei.intValue(); hheji = hheji+heji.intValue(); %> <tr bgcolor="#fafafa"> <td><%=hqname.elementAt(l)%> <td><%=devty%> <td><%=devmod.elementAt(p)%> <td><%=devname%> <td><%=beiyong%> <td><%=shiyong%> <td><%=weixiu%> <td><%=daibaofei%> <td><%=yibaofei%> <td><%=heji%> <tr> <% } } }%> <tr bgcolor="#fafafa"> <td>合计 <td> <td> <td> <td><%=hbeiyong%> <td><%=hshiyong%> <td><%=hweixiu%> <td><%=hdaibaofei%> <td><%=hyibaofei%> <td><%=hheji%> <tr><%}if(!unitn.equals("")&&devtype.intValue()!=-1){ Vector devmod = new Vector(); Integer hqid = new Integer(-111); Collection hqc = new ArrayList(); hqc = officeUnitController.getProcessName(unitn); Iterator hqoi = hqc.iterator(); if(hqoi.hasNext()){ officeUnitStruct ofus = (officeUnitStruct)hqoi.next(); hqid = ofus.unitid; } cc = handtakeController.getCheckAll(); Iterator i = cc.iterator(); while(i.hasNext()) { crj = (CheckReportJBean)i.next(); Judge jd = new Judge(); if(jd.decide(hqid,crj.unitid)) if(crj.dev_type.intValue()==devtype.intValue()) devmod.addElement(crj.dev_model); } ec = eqController.getEqdDetailsAll(); i.remove(); i=ec.iterator(); while(i.hasNext()) { eqd = (EquipmentDetailsStruct)i.next(); Judge jd = new Judge(); if(jd.decide(hqid,eqd.getUnitid())) if(eqd.getType().intValue()==devtype.intValue()) devmod.addElement(eqd.getModel()); } for(int p=0;p<devmod.size()-1;p++) for(int k=p+1;k<devmod.size();k++) { if(devmod.elementAt(p).equals(devmod.elementAt(k))) { devmod.remove(k); k--; } } int hbeiyong=0; int hshiyong=0; int hweixiu=0; int hdaibaofei=0; int hyibaofei=0; int hheji=0;if(!devmode.equals("")){ String devname=""; Integer det = new Integer(-1);cc=handtakeController.getCheckByModel(devmode);Iterator ii=cc.iterator();if(ii.hasNext()) { crj = (CheckReportJBean)ii.next(); devname=crj.dev_name; det = crj.dev_type; }if(devname.equals("")){ec = eqController.getEqdetailsByModel(devmode);Iterator iii=ec.iterator();if(iii.hasNext()){eqd = (EquipmentDetailsStruct)iii.next();devname=eqd.getName();det = eqd.getType();}}String devty="";if(det.intValue()!=-1){if(det.intValue()==1) devty="VTS备件";if(det.intValue()==2) devty="航标设备及备件";if(det.intValue()==3) devty="AIS系统及备件";if(det.intValue()==4) devty="测绘设备及备件";if(det.intValue()==5) devty="其他";}Integer beiyong=new Integer(0);Integer shiyong=new Integer(0);Integer weixiu=new Integer(0);Integer daibaofei=new Integer(0);Integer yibaofei=new Integer(0);Integer heji = new Integer(0);Collection ect = new ArrayList();EquipmentJBean eqj = new EquipmentJBean();ect = eqController.getEqdetailsByModel(devmode);Iterator equipi = ect.iterator();while(equipi.hasNext()){eqd = (EquipmentDetailsStruct)equipi.next();eqj = eqController.getEquipmentByDeviceid(eqd.getDeviceid());Judge jd = new Judge();if(jd.decide(hqid,eqj.getUnitid())){if(eqj.getStatus().intValue()==1) {beiyong=new Integer(beiyong.intValue()+1);}if(eqj.getStatus().intValue()==2) {shiyong=new Integer(shiyong.intValue()+1);}if(eqj.getStatus().intValue()==3) {weixiu=new Integer(weixiu.intValue()+1);}if(eqj.getStatus().intValue()==4) {daibaofei=new Integer(daibaofei.intValue()+1);}if(eqj.getStatus().intValue()==5) {yibaofei=new Integer(yibaofei.intValue()+1);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -