mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-12-23 08:36:32 +00:00
Black formatting
This commit is contained in:
parent
5e24b438ff
commit
81ab73f309
2 changed files with 39 additions and 17 deletions
|
@ -8,29 +8,52 @@ import django.db.models.deletion
|
|||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('bookwyrm', '0055_auto_20210321_0101'),
|
||||
("bookwyrm", "0055_auto_20210321_0101"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='sitesettings',
|
||||
name='allow_invite_requests',
|
||||
model_name="sitesettings",
|
||||
name="allow_invite_requests",
|
||||
field=models.BooleanField(default=True),
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='InviteRequest',
|
||||
name="InviteRequest",
|
||||
fields=[
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('created_date', models.DateTimeField(auto_now_add=True)),
|
||||
('updated_date', models.DateTimeField(auto_now=True)),
|
||||
('remote_id', bookwyrm.models.fields.RemoteIdField(max_length=255, null=True, validators=[bookwyrm.models.fields.validate_remote_id])),
|
||||
('email', models.EmailField(max_length=255, unique=True)),
|
||||
('invite_sent', models.BooleanField(default=False)),
|
||||
('ignored', models.BooleanField(default=False)),
|
||||
('invite', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='bookwyrm.siteinvite')),
|
||||
(
|
||||
"id",
|
||||
models.AutoField(
|
||||
auto_created=True,
|
||||
primary_key=True,
|
||||
serialize=False,
|
||||
verbose_name="ID",
|
||||
),
|
||||
),
|
||||
("created_date", models.DateTimeField(auto_now_add=True)),
|
||||
("updated_date", models.DateTimeField(auto_now=True)),
|
||||
(
|
||||
"remote_id",
|
||||
bookwyrm.models.fields.RemoteIdField(
|
||||
max_length=255,
|
||||
null=True,
|
||||
validators=[bookwyrm.models.fields.validate_remote_id],
|
||||
),
|
||||
),
|
||||
("email", models.EmailField(max_length=255, unique=True)),
|
||||
("invite_sent", models.BooleanField(default=False)),
|
||||
("ignored", models.BooleanField(default=False)),
|
||||
(
|
||||
"invite",
|
||||
models.ForeignKey(
|
||||
blank=True,
|
||||
null=True,
|
||||
on_delete=django.db.models.deletion.SET_NULL,
|
||||
to="bookwyrm.siteinvite",
|
||||
),
|
||||
),
|
||||
],
|
||||
options={
|
||||
'abstract': False,
|
||||
"abstract": False,
|
||||
},
|
||||
),
|
||||
]
|
||||
|
|
|
@ -93,9 +93,9 @@ class ManageInviteRequests(View):
|
|||
page = 1
|
||||
|
||||
paginated = Paginator(
|
||||
models.InviteRequest.objects.filter(
|
||||
ignored=ignored
|
||||
).order_by("-created_date"),
|
||||
models.InviteRequest.objects.filter(ignored=ignored).order_by(
|
||||
"-created_date"
|
||||
),
|
||||
PAGE_LENGTH,
|
||||
)
|
||||
|
||||
|
@ -109,7 +109,6 @@ class ManageInviteRequests(View):
|
|||
""" send out an invite """
|
||||
|
||||
|
||||
|
||||
class InviteRequest(View):
|
||||
""" prospective users sign up here """
|
||||
|
||||
|
|
Loading…
Reference in a new issue