5
Tôi đang sử dụng User
mô hình từ django.contrib.auth.models
, id mặc định (primary_key) loại là int, làm thế nào để thay đổi nó để UUID ?, ví dụ id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False)
Thay đổi loại User ID để UUID
https://docs.djangoproject.com/en/stable/topics/auth/customizing/#substituting-a-custom-user-model –