UI: Training templates fluid video layouts #104435
@ -72,8 +72,8 @@
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="https://twitter.com/BlenderStudio_" title="Follow Blender Studio on Twitter" target="_blank" class="social-icons__twitter">
|
||||
<i class="i-twitter"></i>Twitter
|
||||
<a href="https://x.com/BlenderStudio_" title="Follow Blender Studio on X" target="_blank" class="social-icons__twitter">
|
||||
<i class="i-twitter"></i>X
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
|
@ -1,32 +1,31 @@
|
||||
<nav>
|
||||
<ul class="pagination">
|
||||
|
||||
{% if page_obj.has_previous %}
|
||||
<li class="page-item page-next">
|
||||
<a href="?page=1">
|
||||
<i class="i-skip-forward d-block" style="transform: scaleX(-1)"></i>
|
||||
</a>
|
||||
{% if not page_obj.previous_page_number == 1 %}
|
||||
<li class="page-item page-first">
|
||||
<a href="?page=1">First</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
|
||||
{% for page_num in page_range %}
|
||||
{% if page_num == page_obj.number %}
|
||||
<li class="active disabled page-item">
|
||||
<a href="#">{{ page_obj.number }}</a>
|
||||
</li>
|
||||
{% else %}
|
||||
<li class="page-item">
|
||||
<a href="?page={{ page_num }}">{{page_num}}</a>
|
||||
<li class="page-item page-prev">
|
||||
<a href="?page={{ page_obj.previous_page_number }}"><i class="i-chevron-left"></i> Previous</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
|
||||
<li class="page-item page-current">
|
||||
<a href="#">Page {{ page_obj.number }} of {{ page_obj.paginator.num_pages }}</a>
|
||||
</li>
|
||||
|
||||
{% if page_obj.has_next %}
|
||||
<li class="page-item page-prev">
|
||||
<a href="?page={{ page_obj.paginator.num_pages }}">
|
||||
<i class="i-skip-forward"></i>
|
||||
</a>
|
||||
<li class="page-item page-next">
|
||||
<a href="?page={{ page_obj.next_page_number }}">Next <i class="i-chevron-right"></i></a>
|
||||
</li>
|
||||
|
||||
{% if not page_obj.next_page_number == page_obj.paginator.num_pages %}
|
||||
<li class="page-item page-last">
|
||||
<a href="?page={{ page_obj.paginator.num_pages }}">Last</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</ul>
|
||||
</nav>
|
@ -1 +1 @@
|
||||
Subproject commit 23fdb84a86ac1ada1eb06152a76f655307a9e82f
|
||||
Subproject commit 666ff483b500b3b417c617596ddeebe58afb718d
|
@ -81,7 +81,6 @@ pypdf==4.2.0
|
||||
pypng==0.20220715.0
|
||||
python-bidi==0.4.2
|
||||
python-dateutil==2.8.2
|
||||
python-dotenv==0.21.0
|
||||
python-monkey-business==1.0.0
|
||||
python-stdnum==1.18
|
||||
pytz==2022.7.1
|
||||
|
@ -34,6 +34,7 @@ pycodestyle==2.7.0
|
||||
pydocstyle==6.1.1
|
||||
pyflakes==2.3.1
|
||||
Pygments==2.13.0
|
||||
python-dotenv==0.21.0
|
||||
responses==0.25.3
|
||||
snowballstemmer==2.2.0
|
||||
tblib==3.0.0
|
||||
|
@ -9,7 +9,6 @@ import os
|
||||
import pathlib
|
||||
import sys
|
||||
|
||||
from dotenv import load_dotenv
|
||||
import braintree
|
||||
import dj_database_url
|
||||
import meilisearch
|
||||
@ -17,10 +16,14 @@ import meilisearch
|
||||
import common.upload_paths
|
||||
|
||||
|
||||
# Load variables from .env, if available
|
||||
path = os.path.dirname(os.path.abspath(__file__)) + '/../.env'
|
||||
if os.path.isfile(path):
|
||||
try:
|
||||
from dotenv import load_dotenv
|
||||
# Load variables from .env, if available
|
||||
path = os.path.dirname(os.path.abspath(__file__)) + '/../.env'
|
||||
if os.path.isfile(path):
|
||||
load_dotenv(path)
|
||||
except ImportError: # This is expected: there should be no python-dotenv in production
|
||||
pass
|
||||
|
||||
|
||||
def _get(name: str, default=None, coerse_to=None):
|
||||
@ -319,6 +322,11 @@ LOGGING = {
|
||||
'formatter': 'default', # Set to 'verbose' in production
|
||||
'stream': 'ext://sys.stderr',
|
||||
},
|
||||
'mail_admins': {
|
||||
'level': 'ERROR',
|
||||
'class': 'django.utils.log.AdminEmailHandler',
|
||||
'include_html': True,
|
||||
},
|
||||
},
|
||||
'loggers': {
|
||||
'asyncio': {'level': 'WARNING'},
|
||||
@ -328,7 +336,7 @@ LOGGING = {
|
||||
'static_assets': {'level': 'DEBUG'},
|
||||
'looper': {'level': 'DEBUG'},
|
||||
},
|
||||
'root': {'level': 'WARNING', 'handlers': ['console']},
|
||||
'root': {'level': 'WARNING', 'handlers': ['console', 'mail_admins']},
|
||||
}
|
||||
|
||||
SITE_ID = 1
|
||||
@ -512,8 +520,14 @@ GATEWAYS = {
|
||||
},
|
||||
}
|
||||
|
||||
# Optional Sentry configuration
|
||||
if os.environ.get('ADMINS') is not None:
|
||||
# Expects the following format:
|
||||
# ADMINS='J Doe: jane@example.com, John Dee: john@example.com'
|
||||
ADMINS = [[_.strip() for _ in adm.split(':')] for adm in os.environ.get('ADMINS').split(',')]
|
||||
EMAIL_SUBJECT_PREFIX = f'[{ALLOWED_HOSTS[0]}]'
|
||||
SERVER_EMAIL = f'django@{ALLOWED_HOSTS[0]}'
|
||||
|
||||
# Optional Sentry configuration
|
||||
SENTRY_DSN = _get('SENTRY_DSN')
|
||||
if SENTRY_DSN:
|
||||
import sentry_sdk
|
||||
|
@ -1,5 +1,5 @@
|
||||
"""
|
||||
WSGI config for training project.
|
||||
WSGI config for Blender Studio project.
|
||||
|
||||
It exposes the WSGI callable as a module-level variable named ``application``.
|
||||
|
||||
@ -8,18 +8,9 @@ https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
|
||||
"""
|
||||
|
||||
import os
|
||||
import os.path
|
||||
import pathlib
|
||||
|
||||
from django.core.wsgi import get_wsgi_application
|
||||
from dotenv import load_dotenv
|
||||
|
||||
BASE_DIR = pathlib.Path(__file__).absolute().parent.parent
|
||||
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'studio.settings')
|
||||
|
||||
# Load variables from .env, if available
|
||||
path = BASE_DIR / '.env'
|
||||
if os.path.isfile(path):
|
||||
load_dotenv(path)
|
||||
|
||||
application = get_wsgi_application()
|
||||
|
Loading…
Reference in New Issue
Block a user