Skip to content

Commit

Permalink
Update examples for Mongoz with Meta
Browse files Browse the repository at this point in the history
  • Loading branch information
tarsil committed Oct 1, 2023
1 parent 6101579 commit dc25969
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/check_password.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.last_login}"
Expand Down
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/create_superuser.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.last_login}"
Expand Down
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/create_user.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.last_login}"
Expand Down
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/example/create_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.role.name}"
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.role.name}"
Expand Down
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/set_password.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.last_login}"
Expand Down
1 change: 1 addition & 0 deletions docs_src/databases/mongoz/settings/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ class User(BaseUser):

class Meta:
registry = registry
database = "my_db"

def __str__(self):
return f"{self.email} - {self.role.name}"

0 comments on commit dc25969

Please sign in to comment.