openfoodfoundation / wishlist

This repository welcomes ideas and suggestions to improve the OFN software.
3 stars 0 forks source link

Change pop-up warning when deleting a payment method to avoid accidental deletions #502

Open BethanOFN opened 7 months ago

BethanOFN commented 7 months ago

What is the need/problem?

Producer A in the UK deleted a payment method from their own account. The payment method was also attached to another enterprise, Hub B, and deleting it therefore deleted it for both Producer A and Hub B. The payment method was the main payment method for Hub B, and so deleting it caused their shop to 'close' as they had no valid payment methods. This was unexpected behaviour for both Producer A and Hub B, meaning Hub B were concerned they had been hacked and questioned the security of the OFN platform.

What type of users does this affect (and how many, if known)?

There are 80+ UK payment methods associated to more than one enterprise. This is a common feature used by many users where a single enterprise may manage the accounts of multiple other enterprises (e.g. a hub managing lots of their producers' OFN accounts).

Potential solutions that could solve the problem?

Amend the pop-up soft warning when a user deletes a payment method to list the linked enterprises. Currently, the warning is just an 'Are you sure?' message. Note the two hubs listed in the payment methods list (Demo Procurement Hub and User Guide Demo Hub) behind the pop-up:

Screenshot 2024-03-04 at 14 29 47

Suggested amendment to change the text to 'This will delete the payment method for:

Are you sure?'

By listing the linked enterprise(s) this should warn users from accidentally deleting a payment method from other enterprises.

Screenshot 2024-03-04 at 14 29 47

Additional context

Link to slack thread discussing issue