Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
Y
YX_IDENT_beijing_auxiliary_YD
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhangyusheng
YX_IDENT_beijing_auxiliary_YD
Commits
740f98f8
Commit
740f98f8
authored
Apr 12, 2019
by
liboyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
e5f3263f
b4b5c1c0
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
283 additions
and
50 deletions
+283
-50
ReadXmlApi.java
src/main/java/com/yxproject/start/api/ReadXmlApi.java
+1
-7
ReportApi.java
src/main/java/com/yxproject/start/api/ReportApi.java
+68
-7
TaskListApi.java
src/main/java/com/yxproject/start/api/TaskListApi.java
+30
-17
DataAuditingEntity.java
...n/java/com/yxproject/start/entity/DataAuditingEntity.java
+74
-0
DataAuditingMapper.java
...n/java/com/yxproject/start/mapper/DataAuditingMapper.java
+31
-0
TaskListMapper.java
src/main/java/com/yxproject/start/mapper/TaskListMapper.java
+13
-13
DataAuditingService.java
...java/com/yxproject/start/service/DataAuditingService.java
+17
-0
TaskListService.java
...ain/java/com/yxproject/start/service/TaskListService.java
+1
-1
DataAuditingServiceImpl.java
...yxproject/start/service/impl/DataAuditingServiceImpl.java
+40
-0
TaskListServiceImpl.java
...com/yxproject/start/service/impl/TaskListServiceImpl.java
+6
-5
taskListSorting.html
src/main/resources/static/views/task/taskListSorting.html
+2
-0
No files found.
src/main/java/com/yxproject/start/api/ReadXmlApi.java
View file @
740f98f8
...
...
@@ -110,8 +110,6 @@ public class ReadXmlApi {
}
}
}
// item
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
yxresp
.
outPutError
(
"FileUploadException"
,
"文件上传发生异常:"
+
e
.
getMessage
());
...
...
@@ -178,14 +176,9 @@ public class ReadXmlApi {
}
}
else
{
for
(
int
i
=
min
-
1
;
i
<
max
;
i
++){
list
.
add
(
mapList
.
get
(
i
));
}
}
resultMap
.
put
(
"mapList"
,
list
);
}
else
{
resultMap
.
put
(
"mapList"
,
mapList
);
}
...
...
@@ -212,6 +205,7 @@ public class ReadXmlApi {
yxjsonResponse
.
outPutSuccess
(
i
+
""
);
return
yxjsonResponse
.
toJSONString
();
}
private
String
replaceDate
(
String
str
){
return
str
.
replace
(
"-"
,
""
);
}
...
...
src/main/java/com/yxproject/start/api/ReportApi.java
View file @
740f98f8
package
com
.
yxproject
.
start
.
api
;
import
com.yxproject.start.
entity.TaskList.CountCountyEntity
;
import
com.yxproject.start.
service.DataAuditingService
;
import
com.yxproject.start.service.TaskListService
;
import
net.sf.json.JSONObject
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -9,30 +9,91 @@ import org.springframework.web.bind.annotation.RequestParam;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.List
;
import
java.util.Map
;
/**
* @auther zhangyusheng
* 2019/4/9 12:04
* 报表接口
*/
@RestController
@RequestMapping
(
"ReportApi"
)
public
class
ReportApi
{
@Autowired
private
TaskListService
taskListService
;
@Autowired
private
DataAuditingService
dataAuditingService
;
/**
* 查询报表
* 数据核验
* @param submitDate
* @param startDate 开始时间
* @param endDate 结束时间
* @return
*/
@RequestMapping
(
"queryDataAuditingReport"
)
public
JSONObject
queryDataAuditingReport
(
@RequestParam
(
value
=
"startDate"
)
String
startDate
,
@RequestParam
(
value
=
"endDate"
)
String
endDate
)
{
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingReport
(
startDate
,
endDate
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
mapList
);
return
resultJson
;
}
/**
* 查询报表
* 膜打印
* @param startDate 开始时间
* @param endDate 结束时间
* @return
*/
@RequestMapping
(
"queryFilmPrintReport"
)
public
JSONObject
queryFilmPrintReport
(
@RequestParam
(
value
=
"startDate"
)
String
startDate
,
@RequestParam
(
value
=
"endDate"
)
String
endDate
)
{
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingReport
(
startDate
,
endDate
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
mapList
);
return
resultJson
;
}
/**
* 查询报表
* 工作组
* @param startDate 开始时间
* @param endDate 结束时间
* @param workGroup 工作组
* @return
*/
@RequestMapping
(
"query
ReportApi
"
)
public
JSONObject
selectByCounty
(
@RequestParam
(
value
=
"submitDate"
)
String
submitDate
)
{
List
<
CountCountyEntity
>
resultList
=
taskListService
.
selectByCounty
(
submit
Date
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
result
List
);
@RequestMapping
(
"query
WorkGroupReport
"
)
public
JSONObject
queryWorkGroupReport
(
@RequestParam
(
value
=
"startDate"
)
String
startDate
,
@RequestParam
(
value
=
"endDate"
)
String
endDate
,
@RequestParam
(
value
=
"workGroup"
)
String
workGroup
)
{
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingReport
(
startDate
,
end
Date
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
map
List
);
return
resultJson
;
}
/**
* 查询报表
* 分拣
* @param startDate 开始时间
* @param endDate 结束时间
* @return
*/
@RequestMapping
(
"querySortingReport"
)
public
JSONObject
querySortingReport
(
@RequestParam
(
value
=
"startDate"
)
String
startDate
,
@RequestParam
(
value
=
"endDate"
)
String
endDate
)
{
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingReport
(
startDate
,
endDate
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
mapList
);
return
resultJson
;
}
/**
* 查询报表
* 质检
* @param startDate 开始时间
* @param endDate 结束时间
* @return
*/
@RequestMapping
(
"queryQualityCheckReport"
)
public
JSONObject
queryQualityCheckReport
(
@RequestParam
(
value
=
"startDate"
)
String
startDate
,
@RequestParam
(
value
=
"endDate"
)
String
endDate
)
{
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingReport
(
startDate
,
endDate
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
mapList
);
return
resultJson
;
}
}
src/main/java/com/yxproject/start/api/TaskListApi.java
View file @
740f98f8
...
...
@@ -4,10 +4,12 @@ import com.yxproject.start.entity.*;
import
com.yxproject.start.entity.TaskList.CountCountyEntity
;
import
com.yxproject.start.entity.TaskList.CountGajgEntity
;
import
com.yxproject.start.entity.TaskList.TaskListEntity
;
import
com.yxproject.start.mapper.DataAuditingMapper
;
import
com.yxproject.start.service.GroupNoService
;
import
com.yxproject.start.service.PreproPersonService
;
import
com.yxproject.start.service.SpecialCardService
;
import
com.yxproject.start.service.TaskListService
;
import
com.yxproject.start.service.impl.DataAuditingServiceImpl
;
import
net.sf.json.JSONArray
;
import
net.sf.json.JSONObject
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -18,6 +20,7 @@ import org.springframework.web.bind.annotation.RestController;
import
javax.servlet.http.HttpServletResponse
;
import
javax.transaction.Transactional
;
import
java.util.ArrayList
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -37,20 +40,22 @@ public class TaskListApi {
private
GroupNoService
groupNoService
;
@Autowired
private
PreproPersonService
preproPersonService
;
@Autowired
private
DataAuditingServiceImpl
dataAuditingService
;
/**
* 查询以区为单位的制证数量
* 受理库
*
* @param submitDate
* @return
*/
@RequestMapping
(
"selectByCounty"
)
public
JSONObject
selectByCounty
(
@RequestParam
(
value
=
"submitDate"
)
String
submitDate
)
{
List
<
CountCountyEntity
>
resultList
=
taskListService
.
selectByCounty
(
submitDate
);
JSONObject
resultJson
=
JSONObject
.
fromObject
(
resultList
);
return
resultJson
;
}
//
/**
//
* 查询以区为单位的制证数量
//
* 受理库
//
*
//
* @param submitDate
//
* @return
//
*/
//
@RequestMapping("selectByCounty")
//
public JSONObject selectByCounty(@RequestParam(value = "submitDate") String submitDate) {
//
List<CountCountyEntity> resultList = taskListService.selectByCounty(submitDate);
//
JSONObject resultJson = JSONObject.fromObject(resultList);
//
return resultJson;
//
}
/**
* 查询以派出所为单位的制证数量
...
...
@@ -272,9 +277,7 @@ public class TaskListApi {
public
Map
<
String
,
Object
>
queryByCountyAtACCU
(
@RequestBody
String
str
,
HttpServletResponse
resp
)
{
System
.
out
.
println
(
str
);
JSONObject
jsonObject
=
JSONObject
.
fromObject
(
str
);
String
date
=
jsonObject
.
getString
(
"date"
);
String
name
=
jsonObject
.
getString
(
"name"
);
JSONArray
jsonGroup
=
jsonObject
.
getJSONArray
(
"groupList"
);
//生成某几个组的区县任务单
if
(
jsonGroup
.
size
()
>
0
)
{
...
...
@@ -290,9 +293,19 @@ public class TaskListApi {
}
}
List
<
Map
<
String
,
Object
>>
objects
=
taskListService
.
selectGroupAtACCU
(
groupNo
);
// 查询数据核验报表信息 并保存数据核验报表
List
<
Map
<
String
,
Object
>>
mapList
=
dataAuditingService
.
selectDataAuditingList
(
groupNo
);
List
<
DataAuditingEntity
>
dataAuditingEntities
=
new
ArrayList
<>();
for
(
Map
<
String
,
Object
>
map
:
mapList
){
DataAuditingEntity
dataAuditingEntity
=
new
DataAuditingEntity
();
dataAuditingEntity
.
setCount
(
Long
.
valueOf
(
map
.
get
(
"COUNT"
)+
""
));
dataAuditingEntity
.
setPoliceSubstation
(
map
.
get
(
"POLICE_SUBSTATION"
)+
""
);
dataAuditingEntities
.
add
(
dataAuditingEntity
);
}
boolean
b
=
taskListService
.
saveTask
(
objects
,
name
,
0
+
""
);
dataAuditingService
.
saveDataAuditingList
(
dataAuditingEntities
);
}
}
Map
<
String
,
Object
>
map
=
new
LinkedHashMap
<>();
map
.
put
(
"msg"
,
"成功生成任务单"
);
...
...
@@ -313,7 +326,7 @@ public class TaskListApi {
@RequestMapping
(
"createFastTask"
)
@Transactional
public
Map
<
String
,
Object
>
createFastTask
(
@RequestBody
String
object
,
HttpServletResponse
resp
)
{
//
todo
添加没有解析进去受理库情况
// 添加没有解析进去受理库情况
JSONObject
jsonObject
=
JSONObject
.
fromObject
(
object
);
String
acceptNo
=
jsonObject
.
getString
(
"acceptNo"
);
String
cardType
=
jsonObject
.
getString
(
"cardType"
);
...
...
src/main/java/com/yxproject/start/entity/DataAuditingEntity.java
0 → 100644
View file @
740f98f8
package
com
.
yxproject
.
start
.
entity
;
import
javax.persistence.*
;
import
java.sql.Time
;
import
java.util.Objects
;
/**
* @auther zhangyusheng
* 2019/4/11 11:54
*/
@Entity
@Table
(
name
=
"DATA_AUDITING"
,
schema
=
"YINGXIN"
,
catalog
=
""
)
public
class
DataAuditingEntity
{
private
Long
id
;
private
String
policeSubstation
;
private
Long
count
;
private
Time
submitDate
;
@Id
@Column
(
name
=
"ID"
)
public
Long
getId
()
{
return
id
;
}
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
@Basic
@Column
(
name
=
"POLICE_SUBSTATION"
)
public
String
getPoliceSubstation
()
{
return
policeSubstation
;
}
public
void
setPoliceSubstation
(
String
policeSubstation
)
{
this
.
policeSubstation
=
policeSubstation
;
}
@Basic
@Column
(
name
=
"COUNT"
)
public
Long
getCount
()
{
return
count
;
}
public
void
setCount
(
Long
count
)
{
this
.
count
=
count
;
}
@Basic
@Column
(
name
=
"SUBMIT_DATE"
)
public
Time
getSubmitDate
()
{
return
submitDate
;
}
public
void
setSubmitDate
(
Time
submitDate
)
{
this
.
submitDate
=
submitDate
;
}
@Override
public
boolean
equals
(
Object
o
)
{
if
(
this
==
o
)
return
true
;
if
(
o
==
null
||
getClass
()
!=
o
.
getClass
())
return
false
;
DataAuditingEntity
that
=
(
DataAuditingEntity
)
o
;
return
Objects
.
equals
(
id
,
that
.
id
)
&&
Objects
.
equals
(
policeSubstation
,
that
.
policeSubstation
)
&&
Objects
.
equals
(
count
,
that
.
count
)
&&
Objects
.
equals
(
submitDate
,
that
.
submitDate
);
}
@Override
public
int
hashCode
()
{
return
Objects
.
hash
(
id
,
policeSubstation
,
count
,
submitDate
);
}
}
src/main/java/com/yxproject/start/mapper/DataAuditingMapper.java
0 → 100644
View file @
740f98f8
package
com
.
yxproject
.
start
.
mapper
;
import
com.yxproject.start.entity.DataAuditingEntity
;
import
org.apache.ibatis.annotations.*
;
import
java.util.List
;
import
java.util.Map
;
/**
* @auther zhangyusheng
* 2019/4/11 11:55
*/
@Mapper
public
interface
DataAuditingMapper
{
@Insert
(
"insert into Data_Auditing (POLICE_SUBSTATION,count,submit_date) values (#{policeSubstation},#{count},sysdate) "
)
@Options
(
useGeneratedKeys
=
true
,
keyProperty
=
"id"
,
keyColumn
=
"ID"
)
public
boolean
saveDataAuditingEntity
(
DataAuditingEntity
dataAuditingEntity
);
@Select
(
"select substr(UPLOAD_NO,0,6)||'000' POLICE_SUBSTATION ,count(UPLOAD_NO) count from ACC_CARD_T@ACCU_LINK \n"
+
"where ACCEPT_NO not in (select ACCEPT_NO from ACC_ERROR_INFO_T@ACCU_LINK) and substr(ACCEPT_NO,0,8) in (#{groupNo})\n"
+
"group by substr(UPLOAD_NO,0,6)"
)
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingEntity
(
@Param
(
"groupNo"
)
String
groupNo
);
@Select
(
"select DATA_AUDITING.POLICE_SUBSTATION,sum(count),GAJG_DM.GAJG_MC from DATA_AUDITING \n"
+
"left join GAJG_DM on GAJG_DM.GAJG_DM = DATA_AUDITING.POLICE_SUBSTATION \n"
+
"where to_char(SUBMIT_DATE,'yyyyMMdd') BETWEEN #{startDate} and #{endDate}\n"
+
"group by DATA_AUDITING.POLICE_SUBSTATION,GAJG_DM.GAJG_MC"
)
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingReport
(
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
);
}
src/main/java/com/yxproject/start/mapper/TaskListMapper.java
View file @
740f98f8
...
...
@@ -15,19 +15,19 @@ import java.util.Map;
@Mapper
public
interface
TaskListMapper
{
/**
* 区县计数查询
* 受理库
* @param submitDate
* @return
*/
@Select
(
" SELECT coun.COUNTYNAME,substr(act.upload_no,0,6),count(*) as count FROM ACC_CARD_T@ACCU_LINK act ,count()"
+
" LEFT JOIN ACC_GROUP_T@ACCU_LINK agt on substr(act.accept_no,0,8) = agt.group_no "
+
" LEFT JOIN COUNTY_DIC coun on substr(act.upload_no,0,6) = coun.county_code "
+
" WHERE agt.group_no not in (select GROUP_NO.group_no from GROUP_NO) "
+
" and to_char(IMPORT_TIME,'yyyymmdd') = #{submitDate} "
+
" GROUP by coun.COUNTYNAME,substr(act.upload_no,0,6)"
)
public
List
<
CountCountyEntity
>
selectByCounty
(
@Param
(
"submitDate"
)
String
submitDate
);
//
/**
//
* 区县计数查询
//
* 受理库
//
* @param submitDate
//
* @return
//
*/
//
@Select(" SELECT coun.COUNTYNAME,substr(act.upload_no,0,6),count(*) as count FROM ACC_CARD_T@ACCU_LINK act ,count()" +
//
" LEFT JOIN ACC_GROUP_T@ACCU_LINK agt on substr(act.accept_no,0,8) = agt.group_no " +
//
" LEFT JOIN COUNTY_DIC coun on substr(act.upload_no,0,6) = coun.county_code " +
//
" WHERE agt.group_no not in (select GROUP_NO.group_no from GROUP_NO) " +
//
" and to_char(IMPORT_TIME,'yyyymmdd') = #{submitDate} " +
//
" GROUP by coun.COUNTYNAME,substr(act.upload_no,0,6)")
//
public List<CountCountyEntity> selectByCounty(@Param("submitDate") String submitDate);
/**
* 任务单查询
...
...
src/main/java/com/yxproject/start/service/DataAuditingService.java
0 → 100644
View file @
740f98f8
package
com
.
yxproject
.
start
.
service
;
import
com.yxproject.start.entity.DataAuditingEntity
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.List
;
import
java.util.Map
;
/**
* @auther zhangyusheng
* 2019/4/11 11:55
*/
public
interface
DataAuditingService
{
public
boolean
saveDataAuditingList
(
List
<
DataAuditingEntity
>
dataAuditingEntityList
);
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingList
(
String
groupNo
);
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingReport
(
String
startDate
,
String
endDate
);
}
src/main/java/com/yxproject/start/service/TaskListService.java
View file @
740f98f8
...
...
@@ -13,7 +13,7 @@ import java.util.Map;
public
interface
TaskListService
{
public
List
<
CountCountyEntity
>
selectByCounty
(
String
submitDate
);
//
public List<CountCountyEntity> selectByCounty(String submitDate);
public
List
<
CountGajgEntity
>
selectByGajg
(
String
submitDate
,
String
countyCode
);
...
...
src/main/java/com/yxproject/start/service/impl/DataAuditingServiceImpl.java
0 → 100644
View file @
740f98f8
package
com
.
yxproject
.
start
.
service
.
impl
;
import
com.yxproject.start.entity.DataAuditingEntity
;
import
com.yxproject.start.mapper.DataAuditingMapper
;
import
com.yxproject.start.service.DataAuditingService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
javax.transaction.Transactional
;
import
java.util.List
;
import
java.util.Map
;
/**
* @auther zhangyusheng
* 2019/4/11 11:56
*/
@Service
public
class
DataAuditingServiceImpl
implements
DataAuditingService
{
@Autowired
private
DataAuditingMapper
dataAuditingMapper
;
@Override
@Transactional
public
boolean
saveDataAuditingList
(
List
<
DataAuditingEntity
>
dataAuditingEntityList
)
{
for
(
DataAuditingEntity
dataAuditingEntity:
dataAuditingEntityList
){
dataAuditingMapper
.
saveDataAuditingEntity
(
dataAuditingEntity
);
}
return
true
;
}
@Override
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingList
(
String
groupNo
)
{
return
dataAuditingMapper
.
selectDataAuditingEntity
(
groupNo
);
}
@Override
public
List
<
Map
<
String
,
Object
>>
selectDataAuditingReport
(
String
startDate
,
String
endDate
)
{
return
dataAuditingMapper
.
selectDataAuditingReport
(
startDate
,
endDate
);
}
}
src/main/java/com/yxproject/start/service/impl/TaskListServiceImpl.java
View file @
740f98f8
...
...
@@ -26,11 +26,11 @@ public class TaskListServiceImpl implements TaskListService {
@Autowired
private
FailedCardService
failedCardService
;
@Override
public
List
<
CountCountyEntity
>
selectByCounty
(
String
submitDate
)
{
List
<
CountCountyEntity
>
resultList
=
taskListMapper
.
selectByCounty
(
submitDate
);
return
resultList
;
}
//
@Override
//
public List<CountCountyEntity> selectByCounty(String submitDate) {
//
List<CountCountyEntity> resultList = taskListMapper.selectByCounty(submitDate);
//
return resultList;
//
}
@Override
public
List
<
CountGajgEntity
>
selectByGajg
(
String
submitDate
,
String
countyCode
)
{
...
...
@@ -629,6 +629,7 @@ public class TaskListServiceImpl implements TaskListService {
groupNoEntity
.
setTaskId
(
taskEntity
.
getTaskId
());
groupNoMapper
.
saveGroupNo
(
groupNoEntity
);
}
return
true
;
}
...
...
src/main/resources/static/views/task/taskListSorting.html
View file @
740f98f8
...
...
@@ -91,6 +91,7 @@
<th>
电质检数量
</th>
<th>
特殊证件数量
</th>
<th>
废证数量
</th>
<th>
复核数量
</th>
<th></th>
</thead>
<tbody>
...
...
@@ -102,6 +103,7 @@
<td>
{{item.CHECK_COUNT}}
</td>
<td>
{{item.SPECIAL_CARD_COUNT}}
</td>
<td>
{{item.FAILECOUNT}}
</td>
<td>
{{item.FINISH_COUNT}}
</td>
<td>
<a
ng-click=
"getSpecialCardsInfo(item.GROUP_NO,item.SPECIAL_CARD_COUNT)"
>
特殊证件详情
</a>
</td>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment