1
0
mirror of https://github.com/django/django.git synced 2024-12-22 17:16:24 +00:00
django/tests/auth_tests/models/uuid_pk.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
335 B
Python
Raw Permalink Normal View History

import uuid
from django.contrib.auth.models import AbstractUser
from django.db import models
from .custom_user import RemoveGroupsAndPermissions
with RemoveGroupsAndPermissions():
class UUIDUser(AbstractUser):
"""A user with a UUID as primary key"""
id = models.UUIDField(default=uuid.uuid4, primary_key=True)