From a16c42ca5a9de21cec01f1342902052a5c32f362 Mon Sep 17 00:00:00 2001
From: 81041 <81041@192.168.10.30>
Date: 星期三, 14 十一月 2018 16:03:12 +0800
Subject: [PATCH] 电池组信息跨域
---
gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java | 72 +++++++++++++++++++++++++++++++++++
gx_tieta/src/com/fgkj/services/BattInfServices.java | 14 +++++++
2 files changed, 85 insertions(+), 1 deletions(-)
diff --git a/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java b/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
index 15e221f..af7ad73 100644
--- a/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
+++ b/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
@@ -233,6 +233,75 @@
}
return list;
}
+ //鏍规嵁缁存姢鍖哄拰鏈烘埧鍚嶇О鏌ヨ鐢垫睜缁勪俊鎭�(鐢垫睜缁勪俊鎭厤缃�)<-------璺ㄥ煙----------->
+ public List searchInform_ky(){
+ String sql="select distinct(StationId),StationId_ex,StationName,StationName1,StationName2,StationName3,StationName4,StationName5,StationIp,FBSDeviceId,FbsDeviceIp_YM,FbsDeviceIp_WG,FbsDeviceIp,"
+ + "FBSDeviceName,GroupIndexInFBSDevice,battgroupId,BattGroupNum,BattGroupName,FloatVolLevel,OfflineVolLevel,BattFloatCurrent" +
+ ",MonCount,MonCapStd,monVolStd,monResStd,MonSerStd,MonVolLowToAvg,BattProducer,BattModel,BattProductDate,BattInUseDate,battGuarantDayCount,SignalId,CInterFaceId,Load_curr,DisCurrMax,SignalName,Station_install,station_phone " +
+ " From db_battinf.tb_battinf " +
+ " order by StationId ";
+ List<BattInf> list=DAOHelper.executeQueryLimit(sql,DBUtil.getConn(), null,new CallBack() {
+
+ public List getResults(ResultSet rs) {
+ List list = new ArrayList<BattInf>();
+ int id=0;
+
+ try {
+ while (rs.next()) {
+ BattInf binf = new BattInf();
+ binf.setStationId(rs.getString("stationId"));
+ binf.setStationId_ex(rs.getString("stationId_ex"));
+ binf.setStationName(rs.getString("stationName"));
+ binf.setStationName1(rs.getString("stationName1"));
+ binf.setStationName2(rs.getString("stationName2"));
+ binf.setStationName3(rs.getString("stationName3"));
+ binf.setStationName4(rs.getString("stationName4"));
+ binf.setStationName5(rs.getString("stationName5"));
+ binf.setStationIp(rs.getString("stationIp"));
+ binf.setFBSDeviceId(rs.getInt("fBSDeviceId"));
+
+ binf.setFbsDeviceIp(rs.getString("fbsDeviceIp"));
+
+ binf.setFbsDeviceIp_YM(rs.getString("fbsDeviceIp_YM"));
+
+ binf.setFbsDeviceIp_WG(rs.getString("fbsDeviceIp_WG"));
+
+ binf.setFBSDeviceName(rs.getString("fBSDeviceName"));
+ binf.setGroupIndexInFBSDevice(rs.getInt("groupIndexInFBSDevice"));
+ binf.setBattGroupId(rs.getInt("battGroupId"));
+ binf.setBattGroupNum(rs.getInt("battGroupNum"));
+ binf.setBattGroupName(rs.getString("battGroupName"));
+ binf.setFloatVolLevel(rs.getFloat("floatVolLevel"));
+ binf.setOfflineVolLevel(rs.getFloat("offlineVolLevel"));
+ binf.setBattFloatCurrent(rs.getFloat("battFloatCurrent"));
+ binf.setMonCount(rs.getInt("monCount"));
+ binf.setMonCapStd(rs.getFloat("monCapStd"));
+ binf.setMonVolStd(rs.getFloat("monVolStd"));
+ binf.setMonResStd(rs.getFloat("monResStd"));
+ binf.setMonSerStd(rs.getFloat("monSerStd"));
+ binf.setMonVolLowToAvg(rs.getFloat("monVolLowToAvg"));
+ binf.setBattProducer(rs.getString("battProducer"));
+ binf.setBattModel(rs.getString("battModel"));
+ binf.setBattProductDate(rs.getDate("battProductDate"));
+ binf.setBattInUseDate(rs.getDate("battInUseDate"));
+ binf.setBattGuarantDayCount(rs.getInt("battGuarantDayCount"));
+ binf.setSignalId(rs.getString("signalId"));
+ binf.setCInterFaceId(rs.getInt("cInterFaceId"));
+ binf.setStation_install(rs.getInt("station_install"));
+ binf.setLoad_curr(rs.getFloat("load_curr"));
+ binf.setDisCurrMax(rs.getFloat("disCurrMax"));
+ binf.setStation_phone(rs.getString("station_phone"));
+ list.add(binf);
+
+ }
+ } catch (SQLException e) {
+ e.printStackTrace();
+ }
+ return list;
+ }
+ });
+ return list;
+ }
//鏍规嵁缁存姢鍖哄拰鏈烘埧鍚嶇О鏌ヨ鐢垫睜缁勪俊鎭�(鐢垫睜缁勪俊鎭厤缃�)
public List searchInform1(Object obj){
Batt_Maint_Dealarm bmd=(Batt_Maint_Dealarm) obj;
@@ -4125,7 +4194,8 @@
//List<BattInf> list=biml.serchGroupByInfor(binf);
//List<BattInf> list=biml.searchInform1(bmd);
//<BattInf> list=biml.serchStationName5(binf);
- List<BattInf> list=biml.serchBattAllInfoByStationId(binf);
+ //List<BattInf> list=biml.serchBattAllInfoByStationId(binf);
+ List<BattInf> list=biml.searchInform_ky();
for (BattInf b : list) {
System.out.println(b);
}
diff --git a/gx_tieta/src/com/fgkj/services/BattInfServices.java b/gx_tieta/src/com/fgkj/services/BattInfServices.java
index 017e484..18e6bf8 100644
--- a/gx_tieta/src/com/fgkj/services/BattInfServices.java
+++ b/gx_tieta/src/com/fgkj/services/BattInfServices.java
@@ -153,6 +153,20 @@
}
return model;
}
+ //鏍规嵁缁存姢鍖哄拰鏈烘埧鍚嶇О鏌ヨ鐢垫睜缁勪俊鎭�(鐢垫睜缁勪俊鎭厤缃�)<-------璺ㄥ煙----------->
+ public ServiceModel searchInform_ky() {
+ List<BattInf> list=((BattInfImpl)dao).searchInform_ky();
+ if (list != null && list.size() > 0) {
+ model.setCode(1);
+ model.setData(list);
+ model.setMsg("鏌ヨ鎴愬姛!");
+ }
+ else{
+ model.setCode(0);
+ model.setMsg("鏌ヨ澶辫触!");
+ }
+ return model;
+ }
//鏍规嵁缁存姢鍖哄拰鏈烘埧鍚嶇О鏌ヨ鐢垫睜缁勪俊鎭�
public ServiceModel searchInform1(Object obj) {
List<BattInf> list=((BattInfImpl)dao).searchInform1(obj);
--
Gitblit v1.9.1