Commit b9d35a90 authored by dahai's avatar dahai

Merge remote-tracking branch 'origin/dev' into dev

parents 104a2742 ef429d5c
......@@ -94,27 +94,29 @@ public class FailedCardApi {
public Boolean insertRemaining(@RequestBody String jsonStr){
JSONObject jsonObject = JSONObject.fromObject(jsonStr);
JSONArray jsonarray = JSONArray.fromObject(jsonObject.get("list"));
System.out.println("1111111111111"+jsonarray);
TaskEntity taskEntity = new TaskEntity();
for (int i=0;i<jsonarray.size();i++) {
/*查询生成任务单需要的数据*/
// JSONObject jsonObject2 =(JSONObject)o;
Map<String,Object> resultMap= failedCardService.selectTaskListDate((String) jsonarray.get(i));
try {
//TODO 会报空指针异常
String countyCode = resultMap.get("COUNTY_CODE").toString();
Long cardType = (Long) resultMap.get("CARD_TYPE_ID");
String acceptNo = (String) resultMap.get("ACCEPT_NO");
taskEntity.setCountyCode(countyCode);
taskEntity.setCardType(cardType);
taskEntity.setTaskStateId((long) 1);
}catch (NullPointerException e){
}
System.out.println("333333333333333333333333过");
taskListService.saveTask(taskEntity);
/*特证表添加特证*/
failedCardService.addSpecialCard((String) jsonarray.get(i));
failedCardService.addSpecialCard(acceptNo);
/*特证数+1*/
failedCardService.specialCardAdd((String) jsonarray.get(i));
failedCardService.specialCardAdd(acceptNo);
}catch (NullPointerException e){
}
}
return true;
}
......
......@@ -71,12 +71,19 @@ public interface FailedCardMapper {
@Select("select SPECIAL_CARD.SPECIAL_TYPE,subStr(prod_card_t.UPLOAD_NO,0,6),SPECIAL_CARD.INITIATOR,PREPRO_PERSON.CARD_TYPE_ID\n" +
@Select("select SPECIAL_CARD.SPECIAL_TYPE,prod_card_t.accept_no,subStr(prod_card_t.UPLOAD_NO,0,6),SPECIAL_CARD.INITIATOR,PREPRO_PERSON.CARD_TYPE_ID\n" +
"from prod_card_t@prod_link\n" +
"left join SPECIAL_CARD on prod_card_t.accept_no = SPECIAL_CARD.accept_no\n" +
"left join PREPRO_PERSON on PREPRO_PERSON.JMSFZSLH=prod_card_t.UPLOAD_NO\n" +
"where prod_card_t.accept_no=#{acceptNo}")
"where prod_card_t.accept_no=#{acceptNo} or prod_card_t.ID_NO=#{acceptNo}")
public Map<String,Object> selectTaskListDate(String acceptNo);
/*历史回迁证*/
}
......@@ -84,7 +84,7 @@ public interface LogMapper {
" and NEW_FILES.DWDM=#{uploadCountyCode}" +
" </if>" +
" <if test='createDate !=\"\"' >" +
" and NEW_FILES.CREATE_DATE=#{createDate}" +
" and substr(NEW_FILES.CREATE_DATE,0,8)=#{createDate}" +
" </if>" +
" <if test='cardId !=\"\"' >" +
" and PREPRO_PERSON.GMSFHM=#{cardId} " +
......
......@@ -29,7 +29,11 @@ public interface PersonPostMapper {
//TODO getToCounty是List
@Select("SELECT * FROM PERSON_POST " +
@Select("<script> " +
"SELECT * FROM " +
"( " +
"SELECT A.*, ROWNUM RN " +
" from (SELECT * FROM PERSON_POST " +
" LEFT JOIN FILE_NAME_DIC ON FILE_NAME_DIC.FILE_ID=PERSON_POST.FILE_ID" +
"WHERE 1=1" +
" <when test='applicantName!=null'> and PERSON_POST.APPLICANT_NAME = #{applicantName} </when>" +
......@@ -38,8 +42,29 @@ public interface PersonPostMapper {
" <when test='latticeMouthInformation!=null'> and PERSON_POST.LATTICE_MOUTH_INFORMATION=#{latticeMouthInformation} </when>" +
" <when test='getToCounty!=null'> and PERSON_POST.GET_TO_COUNTY in ( #{getToCounty} ) </when>" +
" <when test='uploadDate!=null'> and FILE_NAME_DIC.UPLOAD_DATE=#{uploadDate} </when>" +
"PERSON_POST limit #{firstIndex},#{pageSize}")
public List<PersonPostEntity> findAllPersonalData(@Param("applicantName")String applicantName,@Param("orderNumber")String orderNumber,@Param("state")String state,@Param("latticeMouthInformation")String latticeMouthInformation,@Param("getToCounty")String getToCounty,@Param("uploadDate")String uploadDate,@Param("firstIndex")String firstIndex,@Param("pageSize")String pageSize);
// "PERSON_POST limit #{firstIndex},#{pageSize}"
") " +
"A" +
")" +
"WHERE RN BETWEEN #{firstIndex} AND #{pageSize}" +
"</script>")
public List<PersonPostEntity> findAllPersonalData(@Param("applicantName")String applicantName,@Param("orderNumber")String orderNumber,@Param("state")String state,@Param("latticeMouthInformation")String latticeMouthInformation,@Param("getToCounty")String getToCounty,@Param("uploadDate")String uploadDate,@Param("firstIndex")long firstIndex,@Param("pageSize")long pageSize);
@Select("<script> " +
"SELECT COUNT(*) FROM NEW_FILES \n" +
"LEFT JOIN PREPRO_PERSON ON NEW_FILES.ID = PREPRO_PERSON.NEW_FILE_ID " +
" where 1=1 " +
" <when test='applicantName!=null'> and PERSON_POST.APPLICANT_NAME = #{applicantName} </when>" +
" <when test='orderNumber!=null'> and PERSON_POST.ORDER_NUMBER=#{orderNumber} </when>" +
" <when test='state!=null'> and PERSON_POST.STATE=#{state} </when>" +
" <when test='latticeMouthInformation!=null'> and PERSON_POST.LATTICE_MOUTH_INFORMATION=#{latticeMouthInformation} </when>" +
" <when test='getToCounty!=null'> and PERSON_POST.GET_TO_COUNTY in ( #{getToCounty} ) </when>" +
" <when test='uploadDate!=null'> and FILE_NAME_DIC.UPLOAD_DATE=#{uploadDate} </when>" +
"</script>")
public int findPersonalDataCount(String applicantName, String orderNumber, String state, String latticeMouthInformation, List<String> getToCounty, String uploadDate);
@Delete("DELETE PERSON_POST " +
"WHERE 1=1" +
......@@ -51,6 +76,8 @@ public interface PersonPostMapper {
" <when test='uploadDate!=null'> and FILE_NAME_DIC.UPLOAD_DATE=#{uploadDate} </when>")
public boolean deleteAllPersonalData(@Param("applicantName")String applicantName,@Param("orderNumber")String orderNumber,@Param("state")String state,@Param("latticeMouthInformation")String latticeMouthInformation,List<String> getToCounty ,@Param("uploadDate")String uploadDate);
@Delete("DELETE FROM PERSON_POST WHERE FILE_ID = #{fileId}")
public void deletePersonPostByFileId(@Param("fileId")String fileId);
......
......@@ -53,6 +53,8 @@ public class PersonPostServiceImpl implements PersonPostService {
@Override
public List<PersonPostEntity> findPersonalData(String applicantName,String orderNumber,String state,String latticeMouthInformation,List<String> getToCounty,String uploadDate,String firstIndex,String pageSize){
String str = null;
long firstIndexLong= Long.valueOf(firstIndex);
long pageSizeLong = Long.valueOf(pageSize);
for (int i = 0;i<getToCounty.size();i++){
if (i==getToCounty.size()-1){
str+="'"+getToCounty.get(i);
......@@ -60,7 +62,7 @@ public class PersonPostServiceImpl implements PersonPostService {
str+="'"+getToCounty.get(i)+",";
}
}
List<PersonPostEntity> list = personPostMapper.findAllPersonalData(applicantName,orderNumber,state,latticeMouthInformation,str,uploadDate,firstIndex,pageSize);
List<PersonPostEntity> list = personPostMapper.findAllPersonalData(applicantName,orderNumber,state,latticeMouthInformation,str,uploadDate,firstIndexLong * pageSizeLong,(firstIndexLong - 1) * pageSizeLong + 1);
return list;
}
......@@ -86,7 +88,8 @@ public class PersonPostServiceImpl implements PersonPostService {
@Override
public int findPersonalDataCount(String applicantName, String orderNumber, String state, String latticeMouthInformation, List<String> getToCounty, String uploadDate) {
return 0;
int count=personPostMapper.findPersonalDataCount(applicantName,orderNumber,state,latticeMouthInformation,getToCounty,uploadDate);
return count;
}
// /**
......
......@@ -16,7 +16,6 @@ public class SelectSerialNumberServiceImpl implements SelectSerialNumberService{
@Override
public List<Map<String, Object>> selectByWorkOrderFromYX(String id){
List<Map<String, Object>> result = selectSerialNumberMapper.selectByWorkOrder(id);
System.out.println("任务单信息:"+result);
return result;
}
......@@ -24,7 +23,6 @@ public class SelectSerialNumberServiceImpl implements SelectSerialNumberService{
public List<Map<String, Object>> selectByGroupNo(String id) {
System.out.println("impl");
List<Map<String, Object>> result = selectSerialNumberMapper.selectByGroupNo(id);
System.out.println("查询结果:"+result);
return result;
}
......
......@@ -342,6 +342,9 @@ angular.module('AvatarCheck.http', ['ngDialog', 'LocalStorageModule'])
if(angular.isUndefined(county)){
county = -1;
}
if(date==""){
date=$filter("date")(new Date(), "yyyy-MM-dd");
}
console.log(newPackageName,idCard,date,county)
$http({
method: 'GET',
......@@ -366,6 +369,9 @@ angular.module('AvatarCheck.http', ['ngDialog', 'LocalStorageModule'])
if(angular.isUndefined(county)){
county = -1;
}
if(date==""){
date=$filter("date")(new Date(), "yyyy-MM-dd");
}
console.log(newPackageName,idCard,date,county)
$http({
method: 'GET',
......
......@@ -148,10 +148,11 @@ angular.module('AvatarCheck.task', ['ngRoute', 'AvatarCheck.http'])
var checks = document.getElementsByClassName("checkOneBox");
for (var i=0;i<checks.length;i++){
if (checks[i].checked) {
sum += parseInt(checks[i].value);
sum += parseInt(checks[i].name);
}
}
$rootScope.cardsTotal = $rootScope.cardsTotal + sum - temp;
$scope.restCount=$rootScope.cardsTotal%8;
temp = sum;
};
......@@ -169,22 +170,21 @@ angular.module('AvatarCheck.task', ['ngRoute', 'AvatarCheck.http'])
var sum = 0;
var checks = document.getElementsByClassName("checkOneBox");
for (var i = 0; i < checks.length; i++) {
sum += parseInt(checks[i].value);
sum += parseInt(checks[i].name);
}
$rootScope.cardsTotal = $rootScope.cardsTotal + sum - temp;
$scope.restCount=$rootScope.cardsTotal%8;
temp = sum;
}else{
$rootScope.cardsTotal =0;
$scope.restCount=0
temp = 0;
}
};
$scope.isSelected = function (task) {
return $scope.selected.indexOf(task) >= 0;
};
$scope.isSelectedAll = function (index) {
return $scope.selected.length === $scope.cycleSheetData[index].countyList.length > 0;
};
$scope.currentTab = 0;
$scope.func = function (index) {
......
......@@ -28,8 +28,8 @@
</a>
</li>
<li class="pull-right" style="padding-right: 20px;">
<h5>任务总数:8001</h5>
<h4>余证数:1</h4>
<h5>任务总数:{{cardsTotal}}</h5>
<h4>余证数:{{restCount}}</h4>
</li>
</ul>
</div>
......@@ -43,22 +43,24 @@
<th>地区</th>
<th>组数</th>
<th>组号</th>
<th>数据核验数量</th>
<th>电写入数量</th>
<th>核验数量</th>
<th>证件数量</th>
<th>特殊证件数量</th>
<th>废证数量</th>
<th></th>
</tr>
</thead>
<tbody>
<tr ng-repeat="task in type.countyList">
<td><input type="checkbox" class="checkOneBox" ng-checked="isSelected(task)" value="{{task.taskId}}" ng-click="updateSelection($event,task)"></td>
<td><input type="checkbox" class="checkOneBox" ng-checked="isSelected(task)" value="{{task.taskId}}" name="{{task.countyValidCount-task.specialCount}}" ng-click="updateSelection($event,task)"></td>
<td class="mailbox-star"><b>{{task.taskId}}</b></td>
<td class="mailbox-subject">{{task.checkDate}}</td>
<td class="mailbox-subject">{{task.saveDate}}</td>
<td class="mailbox-subject"><a>{{task.countyName}}</a></td>
<td class="mailbox-subject">{{task.groupList.length}}</td>
<td class="mailbox-subject">{{task.groupNum}}</td>
<td class="mailbox-subject">{{task.dataCheckCount}}</td>
<td class="mailbox-attachment">{{task.electricCount}}</td>
<td class="mailbox-subject">{{task.countyValidCount}}</td>
<td class="mailbox-subject">{{task.countyValidCount-task.specialCount}}</td>
<td class="mailbox-attachment">{{task.specialCount}}</td>
<td ng-if="task.faileCount!=0" class="mailbox-subject" style="color: red;">{{task.faileCount}}</td>
<td ng-if="task.faileCount==0" class="mailbox-subject">{{task.faileCount}}</td>
<td class="mailbox-date"><a ng-click="getPoliceList(task.taskId)">组号列表</a></td>
......
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