2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2024-11-22 07:11:52 +00:00

Fix up parser paths so everything is found

This commit is contained in:
expo 2012-08-05 00:26:05 +02:00
parent 833ddeef8b
commit 0c20ef2a04
2 changed files with 3 additions and 2 deletions

View File

@ -50,7 +50,8 @@ def flatpage(request, path):
return render_with_context(request, 'pagenotfound.html', {'path': path})
else:
try:
o = open(os.path.normpath(settings.EXPOWEB + path), "rb")
filetobeopened = os.path.normpath(settings.EXPOWEB + path)
o = open(filetobeopened, "rb")
except IOError:
return render_with_context(request, 'pagenotfound.html', {'path': path})
if path.endswith(".htm") or path.endswith(".html"):

View File

@ -89,7 +89,7 @@ def listdir(*directories):
# add survey scans
def parseSurveyScans(year, logfile=None):
# yearFileList = listdir(year.year)
yearPath=os.path.join(settings.SURVEY_SCANS, "years", year.year)
yearPath=os.path.join(settings.SURVEY_SCANS, year.year)
yearFileList=os.listdir(yearPath)
print yearFileList
for surveyFolder in yearFileList: