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

[Feature] Admin approval #1232

Merged
merged 4 commits into from
Nov 24, 2024
Merged

Conversation

BentiGorlich
Copy link
Member

@BentiGorlich BentiGorlich commented Nov 19, 2024

  • admins can now decide to turn a mandatory approval on in the admin settings
  • a new tab will appear labelled "Applications" where new users that are not yet approved will appear
  • when the setting is enabled a new input will be displayed on the register page: "Application Text"
  • This behavior will be apparent on registering with an added flash message informing the user about it
  • Users will receive an email when they are accepted or rejected
  • when a user is not approved they cannot log in and an appropriate message will be displayed
  • the register site now redirects to the login page instead of the front page

Tasks

  • API implemented
  • Updated Docs
  • Included Images
  • Implemented mails
  • Refine email texts (I am definitely not qualified to do that)
  • Refine Admin application page

Pictures

Register Page

Register page
After registration

Admin application view

Admin application view

Mails

Approved email

Rejected email

Closing #722

@BentiGorlich BentiGorlich added enhancement New feature or request backend Backend related issues and pull requests labels Nov 19, 2024
@BentiGorlich BentiGorlich added this to the v1.8.0 milestone Nov 19, 2024
@BentiGorlich BentiGorlich self-assigned this Nov 19, 2024
@BentiGorlich BentiGorlich force-pushed the new/users-admin-approval branch from 0440e1f to 230d2d3 Compare November 19, 2024 22:00
@BentiGorlich BentiGorlich force-pushed the new/users-admin-approval branch from 230d2d3 to e644d0d Compare November 19, 2024 22:22
@melroy89
Copy link
Member

Nice!

@BentiGorlich
Copy link
Member Author

Do we have someone that is good in phrasing user facing stuff like the emails? @jwr1 or @TheVillageGuy maybe?

src/Entity/User.php Outdated Show resolved Hide resolved
@melroy89
Copy link
Member

melroy89 commented Nov 20, 2024

image

The "One last step" in the message now contradict each other 😆 . Yes you still need to use the activation link, but if admin approval is required, this isn't the last step.. you than still need to wait.

@BentiGorlich
Copy link
Member Author

The "One last step" in the message now contradict each other 😆 . Yes you still need to use the activation link, but if admin approval is required, this isn't the last step.. you than still need to wait.

Yeah I know 😅, but I didn't know how to solve this. I didn't really want to mess up the existing translations... But if you think that it is necessary I will split the existing one up, so that both messages can be merged

@BentiGorlich BentiGorlich linked an issue Nov 22, 2024 that may be closed by this pull request
BentiGorlich and others added 3 commits November 24, 2024 12:14
- admins can now decide to turn a mandatory approval on in the admin settings
- a new tab will appear labelled "Applications" where new users that are not yet approved will appear
- when the setting is enabled a new input will be displayed on the register page: "Application Text"
- This behaviour will be apparent on registering with an added flash message informing the user about it
- Users will receive an email when they are accepted or rejected
- when a user is not approved they cannot log in and an appropriate message will be displayed
- the register site now redirects to the login page instead of the front page
@BentiGorlich BentiGorlich force-pushed the new/users-admin-approval branch from 8ed5d6a to 4868912 Compare November 24, 2024 11:14
- Move from `isApproved` and `isRejected` to an enum model
- update twig to v3.15 to use the new `enum` method
- improve the signup_requests page
- fix the `SettingsManager` handling of the new variable
- fix the `UserCommand` not taking an application text
@BentiGorlich
Copy link
Member Author

@melroy89 are you fine with the 2 flash messages upon signup? I think it is fine this way, but I can invest the work to fix it if you want to

@melroy89
Copy link
Member

@melroy89 are you fine with the 2 flash messages upon signup? I think it is fine this way, but I can invest the work to fix it if you want to

It's fine for me.

@melroy89 melroy89 self-requested a review November 24, 2024 17:43
@BentiGorlich BentiGorlich merged commit c1aba40 into dev/new_features Nov 24, 2024
5 checks passed
@BentiGorlich BentiGorlich deleted the new/users-admin-approval branch November 24, 2024 18:01
BentiGorlich added a commit that referenced this pull request Dec 8, 2024
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Dec 10, 2024
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 7, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 7, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 7, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 7, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 13, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
BentiGorlich added a commit that referenced this pull request Jan 14, 2025
Co-authored-by: TheVillageGuy <47496248+TheVillageGuy@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Backend related issues and pull requests enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add option for new accounts to require admin approval
3 participants