From 72019e300a1942f08981d38fefc9b21a7a40a21f Mon Sep 17 00:00:00 2001 From: Steven Barth Date: Wed, 11 Jun 2008 20:58:15 +0000 Subject: * Added support for timezone setting --- i18n/english/luasrc/i18n/admin-core.en.lua | 2 -- i18n/english/luasrc/i18n/default.en.lua | 1 + i18n/german/luasrc/i18n/admin-core.de.lua | 2 -- i18n/german/luasrc/i18n/default.de.lua | 1 + .../admin-core/luasrc/controller/admin/system.lua | 2 +- .../luasrc/model/cbi/admin_system/hostname.lua | 21 --------------------- .../luasrc/model/cbi/admin_system/system.lua | 22 ++++++++++++++++++++++ 7 files changed, 25 insertions(+), 26 deletions(-) delete mode 100644 modules/admin-core/luasrc/model/cbi/admin_system/hostname.lua create mode 100644 modules/admin-core/luasrc/model/cbi/admin_system/system.lua diff --git a/i18n/english/luasrc/i18n/admin-core.en.lua b/i18n/english/luasrc/i18n/admin-core.en.lua index d85376e51..0ad12d4be 100644 --- a/i18n/english/luasrc/i18n/admin-core.en.lua +++ b/i18n/english/luasrc/i18n/admin-core.en.lua @@ -76,8 +76,6 @@ a_s_changepw_nomatch = "Error: Passwords do not match" a_s_sshkeys1 = "Here you can paste public SSH-Keys (one per line) for SSH public-key authentication." -a_s_hostname1 = "Defines the router's hostname. The hostname is a unique name in your local network used to identify the device" - a_s_fstab_mountpoints = "Mount Points" a_s_fstab_mountpoints1 = "Mount Points define at which point a memory device will be attached to the filesystem" diff --git a/i18n/english/luasrc/i18n/default.en.lua b/i18n/english/luasrc/i18n/default.en.lua index fb88e97e9..92ee1625f 100644 --- a/i18n/english/luasrc/i18n/default.en.lua +++ b/i18n/english/luasrc/i18n/default.en.lua @@ -82,6 +82,7 @@ syslog = "System Log" system = "System" target = "Target" +timezone = "Timezone" type = "Type" username = "Username" diff --git a/i18n/german/luasrc/i18n/admin-core.de.lua b/i18n/german/luasrc/i18n/admin-core.de.lua index 8108dc5aa..918a4e1dd 100644 --- a/i18n/german/luasrc/i18n/admin-core.de.lua +++ b/i18n/german/luasrc/i18n/admin-core.de.lua @@ -69,8 +69,6 @@ a_s_fstab_swap1 = [[Falls der Arbeitsspeicher des Routers nicht ausreicht, kann dieser nicht benutzte Daten zeitweise auf einem SWAP-Laufwerk auslagern um so die effektive Größe des Arbeitsspeichers zu erhöhen. Die Auslagerung der Daten ist natürlich bedeutend langsamer als direkte Arbeitsspeicherzugriffe.]] -a_s_hostname1 = [[Definiert den Hostnamen des Routers. -Der Hostname ist eine im Netzwerk eindeutige Kennung, die dieses Gerät identifiziert.]] a_s_i_system1 = [[Hier finden sich Einstellungen, die das System selbst, dessen Kennung, installierte Software und Hardware, Authentifizierung oder eingehängte Speicher betreffen.]] a_s_i_system2 = [[Diese Einstellungen definieren die Grundlage des Systems, auf dem die diff --git a/i18n/german/luasrc/i18n/default.de.lua b/i18n/german/luasrc/i18n/default.de.lua index 094dca40b..8fd96d5b2 100644 --- a/i18n/german/luasrc/i18n/default.de.lua +++ b/i18n/german/luasrc/i18n/default.de.lua @@ -82,6 +82,7 @@ syslog = "Systemprotokoll" system = "System" target = "Ziel" +timezone = "Zeitzone" type = "Typ" username = "Benutzername" diff --git a/modules/admin-core/luasrc/controller/admin/system.lua b/modules/admin-core/luasrc/controller/admin/system.lua index ef4e303fb..862a741cd 100644 --- a/modules/admin-core/luasrc/controller/admin/system.lua +++ b/modules/admin-core/luasrc/controller/admin/system.lua @@ -22,7 +22,7 @@ function index() entry({"admin", "system", "packages", "ipkg"}, call("action_ipkg"), i18n("a_s_p_ipkg", "IPKG-Konfiguration")) entry({"admin", "system", "passwd"}, call("action_passwd"), i18n("a_s_changepw", "Passwort ändern"), 20) entry({"admin", "system", "sshkeys"}, call("action_sshkeys"), i18n("a_s_sshkeys", "SSH-Schlüssel"), 30) - entry({"admin", "system", "hostname"}, cbi("admin_system/hostname"), i18n("hostname", "Hostname"), 40) + entry({"admin", "system", "system"}, cbi("admin_system/system"), i18n("system", "System"), 40) entry({"admin", "system", "fstab"}, cbi("admin_system/fstab"), i18n("a_s_fstab", "Einhängepunkte"), 50) entry({"admin", "system", "upgrade"}, call("action_upgrade"), i18n("a_s_flash", "Firmwareupgrade"), 60) entry({"admin", "system", "reboot"}, call("action_reboot"), i18n("reboot", "Neu starten"), 70) diff --git a/modules/admin-core/luasrc/model/cbi/admin_system/hostname.lua b/modules/admin-core/luasrc/model/cbi/admin_system/hostname.lua deleted file mode 100644 index 1c74d90d7..000000000 --- a/modules/admin-core/luasrc/model/cbi/admin_system/hostname.lua +++ /dev/null @@ -1,21 +0,0 @@ ---[[ -LuCI - Lua Configuration Interface - -Copyright 2008 Steven Barth - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -$Id$ -]]-- -m = Map("system", translate("hostname"), translate("a_s_hostname1")) - -s = m:section(TypedSection, "system", "") -s.anonymous = true - -s:option(Value, "hostname", translate("hostname")) - -return m \ No newline at end of file diff --git a/modules/admin-core/luasrc/model/cbi/admin_system/system.lua b/modules/admin-core/luasrc/model/cbi/admin_system/system.lua new file mode 100644 index 000000000..dd59d8c01 --- /dev/null +++ b/modules/admin-core/luasrc/model/cbi/admin_system/system.lua @@ -0,0 +1,22 @@ +--[[ +LuCI - Lua Configuration Interface + +Copyright 2008 Steven Barth + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +$Id$ +]]-- +m = Map("system", translate("system")) + +s = m:section(TypedSection, "system", "") +s.anonymous = true + +s:option(Value, "hostname", translate("hostname")) +s:option(Value, "timezone", translate("timezone")) + +return m \ No newline at end of file -- cgit v1.2.3