Show all events to logged-in users
This commit is contained in:
parent
8d3805a922
commit
c3f9b26aea
1 changed files with 3 additions and 3 deletions
|
@ -55,9 +55,9 @@ def calendar(request, pYear, pMonth):
|
|||
lMonth = int(pMonth)
|
||||
lCalendarFromMonth = datetime(lYear, lMonth, 1)
|
||||
lCalendarToMonth = datetime(lYear, lMonth, monthrange(lYear, lMonth)[1])
|
||||
lEvents = Event.objects.filter(date__gte=lCalendarFromMonth,
|
||||
date__lte=lCalendarToMonth,
|
||||
calendrier="F")
|
||||
lEvents = Event.objects.filter(
|
||||
date__gte=lCalendarFromMonth, date__lte=lCalendarToMonth
|
||||
)
|
||||
if request.user.is_authenticated:
|
||||
lEvents = Event.objects.filter(date__gte=lCalendarFromMonth,
|
||||
date__lte=lCalendarToMonth)
|
||||
|
|
Loading…
Reference in a new issue