Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import os
- from datetime import timedelta
- DATABASES = {
- 'default': {
- 'ENGINE': os.environ.get('DATABASE_ENGINE', 'django.db.backends.postgresql'),
- 'NAME': os.environ.get('DATABASE_NAME', 'ukg'),
- 'USER': os.environ.get('DATABASE_USER', ''),
- 'PASSWORD': os.environ.get('DATABASE_PASSWORD', ''),
- 'HOST': os.environ.get('DATABASE_HOST', 'localhost'),
- 'PORT': os.environ.get('DATABASE_PORT', '5432'),
- 'ATOMIC_REQUESTS': os.environ.get('DATABASE_ATOMIC_REQUESTS', True),
- }
- }
- COMMISSION_NUMBERING_PATTERN = os.environ.get(
- 'COMMISSION_NUMBERING_PATTERN',
- "{partner.number}-{date.yyyy}-{date.mm}"
- )
- # POLICY_NUMBERING_PATTERN = 'TIGER-<d><Y><y><m>-<n>-<bp><p>'
- # QUOTATION_NUMBERING_PATTERN = 'QOT-<d><y>'
- POLICY_NUMBERING_PATTERN = "WPP/{number:06d}/{policy.current_version.headers_dict[source]}"
- QUOTATION_NUMBERING_PATTERN = "WPQ/{number:06d}/{policy.current_version.headers_dict[source]}"
- DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage'
- PRIVATE_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage'
- DEFAULT_FROM_EMAIL = 'noreply@tigerlab.com'
- EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
- EMAIL_HOST = 'smtp.gmail.com'
- EMAIL_HOST_USER = 'noreply@tigerlab.com'
- # EMAIL_HOST_PASSWORD = 'I2go2018!'
- EMAIL_HOST_PASSWORD = 'disabled'
- EMAIL_PORT = 587
- EMAIL_USE_TLS = True
- JWT_AUTH = {
- # how long the original token is valid for
- 'JWT_EXPIRATION_DELTA': timedelta(days=7),
- # allow refreshing of tokens
- 'JWT_ALLOW_REFRESH': True,
- # this is the maximum time AFTER the token was issued that
- # it can be refreshed. exprired tokens can't be refreshed.
- 'JWT_REFRESH_EXPIRATION_DELTA': timedelta(days=7),
- }
- INSURANCE_DIR = os.path.dirname(os.path.abspath(__file__))
- SRC_DIR = os.path.dirname(INSURANCE_DIR)
- ###############################################################################
- template_dirs = [
- os.path.join(SRC_DIR, 'templates'),
- ]
- CLIENT_TEMPLATE = 'purbeck'
- # CLIENT_TEMPLATE = 'asokamas'
- CLIENT_TEMPLATE = 'peliwica'
- if CLIENT_TEMPLATE:
- CLIENT_TEMPLATE_PATH = 'template_overrides/templates/clients/{client}'.format(
- client=CLIENT_TEMPLATE,
- )
- template_dirs.insert(
- 0,
- os.path.join(SRC_DIR, CLIENT_TEMPLATE_PATH)
- )
- TEMPLATES = [
- {
- 'BACKEND': 'django.template.backends.django.DjangoTemplates',
- 'DIRS': template_dirs,
- 'OPTIONS': {
- 'context_processors': [
- 'django.template.context_processors.debug',
- 'django.template.context_processors.request',
- 'django.contrib.auth.context_processors.auth',
- 'django.contrib.messages.context_processors.messages',
- 'core.context_processors.settings',
- # 'permissions.context_processors.navigations',
- ],
- 'loaders': [
- 'django.template.loaders.filesystem.Loader',
- 'django.template.loaders.app_directories.Loader',
- ],
- },
- },
- ]
- CUSTOM_TEMPLATE_FOLDER = os.environ.get('CUSTOM_TEMPLATE_FOLDER', None),
- if CUSTOM_TEMPLATE_FOLDER:
- TEMPLATES[0]['DIRS'] += (CUSTOM_TEMPLATE_FOLDER, )
- INSTALLED_WIZARDS = [
- {'text': 'Travel', 'icon': 'plane', 'url': 'dashboards:wizards:travel:index'},
- {'text': 'Motor', 'icon': 'car', 'url': 'dashboards:wizards:motor:index'},
- # {'text': 'Ktipp', 'icon': 'suitcase', 'url': 'dashboards:wizards:ktipp:index'},
- {'text': 'Personal Guarantee', 'icon': 'suitcase', 'url': 'dashboards:wizards:purbeck:index'},
- {'text': 'Travel', 'icon': 'plane', 'url': 'dashboards:wizards:asokamas:index'},
- {'text': 'Travel', 'icon': 'plane', 'url': 'dashboards:wizards:buana:index'},
- {'text': 'Peliwica Insurance', 'icon': 'suitcase', 'url': 'dashboards:wizards:peliwica:index'},
- ]
- EXTERNAL_URL = {
- 'purbeck': {
- 'csp': 'https://purbeck-hotfix.i2go.io',
- 'rating': 'https://purbeck-rating-hotfix.i2go.io',
- },
- }
- ENABLE_REFERRAL = True
- AGENT_REFERRAL_LINK = os.environ.get('AGENT_REFERRAL_LINK', 'https://purbeck-hotfix.i2go.io?rid=')
- ###############################################################################
- SHOW_JSON_AS_DICTIONARY = False
- ###############################################################################
- # PAYMENT SETTINGS
- ###############################################################################
- PAYMENT = {
- 'STRIPE': {
- 'SECRET_KEY': 'sk_test_5yF1z4rR2yq9wonwNV2mbQup',
- 'PUBLISHABLE_KEY': 'pk_test_UM42rC1bInNuLnMIArc65HkO',
- },
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement