# Path: axes/models.py
# class AccessAttempt(AccessBase):
#     get_data = models.TextField(_("GET Data"))
# 
#     post_data = models.TextField(_("POST Data"))
# 
#     failures_since_start = models.PositiveIntegerField(_("Failed Logins"))
# 
#     def __str__(self):
#         return f"Attempted Access: {self.attempt_time}"
# 
#     class Meta:
#         verbose_name = _("access attempt")
#         verbose_name_plural = _("access attempts")
#         unique_together = [["username", "ip_address", "user_agent"]]


from django.core.management.base import BaseCommand
from axes.models import AccessAttempt



class Command(BaseCommand):
    help = "List access attempts"

    def handle(self, *args, **options):

# Path: axes/models.py
# class AccessAttempt(AccessBase):
#     get_data = models.TextField(_("GET Data"))
# 
#     post_data = models.TextField(_("POST Data"))
# 
#     failures_since_start = models.PositiveIntegerField(_("Failed Logins"))
# 
#     def __str__(self):
#         return f"Attempted Access: {self.attempt_time}"
# 
#     class Meta:
#         verbose_name = _("access attempt")
#         verbose_name_plural = _("access attempts")
#         unique_together = [["username", "ip_address", "user_agent"]]


# Path: axes/management/commands/axes_list_attempts.py
from django.core.management.base import BaseCommand
from axes.models import AccessAttempt




class Command(BaseCommand):
    help = "List access attempts"

    def handle(self, *args, **options):

        for obj in AccessAttempt.objects.all():