diff --git a/pom.xml b/pom.xml
index ab17ae172..843cdd552 100644
--- a/pom.xml
+++ b/pom.xml
@@ -5,11 +5,11 @@
au.com.royalpay.payment
payment-parent
- 2.1.48
+ 2.1.49
4.0.0
manage
- 2.3.8
+ 2.3.9
UTF-8
2.2.0
diff --git a/src/document/openapi/cn/document.yml b/src/document/openapi/cn/document.yml
index b77863011..ac99dd9d4 100644
--- a/src/document/openapi/cn/document.yml
+++ b/src/document/openapi/cn/document.yml
@@ -555,6 +555,10 @@ paths:
type: boolean
default: false
description: 如果希望禁止消费者使用信用卡支付可传入true
+ disable_threeds:
+ type: boolean
+ default: false
+ description: 平台会协助商户自动开启3DS校验以减少盗刷风险。如果商户希望关闭这个功能,可以提交当前参数为true。(3DS校验需要消费者多一步银行端验证,并且如小程序等场景无法实现网页跳转到银行页面导致流程无法继续)
tokenize:
type: boolean
default: false
@@ -669,6 +673,10 @@ paths:
type: boolean
default: false
description: 如果希望禁止消费者使用信用卡支付可传入true
+ disable_threeds:
+ type: boolean
+ default: false
+ description: 平台会协助商户自动开启3DS校验以减少盗刷风险。如果商户希望关闭这个功能,可以提交当前参数为true。(3DS校验需要消费者多一步银行端验证,并且如小程序等场景无法实现网页跳转到银行页面导致流程无法继续)
customer:
$ref: 'components_order.yml#/cardCustomerParam'
responses:
@@ -677,7 +685,13 @@ paths:
content:
application/json:
schema:
- $ref: 'components_order.yml#/orderBasicResponse'
+ allOf:
+ - $ref: 'components_order.yml#/orderBasicResponse'
+ - type: object
+ properties:
+ pay_url:
+ type: string
+ description: 当开启3DS校验时系统会返回当前参数,商户应该引导消费者跳转到此页面完成3DS认证
/micropay/partners/{partner_code}/orders/{partner_order_id}:
put:
summary: 付款码下单
diff --git a/src/document/openapi/en/document.yml b/src/document/openapi/en/document.yml
index 56b998930..09e5846c4 100644
--- a/src/document/openapi/en/document.yml
+++ b/src/document/openapi/en/document.yml
@@ -568,6 +568,10 @@ paths:
type: boolean
default: false
description: pass true if merchant want to disable credit cards from paying to this order.
+ disable_threeds:
+ type: boolean
+ default: false
+ description: We will help merchants to enable 3DS verify by default. If you want to disable this feature please set this parameter as true
tokenize:
type: boolean
default: false
@@ -619,7 +623,7 @@ paths:
put:
summary: Create Card Order
description: |
- Input https://channel.rpayplus.com/channel/v1/view/card_input_frame.js in merchant's webpage.
+ Input https://channel-gateway.royalpay.com.au/channel/v1/view/card_input_frame.js in merchant's webpage.
After called commit, it will return `key_id` and `secret` parameter asyncronized by callback.
Post these parameter to royalpay and finish payment directly.
@@ -690,6 +694,10 @@ paths:
type: boolean
default: false
description: Pass true if want to refuse credit cards.
+ disable_threeds:
+ type: boolean
+ default: false
+ description: We will help merchants to enable 3DS verify by default. If you want to disable this feature please set this parameter as true
customer:
$ref: 'components_order.yml#/cardCustomerParam'
responses:
@@ -698,7 +706,13 @@ paths:
content:
application/json:
schema:
- $ref: 'components_order.yml#/orderBasicResponse'
+ allOf:
+ - $ref: 'components_order.yml#/orderBasicResponse'
+ - type: object
+ properties:
+ pay_url:
+ type: string
+ description: If order requires 3DS verify. it will return this parameter. Merchants's system should guide customer to redirect to this url and finish 3DS verify. Remember to add signatures and return_url param
/micropay/partners/{partner_code}/orders/{partner_order_id}:
put:
summary: Retail Passive Payment Order
diff --git a/src/main/java/au/com/royalpay/payment/manage/mappers/payment/TransactionMapper.java b/src/main/java/au/com/royalpay/payment/manage/mappers/payment/TransactionMapper.java
index 2a0c9e8f4..b143ee3ad 100644
--- a/src/main/java/au/com/royalpay/payment/manage/mappers/payment/TransactionMapper.java
+++ b/src/main/java/au/com/royalpay/payment/manage/mappers/payment/TransactionMapper.java
@@ -1,13 +1,13 @@
package au.com.royalpay.payment.manage.mappers.payment;
+import com.alibaba.fastjson.JSONObject;
+import com.github.miemiedev.mybatis.paginator.domain.PageBounds;
+import com.github.miemiedev.mybatis.paginator.domain.PageList;
import com.yixsoft.support.mybatis.autosql.annotations.AdvanceSelect;
import com.yixsoft.support.mybatis.autosql.annotations.AutoMapper;
import com.yixsoft.support.mybatis.autosql.annotations.AutoSql;
import com.yixsoft.support.mybatis.autosql.annotations.SqlType;
import com.yixsoft.support.mybatis.paginator.annotations.CountRef;
-import com.alibaba.fastjson.JSONObject;
-import com.github.miemiedev.mybatis.paginator.domain.PageBounds;
-import com.github.miemiedev.mybatis.paginator.domain.PageList;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.executor.keygen.Jdbc3KeyGenerator;
@@ -20,8 +20,6 @@ import java.util.List;
*/
@AutoMapper(tablename = "pmt_transactions", pkName = "transaction_id", keyGenerator = Jdbc3KeyGenerator.class)
public interface TransactionMapper {
- @AutoSql(SqlType.INSERT)
- void save(JSONObject transaction);
@CountRef(".countTransFlowPage")
PageList listTransFlowPage(JSONObject params, PageBounds pagination);
@@ -38,9 +36,6 @@ public interface TransactionMapper {
@AdvanceSelect(addonWhereClause = "transaction_type = 'Credit'")
JSONObject findByOrderId(@Param("order_id") String orderId);
- @AutoSql(SqlType.UPDATE)
- void update(JSONObject transaction);
-
JSONObject findLastIncome();
double getClientUnClearedAmount(@Param("client_id") int clientId);
diff --git a/src/main/ui/static/templates/payment/v1/card_pay.js b/src/main/ui/static/templates/payment/v1/card_pay.js
index 8506924ab..8ebbabd84 100644
--- a/src/main/ui/static/templates/payment/v1/card_pay.js
+++ b/src/main/ui/static/templates/payment/v1/card_pay.js
@@ -10,7 +10,16 @@ $(function () {
data: JSON.stringify(secretData),
contentType: 'application/json',
method: 'POST',
- success: function () {
+ success: function (res) {
+ if (res.sdk_params) {
+ let threeDsParams = JSON.parse(res.sdk_params);
+ let form = $('').attr('action', threeDsParams.acs_url).attr('method', 'post').css('display', 'none');
+ $('').attr('name', 'paReq').val(threeDsParams.pa_req).attr('type', 'hidden').appendTo(form);
+ $('').attr('name', 'TermURL').val(threeDsParams.term_url).attr('type', 'hidden').appendTo(form);
+ $(body).append(form);
+ form.commit();
+ return;
+ }
startCheckOrder(window.client_moniker, window.partner_order_id);
},
error: function (jqXHR) {