|
|
|
@ -5,6 +5,7 @@ import au.com.royalpay.payment.manage.mappers.ofei.TopUpOrderMapper;
|
|
|
|
|
import au.com.royalpay.payment.manage.ofei.core.OfeiClient;
|
|
|
|
|
import au.com.royalpay.payment.manage.ofei.enums.OfeiType;
|
|
|
|
|
import au.com.royalpay.payment.tools.codec.MD5Hash;
|
|
|
|
|
import au.com.royalpay.payment.tools.env.PlatformEnvironment;
|
|
|
|
|
import au.com.royalpay.payment.tools.exceptions.BadRequestException;
|
|
|
|
|
import au.com.royalpay.payment.tools.exceptions.ServerErrorException;
|
|
|
|
|
import au.com.royalpay.payment.tools.fixing.FixedDocumentHelper;
|
|
|
|
@ -84,7 +85,7 @@ public class OfeiClientImpl implements OfeiClient {
|
|
|
|
|
params.add(new BasicNameValuePair("sporder_id", orderId));
|
|
|
|
|
params.add(new BasicNameValuePair("sporder_time", DateFormatUtils.format(now, "yyyyMMddHHmmss")));
|
|
|
|
|
params.add(new BasicNameValuePair("game_userid", phoneNumber));
|
|
|
|
|
params.add(new BasicNameValuePair("ret_url", "https://mpay.royalpay.com.au/ofei/notice/"+orderId));
|
|
|
|
|
params.add(new BasicNameValuePair("ret_url", PlatformEnvironment.getEnv().concatUrl("/ofei/notice/"+orderId)));
|
|
|
|
|
|
|
|
|
|
saveOrder(orderId, now, OfeiType.PHONE.getMask(), price, phoneNumber);
|
|
|
|
|
HttpRequestGenerator req = initRequest(topUPUrl, signAndEncryptForm(params), RequestMethod.GET);
|
|
|
|
@ -220,11 +221,11 @@ public class OfeiClientImpl implements OfeiClient {
|
|
|
|
|
params.add(new BasicNameValuePair("sporder_id", orderId));
|
|
|
|
|
params.add(new BasicNameValuePair("sporder_time", DateFormatUtils.format(now, "yyyyMMddHHmmss")));
|
|
|
|
|
params.add(new BasicNameValuePair("game_userid", qqNumber));
|
|
|
|
|
params.add(new BasicNameValuePair("ret_url", "https://mpay.royalpay.com.au/ofei/notice/"+orderId));
|
|
|
|
|
params.add(new BasicNameValuePair("ret_url", PlatformEnvironment.getEnv().concatUrl("/ofei/notice/" + orderId)));
|
|
|
|
|
saveOrder(orderId, now, OfeiType.QB.getMask(), price, qqNumber);
|
|
|
|
|
HttpRequestGenerator req = initRequest(qbTopUpUrl, signAndEncryptForm(params), RequestMethod.POST);
|
|
|
|
|
Element respXml = executeRequestXML(req, "ofei QB top up fail");
|
|
|
|
|
handleResponse(orderId, respXml,qqNumber);
|
|
|
|
|
handleResponse(orderId, respXml, qqNumber);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|