Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
order-group
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
order-group-application
order-group
Commits
79362c00
Commit
79362c00
authored
Oct 13, 2022
by
jiangxiaoyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
getPayCode
parent
2bd92949
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
50 additions
and
0 deletions
+50
-0
order-application-service/src/main/java/cn/freemud/controller/ExposureOrderController.java
+9
-0
order-application-service/src/main/java/cn/freemud/entities/vo/GetPayCodeVo.java
+20
-0
order-application-service/src/main/java/cn/freemud/service/ExposureOrderService.java
+9
-0
order-application-service/src/main/java/cn/freemud/service/impl/PayServiceImpl.java
+12
-0
No files found.
order-application-service/src/main/java/cn/freemud/controller/ExposureOrderController.java
View file @
79362c00
...
@@ -122,4 +122,13 @@ public class ExposureOrderController {
...
@@ -122,4 +122,13 @@ public class ExposureOrderController {
return
ResponseUtil
.
success
(
exposureOrderService
.
getVirtualStore
(
req
.
getAppId
(),
req
.
getType
()));
return
ResponseUtil
.
success
(
exposureOrderService
.
getVirtualStore
(
req
.
getAppId
(),
req
.
getType
()));
}
}
/**
* 查询支付配置paycode
*/
@ApiAnnotation
(
logMessage
=
"查询支付配置paycode"
)
@PostMapping
(
"/getPayCode"
)
public
BaseResponse
<
String
>
getPayCode
(
@Validated
@LogParams
@RequestBody
GetPayCodeVo
req
)
{
return
ResponseUtil
.
success
(
exposureOrderService
.
getPayCode
(
req
));
}
}
}
order-application-service/src/main/java/cn/freemud/entities/vo/GetPayCodeVo.java
0 → 100644
View file @
79362c00
package
cn
.
freemud
.
entities
.
vo
;
import
lombok.Data
;
import
javax.validation.constraints.NotBlank
;
@Data
public
class
GetPayCodeVo
{
@NotBlank
(
message
=
"商户号不能为空"
)
private
String
partnerId
;
@NotBlank
(
message
=
"门店id不能为空"
)
private
String
storeId
;
@NotBlank
(
message
=
"小程序id不能为空"
)
private
String
appId
;
private
String
channel
;
}
order-application-service/src/main/java/cn/freemud/service/ExposureOrderService.java
View file @
79362c00
...
@@ -3,6 +3,8 @@ package cn.freemud.service;
...
@@ -3,6 +3,8 @@ package cn.freemud.service;
import
cn.freemud.entities.vo.GetMallPayConfigVo
;
import
cn.freemud.entities.vo.GetMallPayConfigVo
;
import
cn.freemud.entities.vo.GetPayConfigVo
;
import
cn.freemud.entities.vo.GetPayConfigVo
;
import
cn.freemud.entities.vo.GetPaySuccessDataRequest
;
import
cn.freemud.entities.vo.GetPaySuccessDataRequest
;
import
cn.freemud.base.entity.BaseResponse
;
import
cn.freemud.entities.vo.*
;
import
cn.freemud.entities.vo.order.PayConfigVo
;
import
cn.freemud.entities.vo.order.PayConfigVo
;
import
cn.freemud.entities.vo.order.PaySuccessDataVo
;
import
cn.freemud.entities.vo.order.PaySuccessDataVo
;
import
cn.freemud.enums.AggregationTypeEnum
;
import
cn.freemud.enums.AggregationTypeEnum
;
...
@@ -84,4 +86,11 @@ public class ExposureOrderService {
...
@@ -84,4 +86,11 @@ public class ExposureOrderService {
AssortmentOpenPlatformIappWxappStore
wxAppStore
=
payService
.
getIappWxappStoreInfo
(
appId
,
type
);
AssortmentOpenPlatformIappWxappStore
wxAppStore
=
payService
.
getIappWxappStoreInfo
(
appId
,
type
);
return
wxAppStore
==
null
?
""
:
wxAppStore
.
getStoreId
();
return
wxAppStore
==
null
?
""
:
wxAppStore
.
getStoreId
();
}
}
/**
* 查询支付配置paycode
*/
public
String
getPayCode
(
GetPayCodeVo
req
)
{
return
payService
.
getPayCode
(
req
.
getAppId
(),
req
.
getStoreId
(),
req
.
getChannel
());
}
}
}
order-application-service/src/main/java/cn/freemud/service/impl/PayServiceImpl.java
View file @
79362c00
...
@@ -1711,4 +1711,16 @@ public class PayServiceImpl {
...
@@ -1711,4 +1711,16 @@ public class PayServiceImpl {
return
payTypeCode
;
return
payTypeCode
;
}
}
public
String
getPayCode
(
String
wxAppid
,
String
storeId
,
String
channel
)
{
PayChannelType
byIndex
=
PayChannelType
.
getByIndex
(
Byte
.
parseByte
(
channel
));
if
(
byIndex
.
getEbcode
()
==
null
)
return
""
;
AssortmentOpenPlatformIappWxappStore
wxAppStore
=
assortmentOpenPlatformIappWxappStoreManager
.
selectWxappStoreByWxAppIdAndStoreId
(
wxAppid
,
storeId
,
byIndex
.
getEbcode
());
if
(
wxAppStore
!=
null
&&
StringUtils
.
isNotBlank
(
wxAppStore
.
getPayCode
()))
{
return
wxAppStore
.
getPayCode
();
}
return
"9"
;
}
}
}
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