forked from mirrors/bookwyrm
Limit length on list item note
This commit is contained in:
parent
a651352b8b
commit
d0a4c78d02
2 changed files with 22 additions and 1 deletions
21
bookwyrm/migrations/0130_alter_listitem_notes.py
Normal file
21
bookwyrm/migrations/0130_alter_listitem_notes.py
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
# Generated by Django 3.2.10 on 2022-01-24 20:01
|
||||||
|
|
||||||
|
import bookwyrm.models.fields
|
||||||
|
from django.db import migrations
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
("bookwyrm", "0129_auto_20220117_1716"),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name="listitem",
|
||||||
|
name="notes",
|
||||||
|
field=bookwyrm.models.fields.TextField(
|
||||||
|
blank=True, max_length=300, null=True
|
||||||
|
),
|
||||||
|
),
|
||||||
|
]
|
|
@ -125,7 +125,7 @@ class ListItem(CollectionItemMixin, BookWyrmModel):
|
||||||
user = fields.ForeignKey(
|
user = fields.ForeignKey(
|
||||||
"User", on_delete=models.PROTECT, activitypub_field="actor"
|
"User", on_delete=models.PROTECT, activitypub_field="actor"
|
||||||
)
|
)
|
||||||
notes = fields.TextField(blank=True, null=True)
|
notes = fields.TextField(blank=True, null=True, max_length=300)
|
||||||
approved = models.BooleanField(default=True)
|
approved = models.BooleanField(default=True)
|
||||||
order = fields.IntegerField()
|
order = fields.IntegerField()
|
||||||
endorsement = models.ManyToManyField("User", related_name="endorsers")
|
endorsement = models.ManyToManyField("User", related_name="endorsers")
|
||||||
|
|
Loading…
Reference in a new issue