81,092
社区成员
发帖
与我相关
我的任务
分享
private ActionForward callbackOperation(Charge charge,
HttpServletRequest request) throws AppException {
System.out.println("-----开始执行callbackOperation----------");
ActionRedirect redirect = new ActionRedirect("/agent/agent.do");
redirect.addParameter("thisAction", "agentInfoById");
final String chargeType = charge.getType();
final String remark = charge.getRemark();
try {
if (Charge.CHARGE_TYPE_SELF.equals(chargeType)) {
return redirect;
} else if (Charge.CHARGE_TYPE_TRANSACTION.equals(chargeType)) {
redirect = new ActionRedirect("/transaction/transaction.do");
redirect.addParameter("thisAction",
"transactionPaymentReturnByBank");
redirect.addParameter("transactionNo", remark);
} else if (Charge.CHARGE_TYPE_NOACCOUNT.equals(chargeType)) {
redirect = new ActionRedirect("/cooperate/gateway.do");
redirect.addParameter("service",
"direct_payment_for_no_account");
redirect.addParameter("remark", remark);
} else if (Charge.CHARGE_TYPE_DIRECTPAYMENT.equals(chargeType)) { //例如我现在执行这里
System.out.println("--0-开始redirect,订单号:" + charge.getOrderNo());
redirect = new ActionRedirect("/cooperate/gateway.do");
redirect.addParameter("service", "direct_payment_by_bank");
redirect.addParameter("remark", remark);
System.out.println("-1-开始redirect,订单号:" + charge.getOrderNo());
} else if (Charge.CHARGE_TYPE_OTHER.equals(chargeType)) {
return redirect;
}
} catch (Exception ex) {
System.out.println("callbackOperation异常," + ex.getMessage());
return null;
}
System.out.println("------------开始执行redirect------" + chargeType
+ ",Charge.CHARGE_TYPE_DIRECTPAYMENT.equals(chargeType)="
+ Charge.CHARGE_TYPE_DIRECTPAYMENT.equals(chargeType));
return redirect;
}