Rennomage des templatetags

This commit is contained in:
Tom Hubrecht 2021-05-29 09:22:04 +02:00
parent a9473e83ee
commit ecee55b343
11 changed files with 17 additions and 14 deletions

View file

@ -1,5 +1,5 @@
{% extends "base.html" %} {% extends "base.html" %}
{% load i18n bulma_utils %} {% load i18n string %}
{% block content %} {% block content %}

View file

@ -1,5 +1,5 @@
{% extends "base.html" %} {% extends "base.html" %}
{% load i18n static bulma_utils %} {% load i18n static string %}
{% block content %} {% block content %}

View file

@ -1,5 +1,5 @@
{% extends "base.html" %} {% extends "base.html" %}
{% load i18n static bulma_utils %} {% load i18n static string %}
{% block content %} {% block content %}

View file

@ -1,4 +1,4 @@
{% load static bulma_utils i18n %} {% load static bulma i18n %}
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>

View file

@ -1,4 +1,4 @@
{% load bulma_utils %} {% load bulma %}
<div class="field"> <div class="field">
{% if field|is_checkbox %} {% if field|is_checkbox %}

View file

@ -1,4 +1,4 @@
{% load bulma_utils i18n %} {% load i18n bulma %}
<label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}"> <label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}">
{{ field.label_tag }} {{ field.label_tag }}

View file

@ -1,4 +1,4 @@
{% load bulma_utils %} {% load bulma %}
<label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}"> <label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}">
{{ field.label_tag }} {{ field.label_tag }}

View file

@ -1,4 +1,4 @@
{% load bulma_utils %} {% load bulma %}
<label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}"> <label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}">
{{ field.label_tag }} {{ field.label_tag }}

View file

@ -1,4 +1,4 @@
{% load bulma_utils %} {% load bulma %}
<label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}"> <label class="label {% if field.field.required %}{{ form.required_css_class }}{% endif %}">
{{ field.label_tag }} {{ field.label_tag }}

View file

@ -72,8 +72,3 @@ def bulma_message_tag(tag):
return "danger" return "danger"
return tag return tag
@register.filter
def concatenate(a, b):
return str(a) + str(b)

View file

@ -0,0 +1,8 @@
from django import template
register = template.Library()
@register.filter
def concatenate(a, b):
return str(a) + str(b)