mirror of
https://github.com/pacnpal/thrillwiki_django_no_react.git
synced 2026-02-05 11:45:18 -05:00
feat: Implement a new notifications application, add admin API views for dashboard metrics, introduce scheduled tasks, and update API routing and project configurations.
This commit is contained in:
@@ -66,6 +66,31 @@ app.conf.update(
|
||||
"task": "rides.check_overdue_closings",
|
||||
"schedule": 86400.0, # Daily at midnight
|
||||
},
|
||||
# ====== New scheduled tasks ======
|
||||
"process-scheduled-deletions": {
|
||||
"task": "core.process_scheduled_deletions",
|
||||
"schedule": 86400.0, # Daily
|
||||
},
|
||||
"process-closing-entities": {
|
||||
"task": "core.process_closing_entities",
|
||||
"schedule": 86400.0, # Daily
|
||||
},
|
||||
"process-expired-bans": {
|
||||
"task": "core.process_expired_bans",
|
||||
"schedule": 3600.0, # Hourly
|
||||
},
|
||||
"cleanup-orphaned-images": {
|
||||
"task": "core.cleanup_orphaned_images",
|
||||
"schedule": 604800.0, # Weekly
|
||||
},
|
||||
"cleanup-old-versions": {
|
||||
"task": "core.cleanup_old_versions",
|
||||
"schedule": 2592000.0, # Monthly (30 days)
|
||||
},
|
||||
"data-retention-cleanup": {
|
||||
"task": "core.data_retention_cleanup",
|
||||
"schedule": 86400.0, # Daily
|
||||
},
|
||||
},
|
||||
# Task result settings
|
||||
result_expires=3600, # 1 hour
|
||||
|
||||
@@ -73,8 +73,7 @@ THIRD_PARTY_APPS = [
|
||||
"rest_framework.authtoken",
|
||||
"rest_framework_simplejwt", # JWT authentication
|
||||
"rest_framework_simplejwt.token_blacklist", # JWT token blacklist
|
||||
"dj_rest_auth", # REST authentication with JWT support
|
||||
"dj_rest_auth.registration", # REST registration support
|
||||
# Note: dj_rest_auth removed - using custom auth views in apps.api.v1.auth
|
||||
"drf_spectacular", # OpenAPI 3.0 documentation
|
||||
"corsheaders", # CORS headers for API
|
||||
"pghistory", # django-pghistory
|
||||
@@ -102,6 +101,8 @@ THIRD_PARTY_APPS = [
|
||||
"django_celery_beat", # Celery beat scheduler
|
||||
"django_celery_results", # Celery result backend
|
||||
"django_extensions", # Django Extensions for enhanced development tools
|
||||
# Note: django-notifications-hq is installed but not in INSTALLED_APPS
|
||||
# to avoid app label conflict. We use a custom implementation instead.
|
||||
]
|
||||
|
||||
LOCAL_APPS = [
|
||||
@@ -117,6 +118,7 @@ LOCAL_APPS = [
|
||||
"apps.media",
|
||||
"apps.blog",
|
||||
"apps.support",
|
||||
"apps.notifications", # Notification service
|
||||
]
|
||||
|
||||
INSTALLED_APPS = DJANGO_APPS + THIRD_PARTY_APPS + LOCAL_APPS
|
||||
|
||||
@@ -34,7 +34,7 @@ ACCOUNT_LOGIN_METHODS = {"email", "username"}
|
||||
|
||||
# Email verification settings
|
||||
ACCOUNT_EMAIL_VERIFICATION = config("ACCOUNT_EMAIL_VERIFICATION", default="mandatory")
|
||||
ACCOUNT_EMAIL_REQUIRED = True
|
||||
# Note: ACCOUNT_EMAIL_REQUIRED is handled by ACCOUNT_SIGNUP_FIELDS above (email* = required)
|
||||
ACCOUNT_EMAIL_VERIFICATION_SUPPORTS_CHANGE = True
|
||||
ACCOUNT_EMAIL_VERIFICATION_SUPPORTS_RESEND = True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user