From e0d57cd4a0d149a1512cca43b64ad07707b82489 Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 19:54:53 +0300 Subject: [PATCH 1/7] OF-2892: admin console Available Plugins page: use plugin.available.name instead of plugin.available.open_source And remove the unused open_source key --- i18n/src/main/resources/openfire_i18n.properties | 1 - i18n/src/main/resources/openfire_i18n_cs_CZ.properties | 1 - i18n/src/main/resources/openfire_i18n_de.properties | 1 - i18n/src/main/resources/openfire_i18n_es.properties | 1 - i18n/src/main/resources/openfire_i18n_fr.properties | 1 - i18n/src/main/resources/openfire_i18n_he.properties | 1 - i18n/src/main/resources/openfire_i18n_ja_JP.properties | 1 - i18n/src/main/resources/openfire_i18n_nl.properties | 1 - i18n/src/main/resources/openfire_i18n_pl_PL.properties | 1 - i18n/src/main/resources/openfire_i18n_pt_BR.properties | 1 - i18n/src/main/resources/openfire_i18n_pt_PT.properties | 1 - i18n/src/main/resources/openfire_i18n_ru_RU.properties | 1 - i18n/src/main/resources/openfire_i18n_sk.properties | 1 - i18n/src/main/resources/openfire_i18n_uk_UA.properties | 1 - i18n/src/main/resources/openfire_i18n_zh_CN.properties | 1 - xmppserver/src/main/webapp/available-plugins.jsp | 2 +- 16 files changed, 1 insertion(+), 16 deletions(-) diff --git a/i18n/src/main/resources/openfire_i18n.properties b/i18n/src/main/resources/openfire_i18n.properties index 8a11f18238..74e799167b 100644 --- a/i18n/src/main/resources/openfire_i18n.properties +++ b/i18n/src/main/resources/openfire_i18n.properties @@ -3131,7 +3131,6 @@ plugin.available.file_size=File Size plugin.available.install=Install plugin.available.no_plugin=No new plugins available. plugin.available.download=Download and Install -plugin.available.open_source= Open Source Plugins plugin.available.installation.success = plugin installed successfully. plugin.available.commercial_plugins = Commercial Plugins plugin.available.outdated = The list of plugins below requires a newer version of the server. diff --git a/i18n/src/main/resources/openfire_i18n_cs_CZ.properties b/i18n/src/main/resources/openfire_i18n_cs_CZ.properties index 9219a6c38b..dcc99f1928 100644 --- a/i18n/src/main/resources/openfire_i18n_cs_CZ.properties +++ b/i18n/src/main/resources/openfire_i18n_cs_CZ.properties @@ -2094,7 +2094,6 @@ plugin.available.author=Autor plugin.available.install=Instalovat plugin.available.no_plugin=Žádné doplňky nejsou dostupné. plugin.available.download=Stáhnout a nainstalovat -plugin.available.open_source= Open Source doplňky plugin.available.installation.success = doplněk úspěšně nainstalován. plugin.available.commercial_plugins = Komerční doplňky plugin.available.outdated = Níže uvedený seznam doplňků vyžaduje novější verzi Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_de.properties b/i18n/src/main/resources/openfire_i18n_de.properties index faa9596716..23e8a8fcb1 100644 --- a/i18n/src/main/resources/openfire_i18n_de.properties +++ b/i18n/src/main/resources/openfire_i18n_de.properties @@ -2872,7 +2872,6 @@ plugin.available.author=Autor plugin.available.install=Installiere plugin.available.no_plugin=Keine neuen Plugins verfüegbar. plugin.available.download=Herunterladen und installieren -plugin.available.open_source=Open-Source Plugins plugin.available.installation.success=Plugin erfolgreich installiert. plugin.available.commercial_plugins=Gewerbliche Plugins plugin.available.outdated=Die untere Pluginliste erfordert eine neuere Openfire Version. diff --git a/i18n/src/main/resources/openfire_i18n_es.properties b/i18n/src/main/resources/openfire_i18n_es.properties index 14074045bc..41f492d61b 100644 --- a/i18n/src/main/resources/openfire_i18n_es.properties +++ b/i18n/src/main/resources/openfire_i18n_es.properties @@ -2823,7 +2823,6 @@ plugin.available.file_size=Tamaño de Archivo plugin.available.install=Instalar plugin.available.no_plugin=No se han encontrados nuevos plugins. plugin.available.download=Descargar e Instalar -plugin.available.open_source= Plugins de Código Abierto plugin.available.installation.success = plugin instalado exitosamente. plugin.available.commercial_plugins = Plugins Comericales plugin.available.outdated = La lista de plugins a continuación requiere una nueva versión de Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_fr.properties b/i18n/src/main/resources/openfire_i18n_fr.properties index b0db1471f8..8ba8b55b1e 100644 --- a/i18n/src/main/resources/openfire_i18n_fr.properties +++ b/i18n/src/main/resources/openfire_i18n_fr.properties @@ -1944,7 +1944,6 @@ plugin.available.author = Auteur plugin.available.install = Installer plugin.available.no_plugin = Aucun nouveau plugin disponible. plugin.available.download = Télécharger et Installer -plugin.available.open_source = Plugins Open Source plugin.available.installation.success = l'installation du plugin est terminée. plugin.available.commercial_plugins = Plugins Commerciaux plugin.available.outdated = La liste des plugins suivant nécéssite une version plus récente de Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_he.properties b/i18n/src/main/resources/openfire_i18n_he.properties index 96a01758d0..79c144219e 100644 --- a/i18n/src/main/resources/openfire_i18n_he.properties +++ b/i18n/src/main/resources/openfire_i18n_he.properties @@ -2847,7 +2847,6 @@ plugin.available.file_size=גודל קובץ plugin.available.install=התקן plugin.available.no_plugin=No new plugins available. plugin.available.download=הורד והתקן -plugin.available.open_source= תוספים קוד פתוח plugin.available.installation.success = תוסף הותקן בהצלחה. plugin.available.commercial_plugins = תוספים מסחריים plugin.available.outdated = The list of plugins below requires a newer version of the server. diff --git a/i18n/src/main/resources/openfire_i18n_ja_JP.properties b/i18n/src/main/resources/openfire_i18n_ja_JP.properties index a99ca059bf..26f79e2e02 100644 --- a/i18n/src/main/resources/openfire_i18n_ja_JP.properties +++ b/i18n/src/main/resources/openfire_i18n_ja_JP.properties @@ -2051,7 +2051,6 @@ plugin.available.author=作者 plugin.available.install=インストール plugin.available.no_plugin=利用可能な新規のプラグインがありません。 plugin.available.download=ダウンロードとインストール -plugin.available.open_source= オープンソースプラグイン plugin.available.installation.success = プラグインが正常にインストールされました。 plugin.available.commercial_plugins = 商用プラグイン plugin.available.outdated = 下のプラグインのリストは、より新しいバージョンのサーバーが要求されます。 diff --git a/i18n/src/main/resources/openfire_i18n_nl.properties b/i18n/src/main/resources/openfire_i18n_nl.properties index 8d90497728..2f440621f9 100644 --- a/i18n/src/main/resources/openfire_i18n_nl.properties +++ b/i18n/src/main/resources/openfire_i18n_nl.properties @@ -2817,7 +2817,6 @@ plugin.available.file_size=Bestandsgrootte plugin.available.install=Install plugin.available.no_plugin=No new plugins available. plugin.available.download=Download and Install -plugin.available.open_source= Open Source Plugins plugin.available.installation.success = plugin installed successfully. plugin.available.commercial_plugins = Commercial Plugins plugin.available.outdated = The list of plugins below requires a newer version of Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_pl_PL.properties b/i18n/src/main/resources/openfire_i18n_pl_PL.properties index 8ed9b9dd42..af00e8fba2 100644 --- a/i18n/src/main/resources/openfire_i18n_pl_PL.properties +++ b/i18n/src/main/resources/openfire_i18n_pl_PL.properties @@ -1964,7 +1964,6 @@ plugin.available.author=Autor plugin.available.install=Zainstaluj plugin.available.no_plugin=Brak nowych wtyczek. plugin.available.download=Ściągnij i zainstaluj -plugin.available.open_source= Wtyczki Open Source plugin.available.installation.success = Zainstalowano wtyczkę. plugin.available.commercial_plugins = Wtyczki komercyjne plugin.available.outdated = Lista wtyczek poniżej wymaga nowszej wersji serwera Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_pt_BR.properties b/i18n/src/main/resources/openfire_i18n_pt_BR.properties index d6718b696c..3a33786a03 100644 --- a/i18n/src/main/resources/openfire_i18n_pt_BR.properties +++ b/i18n/src/main/resources/openfire_i18n_pt_BR.properties @@ -2063,7 +2063,6 @@ plugin.available.author=Autor plugin.available.install=Instalar plugin.available.no_plugin=Nenhum novo plugin disponível. plugin.available.download=Baixar e Instalar -plugin.available.open_source= Plugins de Código Aberto plugin.available.installation.success = plugin instalado com sucesso. plugin.available.commercial_plugins = Plugins Comerciais plugin.available.outdated = A lista de plugins abaixo requerem uma versão mais nova do Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_pt_PT.properties b/i18n/src/main/resources/openfire_i18n_pt_PT.properties index 8f917ed2a8..550119ece8 100644 --- a/i18n/src/main/resources/openfire_i18n_pt_PT.properties +++ b/i18n/src/main/resources/openfire_i18n_pt_PT.properties @@ -2211,7 +2211,6 @@ plugin.available.author=Autor plugin.available.install=Instalar plugin.available.no_plugin=Nenhum novo plugin disponível. plugin.available.download=Baixar e Instalar -plugin.available.open_source= Plugins de Código Aberto plugin.available.installation.success = plugin instalado com sucesso. plugin.available.commercial_plugins = Plugins Comerciais plugin.available.outdated = A lista de plugins abaixo requerem uma versão mais nova do Openfire. diff --git a/i18n/src/main/resources/openfire_i18n_ru_RU.properties b/i18n/src/main/resources/openfire_i18n_ru_RU.properties index 67b87f878a..cbe3b61dd6 100644 --- a/i18n/src/main/resources/openfire_i18n_ru_RU.properties +++ b/i18n/src/main/resources/openfire_i18n_ru_RU.properties @@ -2570,7 +2570,6 @@ plugin.available.author=Разработчик plugin.available.install=Установить plugin.available.no_plugin=Нет новых плагинов. plugin.available.download=Скачать и установить -plugin.available.open_source= Бесплатные плагины plugin.available.installation.success = плагин успешно установлен. plugin.available.commercial_plugins = Коммерческие плагины plugin.available.outdated = Список плагинов ниже требует более новой версии сервера. diff --git a/i18n/src/main/resources/openfire_i18n_sk.properties b/i18n/src/main/resources/openfire_i18n_sk.properties index aeed935904..0a5fbf1c74 100644 --- a/i18n/src/main/resources/openfire_i18n_sk.properties +++ b/i18n/src/main/resources/openfire_i18n_sk.properties @@ -1951,7 +1951,6 @@ plugin.available.author=Autor plugin.available.install=Nainštalovať plugin.available.no_plugin=Nie sú dostupné žiadne nové zásuvné moduly. plugin.available.download=Stiahnuť a nainštalovať -plugin.available.open_source= Open source zásuvné moduly plugin.available.installation.success = Zásuvný modul bol úspešne nainštalovaný. plugin.available.commercial_plugins = Komerčné zásuvné moduly plugin.available.outdated = Zoznam zásuvných modulov vyžaduje novšiu verziu servera. diff --git a/i18n/src/main/resources/openfire_i18n_uk_UA.properties b/i18n/src/main/resources/openfire_i18n_uk_UA.properties index 5d963a6709..b2b896008b 100644 --- a/i18n/src/main/resources/openfire_i18n_uk_UA.properties +++ b/i18n/src/main/resources/openfire_i18n_uk_UA.properties @@ -2839,7 +2839,6 @@ plugin.available.file_size=Розмір файлу plugin.available.install=Встановити plugin.available.no_plugin=Немає нових плагінів. plugin.available.download=Завантажте та встановіть -plugin.available.open_source= Плагіни з відкритим кодом plugin.available.installation.success = плагін успішно встановлено. plugin.available.commercial_plugins = Комерційні плагіни plugin.available.outdated = Для наведеного нижче списку плагінів потрібна новіша версія сервера. diff --git a/i18n/src/main/resources/openfire_i18n_zh_CN.properties b/i18n/src/main/resources/openfire_i18n_zh_CN.properties index e52fa8281b..5484488df5 100644 --- a/i18n/src/main/resources/openfire_i18n_zh_CN.properties +++ b/i18n/src/main/resources/openfire_i18n_zh_CN.properties @@ -2849,7 +2849,6 @@ plugin.available.file_size=文件大小 plugin.available.install=安装 plugin.available.no_plugin=没有可用的新插件。 plugin.available.download=下载并安装 -plugin.available.open_source= 开源插件 plugin.available.installation.success = 插件安装成功。 plugin.available.commercial_plugins = 商用插件 plugin.available.outdated = 下面的插件列表需要较新版本的服务器。 diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index 270b9978cd..f72fd7affd 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -240,7 +240,7 @@   - + From 77fb8fca229e18b9175a4651a18fd7974d17cc8a Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 20:16:19 +0300 Subject: [PATCH 2/7] OF-2892: admin console plugins pages: wrap description --- xmppserver/src/main/webapp/available-plugins.jsp | 2 +- xmppserver/src/main/webapp/plugin-admin.jsp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index f72fd7affd..b3654b480b 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -241,7 +241,7 @@   - + diff --git a/xmppserver/src/main/webapp/plugin-admin.jsp b/xmppserver/src/main/webapp/plugin-admin.jsp index d3c8f1fcf7..6534259a0e 100644 --- a/xmppserver/src/main/webapp/plugin-admin.jsp +++ b/xmppserver/src/main/webapp/plugin-admin.jsp @@ -380,7 +380,7 @@ tr.lowerhalf > td:last-child { - + From 8f77ef4a80bd67a297a51d20db354b40692726d2 Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 22:11:23 +0300 Subject: [PATCH 3/7] OF-2892: admin console Plugins pages: use text instead of icons --- xmppserver/src/main/webapp/available-plugins.jsp | 8 ++++---- xmppserver/src/main/webapp/plugin-admin.jsp | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index b3654b480b..de1bc10ead 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -276,14 +276,14 @@ "> - + target="_blank"> + "> - + target="_blank"> + diff --git a/xmppserver/src/main/webapp/plugin-admin.jsp b/xmppserver/src/main/webapp/plugin-admin.jsp index 6534259a0e..af311981ad 100644 --- a/xmppserver/src/main/webapp/plugin-admin.jsp +++ b/xmppserver/src/main/webapp/plugin-admin.jsp @@ -439,14 +439,14 @@ tr.lowerhalf > td:last-child { "> - + target="_blank"> + "> - + target="_blank"> + From 9ac53d8d539e79c2b47ce65ea6271dd79b74cd44 Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 22:13:10 +0300 Subject: [PATCH 4/7] OF-2892: admin console Plugins pages: merge name and description --- .../src/main/webapp/available-plugins.jsp | 17 +++++------- xmppserver/src/main/webapp/plugin-admin.jsp | 26 ++++++++++--------- 2 files changed, 20 insertions(+), 23 deletions(-) diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index de1bc10ead..7b24272cea 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -240,8 +240,7 @@   - - + @@ -268,12 +267,13 @@ - + - +
+
+ +
- - @@ -287,11 +287,6 @@ - - - - - diff --git a/xmppserver/src/main/webapp/plugin-admin.jsp b/xmppserver/src/main/webapp/plugin-admin.jsp index af311981ad..47924d8349 100644 --- a/xmppserver/src/main/webapp/plugin-admin.jsp +++ b/xmppserver/src/main/webapp/plugin-admin.jsp @@ -378,9 +378,8 @@ tr.lowerhalf > td:last-child {
- - - + + @@ -433,16 +432,24 @@ tr.lowerhalf > td:last-child { - - + - - - - - - - - - - - - - - - - From 5917a862bfe70415b9493bcf5e0b0c2ce2a65f94 Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 22:28:59 +0300 Subject: [PATCH 7/7] OF-2892: admin console Available Plugins page: show releaseDate in ISO and store it --- .../openfire/update/AvailablePlugin.java | 12 +----------- .../jivesoftware/openfire/update/UpdateManager.java | 1 + 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/xmppserver/src/main/java/org/jivesoftware/openfire/update/AvailablePlugin.java b/xmppserver/src/main/java/org/jivesoftware/openfire/update/AvailablePlugin.java index a89f126aeb..8dcab96081 100644 --- a/xmppserver/src/main/java/org/jivesoftware/openfire/update/AvailablePlugin.java +++ b/xmppserver/src/main/java/org/jivesoftware/openfire/update/AvailablePlugin.java @@ -37,8 +37,6 @@ public class AvailablePlugin extends PluginMetadata { private static final Logger Log = LoggerFactory.getLogger( AvailablePlugin.class ); - private static final DateFormat RELEASE_DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd"); - private static final DateFormat RELEASE_DATE_DISPLAY_FORMAT = DateFormat.getDateInstance(DateFormat.MEDIUM); /** * URL from where the latest version of the plugin can be downloaded. @@ -141,15 +139,7 @@ public static AvailablePlugin getInstance( Element plugin ) minJavaVersion = new JavaSpecVersion( minJavaVersionValue ); } - String releaseDate = null; - final String releaseDateString = plugin.attributeValue("releaseDate"); - if( releaseDateString!= null) { - try { - releaseDate = RELEASE_DATE_DISPLAY_FORMAT.format(RELEASE_DATE_FORMAT.parse(releaseDateString)); - } catch (final ParseException e) { - Log.warn("Unexpected exception parsing release date: " + releaseDateString, e); - } - } + final String releaseDate = plugin.attributeValue("releaseDate"); long fileSize = -1; String fileSizeValue = plugin.attributeValue("fileSize"); diff --git a/xmppserver/src/main/java/org/jivesoftware/openfire/update/UpdateManager.java b/xmppserver/src/main/java/org/jivesoftware/openfire/update/UpdateManager.java index eba3ea01e7..6440765120 100644 --- a/xmppserver/src/main/java/org/jivesoftware/openfire/update/UpdateManager.java +++ b/xmppserver/src/main/java/org/jivesoftware/openfire/update/UpdateManager.java @@ -730,6 +730,7 @@ private void saveAvailablePluginsInfo() { Element component = xml.addElement("plugin"); component.addAttribute("name", plugin.getName()); component.addAttribute("latest", plugin.getVersion() != null ? plugin.getVersion().getVersionString() : null); + component.addAttribute("releaseDate", plugin.getReleaseDate()); component.addAttribute("changelog", plugin.getChangelog() != null ? plugin.getChangelog().toExternalForm() : null ); component.addAttribute("url", plugin.getDownloadURL() != null ? plugin.getDownloadURL().toExternalForm() : null ); component.addAttribute("author", plugin.getAuthor());
  - - + +
+ +
+
+
+ + id="${update.hashCode()}-version"> + +
+ @@ -450,11 +457,6 @@ tr.lowerhalf > td:last-child {
- - - - id="${update.hashCode()}-version"> From 93442ded87109381de2267e9b9a6c1a3e04ec9de Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 22:16:44 +0300 Subject: [PATCH 5/7] OF-2892: admin console Plugins pages: merge version, releaseDate and changelog --- xmppserver/src/main/webapp/available-plugins.jsp | 16 ++++++++-------- xmppserver/src/main/webapp/plugin-admin.jsp | 7 ------- 2 files changed, 8 insertions(+), 15 deletions(-) diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index 7b24272cea..802d5ddb9b 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -280,19 +280,19 @@ - - - - - - +
-
+
+
+ + + +
diff --git a/xmppserver/src/main/webapp/plugin-admin.jsp b/xmppserver/src/main/webapp/plugin-admin.jsp index 47924d8349..2b4880c9e1 100644 --- a/xmppserver/src/main/webapp/plugin-admin.jsp +++ b/xmppserver/src/main/webapp/plugin-admin.jsp @@ -457,13 +457,6 @@ tr.lowerhalf > td:last-child { - - id="${update.hashCode()}-version"> - - - - From c875de455a81ca2196468240cfcaf9ab959bef1d Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Thu, 17 Oct 2024 22:18:17 +0300 Subject: [PATCH 6/7] OF-2892: admin console Plugins pages: fix column width --- xmppserver/src/main/webapp/available-plugins.jsp | 12 ++++++------ xmppserver/src/main/webapp/plugin-admin.jsp | 12 ++++-------- 2 files changed, 10 insertions(+), 14 deletions(-) diff --git a/xmppserver/src/main/webapp/available-plugins.jsp b/xmppserver/src/main/webapp/available-plugins.jsp index 802d5ddb9b..4782fb2c57 100644 --- a/xmppserver/src/main/webapp/available-plugins.jsp +++ b/xmppserver/src/main/webapp/available-plugins.jsp @@ -257,7 +257,7 @@
+ Plugin @@ -267,7 +267,7 @@ +
@@ -281,7 +281,7 @@
+
@@ -295,15 +295,15 @@
+ + + <fmt:message key="> diff --git a/xmppserver/src/main/webapp/plugin-admin.jsp b/xmppserver/src/main/webapp/plugin-admin.jsp index 2b4880c9e1..2f2e5433b8 100644 --- a/xmppserver/src/main/webapp/plugin-admin.jsp +++ b/xmppserver/src/main/webapp/plugin-admin.jsp @@ -444,7 +444,7 @@ tr.lowerhalf > td:last-child { + id="${update.hashCode()}-version"> @@ -457,19 +457,19 @@ tr.lowerhalf > td:last-child { + + " ><fmt:message key= ${plugin.name}"> + ')) { location.replace('plugin-admin.jsp?csrf=${csrf}&deleteplugin=${admin:urlEncode( plugin.canonicalName )}'); } " title="" ><fmt:message key= ${plugin.name}"> @@ -489,11 +489,7 @@ tr.lowerhalf > td:last-child {