fix: use local calendar dates in demo seed
Managed validation / full (pull_request) Successful in 3m2s

This commit is contained in:
NuklearRabbit
2026-09-03 01:11:07 +02:00
parent c855253072
commit 7c4652ac49
2 changed files with 14 additions and 6 deletions
+3 -2
View File
@@ -152,6 +152,7 @@ def seed_demo_environment(user) -> None:
profile.save(update_fields=["is_active"])
now = timezone.now()
today = timezone.localdate(now)
workplace_map = {
"hybrid": JobPosting.Workplace.HYBRID,
"remote": JobPosting.Workplace.REMOTE,
@@ -254,7 +255,7 @@ def seed_demo_environment(user) -> None:
defaults={
"status": Application.Status.INTERVIEW,
"applied_at": now - timedelta(days=6),
"follow_up_date": (now + timedelta(days=2)).date(),
"follow_up_date": today + timedelta(days=2),
"contact_name": "Sofie Vandael",
"contact_email": "sofie.vandael@cloudnexus.example",
"notes": "Eerste gesprek gepland. Demo-data.",
@@ -267,7 +268,7 @@ def seed_demo_environment(user) -> None:
defaults={
"status": Application.Status.APPLIED,
"applied_at": now - timedelta(days=2),
"follow_up_date": (now + timedelta(days=5)).date(),
"follow_up_date": today + timedelta(days=5),
"notes": "Sollicitatie verstuurd. Demo-data.",
},
)