Deployed 4bd6185 to dev with MkDocs 1.4.2 and mike 1.1.2

This commit is contained in:
fastapi-users-ci
2023-04-14 13:47:15 +00:00
parent a80526d783
commit 9b4b78ab90
50 changed files with 287 additions and 300 deletions

View File

@@ -1,5 +1,5 @@
import motor.motor_asyncio
from beanie import PydanticObjectId
from beanie import Document
from fastapi_users.db import BeanieBaseUser, BeanieUserDatabase
DATABASE_URL = "mongodb://localhost:27017"
@@ -9,7 +9,7 @@ client = motor.motor_asyncio.AsyncIOMotorClient(
db = client["database_name"]
class User(BeanieBaseUser[PydanticObjectId]):
class User(BeanieBaseUser, Document):
pass

View File

@@ -1,5 +1,5 @@
import motor.motor_asyncio
from beanie import PydanticObjectId
from beanie import Document
from fastapi_users.db import BeanieBaseUser, BeanieUserDatabase
from fastapi_users_db_beanie.access_token import (
BeanieAccessTokenDatabase,
@@ -13,11 +13,11 @@ client = motor.motor_asyncio.AsyncIOMotorClient(
db = client["database_name"]
class User(BeanieBaseUser):
class User(BeanieBaseUser, Document):
pass
class AccessToken(BeanieBaseAccessToken[PydanticObjectId]): # (1)!
class AccessToken(BeanieBaseAccessToken, Document): # (1)!
pass

View File

@@ -1,7 +1,7 @@
from typing import List
import motor.motor_asyncio
from beanie import PydanticObjectId
from beanie import Document
from fastapi_users.db import BaseOAuthAccount, BeanieBaseUser, BeanieUserDatabase
from pydantic import Field
@@ -16,7 +16,7 @@ class OAuthAccount(BaseOAuthAccount):
pass
class User(BeanieBaseUser[PydanticObjectId]):
class User(BeanieBaseUser, Document):
oauth_accounts: List[OAuthAccount] = Field(default_factory=list)