Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
thalia
concrexit
Commits
599eee00
Unverified
Commit
599eee00
authored
Jan 24, 2017
by
Thom Wiggers
📐
Browse files
Validations should be a list
This breaks Django2 otherwise
parent
2517eafc
Changes
3
Hide whitespace changes
Inline
Side-by-side
website/activemembers/migrations/0016_auto_20170124_1431.py
0 → 100644
View file @
599eee00
# -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-01-24 13:31
from
__future__
import
unicode_literals
import
django.core.validators
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'activemembers'
,
'0015_datamigration_lifelong'
),
]
operations
=
[
migrations
.
AlterField
(
model_name
=
'mentorship'
,
name
=
'year'
,
field
=
models
.
IntegerField
(
validators
=
[
django
.
core
.
validators
.
MinValueValidator
(
1990
)]),
),
]
website/activemembers/migrations/0018_merge_20170125_1452.py
0 → 100644
View file @
599eee00
# -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-01-25 13:52
from
__future__
import
unicode_literals
from
django.db
import
migrations
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'activemembers'
,
'0016_auto_20170124_1431'
),
(
'activemembers'
,
'0017_auto_20170121_1105'
),
]
operations
=
[
]
website/activemembers/models.py
View file @
599eee00
...
...
@@ -284,7 +284,7 @@ class Mentorship(models.Model):
on_delete
=
models
.
CASCADE
,
verbose_name
=
_
(
'Member'
),
)
year
=
models
.
IntegerField
(
validators
=
MinValueValidator
(
1990
))
year
=
models
.
IntegerField
(
validators
=
[
MinValueValidator
(
1990
)
]
)
def
__str__
(
self
):
return
_
(
"{name} mentor in {year}"
).
format
(
name
=
self
.
member
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment