mirror of https://gitlab.federez.net/re2o/re2o
Browse Source
A CDN can be used. Other locations than the debian ones can be used for staticfiles. python3 manage.py runserver is now functionnal Configuration need to be changed to have re2o2.9 behaviorfix_mandate_history
5 changed files with 58 additions and 13 deletions
@ -0,0 +1,20 @@ |
|||
""" |
|||
Templatetags for fontawesome |
|||
""" |
|||
from django import template |
|||
from django.conf import settings |
|||
from django.templatetags.static import static |
|||
|
|||
register = template.Library() |
|||
|
|||
@register.simple_tag |
|||
def font_awesome_url(): |
|||
"""Return the font awesome url depending on the use of a CDN. |
|||
|
|||
Returns: |
|||
string: url of the font-awesome css file |
|||
""" |
|||
if settings.USE_CDN: |
|||
return "https://pro.fontawesome.com/releases/v5.10.0/css/all.css" |
|||
else: |
|||
return static("css/font-awesome.min.css") |
|||
Loading…
Reference in new issue