|
@@ -15,6 +15,7 @@ import com.zanxiang.game.module.sdk.util.HttpUtil;
|
|
import com.zanxiang.game.module.sdk.util.WxPayUtil;
|
|
import com.zanxiang.game.module.sdk.util.WxPayUtil;
|
|
import com.zanxiang.game.module.sdk.util.XmlUtil;
|
|
import com.zanxiang.game.module.sdk.util.XmlUtil;
|
|
import com.zanxiang.module.util.JsonUtil;
|
|
import com.zanxiang.module.util.JsonUtil;
|
|
|
|
+import com.zanxiang.module.util.NumberUtil;
|
|
import com.zanxiang.module.util.exception.BaseException;
|
|
import com.zanxiang.module.util.exception.BaseException;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
import org.apache.commons.io.IOUtils;
|
|
import org.apache.commons.io.IOUtils;
|
|
@@ -328,7 +329,7 @@ public class WxPayService extends PayBaseService {
|
|
paramData.put("body", product.getSubject());
|
|
paramData.put("body", product.getSubject());
|
|
paramData.put("out_trade_no", product.getOutTradeNo());
|
|
paramData.put("out_trade_no", product.getOutTradeNo());
|
|
paramData.put("fee_type", "CNY");
|
|
paramData.put("fee_type", "CNY");
|
|
- paramData.put("total_fee", WxPayUtil.subZeroAndDot(String.valueOf(Float.parseFloat(product.getTotalFee()) * 100)));
|
|
|
|
|
|
+ paramData.put("total_fee", String.valueOf(NumberUtil.multiply100(new BigDecimal(product.getTotalFee())).longValue()));
|
|
paramData.put("spbill_create_ip", product.getSpbillCreateIp());
|
|
paramData.put("spbill_create_ip", product.getSpbillCreateIp());
|
|
paramData.put("notify_url", notifyUrl);
|
|
paramData.put("notify_url", notifyUrl);
|
|
paramData.put("trade_type", tradeType);
|
|
paramData.put("trade_type", tradeType);
|