我正在为这样的人建模:
class Person(models.Model):
""" Represent a person who has credentials. The person may have
devices and/or accessories. """
#basic information
name = models.CharField(max_length=50, unique=True)
email = models.CharField(max_length=50, unique=True)
phone_number = PhoneNumberField(unique=True)
但我希望能够添加如下内容:
/* create admin user with a group priveledge*/
user_account = #link to user account here
我这样做是因为当我添加人员对象时,我希望他们拥有一个具有某些特权的帐户。
感谢任何能提供帮助的人..