THE ORIONIS API
Build with clarity.
Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.
class documentation
class LoginController(BaseController): (source)
Constructor: LoginController(application)
Undocumented
| Method | __init__ |
Configure the controller from the session authentication settings. |
| Async Method | index |
Return the login page response. |
| Async Method | login |
Handle the login form submission. |
| Async Method | logout |
Invalidate the current session and return to the public welcome page. |
| Constant | DEFAULT |
Undocumented |
| Constant | HOME |
Undocumented |
| Constant | LOGIN |
Undocumented |
| Constant | LOGOUT |
Undocumented |
| Instance Variable | redirect |
Undocumented |
Configure the controller from the session authentication settings.
Web login uses the session guard through Auth.attempt() regardless of the guard configured as the application's default.
| Parameters | |
application:IApplication | Application instance used to read the auth configuration. |
| Returns | |
None | Complete the documented operation without returning a value. |
async def login(self, request:
Request, payload: LoginSchema, auth: IAuthManager) -> HttpResponse:
(source)
¶
Handle the login form submission.
| Parameters | |
request:Request | Incoming HTTP request, used to read the raw submitted payload. |
payload:LoginSchema | Validated credentials; invalid submissions never reach this method. |
auth:IAuthManager | Authentication service using the request's existing session. |
| Returns | |
HttpResponse | Redirect to the dashboard, or back with a generic credential error. |
Invalidate the current session and return to the public welcome page.
| Parameters | |
auth:IAuthManager | Authentication service bound to the current request. |
| Returns | |
HttpResponse | Redirect whose session cookie is cleared by the web middleware. |