forked from mirrors/bookwyrm
fix to pass invite request pytest
This commit is contained in:
parent
74a1697cda
commit
a0ae96923c
4 changed files with 31 additions and 53 deletions
|
@ -1,29 +0,0 @@
|
||||||
# Generated by Django 3.2.12 on 2022-03-12 10:16
|
|
||||||
|
|
||||||
from django.db import migrations, models
|
|
||||||
|
|
||||||
|
|
||||||
class Migration(migrations.Migration):
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
('bookwyrm', '0144_alter_announcement_display_type'),
|
|
||||||
]
|
|
||||||
|
|
||||||
operations = [
|
|
||||||
migrations.AddField(
|
|
||||||
model_name='inviterequest',
|
|
||||||
name='answer',
|
|
||||||
field=models.TextField(default='Foundation by Isaac Azimov', max_length=50),
|
|
||||||
preserve_default=False,
|
|
||||||
),
|
|
||||||
migrations.AddField(
|
|
||||||
model_name='sitesettings',
|
|
||||||
name='invite_question_text',
|
|
||||||
field=models.CharField(blank=True, default='What is your favourite book?', max_length=255),
|
|
||||||
),
|
|
||||||
migrations.AddField(
|
|
||||||
model_name='sitesettings',
|
|
||||||
name='invite_request_question',
|
|
||||||
field=models.BooleanField(default=False),
|
|
||||||
),
|
|
||||||
]
|
|
30
bookwyrm/migrations/0145_auto_20220313_2206.py
Normal file
30
bookwyrm/migrations/0145_auto_20220313_2206.py
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
# Generated by Django 3.2.12 on 2022-03-13 22:06
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
("bookwyrm", "0144_alter_announcement_display_type"),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name="inviterequest",
|
||||||
|
name="answer",
|
||||||
|
field=models.TextField(blank=True, max_length=50, null=True),
|
||||||
|
),
|
||||||
|
migrations.AddField(
|
||||||
|
model_name="sitesettings",
|
||||||
|
name="invite_question_text",
|
||||||
|
field=models.CharField(
|
||||||
|
blank=True, default="What is your favourite book?", max_length=255
|
||||||
|
),
|
||||||
|
),
|
||||||
|
migrations.AddField(
|
||||||
|
model_name="sitesettings",
|
||||||
|
name="invite_request_question",
|
||||||
|
field=models.BooleanField(default=False),
|
||||||
|
),
|
||||||
|
]
|
|
@ -1,23 +0,0 @@
|
||||||
# Generated by Django 3.2.12 on 2022-03-11 15:22
|
|
||||||
|
|
||||||
from django.db import migrations, models
|
|
||||||
|
|
||||||
|
|
||||||
class Migration(migrations.Migration):
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
("bookwyrm", "0145_auto_20220307_2025"),
|
|
||||||
]
|
|
||||||
|
|
||||||
operations = [
|
|
||||||
migrations.AlterField(
|
|
||||||
model_name="sitesettings",
|
|
||||||
name="invite_question_text",
|
|
||||||
field=models.CharField(
|
|
||||||
blank=True,
|
|
||||||
default="What is your favourite book?",
|
|
||||||
max_length=255,
|
|
||||||
null=True,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
]
|
|
|
@ -155,7 +155,7 @@ class InviteRequest(BookWyrmModel):
|
||||||
invite = models.ForeignKey(
|
invite = models.ForeignKey(
|
||||||
SiteInvite, on_delete=models.SET_NULL, null=True, blank=True
|
SiteInvite, on_delete=models.SET_NULL, null=True, blank=True
|
||||||
)
|
)
|
||||||
answer = models.TextField(max_length=50, unique=False, null=False)
|
answer = models.TextField(max_length=50, unique=False, null=True, blank=True)
|
||||||
invite_sent = models.BooleanField(default=False)
|
invite_sent = models.BooleanField(default=False)
|
||||||
ignored = models.BooleanField(default=False)
|
ignored = models.BooleanField(default=False)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue