Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-zx-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
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
Jobs
Commits
Open sidebar
项目统一框架
一体化_户用光伏项目代码
amos-boot-zx-biz
Commits
7c4124fc
Commit
7c4124fc
authored
Dec 04, 2024
by
wujiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加icbc修复接口
parent
42a37921
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
54 additions
and
10 deletions
+54
-10
HygfIcbcController.java
...s/boot/module/hygf/biz/controller/HygfIcbcController.java
+7
-1
HygfIcbcServiceImpl.java
...oot/module/hygf/biz/service/impl/HygfIcbcServiceImpl.java
+47
-9
No files found.
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/HygfIcbcController.java
View file @
7c4124fc
...
...
@@ -112,8 +112,14 @@ public class HygfIcbcController extends BaseController {
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"聚富通电子钱包分页查询"
,
notes
=
"聚富通电子钱包分页查询"
)
@UserLimits
public
ResponseModel
<
Page
<
HygfIcbcRecordDTO
>>
queryForPage
(
@ApiParam
HygfIcbcRecordQueryDTO
hygfIcbcRecordQueryDTO
)
{
return
ResponseHelper
.
buildResponse
(
hygfIcbcService
.
queryForPage
(
hygfIcbcRecordQueryDTO
.
getCurrent
(),
hygfIcbcRecordQueryDTO
.
getSize
(),
hygfIcbcRecordQueryDTO
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/repair"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"修复入库失败的数据"
,
notes
=
"修复入库失败的数据"
)
public
ResponseModel
<
Object
>
repair
(
@RequestParam
(
"userId"
)
String
userId
)
{
return
ResponseHelper
.
buildResponse
(
hygfIcbcService
.
repair
(
userId
));
}
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/HygfIcbcServiceImpl.java
View file @
7c4124fc
...
...
@@ -69,8 +69,6 @@ import lombok.extern.slf4j.Slf4j;
@Slf4j
public
class
HygfIcbcServiceImpl
extends
BaseService
<
HygfIcbcRecordDTO
,
HygfIcbcRecord
,
HygfIcbcRecordMapper
>
implements
IHygfIcbcService
{
private
static
final
String
trxChannel
=
"05"
;
// 05表示小程序
...
...
@@ -254,8 +252,7 @@ public class HygfIcbcServiceImpl extends BaseService<HygfIcbcRecordDTO, HygfIcbc
* @param request request
* @param response response
* @return {@link Object}
* @throws
* @author yangyang
* @throws @author yangyang
* @date 2024/7/18 20:15
*/
public
Object
registerWalletCallback
(
HttpServletRequest
request
,
HttpServletResponse
response
)
throws
Exception
{
...
...
@@ -302,7 +299,7 @@ public class HygfIcbcServiceImpl extends BaseService<HygfIcbcRecordDTO, HygfIcbc
Map
<
String
,
String
>
data
=
JSONObject
.
parseObject
(
decode
,
Map
.
class
);
log
.
debug
(
"解密后参数:{}"
,
data
);
// 进行自己的处理,此处默认处理成功,返回通知方成功,return_code=0
// 其中certNo、custName、newPayAcc字段进行了base64编码,可以调用示例代码中的base64Decode进行解码
//String custName = base64Decode(data.get("custName"));
//
String custName = base64Decode(data.get("custName"));
String
certNo
=
base64Decode
(
data
.
get
(
"certNo"
));
String
newPayAcc
=
base64Decode
(
data
.
get
(
"newPayAcc"
));
String
outUserId
=
data
.
get
(
"outUserId"
);
...
...
@@ -329,7 +326,7 @@ public class HygfIcbcServiceImpl extends BaseService<HygfIcbcRecordDTO, HygfIcbc
hygfIcbcRequest
.
setPhase
(
"组装"
);
hygfIcbcRequest
.
setException
(
data
.
get
(
"custName"
)
+
" -> "
+
peasantHousehold
.
getOwnersName
());
hygfIcbcRequestMapper
.
updateById
(
hygfIcbcRequest
);
if
(
hygfIcbcWalletInfo
!=
null
)
{
hygfIcbcRecord
.
setCustName
(
hygfIcbcWalletInfo
.
getCustName
());
hygfIcbcRecord
.
setIdCard
(
hygfIcbcWalletInfo
.
getCertNo
());
...
...
@@ -427,11 +424,12 @@ public class HygfIcbcServiceImpl extends BaseService<HygfIcbcRecordDTO, HygfIcbc
.
collect
(
Collectors
.
groupingBy
(
PeasantHousehold:
:
getAmosUserId
));
// 根据农户 ID 分组
List
<
PeasantHousehold
>
peasantHouseholdList
=
peasantHouseholdMap
.
get
(
amosUserId
);
if
(
peasantHouseholdList
!=
null
&&
peasantHouseholdList
.
size
()
>
0
)
{
if
(
peasantHouseholdList
!=
null
&&
peasantHouseholdList
.
size
()
>
0
)
{
peasantHouseholdList
.
forEach
(
e
->
{
if
(
e
.
getSurveyInformationId
()
!=
null
)
{
if
(
e
.
getSurveyInformationId
()
!=
null
)
{
e
.
setScale
(
householdContractMapper
.
getHygfCommercialScale
(
e
.
getPeasantHouseholdNo
()));
e
.
setRealScale
(
powerStationEngineeringInfoMapper
.
getRealScaleByPeasantHouseholdNo
(
e
.
getPeasantHouseholdNo
()));
e
.
setRealScale
(
powerStationEngineeringInfoMapper
.
getRealScaleByPeasantHouseholdNo
(
e
.
getPeasantHouseholdNo
()));
}
});
}
...
...
@@ -601,4 +599,43 @@ public class HygfIcbcServiceImpl extends BaseService<HygfIcbcRecordDTO, HygfIcbc
Map
<
Object
,
Boolean
>
distinctMap
=
new
ConcurrentHashMap
<>();
return
object
->
distinctMap
.
putIfAbsent
(
distinctField
.
apply
(
object
),
Boolean
.
TRUE
)
==
null
;
}
public
String
repair
(
String
userId
)
{
JftApiUserEntrustopenacctQueryResponseV1
hygfIcbcWalletInfo
=
getHygfIcbcWalletInfo
(
userId
);
PeasantHousehold
peasantHousehold
=
peasantHouseholdService
.
lambdaQuery
().
select
(
PeasantHousehold:
:
getTelephone
)
.
eq
(
PeasantHousehold:
:
getAmosUserId
,
userId
).
last
(
"limit 1"
).
one
();
HygfIcbcRecord
hygfIcbcRecord
=
this
.
lambdaQuery
().
eq
(
HygfIcbcRecord:
:
getAmosUserId
,
userId
).
last
(
" limit 1"
)
.
one
();
if
(
hygfIcbcRecord
==
null
)
{
hygfIcbcRecord
=
new
HygfIcbcRecord
();
}
if
(
hygfIcbcWalletInfo
!=
null
)
{
hygfIcbcRecord
.
setPhone
(
peasantHousehold
!=
null
?
peasantHousehold
.
getTelephone
()
:
""
);
hygfIcbcRecord
.
setMediumId
(
hygfIcbcWalletInfo
.
getMediumId
());
hygfIcbcRecord
.
setProjectId
(
"PJ140014023565102203"
);
hygfIcbcRecord
.
setOpenAccountStatus
(
hygfIcbcWalletInfo
.
getOpenacctStatus
());
hygfIcbcRecord
.
setSignEntrsutPrtlStatus
(
"1"
);
hygfIcbcRecord
.
setCustName
(
hygfIcbcWalletInfo
.
getCustName
());
hygfIcbcRecord
.
setIdCard
(
hygfIcbcWalletInfo
.
getCertNo
());
hygfIcbcRecord
.
setProtocolStatus
(
hygfIcbcWalletInfo
.
getProtocolStatus
());
hygfIcbcRecord
.
setProtocolStartTime
(
hygfIcbcWalletInfo
.
getProtocolStartDate
());
hygfIcbcRecord
.
setProtocolEndTime
(
hygfIcbcWalletInfo
.
getProtocolEndDate
());
hygfIcbcRecord
.
setTrxLimitAmount
(
hygfIcbcWalletInfo
.
getTrxLimitAmount
());
hygfIcbcRecord
.
setDayLimitAmount
(
hygfIcbcWalletInfo
.
getDayLimitAmount
());
hygfIcbcRecord
.
setProtocolLimitAmount
(
hygfIcbcWalletInfo
.
getProtocolLimitAmount
());
hygfIcbcRecord
.
setAppId
(
hygfIcbcWalletInfo
.
getAppId
());
hygfIcbcRecord
.
setOutUserId
(
hygfIcbcWalletInfo
.
getOutUserId
());
hygfIcbcRecord
.
setOutVendorId
(
hygfIcbcWalletInfo
.
getOutVendorId
());
}
else
{
return
"开卡信息不存在"
;
}
// hygfIcbcRecord.setDiscardStatus();
hygfIcbcRecord
.
setAmosUserId
(
userId
);
hygfIcbcRecord
.
setRecDate
(
new
Date
());
this
.
saveOrUpdate
(
hygfIcbcRecord
);
return
"success"
;
}
}
\ No newline at end of file
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