Coverage for lino/api/rt.py : 85%

Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
# Copyright 2014-2015 Luc Saffre # License: BSD (see file COPYING for details)
are available "at runtime", i.e. when the Django machine has been initialized.
You may *import* it at the global namespace of a :xfile:`models.py` file, but you can *use* most of it only when the :func:`startup` function has been called.
.. attribute:: modules
Shortcut to :attr:`lino.core.site.Site.modules`
"""
# get_printable_context = settings.SITE.get_printable_context # get_settings_subdirs = settings.SITE.get_settings_subdirs # is_local_project_dir = settings.SITE.is_local_project_dir
"""Shortcut to :meth:`get_template` on the global `jinja2.Environment` (:attr:`jinja_env <lino.core.site.Site.jinja_env>`, see :mod:`lino.core.web`).
""" return settings.SITE.plugins.jinja.renderer.jinja_env.get_template( *args, **kw)
"""Calls :meth:`show <lino.core.requests.BaseRequest.show>` on a temporary anonymous session (created using :meth:`Site.login`).
"""
"Shortcut to :meth:`lino.core.site.Site.emit_system_note`." return settings.SITE.emit_system_note(*args, **kw)
"Shortcut to :meth:`lino.core.site.Site.send_email`." return settings.SITE.send_email(*args, **kw) |