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

chore: [IOBP-667,IOBP-666] Adapt user wallet definitions with the new openapi #384

Merged
merged 3 commits into from
Jun 4, 2024

Conversation

Hantex9
Copy link
Contributor

@Hantex9 Hantex9 commented May 29, 2024

Short description

This PR adapts the new user wallet definition upgrading the openapi file

List of changes proposed in this pull request

  • Adapted details of a method with type = PAYPAL adding the new pspBusinessName metadata
  • Adapted the clients attribute with the IO key;

How to test

Try this PR combined with this other PR on the io-app: pagopa/io-app#5803 , you should be able to see a pre-selected payment method and if it is a "Pagamento veloce con PayPal", you should be able to see also the email and PSP name.

Copy link

codecov bot commented May 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.66%. Comparing base (33ca3dd) to head (850ac85).
Report is 1 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #384   +/-   ##
=======================================
  Coverage   69.66%   69.66%           
=======================================
  Files         156      156           
  Lines        5008     5008           
  Branches      605      605           
=======================================
  Hits         3489     3489           
+ Misses       1518     1441   -77     
- Partials        1       78   +77     
Files Coverage Δ
...rc/features/payments/persistence/paymentMethods.ts 89.47% <ø> (ø)
src/features/payments/persistence/userWallet.ts 70.73% <ø> (ø)

... and 26 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6c2a272...850ac85. Read the comment docs.

@Hantex9 Hantex9 merged commit 77c481d into master Jun 4, 2024
8 checks passed
@Hantex9 Hantex9 deleted the IOBP-667-paypal-metadata-openapi branch June 4, 2024 07:29
Hantex9 added a commit to pagopa/io-app that referenced this pull request Jun 4, 2024
…thod adaption (#5803)

## Short description
This PR adds the metadata for fast PayPal payment by adding the masked
email and the pspBusinessName if both are present. In addition, the
selector has been adapted to handle the “recently used” logic by taking
into account the `lastUsage` attribute of the `clients` map

## List of changes proposed in this pull request
- Upgraded the new openapi for wallet & ecommerce
- Changed the selector to filter the "recently used" payment method
following the new openapi definitions
- Added metadata to the "Pagamento veloce con PayPal" with the
pspBusinessName and maskedEmail if both present.

## How to test
- Checkout this PR: pagopa/io-dev-api-server#384
- Start a new payment and when you are in the payment selection step,
you should be able to see a pre-selected method. If in the list of saved
methods or the "recently used" there is a "Pagamento veloce con PayPal",
you should be able even to see metadata in the list item description


## Preview
<img
src="https://github.com/pagopa/io-app/assets/34343582/f2dcd4ae-276d-4f32-b6bf-81fd75911ca3"
width="350px" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants