Commit 4435478c authored by zhoumaotao's avatar zhoumaotao

大屏代码调整2

parent 16d36de3
...@@ -119,10 +119,10 @@ public class GpfkcxDaoImpl extends BaseDaoImpl implements GpfkcxDao { ...@@ -119,10 +119,10 @@ public class GpfkcxDaoImpl extends BaseDaoImpl implements GpfkcxDao {
SqlMap sqlMap = new SqlMap(); SqlMap sqlMap = new SqlMap();
sqlMap.append("select GPFK_ID, GPFK_WOSNID, GPFK_FKLX, GPFK_FKGX, "); sqlMap.append("select GPFK_ID, GPFK_WOSNID, GPFK_FKLX, GPFK_FKGX, ");
sqlMap.append(" GPFK_FKSJ,GPFK_FKR,GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,"); sqlMap.append(" GPFK_FKSJ,GPFK_FKR,GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,");
sqlMap.append(" GPFK_HGBZ,GPFK_FKSL,GPFK_HGSL,GPFK_BHGSL,GPFK_GFSL,GPFK_WOGYLX, "); sqlMap.append(" GPFK_HGBZ,GPFK_FKSL,GPFK_HGSL,GPFK_BHGSL,GPFK_GFSL, ");
sqlMap.append(" GPFK_LFSL,WOGYLX_GXBZ "); sqlMap.append(" GPFK_LFSL,WOGYLX_GXBZ ");
sqlMap.append("from GPFK "); sqlMap.append("from GPFK ");
sqlMap.append(" left join WOGYLX on WOGYLX_ID = GPFK_WOGYLX "); sqlMap.append(" left join WOGYLX on WOGYLX_ID = GPFK_FKGX ");
sqlMap.append("where (GPFK_FKSJ >= :pStart and GPFK_FKSJ < :pEnd) and (WOGYLX_GXBZ = :pDGxbz or WOGYLX_GXBZ = :pMGxbz) ");//[a,b) sqlMap.append("where (GPFK_FKSJ >= :pStart and GPFK_FKSJ < :pEnd) and (WOGYLX_GXBZ = :pDGxbz or WOGYLX_GXBZ = :pMGxbz) ");//[a,b)
sqlMap.setParamValue("pStart", start); sqlMap.setParamValue("pStart", start);
sqlMap.setParamValue("pEnd", end); sqlMap.setParamValue("pEnd", end);
...@@ -136,10 +136,10 @@ public class GpfkcxDaoImpl extends BaseDaoImpl implements GpfkcxDao { ...@@ -136,10 +136,10 @@ public class GpfkcxDaoImpl extends BaseDaoImpl implements GpfkcxDao {
SqlMap sqlMap = new SqlMap(); SqlMap sqlMap = new SqlMap();
sqlMap.append("select GPFK_ID, GPFK_WOSNID, GPFK_FKLX, GPFK_FKGX, "); sqlMap.append("select GPFK_ID, GPFK_WOSNID, GPFK_FKLX, GPFK_FKGX, ");
sqlMap.append(" GPFK_FKSJ,GPFK_FKR,GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,"); sqlMap.append(" GPFK_FKSJ,GPFK_FKR,GPFK_FKRID, GPFK_FKBX, GPFK_FKJSSJ,");
sqlMap.append(" GPFK_HGBZ,GPFK_FKSL,GPFK_HGSL,GPFK_BHGSL,GPFK_GFSL,GPFK_WOGYLX, "); sqlMap.append(" GPFK_HGBZ,GPFK_FKSL,GPFK_HGSL,GPFK_BHGSL,GPFK_GFSL, ");
sqlMap.append(" GPFK_LFSL,WOGYLX_GXBZ "); sqlMap.append(" GPFK_LFSL,WOGYLX_GXBZ ");
sqlMap.append("from GPFK "); sqlMap.append("from GPFK ");
sqlMap.append(" left join WOGYLX on WOGYLX_ID = GPFK_WOGYLX "); sqlMap.append(" left join WOGYLX on WOGYLX_ID = GPFK_FKGX ");
sqlMap.append(" left join BZGX on BZGX_ID = WOGYLX_BZGXID "); sqlMap.append(" left join BZGX on BZGX_ID = WOGYLX_BZGXID ");
sqlMap.append("where ( GPFK_FKSJ >= :pKsrq and GPFK_FKSJ < :pJsrq ) "); sqlMap.append("where ( GPFK_FKSJ >= :pKsrq and GPFK_FKSJ < :pJsrq ) ");
sqlMap.append(" and ").append("WOGYLX_BZGXID", gxbzs); sqlMap.append(" and ").append("WOGYLX_BZGXID", gxbzs);
......
...@@ -17,8 +17,6 @@ import com.gavel.kwell.vo.PcslVO; ...@@ -17,8 +17,6 @@ import com.gavel.kwell.vo.PcslVO;
import com.gavel.kwell.vo.SdclVO; import com.gavel.kwell.vo.SdclVO;
import com.gavel.kwell.vo.UWoVO; import com.gavel.kwell.vo.UWoVO;
import com.gavel.wo.persistent.Pcjhmx; import com.gavel.wo.persistent.Pcjhmx;
import org.apache.commons.collections.ListUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -28,11 +26,7 @@ import org.springframework.transaction.annotation.Transactional; ...@@ -28,11 +26,7 @@ import org.springframework.transaction.annotation.Transactional;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.*; import java.io.*;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.ArrayList; import java.util.*;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Service("kmesBoardService") @Service("kmesBoardService")
...@@ -150,6 +144,7 @@ public class KmesBoardServiceImpl extends BaseEditServiceImpl implements KmesBoa ...@@ -150,6 +144,7 @@ public class KmesBoardServiceImpl extends BaseEditServiceImpl implements KmesBoa
gpfkHgVO.setFksl(fksl); gpfkHgVO.setFksl(fksl);
gpfkHgVO.setHgsl(hgsl); gpfkHgVO.setHgsl(hgsl);
} }
gpfkHgVO.setFkrq(date);
gpfkHgVOList.add(gpfkHgVO); gpfkHgVOList.add(gpfkHgVO);
} }
return gpfkHgVOList; return gpfkHgVOList;
...@@ -178,24 +173,32 @@ public class KmesBoardServiceImpl extends BaseEditServiceImpl implements KmesBoa ...@@ -178,24 +173,32 @@ public class KmesBoardServiceImpl extends BaseEditServiceImpl implements KmesBoa
@Override @Override
public void doAttachmentPreview(HttpServletResponse response, FileInputStream fileInputStream) { public void doAttachmentPreview(HttpServletResponse response, FileInputStream fileInputStream) {
try { try {
BufferedInputStream bis = new BufferedInputStream(fileInputStream); BufferedInputStream bis = null;
BufferedOutputStream bos = null;
try { try {
BufferedOutputStream bos = new BufferedOutputStream(response.getOutputStream());
try { try {
bis = new BufferedInputStream(fileInputStream);
bos = new BufferedOutputStream(response.getOutputStream());
byte[] buff = new byte[2048]; byte[] buff = new byte[2048];
int bytesRead; int bytesRead;
while(-1 != (bytesRead = bis.read(buff, 0, buff.length))) { while(-1 != (bytesRead = bis.read(buff, 0, buff.length))) {
bos.write(buff, 0, bytesRead); bos.write(buff, 0, bytesRead);
} }
} finally { }catch (Exception var22){
// logger.error("错误信息", var22);
}
finally {
if(bos != null){
bos.close(); bos.close();
} }
}
} finally { } finally {
if(bis != null){
bis.close(); bis.close();
} }
}
} catch (Exception var23) { } catch (Exception var23) {
this.logger.error("", var23); //logger.error("错误信息", var23);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment