websauna.system.admin.admin module

Default admin root implementation.

class websauna.system.admin.admin.Admin(request)[source]

Bases: websauna.system.core.traversal.Resource

Admin interface main object.

Presents /admin part of the URL. Manages model admin registrations and discovery. Provides helper functions to map SQLAlchemy objects to their admin URLs.

Admin declares two default menu systems which can be used to register application specific and third party add on entries

  • Admin.get_quick_menu() returns a vertical menu which is visible in the main site navigation

  • Admin.get_admin_menu() returns a horizontal menu which is visible after entering the admin UI

This class is instiated for each request and does not have global state.

construct()[source]

Call all admin contributors and let them register parts to this admin.

construct_default_menu()[source]

Setup admin main menu.

get_admin_menu()[source]
Return type

Menu

get_admin_menu_entry()[source]
Return type

Entry

get_quick_menu()[source]
Return type

Menu

get_quick_menu_entry()[source]

Return Admin root menu.

Return type

Entry

get_title()[source]

Return human-readable title of this resource.

This is viewed in admin breadcrumbs path, etc.