summaryrefslogtreecommitdiffstats
path: root/databaseReset.py
diff options
context:
space:
mode:
authorPhilip Sargent <philip.sargent@gmail.com>2022-12-09 23:45:07 +0000
committerPhilip Sargent <philip.sargent@gmail.com>2022-12-09 23:45:07 +0000
commitcabcada0b8738366bce33173ad1b3d376e8fb73c (patch)
tree0ed741af5c1c1d1b67433f9dc49fd8c6740a4a8a /databaseReset.py
parent17b2b7b89c2ce34471251a64a1f7c9e416a1c869 (diff)
downloadtroggle-cabcada0b8738366bce33173ad1b3d376e8fb73c.tar.gz
troggle-cabcada0b8738366bce33173ad1b3d376e8fb73c.tar.bz2
troggle-cabcada0b8738366bce33173ad1b3d376e8fb73c.zip
2003 logbook export/re-import as now HTML format
Diffstat (limited to 'databaseReset.py')
-rw-r--r--databaseReset.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/databaseReset.py b/databaseReset.py
index 630d3c6..db7a781 100644
--- a/databaseReset.py
+++ b/databaseReset.py
@@ -47,7 +47,7 @@ from django.db import transaction
from troggle.core.utils import get_process_memory
from troggle.core.models.caves import Cave, Entrance
from troggle.parsers.imports import import_caves, import_people, import_surveyscans, \
- import_logbooks, import_QMs, import_survex, import_loadpos, import_drawingsfiles
+ import_logbooks, import_logbook, import_QMs, import_survex, import_loadpos, import_drawingsfiles
if os.geteuid() == 0:
# This protects the server from having the wrong file permissions written on logs and caches
@@ -343,7 +343,8 @@ def usage():
drawings - read in the Tunnel & Therion files - which scans the survey scans too
survex - read in the survex files - all the survex blocks and entrances x/y/z
- dumplogbooks - Not used. write out autologbooks (not working?)
+ dumplogbooks - Not used. write out autologbooks (not working? use http://localhost:8000/controlpanel )
+ logbook - read a single logbook. Defautl set in python code
and [runlabel] is an optional string identifying this run of the script
in the stored profiling data 'import-profile.json'
@@ -394,6 +395,8 @@ if __name__ == "__main__":
jq.enq("caves",import_caves)
elif "logbooks" in sys.argv:
jq.enq("logbooks",import_logbooks)
+ elif "logbook" in sys.argv:
+ jq.enq("logbooks",import_logbook) # default year set in imports.py
elif "people" in sys.argv:
jq.enq("people",import_people)
elif "QMs" in sys.argv: