attempt to simplify wnt horribly wrong

This commit is contained in:
Philip Sargent
2020-06-06 22:51:55 +01:00
parent f8a3c8f5bc
commit fda50ed570
9 changed files with 135 additions and 88 deletions

View File

@@ -8,8 +8,8 @@ import troggle.core.models as models
import troggle.core.models_caves as models_caves
def readcaves():
# Clear the cave data issues as we are reloading
# Note: these are HTML files in the EXPOWEB repo, not from the loser repo.
models.DataIssue.objects.filter(parser='caves').delete()
area_1623 = models_caves.Area.objects.update_or_create(short_name = "1623", parent = None)
@@ -26,6 +26,7 @@ def readcaves():
def readentrance(filename):
# Note: these are HTML files in the EXPOWEB repo, not from the loser repo.
with open(os.path.join(settings.ENTRANCEDESCRIPTIONS, filename)) as f:
contents = f.read()
context = "in file %s" % filename
@@ -89,6 +90,7 @@ def readentrance(filename):
primary = False
def readcave(filename):
# Note: these are HTML files in the EXPOWEB repo, not from the loser repo.
with open(os.path.join(settings.CAVEDESCRIPTIONS, filename)) as f:
contents = f.read()
context = " in file %s" % filename