2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2026-02-08 12:51:11 +00:00

static files redone

This commit is contained in:
Philip Sargent
2020-06-18 21:50:16 +01:00
parent bd6490631f
commit d9c6986a89
25 changed files with 122 additions and 151 deletions

View File

@@ -115,19 +115,19 @@ environment utility
Patching the django installation
--------------------------------
Since django 1.7 out of update-support, and since python3 has progressed against
the 2015 version that django1.7 is expecting, you need to patch the django
Since django 1.10 is out of update-support, and since python3 has progressed against
the 2015 version that django is expecting, you need to patch the django
installation after installing. In the troggle folder you will find
django-patch/html_parser.py
copy this over the installed version of django on your machine:
$ cd troggle
$ sudo cp django-patch/html_parser.py /usr/local/lib/python3.8/dist-packages/django/utils/
$ sudo cp django-patch/html_parser.py /usr/local/lib/python3.7/dist-packages/django/utils/
or
$ cp django-patch/html_parser.py ~/.local/lib/python3.8/site-packages/django/utils/
$ cp django-patch/html_parser.py ~/.local/lib/python3.7/site-packages/django/utils/
if you didn't use sudo when installing everything using pip.
or if you are using a venv, and you are using python3.7 in it, then
or if you are using a venv, then
$ cd <venv directory>/troggle
$ cp django-patch/html_parser.py lib/python3.7/site-packages/django/utils/html_parser.py
@@ -169,7 +169,7 @@ python manage.py check -v 3 --deploy
which will give security warnings for deployment.
python manage.py check -Wall
Goives warnings of deprecated Django which should be fixed asap.
Gives warnings of deprecated Django which should be fixed asap.
Registering troggle as a django application
-------------------------------------------
@@ -201,18 +201,13 @@ then the settings registration of troggle with django is incomplete.
Delete all your cached .pyc files and try again.
You probably have a mistake in your settings.py or localsettings.py files.
Django 1.9.13
-------------
Works fine, but creating a new,clean database does nopt happen automatically
when you run databaseReset.py. Instead you have to do this:
python manage.py makemigrations core
python manage.py makemigrations flatpages
python manage.py migrate
python manage.py migrate core
python manage.py migrate flatpages
python databaseReset.py reset
CSS and media files
-------------------
Temporarily we are not using the STATICFILES capability but are instead
serving css files from troggle/media/.. (see urls.py) using
view_surveys.cssfilessingle
i.e.
cssfilessingle() in core/view_surveys.py
Setting up survex
-----------------