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
95c4a993
Commit
95c4a993
authored
Mar 14, 2019
by
suichenguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
余证更改
parent
e72a307a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
50 additions
and
12 deletions
+50
-12
FailedCardApi.java
src/main/java/com/yxproject/start/api/FailedCardApi.java
+18
-10
ReadXmlApi.java
src/main/java/com/yxproject/start/api/ReadXmlApi.java
+1
-2
FailedCardMapper.java
...ain/java/com/yxproject/start/mapper/FailedCardMapper.java
+16
-0
FailedCardService.java
...n/java/com/yxproject/start/service/FailedCardService.java
+4
-0
FailedCardServiceImpl.java
...m/yxproject/start/service/impl/FailedCardServiceImpl.java
+11
-0
No files found.
src/main/java/com/yxproject/start/api/FailedCardApi.java
View file @
95c4a993
...
@@ -15,10 +15,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
...
@@ -15,10 +15,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.util.ArrayList
;
import
java.util.*
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* 添加废证
* 添加废证
...
@@ -72,12 +69,23 @@ public class FailedCardApi {
...
@@ -72,12 +69,23 @@ public class FailedCardApi {
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Boolean
insertFailedCard
(
@RequestBody
String
jsonStr
){
public
Boolean
insertFailedCard
(
@RequestBody
String
jsonStr
){
JSONArray
jsonarray
=
JSONArray
.
fromObject
(
jsonStr
);
JSONArray
jsonarray
=
JSONArray
.
fromObject
(
jsonStr
);
for
(
Object
o:
jsonarray
){
for
(
Object
o
:
jsonarray
)
{
JSONObject
jsonObject
=(
JSONObject
)
o
;
JSONObject
jsonObject
=
(
JSONObject
)
o
;
Map
<
String
,
Object
>
idMap
=
failedCardService
.
selectCountIdByCardId
(
jsonObject
.
getString
(
"cardId"
));
String
result
=
failedCardService
.
selectSpecialCard
(((
JSONObject
)
o
).
getString
(
"cardId"
));
int
initiator
=
Integer
.
parseInt
(
jsonObject
.
getString
(
"initiator"
))-
2
;
Map
<
String
,
Object
>
idMap
;
failedCardService
.
insertFailedCard
(
jsonObject
.
getString
(
"failedCardReasonId"
),
idMap
.
get
(
"ACCEPT_NO"
).
toString
(),
idMap
.
get
(
"TASK_ID"
).
toString
(),
String
.
valueOf
(
initiator
),
jsonObject
.
getString
(
"note"
));
//判断是否是特殊证件
}
if
(
result
!=
null
&&
result
!=
""
)
{
idMap
=
failedCardService
.
selectDataById
(
jsonObject
.
getString
(
"cardId"
));
}
else
{
idMap
=
failedCardService
.
selectCountIdByCardId
(
jsonObject
.
getString
(
"cardId"
));
}
int
initiator
=
Integer
.
parseInt
(
jsonObject
.
getString
(
"initiator"
))
-
2
;
failedCardService
.
insertFailedCard
(
jsonObject
.
getString
(
"failedCardReasonId"
),
idMap
.
get
(
"ACCEPT_NO"
).
toString
(),
idMap
.
get
(
"TASK_ID"
).
toString
(),
String
.
valueOf
(
initiator
),
jsonObject
.
getString
(
"note"
));
}
return
true
;
return
true
;
}
}
...
...
src/main/java/com/yxproject/start/api/ReadXmlApi.java
View file @
95c4a993
...
@@ -172,13 +172,12 @@ public class ReadXmlApi {
...
@@ -172,13 +172,12 @@ public class ReadXmlApi {
int
max
=
Integer
.
parseInt
(
currPage
)*
Integer
.
parseInt
(
pageSize
);
int
max
=
Integer
.
parseInt
(
currPage
)*
Integer
.
parseInt
(
pageSize
);
int
min
=
(
Integer
.
parseInt
(
currPage
)-
1
)*
Integer
.
parseInt
(
pageSize
);
int
min
=
(
Integer
.
parseInt
(
currPage
)-
1
)*
Integer
.
parseInt
(
pageSize
);
List
list
=
new
ArrayList
();
List
list
=
new
ArrayList
();
if
(
mapList
.
size
()<
max
){
if
(
mapList
.
size
()<
max
){
for
(
int
i
=
min
-
1
;
i
<
mapList
.
size
();
i
++){
for
(
int
i
=
min
-
1
;
i
<
mapList
.
size
();
i
++){
list
.
add
(
mapList
.
get
(
i
));
list
.
add
(
mapList
.
get
(
i
));
}
}
}
else
{
}
else
{
for
(
int
i
=
min
;
i
<
max
;
i
++){
for
(
int
i
=
min
;
i
<
max
-
1
;
i
++){
list
.
add
(
mapList
.
get
(
i
));
list
.
add
(
mapList
.
get
(
i
));
}
}
...
...
src/main/java/com/yxproject/start/mapper/FailedCardMapper.java
View file @
95c4a993
...
@@ -123,4 +123,20 @@ public interface FailedCardMapper {
...
@@ -123,4 +123,20 @@ public interface FailedCardMapper {
public
boolean
updateFailedState4
(
FailedCardEntity
failedCardEntity
);
public
boolean
updateFailedState4
(
FailedCardEntity
failedCardEntity
);
/**
* 根据身份证号查询是否是特证
*/
@Select
(
"select SPECIAL_CARD_ID from special_card \n"
+
"left join prod_card_t@PROD_LINK ON PROD_CARD_T.ACCEPT_NO = SPECIAL_CARD.ACCEPT_NO\n"
+
"WHERE PROD_CARD_T.ID_NO = #{id} or PROD_CARD_T.ACCEPT_NO=#{id}"
)
public
String
selectSpecialCard
(
String
id
);
/**
* 根据特证表添加废证
*/
@Select
(
"select ACCEPT_NO,TASK_ID FROM SPECIAL_CARD LEFT JOIN prod_card_t@PROD_LINK ON PROD_CARD_T.ACCEPT_NO = SPECIAL_CARD.ACCEPT_NO"
+
"WHERE PROD_CARD_T.ID_NO=#{id} or PROD_CARD_T.ACCEPT_NO=#{id}"
)
public
Map
<
String
,
Object
>
selectDataById
(
String
id
);
}
}
src/main/java/com/yxproject/start/service/FailedCardService.java
View file @
95c4a993
...
@@ -36,5 +36,9 @@ public interface FailedCardService {
...
@@ -36,5 +36,9 @@ public interface FailedCardService {
public
boolean
updateFailedCardState
(
FailedCardEntity
failedCardEntity
);
public
boolean
updateFailedCardState
(
FailedCardEntity
failedCardEntity
);
public
String
selectSpecialCard
(
String
id
);
public
Map
<
String
,
Object
>
selectDataById
(
String
id
);
}
}
src/main/java/com/yxproject/start/service/impl/FailedCardServiceImpl.java
View file @
95c4a993
...
@@ -117,6 +117,17 @@ public class FailedCardServiceImpl implements FailedCardService {
...
@@ -117,6 +117,17 @@ public class FailedCardServiceImpl implements FailedCardService {
return
false
;
return
false
;
}
}
@Override
public
String
selectSpecialCard
(
String
id
)
{
String
result
=
failedCardMapper
.
selectSpecialCard
(
id
);
return
result
;
}
@Override
public
Map
<
String
,
Object
>
selectDataById
(
String
id
)
{
Map
resultMap
=
failedCardMapper
.
selectDataById
(
id
);
return
resultMap
;
}
}
}
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