Docker-in-Docker (DinD) capabilities of public runners deactivated. More info

Commit 9627f932 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update the class Event to select the language of plugin_event.

parent 4911ff0e
......@@ -42,7 +42,7 @@ if is_dbui:
app_libmin="static/track_events-min.js",
app_script="static/app.js")
event.Event.initialise_paths()
event.Event.initialise_paths("fr")
#.............................................................................
#
......
......@@ -6,16 +6,20 @@ from gluon.tools import PluginManager
class Event(object):
"""Initialise the plugin Event.
"""Initialise the plugin event.
"""
def __init__(self):
Event.initialise_paths()
Note:
It has to be performed after the initialisation
of the plugin dbui.
"""
@staticmethod
def initialise_paths():
def initialise_paths(lg="en"):
"""Add paths for the plugin_event.
Args:
lg (str): the language. Possible values are ``en`` or ``fr``.
Note:
The corresponding files will be loaded
via the controller ``plugin_dbui/index``
......@@ -26,6 +30,6 @@ class Event(object):
dbui.plugins_paths["event"] = {
"css": "static/plugin_event/resources/css/event.css",
"debug": "static/plugin_event/event-debug.js",
"lg": "static/plugin_event/locale/event-lang-fr.js",
"lg": "static/plugin_event/locale/event-lang-%s.js" % lg,
"libmin": "static/plugin_event/event-min.js"}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment