mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
Merge branch 'dev' into dev-g
This commit is contained in:
@@ -6,6 +6,7 @@ import com.jsowell.adapay.dto.*;
|
||||
import com.jsowell.adapay.service.AdapayService;
|
||||
import com.jsowell.adapay.vo.AdapayAccountBalanceVO;
|
||||
import com.jsowell.common.annotation.Log;
|
||||
import com.jsowell.common.constant.Constants;
|
||||
import com.jsowell.common.core.controller.BaseController;
|
||||
import com.jsowell.common.core.domain.AjaxResult;
|
||||
import com.jsowell.common.core.page.PageResponse;
|
||||
@@ -15,10 +16,7 @@ import com.jsowell.common.exception.BusinessException;
|
||||
import com.jsowell.common.util.StringUtils;
|
||||
import com.jsowell.pile.service.ClearingWithdrawInfoService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
@@ -201,4 +199,42 @@ public class AdapayMemberController extends BaseController {
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除结算账户
|
||||
* @param dto
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/deleteSettleAccount")
|
||||
public AjaxResult deleteSettleAccount(@RequestBody AdapayMemberInfoDTO dto) {
|
||||
AjaxResult result = null;
|
||||
try {
|
||||
// 新写删除方法
|
||||
adapayService.deleteSettleAccount(dto);
|
||||
result = AjaxResult.success();
|
||||
} catch (Exception e) {
|
||||
logger.error("删除结算账户 error,", e);
|
||||
result = AjaxResult.error();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 在仅删除结算账户后,重新创建新的结算账户
|
||||
* 注:使用原 member_id 重新创建结算账户对象,且必须与原身份证和银行卡户名保持一致
|
||||
* @param dto
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("createBankAccount")
|
||||
public AjaxResult createBankAccount(@RequestBody SettleAccountDTO dto) {
|
||||
AjaxResult result = null;
|
||||
try {
|
||||
adapayService.createBankAccount(dto);
|
||||
} catch (Exception e) {
|
||||
logger.error("重新创建结算账户 error, ", e);
|
||||
result = AjaxResult.error();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -211,15 +211,16 @@ public class PaymentTestController {
|
||||
|
||||
/**
|
||||
* 提现方法
|
||||
*
|
||||
*/
|
||||
@Test
|
||||
public void withdraw() {
|
||||
String merchantId = "349";
|
||||
String merchantId = "87";
|
||||
String orderNo = "drawcash_" + merchantId + "_" + System.currentTimeMillis();
|
||||
BigDecimal cashAmt = new BigDecimal("560.17");
|
||||
String adapayMemberId = "ACM88073310";
|
||||
BigDecimal cashAmt = new BigDecimal("2013.81");
|
||||
String adapayMemberId = "AM67987250";
|
||||
// String adapayAppId = "app_d0c80cb1-ffc8-48cb-a030-fe9bec823aaa"; // 固定参数, 汇付配置的万车充小程序appId
|
||||
String settleAccountId = "0744607938214272";
|
||||
String settleAccountId = "0600303988488384";
|
||||
String wechatAppId = wechatAppId1;
|
||||
try {
|
||||
adapayService.createDrawcashRequest(orderNo, cashAmt, adapayMemberId, adapayAppId, settleAccountId, wechatAppId);
|
||||
|
||||
Reference in New Issue
Block a user