Add UMAP_CUSTOM_TEMPLATES and UMAP_CUSTOM_STATICS
This commit is contained in:
parent
c0f6fcb448
commit
81919ce0f7
2 changed files with 8 additions and 4 deletions
|
@ -35,8 +35,14 @@ else:
|
|||
print('Loaded local config from', path)
|
||||
for key in dir(d):
|
||||
if key.isupper():
|
||||
value = getattr(d, key)
|
||||
if key.startswith('LEAFLET_STORAGE'):
|
||||
# Retrocompat pre 1.0, remove me in 1.1.
|
||||
globals()['UMAP' + key[15:]] = getattr(d, key)
|
||||
globals()['UMAP' + key[15:]] = value
|
||||
elif key == 'UMAP_CUSTOM_TEMPLATES':
|
||||
globals()['TEMPLATES'][0]['DIRS'].insert(0, value)
|
||||
elif key == 'UMAP_CUSTOM_STATICS':
|
||||
globals()['STATICFILES_DIRS'].insert(0, value)
|
||||
print(globals()['STATICFILES_DIRS'])
|
||||
else:
|
||||
globals()[key] = getattr(d, key)
|
||||
globals()[key] = value
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
# -*- coding:utf-8 -*-
|
||||
|
||||
"""Base settings shared by all environments"""
|
||||
# Import global settings to make it easier to extend settings.
|
||||
from django.conf.global_settings import * # pylint: disable=W0614,W0401
|
||||
|
|
Loading…
Reference in a new issue