支付方式接口调整 #63
@ -31,8 +31,15 @@ public class AppPayChannelController {
|
||||
@GetMapping("/get-enable-code-list")
|
||||
@Operation(summary = "获得指定应用的开启的支付渠道编码列表")
|
||||
@Parameter(name = "appId", description = "应用编号", required = true, example = "1")
|
||||
public CommonResult<Set<String>> getEnableChannelCodeList(@RequestParam("appId") Long appId) {
|
||||
public CommonResult<Set<String>> getEnableChannelCodeList(@RequestParam("appId") Long appId, @RequestParam(value = "hideWalletPay", defaultValue = "false") Boolean hideWalletPay) {
|
||||
List<PayChannelDO> channels = channelService.getEnableChannelList(appId);
|
||||
if (hideWalletPay) {
|
||||
for (int i = channels.size() - 1; i >= 0; i--) {
|
||||
if ("wallet".equals(channels.get(i).getCode())) {
|
||||
channels.remove(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
return success(convertSet(channels, PayChannelDO::getCode));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user