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

un opérateur peut bloquer un compte #9324

Merged
merged 2 commits into from
Jul 18, 2023
Merged

un opérateur peut bloquer un compte #9324

merged 2 commits into from
Jul 18, 2023

Conversation

LeSim
Copy link
Member

@LeSim LeSim commented Jul 18, 2023

No description provided.

@what-the-diff
Copy link

what-the-diff bot commented Jul 18, 2023

PR Summary

  • Addition of 'blocked_at' and 'blocked_reason' attributes to users
    This modification has added new data fields named blocked_at and blocked_reason to the users' database table. This will let us track when the user got blocked and why they were blocked.
  • Database migration for user changes
    A necessary update script has been generated to include these changes to the existing database. The file is named 20230718113720_add_blocked_at_block_reasonto_user.rb.
  • Updates to User model
    The User data model has been extended with these two new attributes: blocked_at and blocked_reason. This enables our system to recognize and handle these new pieces of user information.
  • Added a method to check the user's active status
    A method called active_for_authentication? was added to the User model. It will determine if a user's account is active or blocked based on the new attributes.
  • Database schema updated
    The general blueprint of our database, the db/schema.rb file, is updated with these changes. It now illustrates the additions of blocked_at and blocked_reason.
  • New scenario for user sign-in testing
    Added a new test case in sign_up_spec.rb to check that a blocked, yet confirmed, user cannot sign into the system. This will ensure that our block functionality works as intended.

@LeSim LeSim enabled auto-merge July 18, 2023 12:12
@LeSim LeSim added this pull request to the merge queue Jul 18, 2023
Merged via the queue into main with commit 361f6e6 Jul 18, 2023
@LeSim LeSim deleted the block_user branch July 18, 2023 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants