You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to delete a user account as super admin for a user with no orders, who does not appear in any customer lists, triggers a 500 snail error
Expected Behavior
Super admins should be able to delete user accounts who have no associated orders/links to other tables in the database as there are no dependencies. The delete button should be usable for at least some users.
Actual Behaviour
Clicking delete triggers a 500 snail error. No users can therefore be deleted.
Steps to Reproduce
Go to Users screen on UK prod
Search user email associated with user id 222887
Delete user
Observe 500 snail error
Animated Gif/Screenshot
Workaround
Severity
bug-s3 The delete button is currently completely unusable. Workaround is to replace with dummy email when user requests their account to be deleted, but this does nothing to reduce database load. We have around 32,000 user accounts in UK who've never placed an order.
Your Environment
Version used:
Browser name and version:
Operating System and version (desktop or mobile):
Possible Fix
The text was updated successfully, but these errors were encountered:
I was checking the logs
This user has at least one order (maybe in progress)
PG::ForeignKeyViolation: ERROR: update or delete on table "spree_users" violates foreign key constraint "fk_rails_8d07181998" on table "spree_orders"
DETAIL: Key (id)=(222887) is still referenced from table "spree_orders".
do we want in this case remove the orders that belongs to that user?
Indeed it's not a bug @abdellani we need to be able to soft delete users, but that's a feature request. @BethanOFN feel free to reopen if you think otherwise.
Description
Trying to delete a user account as super admin for a user with no orders, who does not appear in any customer lists, triggers a 500 snail error
Expected Behavior
Super admins should be able to delete user accounts who have no associated orders/links to other tables in the database as there are no dependencies. The delete button should be usable for at least some users.
Actual Behaviour
Clicking delete triggers a 500 snail error. No users can therefore be deleted.
Steps to Reproduce
Animated Gif/Screenshot
Workaround
Severity
bug-s3 The delete button is currently completely unusable. Workaround is to replace with dummy email when user requests their account to be deleted, but this does nothing to reduce database load. We have around 32,000 user accounts in UK who've never placed an order.
Your Environment
Possible Fix
The text was updated successfully, but these errors were encountered: