ktlili 2004/12/06 17:54:43 CET
Modified files:
JForumWebApp/WEB-INF/config/languages de_DE.properties
en_US.properties
fr_FR.properties
nl_NL.properties
pt_BR.properties
ru_RU.properties
zh_CN.properties
JForumWebApp/templates/default/admin config_list.htm empty.htm
group_list.htm
user_list.htm
JForumWebApp/templates/default forum_list.htm
src/net/jforum/util/preferences SystemGlobals.java
src/net/jforum/view/admin ConfigAction.java
Log:
Update templates
Revision Changes Path
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/de_DE.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/de_DE.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/en_US.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/en_US.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/fr_FR.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/fr_FR.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/nl_NL.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/nl_NL.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/pt_BR.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/pt_BR.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +2 -1
jforum/JForumWebApp/WEB-INF/config/languages/ru_RU.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/ru_RU.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +1 -0
jforum/JForumWebApp/WEB-INF/config/languages/zh_CN.properties
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/WEB-INF/config/languages/zh_CN.properties.diff?r1=1.3&r2=1.4&f=h
1.4 +3 -0
jforum/JForumWebApp/templates/default/admin/config_list.htm
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/templates/default/admin/config_list.htm.diff?r1=1.3&r2=1.4&f=h
1.5 +7 -0 jforum/JForumWebApp/templates/default/admin/empty.htm
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/templates/default/admin/empty.htm.diff?r1=1.4&r2=1.5&f=h
1.2 +0 -1
jforum/JForumWebApp/templates/default/admin/group_list.htm
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/templates/default/admin/group_list.htm.diff?r1=1.1&r2=1.2&f=h
1.2 +2 -0 jforum/JForumWebApp/templates/default/admin/user_list.htm
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/templates/default/admin/user_list.htm.diff?r1=1.1&r2=1.2&f=h
1.3 +1 -2 jforum/JForumWebApp/templates/default/forum_list.htm
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/JForumWebApp/templates/default/forum_list.htm.diff?r1=1.2&r2=1.3&f=h
1.3 +1 -5 jforum/src/net/jforum/util/preferences/SystemGlobals.java
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/src/net/jforum/util/preferences/SystemGlobals.java.diff?r1=1.2&r2=1.3&f=h
1.3 +115 -80 jforum/src/net/jforum/view/admin/ConfigAction.java
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jforum/src/net/jforum/view/admin/ConfigAction.java.diff?r1=1.2&r2=1.3&f=h
Index: de_DE.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/de_DE.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- de_DE.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ de_DE.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -1,5 +1,5 @@
#
-# Version: $Id: de_DE.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: de_DE.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# Java Resource Bundle
# Modified by Zaval JRC Editor (C) Zaval CE Group
@@ -10,6 +10,7 @@
AdminConfig.Title= Konfigurationen
Administrator= Administrator
CannotDeleteCategory= L\u00f6schen der Kategorie mit ID <b>{0}</b> nicht
m\u00f6glich. Bitte \u00fcberpr\u00fcfen Sie die Foren, die mit dieser
Kategorie verkn\u00fcpft sind bevor Sie diese L\u00f6schen.
+Admin.BackTo = Zur�ck zu Admin
# General error messages
CannotDeleteGroup= L\u00f6schen der Gruppe mit ID <i>"{0}"</i> nicht
m\u00f6glich. Bitte \u00fcberpr\u00fcfen Sie die Benutzer dieser Gruppe bevor
Sie diese L\u00f6schen.
CannotEditPost= Sie k\u00f6nnen diese Beitrag nicht bearbeiten.
Index: en_US.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/en_US.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- en_US.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ en_US.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -1,5 +1,5 @@
#
-# Version: $Id: en_US.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: en_US.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# General error messages
CannotDeleteGroup = Cannot delete the group with ID <i>"{0}"</i>. Please
check for users inside this group before deleting it.
@@ -10,6 +10,7 @@
UsernameExists = The user name you choose is already taken. Please choose
another one.
UsernamePasswordCannotBeNull = User or password cannot be empty.
Administrator = Administrator
+Admin.BackTo = Back to Admin
Manager = Manager
closeWindow = Close Window
or = or
Index: fr_FR.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/fr_FR.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- fr_FR.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ fr_FR.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -1,5 +1,5 @@
#
-# Version: $Id: fr_FR.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: fr_FR.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# General error messages
CannotDeleteGroup = Impossible de d�truire le groupe avec l'ID <i>"{0}"</i>.
V�rifier la pr�sence d'utilisateurs dans ce groupe avant de le d�truire.
@@ -10,6 +10,7 @@
UsernameExists = Ce nom d'utilisateur est d�j� pris. Merci d'en choisir un
autre.
UsernamePasswordCannotBeNull = le nom d'utilisateur et le mot de passe ne
peuvent �tre vides.
Administrator = Administrateur
+Admin.BackTo = Retour � Admin
Manager = Manager
closeWindow = fermer la fen�tre
or = ou
Index: nl_NL.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/nl_NL.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- nl_NL.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ nl_NL.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -1,5 +1,5 @@
#
-# Version: $Id: nl_NL.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: nl_NL.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# General error messages
CannotDeleteGroup = Je kunt de groep met ID <i>"{0}"</i> niet verwijderen.
Controleer eerst of er geen gebruikers meer zijn in een groep voor je de groep
verwijdert.
@@ -10,6 +10,7 @@
UsernameExists = Deze gebruikersnaam is al bezet. Kies een andere naam.
UsernamePasswordCannotBeNull = De gebruikersnaam en/of wachtwoord kunnen
niet leeg zijn.
Administrator = Administrator
+Admin.BackTo = Back to Admin
Manager = Manager
closeWindow = Sluit Venster
Index: pt_BR.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/pt_BR.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- pt_BR.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ pt_BR.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -1,5 +1,5 @@
#
-# Version: $Id: pt_BR.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: pt_BR.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# General error messages
CannotDeleteGroup = N�o � poss�vel remover o grupo de ID <i>"{0}"</i>. por
favor verifique por usu�rios associados ao grupo
@@ -10,6 +10,7 @@
usernameExists = O nome de usu�rio que voc� escolheu j� est� em uso. Por
favor, escolha outro
UsernamePasswordCannotBeNull = Nome de usu�rio ou senha n�o pode ser vazio
Administrator = Administrador
+Admin.BackTo = Back to Admin
Manager = Manager
closeWindow = Fechar janela
or = ou
Index: ru_RU.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/ru_RU.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- ru_RU.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ ru_RU.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -6,7 +6,7 @@
# "native2ascii.exe -reverse ru_RU.properties <unescaped file>"
# Don't forget to compile it again before use.
#
-# Version: $Id: ru_RU.properties,v 1.3 2004/12/06 14:57:21 ktlili Exp $
+# Version: $Id: ru_RU.properties,v 1.4 2004/12/06 16:54:41 ktlili Exp $
#
# Translation made by: Alexander Sgibnev, [EMAIL PROTECTED]
#
@@ -22,6 +22,7 @@
UsernameExists = \u0412\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0435
\u0438\u043c\u044f
\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f
\u0443\u0436\u0435
\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f.
\u041f\u043e\u0436\u0430\u043b\u0443\u0439\u0441\u0442\u0430,
\u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435
\u0434\u0440\u0443\u0433\u043e\u0435.
UsernamePasswordCannotBeNull = \u0418\u043c\u044f \u0438\u043b\u0438
\u043f\u0430\u0440\u043e\u043b\u044c \u043d\u0435
\u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c
\u043f\u0443\u0441\u0442\u044b\u043c\u0438.
Administrator =
\u0410\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440
+Admin.BackTo = Back to Admin
Manager = \u041c\u043e\u0434\u0435\u0440\u0430\u0442\u043e\u0440
closeWindow = \u0417\u0430\u043a\u0440\u044b\u0442\u044c
\u043e\u043a\u043d\u043e
or = \u0438\u043b\u0438
Index: zh_CN.properties
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/WEB-INF/config/languages/zh_CN.properties,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- zh_CN.properties 6 Dec 2004 14:57:21 -0000 1.3
+++ zh_CN.properties 6 Dec 2004 16:54:41 -0000 1.4
@@ -11,6 +11,7 @@
UsernameExists =
\u60a8\u9009\u62e9\u7684\u7528\u6237\u540d\u5df2\u7ecf\u88ab\u4f7f\u7528\u8fc7\u4e86.
\u8bf7\u9009\u62e9\u5176\u4ed6\u7684\u7528\u6237\u540d.
UsernamePasswordCannotBeNull =
\u7528\u6237\u540d\u6216\u8005\u5bc6\u7801\u4e0d\u80fd\u4e3a\u7a7a.
Administrator = \u7ba1\u7406\u5458
+Admin.BackTo = Back to Admin
Manager = \u957f\u8001
closeWindow = \u5173\u95ed
or = \u6216
Index: config_list.htm
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/templates/default/admin/config_list.htm,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- config_list.htm 3 Dec 2004 16:22:41 -0000 1.3
+++ config_list.htm 6 Dec 2004 16:54:42 -0000 1.4
@@ -217,7 +217,10 @@
<tr>
<td class='catSides' colspan="2" align="center"><input type="submit"
value="${I18n.getMessage("Update")}" /> <input type="reset"
value="${I18n.getMessage("Reset")}" /></td>
+
</tr>
+
+
</table>
Index: empty.htm
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/templates/default/admin/empty.htm,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- empty.htm 6 Dec 2004 14:57:22 -0000 1.4
+++ empty.htm 6 Dec 2004 16:54:42 -0000 1.5
@@ -95,6 +95,13 @@
</tr>
<tr>
+ <td align="right">
+ <span class="gen">
+ <a id="adminpanel" class="mainmenu"
href='${JForumContext.encodeURL("/jforum${extension}?module=admBase&action=menu")}'>
+ ${I18n.getMessage("Admin.BackTo")}
+ </a>
+ </span>
+ </td>
<td align="center">
<span class="copyright">Powered by <a class="copyright"
href="http://www.jforum.net/" target="_blank">JForum ${version} </a>© 2004
- Rafael Steil</span>
</td>
Index: group_list.htm
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/templates/default/admin/group_list.htm,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- group_list.htm 30 Nov 2004 13:24:17 -0000 1.1
+++ group_list.htm 6 Dec 2004 16:54:42 -0000 1.2
@@ -51,7 +51,6 @@
<INPUT class=mainoption type=submit
value="${I18n.getMessage("Groups.List.ClickToDelete")}"></TD>
</TR>
-
</TBODY></TABLE>
Index: user_list.htm
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/templates/default/admin/user_list.htm,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- user_list.htm 30 Nov 2004 13:24:17 -0000 1.1
+++ user_list.htm 6 Dec 2004 16:54:42 -0000 1.2
@@ -67,6 +67,8 @@
</tr>
</table>
</form>
+<table align="right">
+</table>
<table width="100%">
<tr>
<td align="right"><#if
thisPage?exists><@pagination.doPagination "list", -1/></#if></td>
Index: forum_list.htm
===================================================================
RCS file:
/home/cvs/repository/jforum/JForumWebApp/templates/default/forum_list.htm,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- forum_list.htm 6 Dec 2004 14:57:23 -0000 1.2
+++ forum_list.htm 6 Dec 2004 16:54:42 -0000 1.3
@@ -128,9 +128,8 @@
</tr>
</table>
+ <#if !logged>
<br/>
-
- <#if !logged>
<form name="formlogin" accept-charset="${encoding}"
action="${JForumContext.encodeURL("/jforum")}" method="post">
<input type="hidden" name="module" value="user"
/>
<input type="hidden" name="action"
value="validateLogin" />
Index: SystemGlobals.java
===================================================================
RCS file:
/home/cvs/repository/jforum/src/net/jforum/util/preferences/SystemGlobals.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- SystemGlobals.java 3 Dec 2004 16:12:54 -0000 1.2
+++ SystemGlobals.java 6 Dec 2004 16:54:43 -0000 1.3
@@ -65,7 +65,7 @@
*
[EMAIL PROTECTED] Rafael Steil
[EMAIL PROTECTED] Pieter
- [EMAIL PROTECTED] $Id: SystemGlobals.java,v 1.2 2004/12/03 16:12:54
ktlili Exp $
+ [EMAIL PROTECTED] $Id: SystemGlobals.java,v 1.3 2004/12/06 16:54:43
ktlili Exp $
*/
public class SystemGlobals implements VariableStore {
@@ -324,10 +324,6 @@
FileOutputStream out = new
FileOutputStream(SystemGlobals.getValue(ConfigKeys.INSTALLATION_CONFIG));
globals.installation.store(out, "Installation specific
configuration options");
out.close();
- /*/ out = new FileOutputStream(globals.defaultConfig);
- globals.defaults.store(out, "Default settings");
- out.close();*/
-
}
Index: ConfigAction.java
===================================================================
RCS file:
/home/cvs/repository/jforum/src/net/jforum/view/admin/ConfigAction.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- ConfigAction.java 3 Dec 2004 16:12:55 -0000 1.2
+++ ConfigAction.java 6 Dec 2004 16:54:43 -0000 1.3
@@ -1,46 +1,46 @@
/*
- * Copyright (c) 2003, 2004 Rafael Steil
- * All rights reserved.
+ * Copyright (c) 2003, 2004 Rafael Steil
+ * All rights reserved.
*
- * Redistribution and use in source and binary forms,
- * with or without modification, are permitted provided
- * that the following conditions are met:
+ * Redistribution and use in source and binary forms,
+ * with or without modification, are permitted provided
+ * that the following conditions are met:
*
- * 1) Redistributions of source code must retain the above
- * copyright notice, this list of conditions and the
- * following disclaimer.
- * 2) Redistributions in binary form must reproduce the
- * above copyright notice, this list of conditions and
- * the following disclaimer in the documentation and/or
- * other materials provided with the distribution.
- * 3) Neither the name of "Rafael Steil" nor
- * the names of its contributors may be used to endorse
- * or promote products derived from this software without
- * specific prior written permission.
+ * 1) Redistributions of source code must retain the above
+ * copyright notice, this list of conditions and the
+ * following disclaimer.
+ * 2) Redistributions in binary form must reproduce the
+ * above copyright notice, this list of conditions and
+ * the following disclaimer in the documentation and/or
+ * other materials provided with the distribution.
+ * 3) Neither the name of "Rafael Steil" nor
+ * the names of its contributors may be used to endorse
+ * or promote products derived from this software without
+ * specific prior written permission.
*
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT
- * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING,
- * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
- * THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
- * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
- * IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
- * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
- * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT
+ * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING,
+ * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
+ * THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
*
- * This file creation date: 15/08/2003 / 20:56:33
- * The JForum Project
- * http://www.jforum.net
+ * This file creation date: 15/08/2003 / 20:56:33
+ * The JForum Project
+ * http://www.jforum.net
*
- * $Id: ConfigAction.java,v 1.2 2004/12/03 16:12:55 ktlili Exp $
+ * $Id: ConfigAction.java,v 1.3 2004/12/06 16:54:43 ktlili Exp $
*/
package net.jforum.view.admin;
@@ -54,61 +54,79 @@
import net.jforum.JForum;
import net.jforum.model.ConfigModel;
import net.jforum.util.preferences.SystemGlobals;
+import net.jforum.util.preferences.ConfigKeys;
+import java.io.*;
+import net.jforum.util.I18n;
import freemarker.template.Template;
/**
- * @author Rafael Steil
+ [EMAIL PROTECTED] Rafael Steil
*/
-public class ConfigAction extends Command
-{
+public class ConfigAction extends Command {
// Listing
- public void list() throws Exception
- {
- Properties p = new Properties();
- Iterator iter = SystemGlobals.fetchConfigKeyIterator();
- while (iter.hasNext()) {
- String key = (String) iter.next();
- String value = SystemGlobals.getValue(key);
- p.put(key, value);
- }
-
- Properties locales = new Properties();
- locales.load(new
FileInputStream(SystemGlobals.getApplicationResourceDir()
+"/config/languages/locales.properties"));
- ArrayList localesList = new ArrayList();
-
- for (Enumeration e = locales.keys(); e.hasMoreElements(); ) {
- localesList.add(e.nextElement());
- }
+ /**
+ * Description of the Method
+ *
+ [EMAIL PROTECTED] Exception Description of Exception
+ */
+ public void list() throws Exception {
+ Properties p = new Properties();
+ Iterator iter = SystemGlobals.fetchConfigKeyIterator();
+ while (iter.hasNext()) {
+ String key = (String) iter.next();
+ String value = SystemGlobals.getValue(key);
+ p.put(key, value);
+ }
+
+ Properties locales = new Properties();
+ locales.load(new
FileInputStream(SystemGlobals.getApplicationResourceDir() +
"/config/languages/locales.properties"));
+ ArrayList localesList = new ArrayList();
+
+ for (Enumeration e = locales.keys(); e.hasMoreElements(); ) {
+ localesList.add(e.nextElement());
+ }
- JForum.getContext().put("config", p);
- JForum.getContext().put("locales", localesList);
+ JForum.getContext().put("config", p);
+ JForum.getContext().put("locales", localesList);
JForum.getContext().put("moduleAction", "config_list.htm");
- }
+ }
+
+
+ /**
+ * Description of the Method
+ *
+ [EMAIL PROTECTED] Exception Description of Exception
+ */
+ public void editSave() throws Exception {
+ Properties p = new Properties();
+
+ Enumeration e = JForum.getRequest().getParameterNames();
+ while (e.hasMoreElements()) {
+ String name = (String) e.nextElement();
+
+ if (name.startsWith("p_")) {
+ p.setProperty(name.substring(name.indexOf('_')
+ 1), JForum.getRequest().getParameter(name));
+ }
+ }
+
+ new ConfigModel().update(p);
+ restartSystemGlobals();
+ this.list();
+ JForum.getContext().put("moduleAction", "menu.htm");
- public void editSave() throws Exception
- {
- Properties p = new Properties();
-
- Enumeration e = JForum.getRequest().getParameterNames();
- while (e.hasMoreElements()) {
- String name = (String)e.nextElement();
-
- if (name.startsWith("p_")) {
- p.setProperty(name.substring(name.indexOf('_')
+ 1), JForum.getRequest().getParameter(name));
- }
- }
-
- new ConfigModel().update(p);
- this.list();
- JForum.getContext().put("moduleAction", "menu.htm");
+ }
- }
/*
- * @see net.jforum.Command#process()
+ * @see net.jforum.Command#process()
*/
- public Template process() throws Exception
- {
+ /**
+ * Description of the Method
+ *
+ [EMAIL PROTECTED] Description of the Returned Value
+ [EMAIL PROTECTED] Exception Description of Exception
+ */
+ public Template process() throws Exception {
if (AdminAction.isAdmin()) {
super.process();
}
@@ -116,4 +134,21 @@
return AdminAction.adminBaseTemplate();
}
+
+ /**
+ * Description of the Method
+ *
+ [EMAIL PROTECTED] Exception Description of Exception
+ */
+ private void restartSystemGlobals() throws Exception {
+ String appPath = SystemGlobals.getApplicationPath();
+ SystemGlobals.initGlobals(appPath, appPath +
"/WEB-INF/config/SystemGlobals.properties", null);
+
+ if (new
File(SystemGlobals.getValue(ConfigKeys.INSTALLATION_CONFIG)).exists()) {
+
SystemGlobals.loadAdditionalDefaults(SystemGlobals.getValue(ConfigKeys.INSTALLATION_CONFIG));
+ }
+
SystemGlobals.loadAdditionalDefaults(SystemGlobals.getValue(ConfigKeys.DATABASE_DRIVER_CONFIG));
+ I18n.load();
+ }
+
}