Commit db360078 authored by renjie's avatar renjie

提现bug

parent a0405b6f
......@@ -35,6 +35,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Service;
import javax.swing.text.Document;
import java.text.SimpleDateFormat;
import java.time.Instant;
import java.time.YearMonth;
......@@ -591,6 +592,7 @@ public class PaymentServiceImpl implements PaymentService {
@Override
public boolean alipayWithdraw(String username, String account, String realName, double amount) {
java.text.DecimalFormat df = new java.text.DecimalFormat("#.00");
Account byName = accountService.findByName(username);
if (byName == null)
throw new ClientRequestException(AccountErrorCode.NAMENOTEXIST, "account does not exist: " + username);
......@@ -619,7 +621,7 @@ public class PaymentServiceImpl implements PaymentService {
AlipayFundTransToaccountTransferRequest alipayRequest = new AlipayFundTransToaccountTransferRequest();
String out_biz_no = internalOrder.getTradeNo();
String trans_amount = "" + amount + ".00";
String trans_amount = "" + df.format(amount);
String identity_type = "ALIPAY_LOGONID";
String subject = "礼金提现" + out_biz_no;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment