From 43fe18b40a84b82ca5c5f1a88abb89ea168f95f5 Mon Sep 17 00:00:00 2001
From: 81041 <81041@192.168.10.23>
Date: 星期一, 12 十一月 2018 10:12:26 +0800
Subject: [PATCH] Merge branch 'dev_lxw' of https://whyclxw1@gitlab.com/whyclxw1/gx_tieta.git into dev_lxw

---
 gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java |   18 ++++++++++++++----
 1 files changed, 14 insertions(+), 4 deletions(-)

diff --git a/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java b/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
index 2eae987..76b6021 100644
--- a/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
+++ b/gx_tieta/src/com/fgkj/dao/impl/BattInfImpl.java
@@ -387,11 +387,11 @@
 		return list;
 	}
 	
-	//5.3娣诲姞閫夊彇鐢垫睜缁勬垨鑰呮満鎴挎垨鑰呯淮鎶ゅ尯
+	//5.3娣诲姞閫夊彇鐢垫睜缁勬垨鑰呮満鎴挎垨鑰呯淮鎶ゅ尯鎴栬�呭叏鍖哄幙
 	public List serchBatt(Object obj) {
 		BattInf binf=(BattInf) obj;
 		String sql="";
-		String baseSql="select distinct(battgroupid),stationid,stationname,stationname1,battgroupname from db_battinf.tb_battinf " +
+		String baseSql="select distinct(battgroupid),stationid,stationname,stationname1,stationname2,stationname5,battgroupname from db_battinf.tb_battinf " +
 				"where ";
 		 //鐢ㄤ簬缁存姢鍖�
 		String station1SqlT=" stationname1!=? ";//鍏ㄩ儴
@@ -408,6 +408,14 @@
 			baseSql+=station2SqlT;
 		}else{
 			baseSql+=station2SqlF;
+		}
+		//鐢ㄤ簬鍖哄幙
+		String station5SqlT=" and stationname5!=? ";//鍏ㄩ儴
+		String station5SqlF=" and stationname5=? ";
+		if(binf.getStationName5().equals("")){
+			baseSql+=station5SqlT;
+		}else{
+			baseSql+=station5SqlF;
 		}
 		//鐢ㄤ簬鏈烘埧绔欑偣
 		String stationSqlT=" and stationname!=? ";//鍏ㄩ儴
@@ -428,7 +436,7 @@
 		String endSql=" order by stationid ";
 		sql=baseSql+endSql;
 		//System.out.println(sql);
-		List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{binf.getStationName1(),binf.getStationName2(),binf.getStationName(),binf.getBattGroupId()}, new CallBack() {
+		List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{binf.getStationName1(),binf.getStationName2(),binf.getStationName5(),binf.getStationName(),binf.getBattGroupId()}, new CallBack() {
 			
 			public List getResults(ResultSet rs) {
 				List list=new ArrayList();
@@ -439,6 +447,8 @@
 					binf.setStationId(rs.getString("StationId"));
 					binf.setStationName(rs.getString("stationName"));
 					binf.setStationName1(rs.getString("stationName1"));
+					binf.setStationName2(rs.getString("stationName2"));
+					binf.setStationName5(rs.getString("stationName5"));
 					binf.setBattGroupName(rs.getString("battGroupName"));
 					list.add(binf);
 					}
@@ -3452,7 +3462,7 @@
 				" FROM db_battinf.tb_battinf " +
 				" where StationName1 like ? and StationName2 like ?  " +
 				" ORDER BY CONVERT( StationName USING gbk ) COLLATE gbk_chinese_ci ASC ";
-		List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{binf.getNum(),"%"+binf.getStationName1()+"%","%"+binf.getStationName2()+"%"},new CallBack() {
+		List list=DAOHelper.executeQuery(sql, DBUtil.getConn(), new Object[]{"%"+binf.getStationName1()+"%","%"+binf.getStationName2()+"%"},new CallBack() {
 			
 			public List getResults(ResultSet rs) {
 				List list=new ArrayList();

--
Gitblit v1.9.1