This commit is contained in:
@@ -4,9 +4,18 @@ from typing import Any
|
||||
|
||||
from django.http import HttpRequest
|
||||
|
||||
from apps.profiles.models import SearchProfile
|
||||
|
||||
|
||||
def navigation_context(request: HttpRequest) -> dict[str, Any]:
|
||||
return {
|
||||
context = {
|
||||
"app_name": "VacatureRadar",
|
||||
"app_version": "0.2.1",
|
||||
"app_version": "0.2.2",
|
||||
}
|
||||
if request.user.is_authenticated:
|
||||
context["navigation_profile"] = (
|
||||
SearchProfile.objects.filter(user=request.user, is_active=True)
|
||||
.only("id", "name")
|
||||
.first()
|
||||
)
|
||||
return context
|
||||
|
||||
Reference in New Issue
Block a user