Skip to content
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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(api_models): follow naming convention for wallets & paylater payment method data enums #1338

Merged
merged 2 commits into from
Jun 15, 2023

Conversation

ArjunKarthik
Copy link
Contributor

@ArjunKarthik ArjunKarthik commented Jun 2, 2023

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

Payment method data enums should follow naming conventions, like if it is Redirect flow then name should be "{Payment_Method_Name}Redirect"

Updated api contract

AliPay Redirect:
"payment_method_data": { "wallet": { "ali_pay_redirect": {} } }

WechatPay Redirect:
"payment_method_data": { "wallet": { "we_chat_pay_redirect": {} } }

MBWay Redirect:
"payment_method_data": { "wallet": { "mb_way_redirect": { "telephone_number":"+351213822199" } } }

Walley Redirect:
"payment_method_data": { "pay_later": { "walley_redirect": {} } }

PayBright Redirect:
"payment_method_data": { "pay_later": { "pay_bright_redirect": {} } }

Additional Changes

  • This PR modifies the API contract
  • This PR modifies the database schema
  • This PR modifies application configuration/environment variables

Motivation and Context

How did you test it?

Postman:
Screen Shot 2023-06-02 at 1 12 58 PM
Screen Shot 2023-06-02 at 1 11 09 PM
Screen Shot 2023-06-02 at 1 11 44 PM
Screen Shot 2023-06-02 at 1 15 32 PM
Screen Shot 2023-06-02 at 1 16 10 PM

Checklist

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed submitted code
  • I added unit tests for my changes where possible
  • I added a CHANGELOG entry if applicable

@ArjunKarthik ArjunKarthik added S-waiting-on-review Status: This PR has been implemented and needs to be reviewed C-refactor Category: Refactor M-api-contract-changes Metadata: This PR involves API contract changes labels Jun 2, 2023
@ArjunKarthik ArjunKarthik self-assigned this Jun 2, 2023
@ArjunKarthik ArjunKarthik requested review from a team as code owners June 2, 2023 07:53
@ArjunKarthik ArjunKarthik added this pull request to the merge queue Jun 15, 2023
Merged via the queue into main with commit 6c0d136 Jun 15, 2023
8 checks passed
@SanchithHegde SanchithHegde deleted the PM-renames branch June 17, 2023 07:29
@SanchithHegde SanchithHegde removed the S-waiting-on-review Status: This PR has been implemented and needs to be reviewed label Jun 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-refactor Category: Refactor M-api-contract-changes Metadata: This PR involves API contract changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants