2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-15 03:25:42 +00:00
This commit is contained in:
Oliver Walters
2020-02-03 21:28:47 +11:00
parent d059aff4f8
commit 41336bd549
5 changed files with 214 additions and 79 deletions

View File

@ -1,6 +1,8 @@
from django.apps import AppConfig
from django.db.utils import OperationalError
import os
import yaml
@ -18,7 +20,10 @@ class CommonConfig(AppConfig):
from .models import InvenTreeSetting
with open('./common/kvp.yaml') as kvp:
here = os.path.dirname(os.path.abspath(__file__))
settings_file = os.path.join(here, 'kvp.yaml')
with open(settings_file) as kvp:
values = yaml.safe_load(kvp)
for value in values: