2026.06.05 frontend javítgatás és új belépési logika megvalósítva

This commit is contained in:
Roo
2026-06-05 05:46:04 +00:00
parent 59a30ac428
commit 18524a08f2
38 changed files with 3967 additions and 1028 deletions

View File

@@ -81,7 +81,7 @@ class ConfigService:
Returns:
A talált érték (a megfelelő típusban) vagy a default.
"""
from sqlalchemy import select, and_, cast, String
from sqlalchemy import select, and_, cast, String, Text
try:
# Convert scope_level to string for comparison - handle both Enum and string
@@ -91,12 +91,12 @@ class ConfigService:
scope_str = str(scope_level)
# Build query with case-insensitive comparison for scope_level
# Use ilike or lower() for case-insensitive comparison since enum values might have inconsistent casing
# Use cast to Text (not String) to avoid asyncpg enum codec cache issues
from sqlalchemy import func
query = select(SystemParameter).where(
and_(
SystemParameter.key == key,
func.lower(cast(SystemParameter.scope_level, String)) == scope_str.lower(),
func.lower(cast(SystemParameter.scope_level, Text)) == scope_str.lower(),
SystemParameter.is_active == True
)
)