Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
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
fangxinjiang
yifu-mvp
Commits
a8751105
Commit
a8751105
authored
Nov 25, 2024
by
hongguangwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MVP1.7.2 工行5次提交_测试下载
parent
a2ba8684
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
186 additions
and
8 deletions
+186
-8
EkpBankPayTask.java
...ava/com/yifu/cloud/plus/v1/ekp/entity/EkpBankPayTask.java
+5
-0
EkpBankResultVo.java
...n/java/com/yifu/cloud/plus/v1/ekp/vo/EkpBankResultVo.java
+20
-0
IcbcTransactionFlowIssueController.java
...v1/ekp/controller/IcbcTransactionFlowIssueController.java
+9
-6
EkpBankPayTaskMapper.java
...m/yifu/cloud/plus/v1/ekp/mapper/EkpBankPayTaskMapper.java
+10
-0
EkpBankPayTaskService.java
...yifu/cloud/plus/v1/ekp/service/EkpBankPayTaskService.java
+19
-0
IcbcTransactionFlowIssueService.java
.../plus/v1/ekp/service/IcbcTransactionFlowIssueService.java
+8
-0
EkpBankPayTaskServiceImpl.java
...d/plus/v1/ekp/service/impl/EkpBankPayTaskServiceImpl.java
+24
-0
IcbcTransactionFlowIssueServiceImpl.java
...ekp/service/impl/IcbcTransactionFlowIssueServiceImpl.java
+65
-2
EkpBankPayTaskMapper.xml
...kp-biz/src/main/resources/mapper/EkpBankPayTaskMapper.xml
+15
-0
EkpTask.java
...main/java/com/yifu/cloud/plus/v1/job/compont/EkpTask.java
+11
-0
No files found.
yifu-ekp/yifu-ekp-api/src/main/java/com/yifu/cloud/plus/v1/ekp/entity/EkpBankPayTask.java
View file @
a8751105
...
@@ -19,6 +19,7 @@ package com.yifu.cloud.plus.v1.ekp.entity;
...
@@ -19,6 +19,7 @@ package com.yifu.cloud.plus.v1.ekp.entity;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
...
@@ -258,4 +259,8 @@ public class EkpBankPayTask {
...
@@ -258,4 +259,8 @@ public class EkpBankPayTask {
@Schema
(
description
=
"MD码"
)
@Schema
(
description
=
"MD码"
)
private
String
fdMdCode
;
private
String
fdMdCode
;
// 明细条数
@TableField
(
exist
=
false
)
private
String
num
;
}
}
yifu-ekp/yifu-ekp-api/src/main/java/com/yifu/cloud/plus/v1/ekp/vo/EkpBankResultVo.java
0 → 100644
View file @
a8751105
package
com
.
yifu
.
cloud
.
plus
.
v1
.
ekp
.
vo
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* @Author hgw
* @Date 2024-11-25 10:32:26
* @Description EKP银企付款获取待查询结果的VO
* @Version 1.0
*/
@Data
public
class
EkpBankResultVo
implements
Serializable
{
private
String
fdId
;
private
String
fdParentId
;
private
String
fdWxNo
;
private
String
num
;
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/controller/IcbcTransactionFlowIssueController.java
View file @
a8751105
package
com
.
yifu
.
cloud
.
plus
.
v1
.
ekp
.
controller
;
package
com
.
yifu
.
cloud
.
plus
.
v1
.
ekp
.
controller
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankAtta
;
import
com.yifu.cloud.plus.v1.ekp.service.IcbcTransactionFlowIssueService
;
import
com.yifu.cloud.plus.v1.ekp.service.IcbcTransactionFlowIssueService
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankAttaReturnVo
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankAttaReturnVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.common.security.annotation.Inner
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryAccountSearchVo
;
import
io.swagger.v3.oas.annotations.Operation
;
import
io.swagger.v3.oas.annotations.Operation
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletRequest
;
...
@@ -27,7 +23,7 @@ import javax.servlet.http.HttpServletResponse;
...
@@ -27,7 +23,7 @@ import javax.servlet.http.HttpServletResponse;
*/
*/
@RestController
@RestController
@RequiredArgsConstructor
@RequiredArgsConstructor
@RequestMapping
(
"/icbcIssue"
)
@RequestMapping
(
"/icbcIssue"
)
@Tag
(
name
=
"聚富通代发工资相关"
)
@Tag
(
name
=
"聚富通代发工资相关"
)
public
class
IcbcTransactionFlowIssueController
{
public
class
IcbcTransactionFlowIssueController
{
...
@@ -131,4 +127,11 @@ public class IcbcTransactionFlowIssueController {
...
@@ -131,4 +127,11 @@ public class IcbcTransactionFlowIssueController {
icbcTransactionFlowIssueService
.
exportAll
(
response
);
icbcTransactionFlowIssueService
.
exportAll
(
response
);
}
}
@Operation
(
summary
=
"每小时获取银企付款结果"
,
description
=
"每小时获取银企付款结果"
)
@Inner
@PostMapping
(
"/inner/doGetEkpBankStatus"
)
public
R
<
String
>
doGetEkpBankStatus
()
{
return
icbcTransactionFlowIssueService
.
doGetEkpBankStatus
();
}
}
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/mapper/EkpBankPayTaskMapper.java
View file @
a8751105
...
@@ -19,8 +19,11 @@ package com.yifu.cloud.plus.v1.ekp.mapper;
...
@@ -19,8 +19,11 @@ package com.yifu.cloud.plus.v1.ekp.mapper;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
java.util.List
;
/**
/**
* 银企付款任务主表信息
* 银企付款任务主表信息
*
*
...
@@ -29,4 +32,11 @@ import org.apache.ibatis.annotations.Mapper;
...
@@ -29,4 +32,11 @@ import org.apache.ibatis.annotations.Mapper;
*/
*/
@Mapper
@Mapper
public
interface
EkpBankPayTaskMapper
extends
BaseMapper
<
EkpBankPayTask
>
{
public
interface
EkpBankPayTaskMapper
extends
BaseMapper
<
EkpBankPayTask
>
{
// 获取发放中的主表,查询结果
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultMain
();
// 获取发放中的明细表,查询结果
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultDetail
();
}
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/EkpBankPayTaskService.java
View file @
a8751105
...
@@ -19,6 +19,9 @@ package com.yifu.cloud.plus.v1.ekp.service;
...
@@ -19,6 +19,9 @@ package com.yifu.cloud.plus.v1.ekp.service;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo
;
import
java.util.List
;
/**
/**
* 银企付款任务主表信息
* 银企付款任务主表信息
...
@@ -28,4 +31,20 @@ import com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask;
...
@@ -28,4 +31,20 @@ import com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask;
*/
*/
public
interface
EkpBankPayTaskService
extends
IService
<
EkpBankPayTask
>
{
public
interface
EkpBankPayTaskService
extends
IService
<
EkpBankPayTask
>
{
/**
* @Description: 获取发放中的主表,查询结果
* @Author: hgw
* @Date: 2024-11-25 10:25:58
* @return: com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
**/
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultMain
();
/**
* @Description: 获取发放中的明细表,查询结果
* @Author: hgw
* @Date: 2024/11/25 10:38
* @return: java.util.List<com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo>
**/
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultDetail
();
}
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/IcbcTransactionFlowIssueService.java
View file @
a8751105
...
@@ -66,4 +66,12 @@ public interface IcbcTransactionFlowIssueService extends IService<EkpSocialInfo>
...
@@ -66,4 +66,12 @@ public interface IcbcTransactionFlowIssueService extends IService<EkpSocialInfo>
void
exportAll
(
HttpServletResponse
response
);
void
exportAll
(
HttpServletResponse
response
);
/**
* @Description: 每小时获取银企付款结果
* @Author: hgw
* @Date: 2024/11/22 16:56
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
R
<
String
>
doGetEkpBankStatus
();
}
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/impl/EkpBankPayTaskServiceImpl.java
View file @
a8751105
...
@@ -20,9 +20,12 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
...
@@ -20,9 +20,12 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask
;
import
com.yifu.cloud.plus.v1.ekp.mapper.EkpBankPayTaskMapper
;
import
com.yifu.cloud.plus.v1.ekp.mapper.EkpBankPayTaskMapper
;
import
com.yifu.cloud.plus.v1.ekp.service.EkpBankPayTaskService
;
import
com.yifu.cloud.plus.v1.ekp.service.EkpBankPayTaskService
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
/**
* 银企付款任务主表信息
* 银企付款任务主表信息
*
*
...
@@ -33,4 +36,25 @@ import org.springframework.stereotype.Service;
...
@@ -33,4 +36,25 @@ import org.springframework.stereotype.Service;
@Service
@Service
public
class
EkpBankPayTaskServiceImpl
extends
ServiceImpl
<
EkpBankPayTaskMapper
,
EkpBankPayTask
>
implements
EkpBankPayTaskService
{
public
class
EkpBankPayTaskServiceImpl
extends
ServiceImpl
<
EkpBankPayTaskMapper
,
EkpBankPayTask
>
implements
EkpBankPayTaskService
{
/**
* @Description: 获取发放中的主表,查询结果
* @Author: hgw
* @Date: 2024/11/25 10:26
* @return: java.util.List<com.yifu.cloud.plus.v1.ekp.entity.EkpBankPayTask>
**/
@Override
public
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultMain
()
{
return
baseMapper
.
getEkpBankMainByNeedResultMain
();
}
/**
* @Description: 获取发放中的明细表,查询结果
* @Author: hgw
* @Date: 2024/11/25 10:39
* @return: java.util.List<com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo>
**/
@Override
public
List
<
EkpBankResultVo
>
getEkpBankMainByNeedResultDetail
()
{
return
baseMapper
.
getEkpBankMainByNeedResultDetail
();
}
}
}
yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/impl/IcbcTransactionFlowIssueServiceImpl.java
View file @
a8751105
...
@@ -21,6 +21,7 @@ import com.yifu.cloud.plus.v1.ekp.mapper.EkpSocialInfoMapper;
...
@@ -21,6 +21,7 @@ import com.yifu.cloud.plus.v1.ekp.mapper.EkpSocialInfoMapper;
import
com.yifu.cloud.plus.v1.ekp.service.*
;
import
com.yifu.cloud.plus.v1.ekp.service.*
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankAttaReturnVo
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankAttaReturnVo
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankExcelVo
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankExcelVo
;
import
com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
...
@@ -379,13 +380,20 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -379,13 +380,20 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
EkpBankAttaReturnVo
vo
=
new
EkpBankAttaReturnVo
();
EkpBankAttaReturnVo
vo
=
new
EkpBankAttaReturnVo
();
List
<
EkpBankExcelVo
>
list
;
List
<
EkpBankExcelVo
>
list
;
log
.
error
(
"fdId==="
+
fdId
);
log
.
error
(
"type==="
+
type
);
log
.
error
(
"CommonConstants.ONE_STRING.equals(type)==="
+
CommonConstants
.
ONE_STRING
.
equals
(
type
));
log
.
error
(
"CommonConstants.TWO_STRING.equals(type)==="
+
CommonConstants
.
TWO_STRING
.
equals
(
type
));
// 1主表整体下载
// 1主表整体下载
if
(
CommonConstants
.
ONE_STRING
.
equals
(
type
))
{
if
(
CommonConstants
.
ONE_STRING
.
equals
(
type
))
{
log
.
error
(
"111111"
);
EkpBankPayTask
main
=
ekpBankPayTaskService
.
getById
(
fdId
);
EkpBankPayTask
main
=
ekpBankPayTaskService
.
getById
(
fdId
);
if
(
main
==
null
)
{
if
(
main
==
null
)
{
return
R
.
failed
(
"未找到表数据!"
);
return
R
.
failed
(
"未找到表数据!"
);
}
else
if
(
Common
.
isNotNull
(
main
.
getFdDownloadNum
())
&&
Common
.
isNotNull
(
main
.
getFdFailNum
())
}
else
if
(
Common
.
isNotNull
(
main
.
getFdDownloadNum
())
&&
Common
.
isNotNull
(
main
.
getFdFailNum
())
&&
(
CommonConstants
.
ZERO_INT
==
main
.
getFdDownloadNum
()
||
main
.
getFdDownloadNum
().
equals
(
main
.
getFdFailNum
())))
{
&&
(
CommonConstants
.
ZERO_INT
==
main
.
getFdDownloadNum
()
||
main
.
getFdDownloadNum
().
equals
(
main
.
getFdFailNum
())))
{
log
.
error
(
"111112"
);
// 新下载
// 新下载
list
=
ekpBankGrantDetailService
.
getEkpBankExcelVoByIdAndMain
(
fdId
);
list
=
ekpBankGrantDetailService
.
getEkpBankExcelVoByIdAndMain
(
fdId
);
return
getNewFileByMain
(
fdId
,
type
,
vo
,
list
,
main
);
return
getNewFileByMain
(
fdId
,
type
,
vo
,
list
,
main
);
...
@@ -393,7 +401,10 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -393,7 +401,10 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
// 取URL数据返回
// 取URL数据返回
return
getOldAttaUrl
(
vo
,
main
.
getFdAttaSrc
(),
main
.
getFdAttaName
());
return
getOldAttaUrl
(
vo
,
main
.
getFdAttaSrc
(),
main
.
getFdAttaName
());
}
}
log
.
error
(
"main.getFdDownloadNum()="
+
main
.
getFdDownloadNum
());
log
.
error
(
"main.getFdFailNum()="
+
main
.
getFdFailNum
());
}
else
if
(
CommonConstants
.
TWO_STRING
.
equals
(
type
))
{
}
else
if
(
CommonConstants
.
TWO_STRING
.
equals
(
type
))
{
log
.
error
(
"222222"
);
// 2明细表
// 2明细表
EkpBankGrantDetail
detail
=
ekpBankGrantDetailService
.
getById
(
fdId
);
EkpBankGrantDetail
detail
=
ekpBankGrantDetailService
.
getById
(
fdId
);
if
(
detail
==
null
)
{
if
(
detail
==
null
)
{
...
@@ -407,6 +418,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -407,6 +418,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
// 取URL数据返回
// 取URL数据返回
return
getOldAttaUrl
(
vo
,
detail
.
getFdAttaSrc
(),
detail
.
getFdAttaName
());
return
getOldAttaUrl
(
vo
,
detail
.
getFdAttaSrc
(),
detail
.
getFdAttaName
());
}
}
log
.
error
(
"main.getFdDownloadNum()="
+
detail
.
getFdDownloadNum
());
log
.
error
(
"main.getFdFailNum()="
+
detail
.
getFdFailNum
());
}
}
return
R
.
failed
(
"请处理表数据的下载次数与失败次数,fdId="
+
fdId
+
";type="
+
type
);
return
R
.
failed
(
"请处理表数据的下载次数与失败次数,fdId="
+
fdId
+
";type="
+
type
);
}
else
{
}
else
{
...
@@ -528,7 +541,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -528,7 +541,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
InputStream
templateIs
=
this
.
getClass
().
getResourceAsStream
(
"/template/ekpBankTemplat.xls"
);
InputStream
templateIs
=
this
.
getClass
().
getResourceAsStream
(
"/template/ekpBankTemplat.xls"
);
String
filePath
=
"ekpBankDownFile"
;
String
filePath
=
"ekpBankDownFile"
;
String
fileName
=
"020101190
_"
+
batchNo
+
"_0_"
+
DateUtil
.
getThisDay
()
+
CommonConstants
.
XLS
;
String
fileName
=
icbcConfigProperties
.
getCompanyNo
()
+
"
_"
+
batchNo
+
"_0_"
+
DateUtil
.
getThisDay
()
+
CommonConstants
.
XLS
;
String
key
=
filePath
+
"/"
+
fileName
;
String
key
=
filePath
+
"/"
+
fileName
;
EasyExcelFactory
.
write
(
filePath
).
withTemplate
(
templateIs
).
excelType
(
ExcelTypeEnum
.
XLS
)
EasyExcelFactory
.
write
(
filePath
).
withTemplate
(
templateIs
).
excelType
(
ExcelTypeEnum
.
XLS
)
...
@@ -594,7 +607,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -594,7 +607,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
response
.
setCharacterEncoding
(
"utf-8"
);
response
.
setCharacterEncoding
(
"utf-8"
);
String
batchNo
=
"WX203"
;
String
batchNo
=
"WX203"
;
String
fileName
=
"020101190_"
+
batchNo
+
"_0_"
+
DateUtil
.
getThisDay
()
+
CommonConstants
.
XLS
;
String
fileName
=
icbcConfigProperties
.
getCompanyNo
()
+
"_"
+
batchNo
+
"_0_"
+
DateUtil
.
getThisDay
()
+
CommonConstants
.
XLS
;
response
.
setHeader
(
CommonConstants
.
CONTENT_DISPOSITION
,
CommonConstants
.
ATTACHMENT_FILENAME
+
URLEncoder
.
encode
(
fileName
,
"UTF-8"
));
response
.
setHeader
(
CommonConstants
.
CONTENT_DISPOSITION
,
CommonConstants
.
ATTACHMENT_FILENAME
+
URLEncoder
.
encode
(
fileName
,
"UTF-8"
));
templateIs
=
this
.
getClass
().
getResourceAsStream
(
"/template/ekpBankTemplat.xls"
);
templateIs
=
this
.
getClass
().
getResourceAsStream
(
"/template/ekpBankTemplat.xls"
);
...
@@ -708,4 +721,54 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
...
@@ -708,4 +721,54 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
}
}
}
}
/**
* @Description: 每小时获取银企付款结果
* @Author: hgw
* @Date: 2024/11/22 17:00
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
@Override
public
R
<
String
>
doGetEkpBankStatus
()
{
// 1:获取发放中的主表数据,查询工行接口
List
<
EkpBankResultVo
>
mainList
=
ekpBankPayTaskService
.
getEkpBankMainByNeedResultMain
();
// 2:获取主表已发放且明细表发放中的明细表数据,查询工行接口
List
<
EkpBankResultVo
>
detailList
=
ekpBankPayTaskService
.
getEkpBankMainByNeedResultDetail
();
DefaultIcbcClient
client
=
new
DefaultIcbcClient
(
icbcConfigProperties
.
getAppId
(),
IcbcConstants
.
SIGN_TYPE_RSA2
,
icbcConfigProperties
.
getAppPrivateKey
(),
IcbcConstants
.
CHARSET_UTF8
,
IcbcConstants
.
FORMAT_JSON
,
icbcConfigProperties
.
getApigwPublicKey
(),
IcbcConstants
.
ENCRYPT_TYPE_AES
,
icbcConfigProperties
.
getAesKey
()
,
null
,
null
);
JftApiPayrollQueryDetailRequestV1
request
=
new
JftApiPayrollQueryDetailRequestV1
();
request
.
setServiceUrl
(
"https://gw.open.icbc.com.cn/api/jft/api/payroll/querydetail/V1"
);
JftApiPayrollQueryDetailRequestV1
.
JftApiPayrollQueryDetailRequestV1Biz
bizContent
=
new
JftApiPayrollQueryDetailRequestV1
.
JftApiPayrollQueryDetailRequestV1Biz
();
bizContent
.
setAppId
(
icbcConfigProperties
.
getAppId
());
//企业编号
bizContent
.
setOutVendorId
(
icbcConfigProperties
.
getCompanyNo
());
//查询类型:1 批次 2 批次明细
bizContent
.
setType
(
"2"
);
//批次号,appSerialno为空时,必输
bizContent
.
setAppBatserialno
(
"WX203"
);
//内部批次号,组成规则:批次号-顺序号,appBatserialno为空时必输
// bizContent.setAppSerialno("WX04-1");
//开始条数,如果送1,则返回排序的第一条开始,appBatserialno不为空时必输
bizContent
.
setStartId
(
"0"
);
//结束条数,每次最多返回50条,返回条数按照结束-开始+1,appBatserialno不为空时必输
bizContent
.
setEndId
(
"10"
);
request
.
setBizContent
(
bizContent
);
try
{
JftApiPayrollQueryDetailResponseV1
responseV1
=
client
.
execute
(
request
);
if
(
Common
.
isNotNull
(
responseV1
))
{
return
R
.
ok
();
}
}
catch
(
IcbcApiException
e
)
{
e
.
printStackTrace
();
return
R
.
failed
();
}
return
R
.
ok
();
}
}
}
yifu-ekp/yifu-ekp-biz/src/main/resources/mapper/EkpBankPayTaskMapper.xml
View file @
a8751105
...
@@ -85,4 +85,19 @@
...
@@ -85,4 +85,19 @@
a.fd_md_dcode
a.fd_md_dcode
</sql>
</sql>
<!-- 获取发放中的主表,查询结果 -->
<select
id=
"getEkpBankMainByNeedResultMain"
resultType=
"com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo"
>
select a.fd_id fdId,a.fd_wx_no fdWxNo,count(d.fd_id) num
from ekp_bank_pay_task a left join ekp_bank_grant_detail d on a.fd_id = d.fd_parent_id
where a.fd_grant_status = '发放中'
GROUP BY a.fd_id
</select>
<!-- 获取发放中的明细表,查询结果 -->
<select
id=
"getEkpBankMainByNeedResultDetail"
resultType=
"com.yifu.cloud.plus.v1.ekp.vo.EkpBankResultVo"
>
select d.fd_id fdId,d.fd_wx_no fdWxNo,d.fd_parent_id fdParentId,'1' num
from ekp_bank_grant_detail d left join ekp_bank_pay_task a on a.fd_id = d.fd_parent_id
where a.fd_grant_status = '已发放' and d.fd_grant_status = '发放失败' and d.fd_handle_status = '发放中'
</select>
</mapper>
</mapper>
yifu-job/yifu-job-api/src/main/java/com/yifu/cloud/plus/v1/job/compont/EkpTask.java
View file @
a8751105
...
@@ -49,5 +49,16 @@ public class EkpTask {
...
@@ -49,5 +49,16 @@ public class EkpTask {
log
.
info
(
"------------定时生成昨日未生成的入账明细数据-定时任务结束------------"
);
log
.
info
(
"------------定时生成昨日未生成的入账明细数据-定时任务结束------------"
);
}
}
/**
* @Author hgw
* @Description 每小时获取银企付款结果
* @Date 2024-11-22 16:52:28
**/
public
void
doGetEkpBankStatus
()
{
log
.
info
(
"------------每小时获取银企付款结果-定时任务开始------------"
);
HttpDaprUtil
.
invokeMethodPost
(
daprEkpProperties
.
getAppUrl
(),
daprEkpProperties
.
getAppId
(),
"/icbcIssue/inner/doGetEkpBankStatus"
,
""
,
Object
.
class
,
SecurityConstants
.
FROM_IN
);
log
.
info
(
"------------每小时获取银企付款结果-定时任务结束------------"
);
}
}
}
\ 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