mirror of
https://github.com/jazzband/django-axes.git
synced 2026-03-16 22:30:23 +00:00
Modified access_attempt as pk
This commit is contained in:
parent
f583e93718
commit
f5951e966c
2 changed files with 8 additions and 14 deletions
|
|
@ -1,4 +1,4 @@
|
|||
# Generated by Django 5.2.1 on 2025-06-07 17:37
|
||||
# Generated by Django 5.2.1 on 2025-06-08 12:44
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
|
@ -15,12 +15,14 @@ class Migration(migrations.Migration):
|
|||
name="AccessAttemptExpiration",
|
||||
fields=[
|
||||
(
|
||||
"id",
|
||||
models.AutoField(
|
||||
auto_created=True,
|
||||
"access_attempt",
|
||||
models.OneToOneField(
|
||||
on_delete=django.db.models.deletion.CASCADE,
|
||||
primary_key=True,
|
||||
related_name="expiration",
|
||||
serialize=False,
|
||||
verbose_name="ID",
|
||||
to="axes.accessattempt",
|
||||
verbose_name="Access Attempt",
|
||||
),
|
||||
),
|
||||
(
|
||||
|
|
@ -32,15 +34,6 @@ class Migration(migrations.Migration):
|
|||
verbose_name="Expires At",
|
||||
),
|
||||
),
|
||||
(
|
||||
"access_attempt",
|
||||
models.OneToOneField(
|
||||
on_delete=django.db.models.deletion.CASCADE,
|
||||
related_name="expiration",
|
||||
to="axes.accessattempt",
|
||||
verbose_name="Access Attempt",
|
||||
),
|
||||
),
|
||||
],
|
||||
options={
|
||||
"verbose_name": "access attempt expiration",
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ class AccessAttempt(AccessBase):
|
|||
class AccessAttemptExpiration(models.Model):
|
||||
access_attempt = models.OneToOneField(
|
||||
AccessAttempt,
|
||||
primary_key=True,
|
||||
on_delete=models.CASCADE,
|
||||
related_name="expiration",
|
||||
verbose_name=_("Access Attempt"),
|
||||
|
|
|
|||
Loading…
Reference in a new issue