Commit aca3b659 authored by dahai's avatar dahai

修改上传EXCEL文件

parent 792d505b
...@@ -22,13 +22,8 @@ import javax.servlet.http.HttpServletResponse; ...@@ -22,13 +22,8 @@ import javax.servlet.http.HttpServletResponse;
import javax.ws.rs.Consumes; import javax.ws.rs.Consumes;
import javax.ws.rs.Produces; import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType; import javax.ws.rs.core.MediaType;
import javax.xml.crypto.Data;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.sql.Time;
import java.sql.Timestamp;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.*; import java.util.*;
/** /**
...@@ -51,10 +46,7 @@ public class ReadExcelApi { ...@@ -51,10 +46,7 @@ public class ReadExcelApi {
@Produces(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON)
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
public boolean ReadPersonPost(HttpServletResponse resp, HttpServletRequest requ) { public boolean ReadPersonPost(HttpServletResponse resp, HttpServletRequest requ) {
System.out.println("进入api");
YXJSONResponse yxresp = new YXJSONResponse(); YXJSONResponse yxresp = new YXJSONResponse();
DateFormat format = new SimpleDateFormat("yyyy-MM-dd");
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
String filename = ""; String filename = "";
DiskFileItemFactory factory = new DiskFileItemFactory(); DiskFileItemFactory factory = new DiskFileItemFactory();
......
...@@ -28,14 +28,16 @@ public interface PreproPersonMapper { ...@@ -28,14 +28,16 @@ public interface PreproPersonMapper {
"left join files on PREPRO_PERSON.FILE_ID = files.ID\n" + "left join files on PREPRO_PERSON.FILE_ID = files.ID\n" +
"left join NEW_FILES on PREPRO_PERSON.FILE_ID = NEW_FILES.ID " + "left join NEW_FILES on PREPRO_PERSON.FILE_ID = NEW_FILES.ID " +
"where 1=1 " + "where 1=1 " +
" <when test='uploadNo!=null'> and PREPRO_PERSON.JMSFZSLH = #{uploadNo} </when>" + " <where>" +
" <when test='IDCard!=null'> and GMSFHM = #{IDCard} </when> " + " <if test='uploadNo != null'> and PREPRO_PERSON.JMSFZSLH = #{uploadNo} </if>" +
" <when test='oldFile!=null'> and files.SOURCE_FILE_NAME =#{oldFile} </when> " + " <if test='IDCard != null'> and GMSFHM = #{IDCard} </if> " +
" <when test='newFile!=null'> and NEW_FILES.NEW_FILE_NAME = #{newFile} </when> " + " <if test='oldFile != null'> and files.SOURCE_FILE_NAME =#{oldFile} </if> " +
" <when test='SSXQDM!=null'> and PREPRO_PERSON.SSXQDM =#{SSXQDM} </when> " + " <if test='newFile != null'> and NEW_FILES.NEW_FILE_NAME = #{newFile} </if> " +
" <when test='cardType!=null'> and PREPRO_PERSON.CARD_TYPE_ID =#{cardType} </when> " + " <if test='SSXQDM != null'> and PREPRO_PERSON.SSXQDM =#{SSXQDM} </if> " +
" <when test='state!=null'> and PREPRO_PERSON.state = #{state} </when> " + " <if test='cardType != null'> and PREPRO_PERSON.CARD_TYPE_ID =#{cardType} </if> " +
" <when test='uploadDate!=null'> and files.CREAT_TIME = #{uploadDate} </when> ") " <if test='state != null'> and PREPRO_PERSON.state = #{state} </if> " +
" <if test='uploadDate != null'> and files.CREAT_TIME = #{uploadDate} </if> " +
" </where>")
public List<PreproPersonEntity> selectPreproPerson(@Param("uploadNo")String uploadNo, @Param("IDCard")String IDCard, @Param("oldFile")String oldFile, @Param("newFile")String newFile, @Param("SSXQDM")String SSXQDM, @Param("cardType")String cardType, @Param("state")String state, @Param("uploadDate")String uploadDate); public List<PreproPersonEntity> selectPreproPerson(@Param("uploadNo")String uploadNo, @Param("IDCard")String IDCard, @Param("oldFile")String oldFile, @Param("newFile")String newFile, @Param("SSXQDM")String SSXQDM, @Param("cardType")String cardType, @Param("state")String state, @Param("uploadDate")String uploadDate);
/*修改标记制证数据状态*/ /*修改标记制证数据状态*/
......
...@@ -24,7 +24,7 @@ public class PreproPersonServiceImpl implements PreproPersonService { ...@@ -24,7 +24,7 @@ public class PreproPersonServiceImpl implements PreproPersonService {
} }
@Override @Override
public List<PreproPersonEntity> selectPreproPerson(String uploadNo, String IDCard, String oldFile, String newFile, String SSXQDM, String cardType, String state, String uploadDate) { public List<PreproPersonEntity> selectPreproPerson(String uploadNo, String IDCard, String oldFile, String newFile, String SSXQDM, String cardType, String state, String uploadDate) {
List<PreproPersonEntity> preproPersonEntities = preproPersonMapper.selectPreproPerson(uploadNo, IDCard, oldFile, newFile, SSXQDM, cardType, state, uploadDate); List<PreproPersonEntity> preproPersonEntities = preproPersonMapper.selectPreproPerson(null, null, null, null, null, 0+"", null, null);
return preproPersonEntities; return preproPersonEntities;
} }
} }
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