1 from datetime
import date
2 from .models
import Event
8 # We intentionally don't put /about/eventarchive/ in the sitemap,
9 # since we don't care about getting it indexed.
10 # We only show events in the future, so only index events in the
13 for n
in Event
.objects
.filter(approved
=True, enddate__gt
=now
):
14 yearsold
= (now
- n
.startdate
).days
/ 365
17 yield ('about/event/%s/' % n
.id,
18 0.5 - (yearsold
/ 10.0))