Authored by tanling

入驻and充值 支付宝不允许是用信用卡类型

... ... @@ -6,6 +6,7 @@ import com.google.common.base.Splitter;
import com.yoho.error.ServiceError;
import com.yoho.error.exception.ServiceException;
import com.yohobuy.ufo.model.order.bo.OrderInfo;
import com.yohobuy.ufo.model.order.common.OrderCodeType;
import com.yohobuy.ufo.model.order.common.Payment;
import com.yohobuy.ufo.model.user.resp.AuthorizeResultRespVO;
import com.yohoufo.common.utils.*;
... ... @@ -19,6 +20,8 @@ import com.yohoufo.order.model.PayRefundBo;
import com.yohoufo.order.model.PaymentData;
import com.yohoufo.order.model.TransferData;
import com.yohoufo.order.service.pay.AbstractPayService;
import com.yohoufo.order.service.support.codegenerator.OrderCodeGenerator;
import com.yohoufo.order.service.support.codegenerator.bean.CodeMeta;
import com.yohoufo.order.service.transfer.TransferChannel;
import com.yohoufo.order.service.transfer.TransferResult;
import com.yohoufo.order.utils.AlipayExceedMillionTransferErrors;
... ... @@ -68,6 +71,10 @@ public abstract class AlipayServiceAbstract extends AbstractPayService {
@Autowired
OrderCodeGenerator orderCodeGenerator;
@Autowired
private OrdersPayHbfqMapper ordersPayHbfqDao;
... ... @@ -638,6 +645,11 @@ public abstract class AlipayServiceAbstract extends AbstractPayService {
tradeNo = outTradeNo;
}
// 入驻or充值 不允许用支付信用卡入口
CodeMeta codeMeta = orderCodeGenerator.expId(Long.parseLong(tradeNo));
if (codeMeta.getType() == OrderCodeType.SELLER_RECHARGE_EARNEST_TYPE.getType()){
params.put("disable_pay_channels", "credit_group"); // 禁用信用卡
}
JSONObject bizJson = new JSONObject(true);
bizJson.put("timeout_express", payExpireTime+"m"); //该订单允许的最晚付款时间
... ...
... ... @@ -15,9 +15,9 @@ public class CodeTest {
// System.out.print(result);
// System.out.println(" 反解结果: "+ orderCodeGenerator.expId(result));
// }
Long ordercode = 36378182115151L;
Long ordercode = 18785142759232l;
CodeMeta meta = orderCodeGenerator.expId(ordercode);
System.out.println(meta);
System.out.println(meta.getType());
// System.out.println(1<<3);
... ...