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
3b66b4d8
Commit
3b66b4d8
authored
Oct 12, 2022
by
fangxinjiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
目录优化
parent
d3e22082
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
14 additions
and
944 deletions
+14
-944
EkpFundProperties.java
...yifu.cloud.plus.v1/yifu/ekp/config/EkpFundProperties.java
+0
-32
EkpIncomeProperties.java
...fu.cloud.plus.v1/yifu/ekp/config/EkpIncomeProperties.java
+0
-37
EkpInsuranceProperties.java
...cloud.plus.v1/yifu/ekp/config/EkpInsuranceProperties.java
+0
-30
EkpOrderProperties.java
...ifu.cloud.plus.v1/yifu/ekp/config/EkpOrderProperties.java
+0
-62
EkpSalaryProperties.java
...fu.cloud.plus.v1/yifu/ekp/config/EkpSalaryProperties.java
+0
-33
EkpSocialProperties.java
...fu.cloud.plus.v1/yifu/ekp/config/EkpSocialProperties.java
+0
-32
EkpFundUtil.java
...ava/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpFundUtil.java
+0
-72
EkpIncomeUtil.java
...a/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpIncomeUtil.java
+0
-112
EkpInsuranceUtil.java
...om/yifu.cloud.plus.v1/yifu/ekp/util/EkpInsuranceUtil.java
+0
-239
EkpOrderUtil.java
...va/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpOrderUtil.java
+0
-144
EkpSalaryUtil.java
...a/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpSalaryUtil.java
+0
-71
EkpSocialUtil.java
...a/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpSocialUtil.java
+0
-72
ekpFundConfig.properties
...fu-common-ekp/src/main/resources/ekpFundConfig.properties
+2
-1
ekpIncomeConfig.properties
...-common-ekp/src/main/resources/ekpIncomeConfig.properties
+2
-1
ekpInsuranceConfig.properties
...mmon-ekp/src/main/resources/ekpInsuranceConfig.properties
+2
-1
ekpOrderConfig.properties
...u-common-ekp/src/main/resources/ekpOrderConfig.properties
+4
-3
ekpSalaryConfig.properties
...-common-ekp/src/main/resources/ekpSalaryConfig.properties
+2
-1
ekpSocialConfig.properties
...-common-ekp/src/main/resources/ekpSocialConfig.properties
+2
-1
No files found.
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpFundProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @Author huyc
* @Description 公积金明细对接
* @Date 11:57 2022/8/29
* @Param
* @return
**/
@Data
@Component
@PropertySource
(
"classpath:ekpFundConfig.properties"
)
@ConfigurationProperties
(
value
=
"ekpfund"
,
ignoreInvalidFields
=
false
)
public
class
EkpFundProperties
{
String
url
;
String
fdModelId
;
String
fdFlowId
;
String
docStatus
;
String
LoginName
;
String
docSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpIncomeProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @Author fxj
* @Description 薪资明细对接
* @Date 11:57 2022/8/22
* @Param
* @return
**/
@Data
@Component
@PropertySource
(
"classpath:ekpIncomeConfig.properties"
)
@ConfigurationProperties
(
value
=
"income"
,
ignoreInvalidFields
=
false
)
public
class
EkpIncomeProperties
{
String
url
;
String
fdModelIdManage
;
String
fdFlowIdManage
;
String
fdModelIdRisk
;
String
fdFlowIdRisk
;
String
docStatus
;
String
loginName
;
String
docSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpInsuranceProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @author zhaji
* @description TODO
* @date 2022-08-31 08:57:02
*/
@Data
@Component
@PropertySource
(
"classpath:ekpInsuranceConfig.properties"
)
@ConfigurationProperties
(
value
=
"insurance"
,
ignoreInvalidFields
=
false
)
public
class
EkpInsuranceProperties
{
String
insuranceUrl
;
String
insuranceFdModelId
;
String
insuranceFdFlowId
;
String
insuranceDocStatus
;
String
insuranceLoginName
;
String
insuranceFocSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpOrderProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @author licancan
* @description 对接ekp订单
* @date 2022-08-31 15:35:20
*/
@Data
@Component
@PropertySource
(
"classpath:ekpOrderConfig.properties"
)
@ConfigurationProperties
(
value
=
"ekporder"
,
ignoreInvalidFields
=
false
)
public
class
EkpOrderProperties
{
/**
* 接口url
*/
String
url
;
/**
* 订单modelId
*/
String
orderFdModelId
;
/**
* 订单flowID
*/
String
orderFdFlowId
;
/**
* 订单回复modelId
*/
String
replyFdModelId
;
/**
* 订单回复flowID
*/
String
replyFdFlowId
;
/**
* 订单附件key
*/
String
replyAttachKey
;
String
docStatus
;
String
LoginName
;
/**
* 描述:用于项目订单更新接口
*/
String
orderDocSubject
;
/**
* 描述:用于订单回复接口
*/
String
replyDocSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpSalaryProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @Author fxj
* @Description 薪资明细对接
* @Date 11:57 2022/8/22
* @Param
* @return
**/
@Data
@Component
@PropertySource
(
"classpath:ekpSalaryConfig.properties"
)
@ConfigurationProperties
(
value
=
"ekp"
,
ignoreInvalidFields
=
false
)
public
class
EkpSalaryProperties
{
String
url
;
String
fdModelId
;
String
fdFlowId
;
String
docStatus
;
String
LoginName
;
String
docSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpSocialProperties.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.PropertySource
;
import
org.springframework.stereotype.Component
;
/**
* @Author huyc
* @Description 社保明细对接
* @Date 11:57 2022/8/29
* @Param
* @return
**/
@Data
@Component
@PropertySource
(
"classpath:ekpSocialConfig.properties"
)
@ConfigurationProperties
(
value
=
"ekpsocial"
,
ignoreInvalidFields
=
false
)
public
class
EkpSocialProperties
{
String
url
;
String
fdModelId
;
String
fdFlowId
;
String
docStatus
;
String
LoginName
;
String
docSubject
;
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpFundUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
cn.hutool.json.JSONObject
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpFundProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpPushFundParam
;
import
io.micrometer.core.instrument.util.StringUtils
;
import
lombok.extern.log4j.Log4j2
;
import
org.codehaus.jackson.map.ObjectMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
/**
* @Author huyc
* @Date 2022/8/29
* @Description
* @Version 1.0
*/
@Log4j2
@EnableConfigurationProperties
(
EkpFundProperties
.
class
)
public
class
EkpFundUtil
{
@Autowired
private
EkpFundProperties
ekpProperties
;
public
String
sendToEKP
(
EkpPushFundParam
param
){
log
.
info
(
"推送EKP开始--公积金明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
JSONObject
loginName
=
new
JSONObject
();
loginName
.
append
(
"LoginName"
,
ekpProperties
.
getLoginName
());
String
loginData
=
new
ObjectMapper
().
writeValueAsString
(
loginName
);
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
//wholeForm.add("docSubject", new String(docSubject.getBytes("UTF-8"),"ISO-8859-1") );
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
//wholeForm.add("docCreator", loginData);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowId
());
//wholeForm.add("formValues", new String(formValues.getBytes("UTF-8"),"ISO-8859-1"));
wholeForm
.
add
(
"formValues"
,
formValues
);
//wholeForm.add("formValues", new String("{\"fd_3adfe6af71a1cc\":\"王五\", \"fd_3adfe658c6229e\":\"2019-03-26\", \"fd_3adfe6592b4158\":\"这里内容\"}".getBytes("UTF-8"),"ISO-8859-1") );
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<
MultiValueMap
<
String
,
Object
>>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
null
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
info
(
e
.
getMessage
());
return
null
;
}
}
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpIncomeUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
cn.hutool.json.JSONObject
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpIncomeProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpIncomeParamManage
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpIncomeParamRisk
;
import
io.micrometer.core.instrument.util.StringUtils
;
import
lombok.extern.log4j.Log4j2
;
import
org.codehaus.jackson.map.ObjectMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
/**
* @Author hgw
* @Date 2022-8-31 12:00:07
* @Description
* @Version 1.0
*/
@Log4j2
@EnableConfigurationProperties
(
EkpIncomeProperties
.
class
)
public
class
EkpIncomeUtil
{
@Autowired
private
EkpIncomeProperties
ekpProperties
;
/**
* @param param 内容传参
* @Description:
* @Author: hgw
* @Date: 2022/9/5 16:12
* @return: java.lang.String
**/
public
String
sendToEkpManage
(
EkpIncomeParamManage
param
)
{
log
.
info
(
"推送EKP开始--收入明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
JSONObject
loginName
=
new
JSONObject
();
loginName
.
append
(
"LoginName"
,
ekpProperties
.
getLoginName
());
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelIdManage
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowIdManage
());
wholeForm
.
add
(
"formValues"
,
formValues
);
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword") 是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
))
{
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
EkpConstants
.
SEND_FAILED
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
)
{
log
.
info
(
e
.
getMessage
());
return
e
.
getMessage
();
}
}
public
String
sendToEkpRisk
(
EkpIncomeParamRisk
param
)
{
log
.
info
(
"推送EKP开始--收入明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
JSONObject
loginName
=
new
JSONObject
();
loginName
.
append
(
"LoginName"
,
ekpProperties
.
getLoginName
());
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelIdRisk
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowIdRisk
());
wholeForm
.
add
(
"formValues"
,
formValues
);
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword") 是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
))
{
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
EkpConstants
.
SEND_FAILED
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
)
{
log
.
info
(
e
.
getMessage
());
return
e
.
getMessage
();
}
}
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpInsuranceUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpInsuranceProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EKPInsurancePushParam
;
import
com.yifu.cloud.plus.v1.yifu.insurances.vo.EkpInteractiveParam
;
import
com.yifu.cloud.plus.v1.yifu.insurances.vo.TInsuranceSettlePushParam
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang.StringUtils
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
import
javax.annotation.Resource
;
import
java.time.LocalDate
;
import
java.time.format.DateTimeFormatter
;
/**
* @author zhaji
* @description EKP交互工具类
*
* @date 2022-08-05 09:42:33
*/
@Slf4j
@EnableConfigurationProperties
(
EkpInsuranceProperties
.
class
)
public
class
EkpInsuranceUtil
{
@Resource
private
EkpInsuranceProperties
ekpInsuranceProperties
;
/**
* 多层级的VO对象,且包含上传功能的样例
* 注意key的书写格式,类似EL表达式的方式,属性关系用'.', 列表和数组关系用[],Map关系用["xxx"]
*/
public
String
sendToEkp
(
EkpInteractiveParam
param
){
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
EKPInsurancePushParam
pushParam
=
insuranceDetail2PushParam
(
param
);
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
pushParam
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
wholeForm
.
add
(
"docSubject"
,
ekpInsuranceProperties
.
getInsuranceFocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpInsuranceProperties
.
getInsuranceDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpInsuranceProperties
.
getInsuranceFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpInsuranceProperties
.
getInsuranceFdFlowId
());
wholeForm
.
add
(
"formValues"
,
formValues
);
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<
MultiValueMap
<
String
,
Object
>>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
log
.
info
(
"推送EKP开始,formValues:"
+
formValues
);
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpInsuranceProperties
.
getInsuranceUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
"交易失败:"
+
obj
);
return
null
;
}
else
{
log
.
info
(
"交易成功:"
+
obj
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
error
(
"交易失败:"
,
e
);
return
null
;
}
}
/**
* 将类转换成EKP要求的格式
*
* @author zhaji
* @param param 转换类
* @return {@link TInsuranceSettlePushParam}
*/
public
static
EKPInsurancePushParam
insuranceDetail2PushParam
(
EkpInteractiveParam
param
){
String
format
=
LocalDate
.
now
().
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
EKPInsurancePushParam
pushParam
=
new
EKPInsurancePushParam
();
param
.
setHappenDate
(
format
);
//ekpId
if
(
null
!=
param
.
getDetailId
()
&&
null
!=
param
.
getDefaultSettleId
()){
pushParam
.
setFd_3afa8a70006bea
(
param
.
getDetailId
()+
CommonConstants
.
DOWN_LINE_STRING
+
param
.
getDefaultSettleId
());
}
else
{
pushParam
.
setFd_3afa8a70006bea
(
CommonConstants
.
EMPTY_STRING
);
}
//单据类型
if
(
null
!=
param
.
getSettleType
()){
pushParam
.
setFd_3adfe6af71a1cc
(
param
.
getSettleType
());
}
else
{
pushParam
.
setFd_3adfe6af71a1cc
(
CommonConstants
.
EMPTY_STRING
);
}
//项目编码
pushParam
.
setFd_3adfe658c6229e
(
param
.
getDeptNo
());
if
(
null
!=
param
.
getDeptNo
()){
pushParam
.
setFd_3adfe658c6229e
(
param
.
getDeptNo
());
}
else
{
pushParam
.
setFd_3adfe658c6229e
(
CommonConstants
.
EMPTY_STRING
);
}
//项目名称
pushParam
.
setFd_3adfe6592b4158
(
param
.
getDeptName
());
if
(
null
!=
param
.
getDeptName
()){
pushParam
.
setFd_3adfe6592b4158
(
param
.
getDeptName
());
}
else
{
pushParam
.
setFd_3adfe6592b4158
(
CommonConstants
.
EMPTY_STRING
);
}
//客户编码
pushParam
.
setFd_3adfe6598281e8
(
param
.
getCustomerCode
());
if
(
null
!=
param
.
getCustomerCode
()){
pushParam
.
setFd_3adfe6598281e8
(
param
.
getCustomerCode
());
}
else
{
pushParam
.
setFd_3adfe6598281e8
(
CommonConstants
.
EMPTY_STRING
);
}
//客户名称
pushParam
.
setFd_3adfe7a2688902
(
param
.
getCustomerName
());
if
(
null
!=
param
.
getCustomerName
()){
pushParam
.
setFd_3adfe7a2688902
(
param
.
getCustomerName
());
}
else
{
pushParam
.
setFd_3adfe7a2688902
(
CommonConstants
.
EMPTY_STRING
);
}
//发生日期
pushParam
.
setFd_3adfe67c24dace
(
param
.
getHappenDate
());
//姓名
pushParam
.
setFd_3adfe65d759650
(
param
.
getEmpName
());
if
(
null
!=
param
.
getEmpName
()){
pushParam
.
setFd_3adfe65d759650
(
param
.
getEmpName
());
}
else
{
pushParam
.
setFd_3adfe65d759650
(
CommonConstants
.
EMPTY_STRING
);
}
//身份证号
pushParam
.
setFd_3adfe65dbd9f68
(
param
.
getEmpIdcardNo
());
if
(
null
!=
param
.
getEmpIdcardNo
()){
pushParam
.
setFd_3adfe65dbd9f68
(
param
.
getEmpIdcardNo
());
}
else
{
pushParam
.
setFd_3adfe65dbd9f68
(
CommonConstants
.
EMPTY_STRING
);
}
//发票号
if
(
null
!=
param
.
getInvoiceNo
()){
pushParam
.
setFd_3adfe65e0cd094
(
param
.
getInvoiceNo
());
}
else
{
pushParam
.
setFd_3adfe65e0cd094
(
CommonConstants
.
EMPTY_STRING
);
}
//险种
if
(
null
!=
param
.
getInsuranceTypeName
()){
pushParam
.
setFd_3adfe65f6599e4
(
param
.
getInsuranceTypeName
());
}
else
{
pushParam
.
setFd_3adfe65f6599e4
(
CommonConstants
.
EMPTY_STRING
);
}
//保险公司
if
(
null
!=
param
.
getInsuranceCompanyName
()){
pushParam
.
setFd_3adfe65ea04728
(
param
.
getInsuranceCompanyName
());
}
else
{
pushParam
.
setFd_3adfe65ea04728
(
CommonConstants
.
EMPTY_STRING
);
}
//保单号
if
(
null
!=
param
.
getPolicyNo
()){
pushParam
.
setFd_3adfe65e60e110
(
param
.
getPolicyNo
());
}
else
{
pushParam
.
setFd_3adfe65e60e110
(
CommonConstants
.
EMPTY_STRING
);
}
//保险开始日期
if
(
null
!=
param
.
getPolicyStart
()){
pushParam
.
setFd_3adfe6b7e0ede8
(
param
.
getPolicyStart
().
toString
());
}
else
{
pushParam
.
setFd_3adfe6b7e0ede8
(
CommonConstants
.
EMPTY_STRING
);
}
//保险结束日期
if
(
null
!=
param
.
getPolicyEnd
()){
pushParam
.
setFd_3adfe6b847bfe6
(
param
.
getPolicyEnd
().
toString
());
}
else
{
pushParam
.
setFd_3adfe6b847bfe6
(
CommonConstants
.
EMPTY_STRING
);
}
//购买标准
pushParam
.
setFd_3adfe6d55384c6
(
param
.
getBuyStandard
());
if
(
null
!=
param
.
getBuyStandard
()){
pushParam
.
setFd_3adfe6d55384c6
(
param
.
getBuyStandard
());
}
else
{
pushParam
.
setFd_3adfe6d55384c6
(
CommonConstants
.
EMPTY_STRING
);
}
//实际保费
if
(
null
!=
param
.
getActualPremium
()){
pushParam
.
setFd_3adfe6610c0d2c
(
param
.
getActualPremium
().
toString
());
}
else
{
pushParam
.
setFd_3adfe6610c0d2c
(
CommonConstants
.
EMPTY_STRING
);
}
//医保
if
(
null
!=
param
.
getMedicalQuota
()){
pushParam
.
setFd_3adfe66041a996
(
param
.
getMedicalQuota
());
}
else
{
pushParam
.
setFd_3adfe66041a996
(
CommonConstants
.
EMPTY_STRING
);
}
//事故或残疾
if
(
null
!=
param
.
getDieDisableQuota
()){
pushParam
.
setFd_3adfe6609aa810
(
param
.
getDieDisableQuota
());
}
else
{
pushParam
.
setFd_3adfe6609aa810
(
CommonConstants
.
EMPTY_STRING
);
}
//预估保费
if
(
null
!=
param
.
getEstimatePremium
()){
pushParam
.
setFd_3adfe6e30f2a3c
(
param
.
getEstimatePremium
().
toString
());
}
else
{
pushParam
.
setFd_3adfe6e30f2a3c
(
CommonConstants
.
EMPTY_STRING
);
}
//结算月
if
(
null
!=
param
.
getSettleMonth
()){
pushParam
.
setFd_3aea2f0180eccc
(
param
.
getSettleMonth
());
}
else
{
pushParam
.
setFd_3aea2f0180eccc
(
CommonConstants
.
EMPTY_STRING
);
}
//交易类型
if
(
null
!=
param
.
getInteractiveType
()){
pushParam
.
setFd_3af9197b31071c
(
param
.
getInteractiveType
());
}
else
{
pushParam
.
setFd_3af9197b31071c
(
CommonConstants
.
EMPTY_STRING
);
}
//有无预估
if
(
null
!=
param
.
getEstimateStatus
()){
pushParam
.
setFd_3b0a5937928c8c
(
param
.
getEstimateStatus
());
}
else
{
pushParam
.
setFd_3b0a5937928c8c
(
CommonConstants
.
EMPTY_STRING
);
}
//是否bro客户
if
(
null
!=
param
.
getBpoFlag
()){
pushParam
.
setFd_3b178f8ba1a91c
(
param
.
getBpoFlag
());
}
else
{
pushParam
.
setFd_3b178f8ba1a91c
(
CommonConstants
.
EMPTY_STRING
);
}
return
pushParam
;
}
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpOrderUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpOrderProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpOrderParam
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpOrderReplyParam
;
import
io.micrometer.core.instrument.util.StringUtils
;
import
lombok.extern.log4j.Log4j2
;
import
org.apache.commons.io.FileUtils
;
import
org.apache.commons.lang.ArrayUtils
;
import
org.codehaus.jackson.map.ObjectMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.core.io.FileSystemResource
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
import
org.springframework.web.multipart.MultipartFile
;
import
java.io.File
;
import
java.util.ArrayList
;
import
java.util.List
;
/**
* @author licancan
* @description 对接ekp订单
* @date 2022-08-31 15:35:20
*/
@Log4j2
@EnableConfigurationProperties
(
EkpOrderProperties
.
class
)
public
class
EkpOrderUtil
{
@Autowired
private
EkpOrderProperties
ekpProperties
;
/**
* 更新订单状态
*
* @author licancan
* @param param
* @return {@link String}
*/
public
String
sendOrderToEKP
(
EkpOrderParam
param
){
log
.
info
(
"推送EKP开始--订单状态"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getOrderDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getOrderFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getOrderFdFlowId
());
wholeForm
.
add
(
"formValues"
,
formValues
);
log
.
info
(
"wholeForm:"
+
wholeForm
);
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<
MultiValueMap
<
String
,
Object
>>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
null
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
error
(
e
);
return
null
;
}
}
/**
* 推送订单回复
*
* @author licancan
* @param param
* @return {@link String}
*/
public
String
sendReplyToEKP
(
EkpOrderReplyParam
param
,
MultipartFile
[]
multipartFiles
){
log
.
info
(
"推送EKP开始--订单回复信息"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
List
<
File
>
fileList
=
new
ArrayList
<>();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getReplyDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getReplyFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getReplyFdFlowId
());
wholeForm
.
add
(
"formValues"
,
formValues
);
if
(
ArrayUtils
.
isNotEmpty
(
multipartFiles
)){
for
(
int
i
=
0
;
i
<
multipartFiles
.
length
;
i
++)
{
String
fileName
=
multipartFiles
[
i
].
getOriginalFilename
();
File
file
=
new
File
(
fileName
);
FileUtils
.
copyInputStreamToFile
(
multipartFiles
[
i
].
getInputStream
(),
file
);
wholeForm
.
add
(
"attachmentForms["
+
i
+
"].fdKey"
,
ekpProperties
.
getReplyAttachKey
());
wholeForm
.
add
(
"attachmentForms["
+
i
+
"].fdFileName"
,
multipartFiles
[
i
].
getOriginalFilename
());
wholeForm
.
add
(
"attachmentForms["
+
i
+
"].fdAttachment"
,
new
FileSystemResource
(
file
));
fileList
.
add
(
file
);
}
}
log
.
info
(
"wholeForm:"
+
wholeForm
);
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<
MultiValueMap
<
String
,
Object
>>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
null
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
error
(
e
);
return
null
;
}
finally
{
//将产生的临时附件删除,这里的fileList没值得话是[],不会是null,如果是null需要做判空处理
fileList
.
stream
().
forEach
(
e
->
{
boolean
delete
=
e
.
delete
();
log
.
info
(
"临时附件删除结果:{}"
,
delete
);
});
}
}
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpSalaryUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
cn.hutool.json.JSONObject
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpSalaryProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpSalaryParam
;
import
io.micrometer.core.instrument.util.StringUtils
;
import
lombok.extern.log4j.Log4j2
;
import
org.codehaus.jackson.map.ObjectMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
/**
* @Author fxj
* @Date 2022/7/11
* @Description
* @Version 1.0
*/
@Log4j2
@EnableConfigurationProperties
(
EkpSalaryProperties
.
class
)
public
class
EkpSalaryUtil
{
@Autowired
private
EkpSalaryProperties
ekpProperties
;
public
String
sendToEKP
(
EkpSalaryParam
param
){
log
.
info
(
"推送EKP开始--薪资明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
JSONObject
loginName
=
new
JSONObject
();
loginName
.
append
(
"LoginName"
,
ekpProperties
.
getLoginName
());
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
//wholeForm.add("docSubject", new String(docSubject.getBytes("UTF-8"),"ISO-8859-1") )
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
//wholeForm.add("docCreator", loginData)
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowId
());
//wholeForm.add("formValues", new String(formValues.getBytes("UTF-8"),"ISO-8859-1"))
wholeForm
.
add
(
"formValues"
,
formValues
);
//wholeForm.add("formValues", new String("{\"fd_3adfe6af71a1cc\":\"王五\", \"fd_3adfe658c6229e\":\"2019-03-26\", \"fd_3adfe6592b4158\":\"这里内容\"}".getBytes("UTF-8"),"ISO-8859-1") )
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
EkpConstants
.
SEND_FAILED
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
info
(
e
.
getMessage
());
return
e
.
getMessage
();
}
}
}
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpSocialUtil.java
deleted
100644 → 0
View file @
d3e22082
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
cn.hutool.json.JSONObject
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpSocialProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpPushSocialParam
;
import
io.micrometer.core.instrument.util.StringUtils
;
import
lombok.extern.log4j.Log4j2
;
import
org.codehaus.jackson.map.ObjectMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.http.*
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
org.springframework.web.client.RestTemplate
;
/**
* @Author huyc
* @Date 2022/8/29
* @Description
* @Version 1.0
*/
@Log4j2
@EnableConfigurationProperties
(
EkpSocialProperties
.
class
)
public
class
EkpSocialUtil
{
@Autowired
private
EkpSocialProperties
ekpProperties
;
public
String
sendToEKP
(
EkpPushSocialParam
param
){
log
.
info
(
"推送EKP开始--社保明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
String
formValues
=
new
ObjectMapper
().
writeValueAsString
(
param
);
//指向EKP的接口url
//把ModelingAppModelParameterAddForm转换成MultiValueMap
JSONObject
loginName
=
new
JSONObject
();
loginName
.
append
(
"LoginName"
,
ekpProperties
.
getLoginName
());
String
loginData
=
new
ObjectMapper
().
writeValueAsString
(
loginName
);
MultiValueMap
<
String
,
Object
>
wholeForm
=
new
LinkedMultiValueMap
<>();
//wholeForm.add("docSubject", new String(docSubject.getBytes("UTF-8"),"ISO-8859-1") );
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
//wholeForm.add("docCreator", loginData);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelId
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowId
());
//wholeForm.add("formValues", new String(formValues.getBytes("UTF-8"),"ISO-8859-1"));
wholeForm
.
add
(
"formValues"
,
formValues
);
//wholeForm.add("formValues", new String("{\"fd_3adfe6af71a1cc\":\"王五\", \"fd_3adfe658c6229e\":\"2019-03-26\", \"fd_3adfe6592b4158\":\"这里内容\"}".getBytes("UTF-8"),"ISO-8859-1") );
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
headers
.
setContentType
(
MediaType
.
MULTIPART_FORM_DATA
);
//必须设置上传类型,如果入参是字符串,使用MediaType.TEXT_PLAIN;如果
HttpEntity
<
MultiValueMap
<
String
,
Object
>>
entity
=
new
HttpEntity
<
MultiValueMap
<
String
,
Object
>>(
wholeForm
,
headers
);
//有返回值的情况 VO可以替换成具体的JavaBean
ResponseEntity
<
String
>
obj
=
yourRestTemplate
.
exchange
(
ekpProperties
.
getUrl
(),
HttpMethod
.
POST
,
entity
,
String
.
class
);
String
body
=
obj
.
getBody
();
if
(
StringUtils
.
isBlank
(
body
)){
log
.
error
(
EkpConstants
.
SEND_FAILED
);
return
null
;
}
else
{
log
.
info
(
EkpConstants
.
SEND_SUCCESS
+
body
);
return
body
;
}
}
catch
(
Exception
e
){
log
.
info
(
e
.
getMessage
());
return
null
;
}
}
}
yifu-common/yifu-common-ekp/src/main/resources/ekpFundConfig.properties
View file @
3b66b4d8
ekpfund.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#ekpfund.url=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
ekpfund.url
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
ekpfund.fdModelId
=
181d741547a691aa68b16149a40de901
ekpfund.fdModelId
=
181d741547a691aa68b16149a40de901
ekpfund.fdFlowId
=
18290af372be55308327273487abf72a
ekpfund.fdFlowId
=
18290af372be55308327273487abf72a
ekpfund.docStatus
=
20
ekpfund.docStatus
=
20
...
...
yifu-common/yifu-common-ekp/src/main/resources/ekpIncomeConfig.properties
View file @
3b66b4d8
income.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#income.url=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
income.url
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
income.fdModelIdManage
=
181d76db26e419a88dba97b0c406689e
income.fdModelIdManage
=
181d76db26e419a88dba97b0c406689e
income.fdFlowIdManage
=
182d3b6e522b2690119e70d4ff082136
income.fdFlowIdManage
=
182d3b6e522b2690119e70d4ff082136
income.fdModelIdRisk
=
181d76db26e4112e14b9bb4274d06ba1
income.fdModelIdRisk
=
181d76db26e4112e14b9bb4274d06ba1
...
...
yifu-common/yifu-common-ekp/src/main/resources/ekpInsuranceConfig.properties
View file @
3b66b4d8
insurance.insuranceUrl
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#insurance.insuranceUrl=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
insurance.insuranceUrl
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
insurance.insuranceFdModelId
=
181d73279372e5a55438a47d7436ab7e
insurance.insuranceFdModelId
=
181d73279372e5a55438a47d7436ab7e
insurance.insuranceFdFlowId
=
18267f206233f29cbd3c5ee425c9408a
insurance.insuranceFdFlowId
=
18267f206233f29cbd3c5ee425c9408a
insurance.insuranceDocStatus
=
20
insurance.insuranceDocStatus
=
20
...
...
yifu-common/yifu-common-ekp/src/main/resources/ekpOrderConfig.properties
View file @
3b66b4d8
ekporder.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#ekporder.url=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
ekporder.url
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
ekporder.orderFdModelId
=
182f1b7ffe2e96f975564e44e559847d
ekporder.orderFdModelId
=
182f1b7ffe2e96f975564e44e559847d
ekporder.orderFdFlowId
=
182f1c098ce991ca96bc927408792beb
ekporder.orderFdFlowId
=
182f1c098ce991ca96bc927408792beb
ekporder.replyFdModelId
=
182f1bb35bb2156fb9a02904bc88dd8a
ekporder.replyFdModelId
=
182f1bb35bb2156fb9a02904bc88dd8a
...
@@ -6,7 +7,7 @@ ekporder.replyFdFlowId=182f1c3d6f5724e335b88d544be8c993
...
@@ -6,7 +7,7 @@ ekporder.replyFdFlowId=182f1c3d6f5724e335b88d544be8c993
ekporder.replyAttachKey
=
fd_3ac904c9342fe2
ekporder.replyAttachKey
=
fd_3ac904c9342fe2
ekporder.docStatus
=
20
ekporder.docStatus
=
20
ekporder.LoginName
=
admin
ekporder.LoginName
=
admin
ekporder.orderDocSubject
=
\u7528\u
4
e8e
\u9879\u
76ee
\u
8ba2
\u5355\u
66f4
\u
65b0
\u
63a5
\u
53e
3
ekporder.orderDocSubject
=
\u7528\u
4
E8E
\u9879\u
76EE
\u
8BA2
\u5355\u
66F4
\u
65B0
\u
63A5
\u
53E
3
ekporder.replyDocSubject
=
\u7528\u
4
e8e
\u
8ba2
\u5355\u
56de
\u
590d
\u
63a5
\u
53e
3
ekporder.replyDocSubject
=
\u7528\u
4
E8E
\u
8BA2
\u5355\u
56DE
\u
590D
\u
63A5
\u
53E
3
yifu-common/yifu-common-ekp/src/main/resources/ekpSalaryConfig.properties
View file @
3b66b4d8
ekp.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#ekp.url=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
ekp.url
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
ekp.fdModelId
=
181d7633ff8bc797276d0d3a54e80ad6
ekp.fdModelId
=
181d7633ff8bc797276d0d3a54e80ad6
ekp.fdFlowId
=
182b40249c1bc940d7226b941c7a4183
ekp.fdFlowId
=
182b40249c1bc940d7226b941c7a4183
ekp.docStatus
=
20
ekp.docStatus
=
20
...
...
yifu-common/yifu-common-ekp/src/main/resources/ekpSocialConfig.properties
View file @
3b66b4d8
ekpsocial.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
#ekpsocial.url=http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
ekpsocial.url
=
http://ekp.wanxinwork.com/api/sys-modeling/appModelRestService/addModel
ekpsocial.fdModelId
=
181d741547a69ba9dbc12377948e98fd
ekpsocial.fdModelId
=
181d741547a69ba9dbc12377948e98fd
ekpsocial.fdFlowId
=
18233028fe91511376b00f74b3a8f3a7
ekpsocial.fdFlowId
=
18233028fe91511376b00f74b3a8f3a7
ekpsocial.docStatus
=
20
ekpsocial.docStatus
=
20
...
...
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