Browse Source

added links for DATAPROTECTION and such ...

master
Benni Baermann 4 years ago
parent
commit
188d39deb9
2 changed files with 11 additions and 1 deletions
  1. +6
    -1
      input/forms.py
  2. +5
    -0
      input/settings.py

+ 6
- 1
input/forms.py View File

@ -1,8 +1,11 @@
from django.db import models from django.db import models
from django.forms import ModelForm, DateField, ChoiceField, RadioSelect, BooleanField from django.forms import ModelForm, DateField, ChoiceField, RadioSelect, BooleanField
from django.contrib.admin.widgets import AdminDateWidget from django.contrib.admin.widgets import AdminDateWidget
from django.utils.html import format_html
from .models import Project, Volunteer, IFG, Library, TYPE_CHOICES from .models import Project, Volunteer, IFG, Library, TYPE_CHOICES
from .settings import DATAPROTECTION, FOERDERRICHTLINIEN
class ProjectForm(ModelForm): class ProjectForm(ModelForm):
@ -18,7 +21,9 @@ class VolunteerForm(ModelForm):
choice = ChoiceField(choices=TYPE_CHOICES, widget=RadioSelect, choice = ChoiceField(choices=TYPE_CHOICES, widget=RadioSelect,
label='Was möchtest Du beantragen?') label='Was möchtest Du beantragen?')
check = BooleanField(required=True, label='Ich stimme den Datenschutzbestimmungen und den Förderrichtlinen zu')
check = BooleanField(required=True,
label=format_html("Ich stimme den <a href='{}'>Datenschutzbestimmungen</a> und den <a href='{}'>Förderrichtlinen</a> zu",
DATAPROTECTION, FOERDERRICHTLINIEN))
class Meta: class Meta:
model = Volunteer model = Volunteer

+ 5
- 0
input/settings.py View File

@ -3,3 +3,8 @@ IF_EMAIL = 'if-test@wikimedia.de'
# prefix for urls # prefix for urls
URLPREFIX = 'http://127.0.0.1:8000' URLPREFIX = 'http://127.0.0.1:8000'
# some links
DATAPROTECTION = "https://www.wikimedia.de/datenschutz/"
FOERDERRICHTLINIEN = "https://de.wikipedia.org/wiki/Wikipedia:Wikimedia_Deutschland/F%C3%B6rderrichtlinien"
NUTZUNGSBEDINGUNGEN = 'TODO'

Loading…
Cancel
Save