mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-08-24 06:55:26 -07:00
Add initial translation text
This commit is contained in:
parent
2884114912
commit
1030ad2eab
3 changed files with 39 additions and 11 deletions
|
@ -104,29 +104,29 @@
|
||||||
<li><a href="home"><i class="fa fa-lg fa-home"></i></a></li>
|
<li><a href="home"><i class="fa fa-lg fa-home"></i></a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "Libraries" or title == "Library" or title == "Info":
|
% if title == "Libraries" or title == "Library" or title == "Info":
|
||||||
<li class="active"><a href="libraries">Libraries</a></li>
|
<li class="active"><a href="libraries">${_('Libraries')}</a></li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="libraries">Libraries</a></li>
|
<li><a href="libraries">${_('Libraries')}</a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "Users" or title == "User":
|
% if title == "Users" or title == "User":
|
||||||
<li class="active"><a href="users">Users</a></li>
|
<li class="active"><a href="users">${_('Users')}</a></li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="users">Users</a></li>
|
<li><a href="users">${_('Users')}</a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "History":
|
% if title == "History":
|
||||||
<li class="active"><a href="history">History</a></li>
|
<li class="active"><a href="history">${_('History')}</a></li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="history">History</a></li>
|
<li><a href="history">${_('History')}</a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "Graphs":
|
% if title == "Graphs":
|
||||||
<li class="active"><a href="graphs">Graphs</a></li>
|
<li class="active"><a href="graphs">${_('Graphs')}</a></li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="graphs">Graphs</a></li>
|
<li><a href="graphs">${_('Graphs')}</a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "Synced Items":
|
% if title == "Synced Items":
|
||||||
<li class="active"><a href="sync">Synced Items</a></li>
|
<li class="active"><a href="sync">${_('Synced Items')}</a></li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="sync">Synced Items</a></li>
|
<li><a href="sync">${_('Synced Items')}</a></li>
|
||||||
% endif
|
% endif
|
||||||
% if title == "Settings":
|
% if title == "Settings":
|
||||||
<li class="dropdown active">
|
<li class="dropdown active">
|
||||||
|
|
25
data/locales/tautulli.pot
Normal file
25
data/locales/tautulli.pot
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
#: ../../data/interfaces/default/base.html:107
|
||||||
|
#: ../../data/interfaces/default/base.html:109
|
||||||
|
msgid "Libraries"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../data/interfaces/default/base.html:112
|
||||||
|
#: ../../data/interfaces/default/base.html:114
|
||||||
|
msgid "Users"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../data/interfaces/default/base.html:117
|
||||||
|
#: ../../data/interfaces/default/base.html:119
|
||||||
|
msgid "History"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../data/interfaces/default/base.html:122
|
||||||
|
#: ../../data/interfaces/default/base.html:124
|
||||||
|
msgid "Graphs"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../data/interfaces/default/base.html:127
|
||||||
|
#: ../../data/interfaces/default/base.html:129
|
||||||
|
msgid "Synced Items"
|
||||||
|
msgstr ""
|
||||||
|
|
|
@ -23,6 +23,7 @@ from backports import csv
|
||||||
|
|
||||||
from io import open, BytesIO
|
from io import open, BytesIO
|
||||||
import base64
|
import base64
|
||||||
|
import gettext
|
||||||
import json
|
import json
|
||||||
import linecache
|
import linecache
|
||||||
import os
|
import os
|
||||||
|
@ -115,6 +116,8 @@ else:
|
||||||
|
|
||||||
|
|
||||||
def serve_template(templatename, **kwargs):
|
def serve_template(templatename, **kwargs):
|
||||||
|
_ = gettext.gettext
|
||||||
|
|
||||||
interface_dir = os.path.join(str(plexpy.PROG_DIR), 'data/interfaces/')
|
interface_dir = os.path.join(str(plexpy.PROG_DIR), 'data/interfaces/')
|
||||||
template_dir = os.path.join(str(interface_dir), plexpy.CONFIG.INTERFACE)
|
template_dir = os.path.join(str(interface_dir), plexpy.CONFIG.INTERFACE)
|
||||||
|
|
||||||
|
@ -130,7 +133,7 @@ def serve_template(templatename, **kwargs):
|
||||||
try:
|
try:
|
||||||
template = _hplookup.get_template(templatename)
|
template = _hplookup.get_template(templatename)
|
||||||
return template.render(http_root=http_root, server_name=server_name, cache_param=cache_param,
|
return template.render(http_root=http_root, server_name=server_name, cache_param=cache_param,
|
||||||
_session=_session, **kwargs)
|
_session=_session, _=_, **kwargs)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.exception("WebUI :: Mako template render error: %s" % e)
|
logger.exception("WebUI :: Mako template render error: %s" % e)
|
||||||
return mako.exceptions.html_error_template().render()
|
return mako.exceptions.html_error_template().render()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue