small imprv

This commit is contained in:
andis
2017-02-02 09:38:38 +01:00
parent c3523a3ba7
commit 8a6df0e4bf
2 changed files with 4 additions and 3 deletions

View File

@@ -78,8 +78,9 @@ def post(name='index'):
spi=[] spi=[]
if not page is None: if not page is None:
page = page_defaults(page,is_index,path) page_defaults(page,is_index,path)
return render_template(page["template"], ld=ld, post=page, sp=sp, spi=spi, path=path) app.logger.info("Render Template"+page["template"] +"for "+path)
return render_template(page["template"], ld=ld, post=page, sp=sp, spi=spi, pth=path)
if os.path.exists('{}/{}'.format(FLATPAGES_ROOT,path)): if os.path.exists('{}/{}'.format(FLATPAGES_ROOT,path)):
return send_from_directory(FLATPAGES_ROOT,path) return send_from_directory(FLATPAGES_ROOT,path)

View File

@@ -31,7 +31,7 @@ Files:
<ul> <ul>
{% for d in ld %} {% for d in ld %}
<li> <li>
<a href="/{{path}}/{{d}}">{{d}} </a> <a href="/{{pth}}/{{d}}">{{d}} </a>
</li> </li>
{% endfor %} {% endfor %}
</ul> </ul>