gluon-config-mode-core: hand over more info to the reboot screen (#930)

This commit is contained in:
Ruben Barkow 2016-12-11 03:13:28 +01:00 committed by Matthias Schiffer
parent dc090d3587
commit ff0ad20752
4 changed files with 29 additions and 9 deletions

View File

@ -33,8 +33,8 @@ msgstr ""
msgid "gluon-config-mode:reboot" msgid "gluon-config-mode:reboot"
msgstr "" msgstr ""
"<p>Dein Knoten startet gerade neu und wird anschließend versuchen, " "<p>Dein Knoten <em><%= escape(hostname) %></em> startet gerade neu und wird "
"sich mit anderen Freifunkknoten in seiner Nähe zu " "anschließend versuchen, sich mit anderen Freifunkknoten in seiner Nähe zu "
"verbinden. Weitere Informationen zur " "verbinden. Weitere Informationen zur "
"Alpha Centauri Freifunk-Community findest du auf " "Alpha Centauri Freifunk-Community findest du auf "
"<a href=\"https://alpha-centauri.freifunk.net/\">unserer Webseite</a>.</p>" "<a href=\"https://alpha-centauri.freifunk.net/\">unserer Webseite</a>.</p>"

View File

@ -30,9 +30,9 @@ msgstr ""
msgid "gluon-config-mode:reboot" msgid "gluon-config-mode:reboot"
msgstr "" msgstr ""
"<p>The node is currently rebooting and will try to connect to other " "<p>Your node <em><%= escape(hostname) %></em> is currently rebooting and will "
"nearby Freifunk nodes after that. " "try to connect to other nearby Freifunk nodes after that. For more "
"For more information on the Freifunk Alpha Centauri community, have a look at " "information about the Freifunk community on Alpha Centauri, have a look at "
"<a href=\"https://alpha-centauri.freifunk.net/\">our homepage</a>.</p>" "<a href=\"https://alpha-centauri.freifunk.net/\">our homepage</a>.</p>"
"<p>To get back to this configuration interface, press the reset button for " "<p>To get back to this configuration interface, press the reset button for "
"3 seconds during normal operation. The device will then reboot into config " "3 seconds during normal operation. The device will then reboot into config "

View File

@ -33,8 +33,8 @@ msgstr ""
msgid "gluon-config-mode:reboot" msgid "gluon-config-mode:reboot"
msgstr "" msgstr ""
"<p>Votre nœud es en train de redémarrer et va ensuite éssayer de se connecter " "<p>Votre nœud <em><%= escape(hostname) %></em> es en train de redémarrer et "
"avec les autres nœuds du réseau Freifunk " "va ensuite éssayer de se connecter avec les autres nœuds du réseau Freifunk "
"Vous pourrez trouver plus d'informations sur votre groupe Freifunk sur la page " "Vous pourrez trouver plus d'informations sur votre groupe Freifunk sur la page "
"<a href=\"https://alpha-centauri.freifunk.net/\"> de ton groupe </a>.</p> " "<a href=\"https://alpha-centauri.freifunk.net/\"> de ton groupe </a>.</p> "
"<p> Pour retrouver cette page de configuration veuillier appuyez pendant le " "<p> Pour retrouver cette page de configuration veuillier appuyez pendant le "

View File

@ -1,3 +1,23 @@
local i18n = require 'luci.i18n' local i18n = require 'luci.i18n'
local site = require 'gluon.site_config'
local gluon_luci = require 'gluon.luci'
local sysconfig = require 'gluon.sysconfig'
local pretty_hostname = require 'pretty_hostname'
return function () luci.template.render_string(i18n.translate('gluon-config-mode:reboot')) end local uci = luci.model.uci.cursor()
local hostname = pretty_hostname.get(uci)
local contact = uci:get_first('gluon-node-info', 'owner', 'contact')
local msg = i18n.translate('gluon-config-mode:reboot')
return function ()
luci.template.render_string(msg, {
hostname = hostname,
site = site,
sysconfig = sysconfig,
contact = contact,
escape = gluon_luci.escape,
urlescape = gluon_luci.urlescape,
})
end