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

feat: [IOBP-647] Latest used method pre-selection #5783

Merged
merged 11 commits into from
May 29, 2024

Conversation

Hantex9
Copy link
Contributor

@Hantex9 Hantex9 commented May 20, 2024

Short description

This PR implements the logic to pre-select a payment method from the user wallets that have been recently used and will be shown in the appropriate “Recently Used” list item

List of changes proposed in this pull request

  • Added an additional selector to filter the recently used payment method from the user wallet with the field updateDate as more recent;
  • Added a pre-selection statement into the reducer when the action paymentsGetPaymentUserMethodsAction.success is fired to filter the most recent payment method.

How to test

Start a new payment flow with the new payment section feature flag enabled;
When you start a payment, you should be able to see the most recently used payment method pre-selected

Preview

preview.mov

@pagopa-github-bot
Copy link
Collaborator

pagopa-github-bot commented May 20, 2024

Affected stories

  • 🌟 IOBP-647: Pre-selezione ultimo metodo utilizzato
    subtask of
    • IOBP-197: [MVP] Integrazione IO-ecommerce PagoPA (Flusso pagamento)

Generated by 🚫 dangerJS against dffa5ad

Copy link

codecov bot commented May 20, 2024

Codecov Report

Attention: Patch coverage is 7.14286% with 13 lines in your changes are missing coverage. Please review.

Project coverage is 49.71%. Comparing base (4f204b4) to head (dffa5ad).
Report is 108 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5783      +/-   ##
==========================================
+ Coverage   48.42%   49.71%   +1.28%     
==========================================
  Files        1488     1630     +142     
  Lines       31617    32418     +801     
  Branches     7669     7788     +119     
==========================================
+ Hits        15311    16116     +805     
- Misses      16238    16247       +9     
+ Partials       68       55      -13     
Files Coverage Δ
...features/payments/checkout/store/reducers/index.ts 14.28% <0.00%> (-1.43%) ⬇️
...ayments/checkout/store/selectors/paymentMethods.ts 25.00% <25.00%> (ø)
...checkout/components/CheckoutPaymentMethodsList.tsx 5.26% <0.00%> (ø)

... and 565 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 cf5223b...dffa5ad. Read the comment docs.

locales/en/index.yml Outdated Show resolved Hide resolved
Copy link
Contributor

@mastro993 mastro993 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Hantex9 Hantex9 merged commit 0e6759f into master May 29, 2024
13 checks passed
@Hantex9 Hantex9 deleted the IOBP-647-latest-used-method branch May 29, 2024 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO-Bonus e pagamenti IO - Bonus e pagamenti
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants