blob: aaf12b7c8339b5ebd9cd76119c96835414ed04a6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
from datetime import date
from models import DocPage
from core.models import Version
def get_struct():
now = date.today()
currentversion = Version.objects.get(current=True)
for d in DocPage.objects.all():
yield ('docs/%s/static/%s' % (d.version, d.file),
None)
#FIXME ^ do something smart with priorities on older
#versions
if d.version == currentversion.tree:
yield ('docs/current/static/%s' % d.file,
1.0)
|