Skip to content
Snippets Groups Projects
Verified Commit 78bc4525 authored by Tom Teichler's avatar Tom Teichler :beers:
Browse files

Add verbose names to models

parent 91804534
No related branches found
No related tags found
1 merge request!43Resolve "Make Alsijil work with current core"
Pipeline #2458 passed
# Generated by Django 3.0.6 on 2020-05-11 13:19
# Generated by Django 3.0.6 on 2020-05-29 10:29
import aleksis.apps.alsijil.models
import django.contrib.postgres.fields.jsonb
......@@ -12,9 +12,9 @@ class Migration(migrations.Migration):
initial = True
dependencies = [
('core', '0001_initial'),
('chronos', '0001_initial'),
('sites', '0002_alter_domain_unique'),
('core', '0001_initial'),
]
operations = [
......@@ -29,6 +29,8 @@ class Migration(migrations.Migration):
('site', models.ForeignKey(default=1, editable=False, on_delete=django.db.models.deletion.CASCADE, to='sites.Site')),
],
options={
'verbose_name': 'Personal note filter',
'verbose_name_plural': 'Personal note filters',
'ordering': ['identifier'],
},
managers=[
......@@ -50,6 +52,8 @@ class Migration(migrations.Migration):
('site', models.ForeignKey(default=1, editable=False, on_delete=django.db.models.deletion.CASCADE, to='sites.Site')),
],
options={
'verbose_name': 'Personal note',
'verbose_name_plural': 'Personal notes',
'ordering': ['lesson_period__lesson__date_start', 'week', 'lesson_period__period__weekday', 'lesson_period__period__period', 'person__last_name', 'person__first_name'],
'unique_together': {('lesson_period', 'week', 'person')},
},
......@@ -69,6 +73,8 @@ class Migration(migrations.Migration):
('site', models.ForeignKey(default=1, editable=False, on_delete=django.db.models.deletion.CASCADE, to='sites.Site')),
],
options={
'verbose_name': 'Lesson documentation',
'verbose_name_plural': 'Lesson documentations',
'ordering': ['lesson_period__lesson__date_start', 'week', 'lesson_period__period__weekday', 'lesson_period__period__period'],
'unique_together': {('lesson_period', 'week')},
},
......
......@@ -27,6 +27,8 @@ class PersonalNote(ExtensibleModel):
remarks = models.CharField(max_length=200, blank=True)
class Meta:
verbose_name = _("Personal note")
verbose_name_plural = _("Personal notes")
unique_together = [["lesson_period", "week", "person"]]
ordering = [
"lesson_period__lesson__date_start",
......@@ -52,6 +54,8 @@ class LessonDocumentation(ExtensibleModel):
homework = models.CharField(verbose_name=_("Homework"), max_length=200, blank=True)
class Meta:
verbose_name = _("Lesson documentation")
verbose_name_plural = _("Lesson documentations")
unique_together = [["lesson_period", "week"]]
ordering = [
"lesson_period__lesson__date_start",
......@@ -74,4 +78,6 @@ class PersonalNoteFilter(ExtensibleModel):
regex = models.CharField(verbose_name=_("Match expression"), max_length=100, unique=True)
class Meta:
verbose_name = _("Personal note filter")
verbose_name_plural = _("Personal note filters")
ordering = ["identifier"]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment