New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Alipay payment #98

Merged
merged 3 commits into from Nov 16, 2017

Conversation

Projects
None yet
1 participant
@guzzilar
Collaborator

guzzilar commented Nov 13, 2017

1. Objective

To add an ability to accept Alipay payment at Omise-Magento plugin.

2. Description of change

  1. Display Alipay configuration at the Magento's payment setting page.
    screen shot 2560-11-13 at 11 40 44 am

  2. Display Alipay payment method at the checkout page.

screen shot 2560-11-13 at 11 44 12 am

  1. You now will be able to place order with Alipay payment.

  2. Add new route that will be used for validate callback /omise/callback_validatealipay

3. Quality assurance

馃敡 Environments:

  • Magento CE: v1.9.2.4, v1.9.3.6.
  • PHP: v5.6.30.

鉁忥笍 Details:

1. Make sure that Alipay payment method can be displayed at the checkout page properly when you enable it.
1.1 Go to payment setting page at Magento admin page. Looking for Alipay payment, enable it.
screen shot 2560-11-13 at 11 40 44 am

1.2 Go to checkout page, Alipay payment method should be displayed at the payment method section there.
screen shot 2560-11-13 at 11 44 12 am

2. Make sure that you can place order with Alipay payment and, an invoice object, a transaction object will be created properly.

2.1 Place an order with Alipay payment at the checkout step.

2.2 An order should be placed with Alipay, order status = pending payment.
screen shot 2560-11-16 at 11 01 54 am

2.3 An invoice object must be created with status pending
screen shot 2560-11-16 at 11 02 15 am

2.4 A transaction object must be created with isClosed status = no, type = order.
screen shot 2560-11-16 at 11 02 24 am

screen_shot_2560-11-16_at_11_02_39_am

screen shot 2560-11-16 at 11 02 57 am

3. Make sure that the order state/status, invoice, transaction will be updated if payment successful

  • If payment successful, the order state/status will be updated to processing
  • An invoiced status will be updated to paid
  • A transaction's isClosed status will be updated to Yes
    001

4. Make sure that the order state/status, invoice, transaction will be updated if payment failed

  • If payment successful, the order state/status will be updated to processing then canceled
  • An invoiced status will be updated to canceled
  • A transaction's isClosed status will be updated to Yes
    002

5. Make sure that the order state/status will be updated to payment-review if Omise return pending status after payer is redirected back from Alipay page

  • If payment successful, the order state/status will be updated to payment-review
  • An invoiced status will still stay as pending
  • A transaction's isClosed status will still stay as No
    003

6. Make sure that merchant can set the order state/status from payment-review to either processing (accept payment) or canceled (deny payment) manually from Magento admin, in case merchant doesn't use Webhook feature
6.1 At the order detail page, there will be accept payment button appears in your top-bar menu if your order is under payment-review status. Click accept payment.
004

6.2 The order state/status will be updated to processing with message Approved payment.
005

6.3 This one goes the same when you click Deny payment. But instead, the order state/status will be updated to canceled (same as the test 4th).
006

7. Make sure that Webhook feature can set the order state/status from payment-review to either processing or canceled
This one gives you the same result as the test 6th. But once you use Webhook feature, you don't need to to click Accept Payment or Deny Payment manually by yourself. Instead, Webhook feature will perform that task for you automatically.

7.1 So go to the payment setting page, you will see Webhook url under the Omise payment method.
007

7.2 Copy and paste at Omise dashboard > Webhook
008

Note, localhost, 127.0.0.1 and ip address can be set at Omsie Dashboard. For this test, I used http://ngrok.com

4. Impact of the change

No

5. Priority of change

Normal

6. Additional Notes

  • Alipay is only available for merchants with a Thai-registered Omise account. We鈥檒l be adding support for other countries soon.

  • For users with a live account, please send an email to support@omise.co You鈥檒l need to review Terms & Conditions before using this feature.

@guzzilar guzzilar changed the title from [WIP] Support Alipay payment to Support Alipay payment Nov 16, 2017

@guzzilar

This comment has been minimized.

Show comment
Hide comment
@guzzilar

guzzilar Nov 16, 2017

Collaborator

馃憤

Collaborator

guzzilar commented Nov 16, 2017

馃憤

@guzzilar guzzilar merged commit e90b9ca into 1-stable Nov 16, 2017

@guzzilar

This comment has been minimized.

Show comment
Hide comment
@guzzilar

guzzilar Nov 16, 2017

Collaborator

updated 3. Quality assurance section. Add use cases & screenshots.

Collaborator

guzzilar commented Nov 16, 2017

updated 3. Quality assurance section. Add use cases & screenshots.

@guzzilar guzzilar deleted the 1-alipay branch Nov 16, 2017

@guzzilar guzzilar referenced this pull request Nov 17, 2017

Merged

鉁 Hello v1.13 鉁 #101

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment