Commit 8dea2a06 authored by Administrator's avatar Administrator

countyList,groupList,查询出入库数,更新出入库数的taskListId字段改为taskId

parent 28db2beb
...@@ -351,8 +351,8 @@ public class UserApi { ...@@ -351,8 +351,8 @@ public class UserApi {
*/ */
@RequestMapping("getCountyList") @RequestMapping("getCountyList")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getCountyListInfoByTaskListID(@RequestParam("taskListId") String taskListId,@RequestParam("taskStateId") String taskStateId,@RequestParam("cardType") String cardType, HttpServletResponse resp) { public String getCountyListInfoByTaskId(@RequestParam("taskId") String taskId,@RequestParam("taskStateId") String taskStateId,@RequestParam("cardType") String cardType, HttpServletResponse resp) {
List<CountyEntity> countyListEntity = countyService.findCountyList(taskListId,taskStateId,cardType); List<CountyEntity> countyListEntity = countyService.findCountyList(taskId,taskStateId,cardType);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(countyListEntity); yxjsonResponse.outPutSuccess(countyListEntity);
...@@ -368,8 +368,8 @@ public class UserApi { ...@@ -368,8 +368,8 @@ public class UserApi {
*/ */
@RequestMapping("getGroupListByTaskListId") @RequestMapping("getGroupListByTaskListId")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getGroupListByTaskListId(@RequestParam("taskListId") String taskListId, HttpServletResponse resp) { public String getGroupListByTaskId(@RequestParam("taskId") String taskId, HttpServletResponse resp) {
List<GroupListEntity> groupNoEntity = groupListService.findGroupListByTaskListId(taskListId); List<GroupListEntity> groupNoEntity = groupListService.findGroupListByTaskId(taskId);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(groupNoEntity); yxjsonResponse.outPutSuccess(groupNoEntity);
...@@ -470,10 +470,10 @@ public class UserApi { ...@@ -470,10 +470,10 @@ public class UserApi {
* *
* @return * @return
*/ */
@RequestMapping("getStorageCountByTaskListId") @RequestMapping("getStorageCountByTaskId")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getStorageCountByTaskListId(@RequestParam("taskListID") String taskListId, HttpServletResponse resp) { public String getStorageCountByTaskId(@RequestParam("taskId") String taskId, HttpServletResponse resp) {
List <CountyListEntity> countyListEntity=countyListService.findStorageCountByTaskListId(taskListId); List <CountyListEntity> countyListEntity=countyListService.findStorageCountByTaskId(taskId);
YXJSONResponse yxjsonResponse=new YXJSONResponse(); YXJSONResponse yxjsonResponse=new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(countyListEntity); yxjsonResponse.outPutSuccess(countyListEntity);
...@@ -517,54 +517,20 @@ public class UserApi { ...@@ -517,54 +517,20 @@ public class UserApi {
} }
/** /**
* 对出入库数进行更改 * 对出入库数进行更改,并更新出入库时间
* *
* @return * @return
*/ */
@RequestMapping("reviseStorageCount") @RequestMapping("reviseStorageCount")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String reviseStorageCount(@RequestParam("taskListId") String taskListId,@RequestParam("countyCode") String countyCode,@RequestParam("inStorageCount") String in_Storage_Count, @RequestParam("outStorageCount") String out_Storage_Count, HttpServletResponse resp) { public String reviseStorageCount(@RequestParam("taskId") String taskId,@RequestParam("countyCode") String countyCode,@RequestParam("inStorageCount") String inStorageCount, @RequestParam("outStorageCount") String outStorageCount, HttpServletResponse resp) {
int i=countyListService.reviseStorageCount(taskListId,countyCode, in_Storage_Count, out_Storage_Count); int i=countyListService.reviseStorageCount(taskId,countyCode, inStorageCount, outStorageCount);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(i+"--更新成功--"); yxjsonResponse.outPutSuccess(i+"--更新成功--");
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
// /**
// * 更新入库时间
// * 前端空值
// * @return
// */
// @RequestMapping("updateInStorageDate")
//// @RequiresPermissions("userInfo.add")//权限管理;
// public String updateInStorageDate(@RequestParam("taskListId") String taskListId,@RequestParam("inStorageCount") String inStorageCount,@RequestParam("outStorageCount") String outStorageCount, HttpServletResponse resp) {
// int i = taskService.updateStorageDate(taskListId,inStorageCount,outStorageCount);
// YXJSONResponse yxjsonResponse = new YXJSONResponse();
// resp.setCharacterEncoding("UTF-8");
// yxjsonResponse.outPutSuccess(i + "更新成功");
// return yxjsonResponse.toJSONString();
// }
// /**
// * 更新出库时间
// * @return
// */
// @RequestMapping("updateOutBoundDate")
//// @RequiresPermissions("userInfo.add")//权限管理;
// public String updateOutBoundDate(@RequestParam("id") String id, HttpServletResponse resp) {
// String map = "{\"id\":\"20181016001\",} ";
// JSONObject jsonObject = JSONObject.fromObject(map);
// Object outStorageCount = jsonObject.get("outStorageCount");
// Object putOutStorageDate = jsonObject.get("putOutStorageDate");
// TaskEntity taskEntity = (TaskEntity) putOutStorageDate;
// CountyListEntity countyListEntity = (CountyListEntity) outStorageCount;
// YXJSONResponse yxjsonResponse = new YXJSONResponse();
// resp.setCharacterEncoding("UTF-8");
// int i = taskService.updateOutBoundDate(taskEntity,countyListEntity);
// yxjsonResponse.outPutSuccess(i + "更新成功");
// return yxjsonResponse.toJSONString();
// }
/** /**
* 查询交接单; * 查询交接单;
......
...@@ -16,10 +16,10 @@ import java.util.Map; ...@@ -16,10 +16,10 @@ import java.util.Map;
@Mapper @Mapper
public interface CountyListMapper { public interface CountyListMapper {
public List<CountyEntity> findCountyList(@Param("taskListId") String taskListId,@Param("taskStateId") String taskStateId,@Param("cardType") String cardType); public List<CountyEntity> findCountyList(@Param("taskId") String taskId,@Param("taskStateId") String taskStateId,@Param("cardType") String cardType);
public int reviseStorageCount( @Param("taskListId") String taskListId, @Param("countyCode") String countyCode,@Param("in_Storage_Count") String in_Storage_Count,@Param("out_Storage_Count") String out_Storage_Count); public int reviseStorageCount( @Param("taskId") String taskId, @Param("countyCode") String countyCode,@Param("inStorageCount") String inStorageCount,@Param("outStorageCount") String out_Storage_Count);
public List<ReceiptListEntity> getReceiptList( @Param("startDate")String startDate , @Param("endDate") String endDate); public List<ReceiptListEntity> getReceiptList( @Param("startDate")String startDate , @Param("endDate") String endDate);
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId); public List<CountyListEntity> findStorageCountByTaskId(String taskId);
public int totalFinshCount (); public int totalFinshCount ();
public int totalInStorageCount (); public int totalInStorageCount ();
public int totalOutStorageCount (); public int totalOutStorageCount ();
......
...@@ -20,7 +20,7 @@ public interface GroupNoMapper { ...@@ -20,7 +20,7 @@ public interface GroupNoMapper {
public int findGroupNoCountByTaskId(String task_Id); public int findGroupNoCountByTaskId(String task_Id);
public List<Map<String,Object>> findSpecialCountyList(String task_Id); public List<Map<String,Object>> findSpecialCountyList(String task_Id);
public List<Map<String,Object>> findNormalCountyList(String task_Id); public List<Map<String,Object>> findNormalCountyList(String task_Id);
public List<GroupListEntity> findGroupListByTaskListId( String taskListId); public List<GroupListEntity> findGroupListByTaskId( String taskId);
} }
...@@ -20,7 +20,7 @@ public interface TaskMapper { ...@@ -20,7 +20,7 @@ public interface TaskMapper {
public int replaceExceptionInformation(TaskEntity taskEntity); public int replaceExceptionInformation(TaskEntity taskEntity);
public List<TypeListEntity> findTypeListByTaskStateId(String taskStateId); public List<TypeListEntity> findTypeListByTaskStateId(String taskStateId);
public List <CityListEntity> findCityList(@Param("taskStateId") String taskStateId,@Param("cardType") String cardType); public List <CityListEntity> findCityList(@Param("taskStateId") String taskStateId,@Param("cardType") String cardType);
public int updateOutStorageDate(String taskListId); public int updateOutStorageDate(String taskId);
public int updateInStorageDate(String taskListId); public int updateInStorageDate(String taskId);
public int updateStorageDate(String taskListId); public int updateStorageDate(String taskId);
} }
...@@ -8,6 +8,6 @@ import java.util.Map; ...@@ -8,6 +8,6 @@ import java.util.Map;
public interface CountyListService { public interface CountyListService {
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId); public List<CountyListEntity> findStorageCountByTaskId(String taskId);
public int reviseStorageCount(String taskListId,String countyCode, String in_Storage_Count, String out_Storage_Count); public int reviseStorageCount(String taskId,String countyCode, String inStorageCount, String outStorageCount);
} }
...@@ -8,7 +8,7 @@ import java.util.List; ...@@ -8,7 +8,7 @@ import java.util.List;
* Created by Administrator on 2018/12/19. * Created by Administrator on 2018/12/19.
*/ */
public interface CountyService { public interface CountyService {
public List<CountyEntity> findCountyList( String taskListId,String taskStateId,String cardType); public List<CountyEntity> findCountyList( String taskId,String taskStateId,String cardType);
} }
...@@ -9,6 +9,6 @@ import java.util.List; ...@@ -9,6 +9,6 @@ import java.util.List;
*/ */
public interface GroupListService { public interface GroupListService {
public List<GroupListEntity> findGroupListByTaskListId( String taskListId); public List<GroupListEntity> findGroupListByTaskId( String taskId);
} }
...@@ -24,7 +24,7 @@ public class CountyListServiceImpl implements CountyListService { ...@@ -24,7 +24,7 @@ public class CountyListServiceImpl implements CountyListService {
public TaskMapper taskMapper; public TaskMapper taskMapper;
@Override @Override
public int reviseStorageCount(String taskListId,String countyCode, String in_Storage_Count, String out_Storage_Count) { public int reviseStorageCount(String taskId,String countyCode, String inStorageCount, String outStorageCount) {
int i = 0; int i = 0;
int totalFinshCount = 0; int totalFinshCount = 0;
int totalInStorageCount = 0; int totalInStorageCount = 0;
...@@ -32,22 +32,22 @@ public class CountyListServiceImpl implements CountyListService { ...@@ -32,22 +32,22 @@ public class CountyListServiceImpl implements CountyListService {
totalFinshCount = countyListMapper.totalFinshCount(); totalFinshCount = countyListMapper.totalFinshCount();
totalInStorageCount = countyListMapper.totalInStorageCount(); totalInStorageCount = countyListMapper.totalInStorageCount();
totalOutStorageCount = countyListMapper.totalOutStorageCount(); totalOutStorageCount = countyListMapper.totalOutStorageCount();
i = countyListMapper.reviseStorageCount(taskListId, countyCode, in_Storage_Count, out_Storage_Count); i = countyListMapper.reviseStorageCount(taskId, countyCode, inStorageCount, outStorageCount);
if(totalInStorageCount == totalFinshCount){ if(totalInStorageCount == totalFinshCount){
taskMapper.updateInStorageDate(taskListId); taskMapper.updateInStorageDate(taskId);
} }
if(totalOutStorageCount == totalFinshCount){ if(totalOutStorageCount == totalFinshCount){
taskMapper.updateOutStorageDate(taskListId); taskMapper.updateOutStorageDate(taskId);
} }
if(totalInStorageCount == totalFinshCount && totalOutStorageCount == totalFinshCount){ if(totalInStorageCount == totalFinshCount && totalOutStorageCount == totalFinshCount){
taskMapper.updateStorageDate(taskListId); taskMapper.updateStorageDate(taskId);
} }
return i; return i;
} }
@Override @Override
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId){ public List<CountyListEntity> findStorageCountByTaskId(String taskId){
return countyListMapper.findStorageCountByTaskListId(taskListId); return countyListMapper.findStorageCountByTaskId(taskId);
} }
......
...@@ -20,8 +20,8 @@ public class CountyServiceImpl implements CountyService { ...@@ -20,8 +20,8 @@ public class CountyServiceImpl implements CountyService {
public CountyListMapper countyListMapper; public CountyListMapper countyListMapper;
@Override @Override
public List <CountyEntity> findCountyList( String taskListId, String taskStateId, String cardType ) { public List <CountyEntity> findCountyList( String taskId, String taskStateId, String cardType ) {
List<CountyEntity> county = countyListMapper.findCountyList(taskListId,taskStateId,cardType); List<CountyEntity> county = countyListMapper.findCountyList(taskId,taskStateId,cardType);
return county; return county;
} }
......
...@@ -22,8 +22,8 @@ public class GroupListServiceImpl implements GroupListService { ...@@ -22,8 +22,8 @@ public class GroupListServiceImpl implements GroupListService {
public SpecialCardMapper specialCardMapper; public SpecialCardMapper specialCardMapper;
@Override @Override
public List<GroupListEntity> findGroupListByTaskListId( String taskListId) { public List<GroupListEntity> findGroupListByTaskId( String taskId) {
List <GroupListEntity> groupList=groupNoMapper.findGroupListByTaskListId(taskListId); List <GroupListEntity> groupList=groupNoMapper.findGroupListByTaskId(taskId);
for ( GroupListEntity groupListEntity:groupList) { for ( GroupListEntity groupListEntity:groupList) {
List <SpecialCardEntity> specialCardEntities=specialCardMapper.findSpecialCardList(groupListEntity.getGroupNo()+""); List <SpecialCardEntity> specialCardEntities=specialCardMapper.findSpecialCardList(groupListEntity.getGroupNo()+"");
groupListEntity.setSpecialCardList(specialCardEntities); groupListEntity.setSpecialCardList(specialCardEntities);
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
SELECT COUNTY_LIST.COUNTY_CODE,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,COUNTY_DIC.COUNTYNAME FROM COUNTY_LIST SELECT COUNTY_LIST.COUNTY_CODE,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,COUNTY_DIC.COUNTYNAME FROM COUNTY_LIST
LEFT JOIN TASK ON COUNTY_LIST.TASK_ID = TASK.TASK_ID LEFT JOIN TASK ON COUNTY_LIST.TASK_ID = TASK.TASK_ID
LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE
WHERE TASK.TASK_ID=#{taskListId} AND TASK.CARD_TYPE=#{cardType} AND TASK.TASK_STATE_ID=#{taskStateId} WHERE TASK.TASK_ID=#{taskId} AND TASK.CARD_TYPE=#{cardType} AND TASK.TASK_STATE_ID=#{taskStateId}
</select> </select>
<select id="getReceiptList" resultType="com.yxproject.start.entity.ReceiptListEntity" parameterType="String"> <select id="getReceiptList" resultType="com.yxproject.start.entity.ReceiptListEntity" parameterType="String">
...@@ -58,16 +58,16 @@ ...@@ -58,16 +58,16 @@
GROUP BY ROLLUP(t_total_count.COUNTYNAME) GROUP BY ROLLUP(t_total_count.COUNTYNAME)
</select> </select>
<select id="findStorageCountByTaskListId" resultType="java.util.HashMap" parameterType="String"> <select id="findStorageCountByTaskId" resultType="java.util.HashMap" parameterType="String">
SELECT TASK_ID,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,CITY_DIC.CITYNAME||' '||COUNTY_DIC.COUNTYNAME,COUNTY_DIC.COUNTY_CODE FROM COUNTY_LIST SELECT TASK_ID,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,CITY_DIC.CITYNAME||' '||COUNTY_DIC.COUNTYNAME,COUNTY_DIC.COUNTY_CODE FROM COUNTY_LIST
LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE
LEFT JOIN CITY_DIC ON substr(CITY_DIC.CITYCODE,1,4) = substr(COUNTY_LIST.COUNTY_CODE,1,4) LEFT JOIN CITY_DIC ON substr(CITY_DIC.CITYCODE,1,4) = substr(COUNTY_LIST.COUNTY_CODE,1,4)
WHERE TASK_ID=#{task_Id} WHERE TASK_ID=#{taskId}
</select> </select>
<insert id="reviseStorageCount" parameterType="String" > <insert id="reviseStorageCount" parameterType="String" >
INSERT INTO COUNTY_LIST (TASK_ID,COUNTY_CODE,IN_STORAGE_COUNT,OUT_STORAGE_COUNT) VALUES ( #{taskListId},#{countyCode},#{in_Storage_Count},#{out_Storage_Count} ) INSERT INTO COUNTY_LIST (TASK_ID,COUNTY_CODE,IN_STORAGE_COUNT,OUT_STORAGE_COUNT) VALUES ( #{taskId},#{countyCode},#{inStorageCount},#{outStorageCount} )
</insert> </insert>
<select id="totalFinshCount" resultType="Integer"> <select id="totalFinshCount" resultType="Integer">
......
...@@ -43,10 +43,10 @@ ...@@ -43,10 +43,10 @@
SELECT * FROM TABLE(find_normal_county_list.GET_county_infos(#{task_Id})) SELECT * FROM TABLE(find_normal_county_list.GET_county_infos(#{task_Id}))
</select> </select>
<select id="findGroupListByTaskListId" resultType="com.yxproject.start.entity.GroupListEntity" parameterType="String"> <select id="findGroupListByTaskId" resultType="com.yxproject.start.entity.GroupListEntity" parameterType="String">
select GROUP_NO as groupNo,sum(VALID_COUNT) as validCount,sum(INVALID_COUNT) as invalidCount,sum(SPECIAL_CARD_COUNT) as specialCardCount from (select sum(VALID_COUNT),sum(INVALID_COUNT),sum(SPECIAL_CARD_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO select GROUP_NO as groupNo,sum(VALID_COUNT) as validCount,sum(INVALID_COUNT) as invalidCount,sum(SPECIAL_CARD_COUNT) as specialCardCount from (select sum(VALID_COUNT),sum(INVALID_COUNT),sum(SPECIAL_CARD_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO
left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID
where TASK.TASK_ID=#{task_Id} where TASK.TASK_ID=#{taskId}
group by GROUP_NO group by GROUP_NO
</select> </select>
......
...@@ -73,15 +73,15 @@ ...@@ -73,15 +73,15 @@
</update> </update>
<update id="updateOutStorageDate"> <update id="updateOutStorageDate">
UPDATE TASK SET OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<update id="updateInStorageDate" > <update id="updateInStorageDate" >
UPDATE TASK SET IN_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET IN_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<update id="updateStorageDate" > <update id="updateStorageDate" >
UPDATE TASK SET IN_STORAGE_DATE = SYSDATE , OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET IN_STORAGE_DATE = SYSDATE , OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<select id="findTypeListByTaskStateId" resultType="com.yxproject.start.entity.TypeListEntity" parameterType="String"> <select id="findTypeListByTaskStateId" resultType="com.yxproject.start.entity.TypeListEntity" parameterType="String">
......
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