From 6a820442f5714f3fee8e48e23cf2dd2c16d575a4 Mon Sep 17 00:00:00 2001 From: rimu <3310831+rimu@users.noreply.github.com> Date: Sat, 3 Aug 2024 21:31:10 +1200 Subject: [PATCH] handle user names with mixed upper and lower case letters. fixes #272 --- app/auth/routes.py | 2 +- app/templates/admin/users.html | 20 ++++++++++---------- app/templates/base.html | 2 +- app/templates/user/_user_nav.html | 2 +- app/templates/user/filters.html | 2 +- app/templates/user/notifications.html | 2 +- app/templates/user/show_profile.html | 2 +- 7 files changed, 16 insertions(+), 16 deletions(-) diff --git a/app/auth/routes.py b/app/auth/routes.py index 73075105..2d52a683 100644 --- a/app/auth/routes.py +++ b/app/auth/routes.py @@ -136,7 +136,7 @@ def register(): application = UserRegistration(user_id=user.id, answer=form.question.data) db.session.add(application) for admin in Site.admins(): - notify = Notification(title='New registration', url='/admin/approve_registrations', user_id=admin.id, + notify = Notification(title='New registration', url=f'/admin/approve_registrations?account={user.id}', user_id=admin.id, author_id=user.id) admin.unread_notifications += 1 db.session.add(notify) diff --git a/app/templates/admin/users.html b/app/templates/admin/users.html index e962a224..12bfbc99 100644 --- a/app/templates/admin/users.html +++ b/app/templates/admin/users.html @@ -19,16 +19,16 @@
Name | -Local/Remote | -Seen | -Attitude | -Rep | -Banned | -Reports | -IP | -Source | -Actions | +{{ _('Name') }} | +{{ _('Local/Remote') }} | +{{ _('Seen') }} | +{{ _('Attitude') }} | +{{ _('Reputation') }} | +{{ _('Banned') }} | +{{ _('Reports') }} | +{{ _('IP and country code') }} | +{{ _('Source') }} | +{{ _('Actions') }} |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{ user.display_name() }} | +{{ user.display_name() }} | {{ _('Unblock') }} |