-
-
Notifications
You must be signed in to change notification settings - Fork 304
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fastapi_auth_partner: Finish first version of the module
- add view, wizard (to send reminder in migration case) - add end2end test - fix cookies and api
- Loading branch information
1 parent
b8f79a8
commit 21282e0
Showing
17 changed files
with
397 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from . import models | ||
from . import routers | ||
from . import schemas | ||
from . import wizards |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink | ||
access_fastapi_auth_directory,fastapi_auth_directory_manager,model_fastapi_auth_directory,base.group_system,1,1,1,1 | ||
access_fastapi_auth_partner,fastapi_auth_partner_manager,model_fastapi_auth_partner,group_partner_auth_manager,1,1,1,1 | ||
api_access_fastapi_auth_partner,fastapi_auth_partner_api,model_fastapi_auth_partner,group_partner_auth_api,1,1,1,0 | ||
api_access_fastapi_auth_directory,fastapi_auth_directory_api,model_fastapi_auth_directory,group_partner_auth_api,1,0,0,0 | ||
api_access_fastapi_res_partner,fastapi_res_partner_api,base.model_res_partner,group_partner_auth_api,1,0,1,0 | ||
api_access_fastapi_auth_partner,fastapi_auth_partner_api,model_fastapi_auth_partner,group_partner_auth_api,1,1,0,0 | ||
api_access_fastapi_res_partner,fastapi_res_partner_api,base.model_res_partner,group_partner_auth_api,1,0,0,0 | ||
api_access_fastapi_wizard_partner_auth_reset_password,fastapi_wizard_partner_auth_reset_password,model_wizard_partner_auth_reset_password,group_partner_auth_manager,1,1,1,1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -80,12 +80,15 @@ def test_forget_password(self): | |
content=json.dumps({"login": "[email protected]"}), | ||
) | ||
self.assertEqual(response.status_code, status.HTTP_200_OK) | ||
mail = self.env["mail.mail"].search([], limit=1, order="id desc") | ||
token = mail.body.split("token=")[1].split('" targe')[0] | ||
response: Response = test_client.post( | ||
"/auth/set_password", | ||
content=json.dumps( | ||
{ | ||
"login": "[email protected]", | ||
"token": "TODO", | ||
"password": "megasecret", | ||
"token": token, | ||
} | ||
), | ||
) | ||
self.assertEqual(response.status_code, status.HTTP_200_OK) |
Oops, something went wrong.