From 46bb7c31c227ea42434fbfaeae29af3cb5a4e296 Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Thu, 4 Jun 2026 20:22:11 -0500 Subject: [PATCH] refactor: rename core plugin, remove branding from support files, rename Heartbeat Token - Plugin name: System - MokoWaaS Core (was System - MokoWaaS) - Description updated to reflect admin tools suite coordinator role - Removed updateAtumBranding() from plugin install script - Removed brand_name placeholder from language override deployment - Renamed "Health API Token" label to "Heartbeat Token" in language files - Updated all .ini and .sys.ini descriptions (en-GB + en-US) Authored-by: Moko Consulting Co-Authored-By: Claude Opus 4.6 (1M context) --- .../en-GB/plg_system_mokowaas.sys.ini | 4 +- .../en-US/plg_system_mokowaas.sys.ini | 4 +- .../language/en-GB/plg_system_mokowaas.ini | 8 +-- .../en-GB/plg_system_mokowaas.sys.ini | 4 +- .../language/en-US/plg_system_mokowaas.ini | 8 +-- .../en-US/plg_system_mokowaas.sys.ini | 4 +- src/packages/plg_system_mokowaas/mokowaas.xml | 4 +- src/packages/plg_system_mokowaas/script.php | 71 ------------------- 8 files changed, 18 insertions(+), 89 deletions(-) diff --git a/src/packages/plg_system_mokowaas/administrator/language/en-GB/plg_system_mokowaas.sys.ini b/src/packages/plg_system_mokowaas/administrator/language/en-GB/plg_system_mokowaas.sys.ini index 53cb9993..14f672b5 100644 --- a/src/packages/plg_system_mokowaas/administrator/language/en-GB/plg_system_mokowaas.sys.ini +++ b/src/packages/plg_system_mokowaas/administrator/language/en-GB/plg_system_mokowaas.sys.ini @@ -15,5 +15,5 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - Moko WaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." diff --git a/src/packages/plg_system_mokowaas/administrator/language/en-US/plg_system_mokowaas.sys.ini b/src/packages/plg_system_mokowaas/administrator/language/en-US/plg_system_mokowaas.sys.ini index 5e278e69..802ce253 100644 --- a/src/packages/plg_system_mokowaas/administrator/language/en-US/plg_system_mokowaas.sys.ini +++ b/src/packages/plg_system_mokowaas/administrator/language/en-US/plg_system_mokowaas.sys.ini @@ -15,5 +15,5 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - Moko WaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." diff --git a/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.ini b/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.ini index 5f0f536a..c8a6ddec 100644 --- a/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.ini +++ b/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.ini @@ -16,8 +16,8 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - MokoWaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." PLG_SYSTEM_MOKOWAAS_ENABLE_BRANDING_LABEL="Enable Branding" PLG_SYSTEM_MOKOWAAS_ENABLE_BRANDING_DESC="Enable or disable the branding overrides across the system." @@ -111,7 +111,7 @@ PLG_SYSTEM_MOKOWAAS_SYNC_PUSH_NOW_DESC="Set to Yes and save to immediately push PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_URL_LABEL="Site URL" PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_URL_DESC="Full URL of the remote Joomla site (e.g. https://client.example.com)." PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_LABEL="API Token" -PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_DESC="The health_api_token from the remote site's MokoWaaS plugin settings." +PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_DESC="The heartbeat token from the remote site's MokoWaaS plugin settings." PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_LABEL_LABEL="Label" PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_LABEL_DESC="Friendly name for this target (for identification only)." @@ -121,7 +121,7 @@ PLG_SYSTEM_MOKOWAAS_FIELDSET_DIAGNOSTICS_DESC="Health check endpoint for externa PLG_SYSTEM_MOKOWAAS_ENABLE_HEALTH_LABEL="Enable Health Endpoint" PLG_SYSTEM_MOKOWAAS_ENABLE_HEALTH_DESC="Expose a JSON health check endpoint at /?mokowaas=health. Requires a valid API token. A random token is generated automatically when enabled." -PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_LABEL="Health API Token" +PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_LABEL="Heartbeat Token" PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_DESC="Auto-generated bearer token for the health endpoint. Use this token in your Grafana datasource configuration. Send as Authorization: Bearer <token> header or &token=<value> query parameter." PLG_SYSTEM_MOKOWAAS_GRAFANA_URL_LABEL="Grafana URL" PLG_SYSTEM_MOKOWAAS_GRAFANA_URL_DESC="Base URL of your Grafana instance (e.g. https://grafana.example.com). When provided along with an API key, the plugin will auto-provision a datasource and dashboard in Grafana when the health endpoint is enabled." diff --git a/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.sys.ini b/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.sys.ini index 7777eca0..14f672b5 100644 --- a/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.sys.ini +++ b/src/packages/plg_system_mokowaas/language/en-GB/plg_system_mokowaas.sys.ini @@ -15,5 +15,5 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - MokoWaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." diff --git a/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.ini b/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.ini index 5f0f536a..c8a6ddec 100644 --- a/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.ini +++ b/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.ini @@ -16,8 +16,8 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - MokoWaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." PLG_SYSTEM_MOKOWAAS_ENABLE_BRANDING_LABEL="Enable Branding" PLG_SYSTEM_MOKOWAAS_ENABLE_BRANDING_DESC="Enable or disable the branding overrides across the system." @@ -111,7 +111,7 @@ PLG_SYSTEM_MOKOWAAS_SYNC_PUSH_NOW_DESC="Set to Yes and save to immediately push PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_URL_LABEL="Site URL" PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_URL_DESC="Full URL of the remote Joomla site (e.g. https://client.example.com)." PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_LABEL="API Token" -PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_DESC="The health_api_token from the remote site's MokoWaaS plugin settings." +PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_TOKEN_DESC="The heartbeat token from the remote site's MokoWaaS plugin settings." PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_LABEL_LABEL="Label" PLG_SYSTEM_MOKOWAAS_SYNC_TARGET_LABEL_DESC="Friendly name for this target (for identification only)." @@ -121,7 +121,7 @@ PLG_SYSTEM_MOKOWAAS_FIELDSET_DIAGNOSTICS_DESC="Health check endpoint for externa PLG_SYSTEM_MOKOWAAS_ENABLE_HEALTH_LABEL="Enable Health Endpoint" PLG_SYSTEM_MOKOWAAS_ENABLE_HEALTH_DESC="Expose a JSON health check endpoint at /?mokowaas=health. Requires a valid API token. A random token is generated automatically when enabled." -PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_LABEL="Health API Token" +PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_LABEL="Heartbeat Token" PLG_SYSTEM_MOKOWAAS_HEALTH_TOKEN_DESC="Auto-generated bearer token for the health endpoint. Use this token in your Grafana datasource configuration. Send as Authorization: Bearer <token> header or &token=<value> query parameter." PLG_SYSTEM_MOKOWAAS_GRAFANA_URL_LABEL="Grafana URL" PLG_SYSTEM_MOKOWAAS_GRAFANA_URL_DESC="Base URL of your Grafana instance (e.g. https://grafana.example.com). When provided along with an API key, the plugin will auto-provision a datasource and dashboard in Grafana when the health endpoint is enabled." diff --git a/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.sys.ini b/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.sys.ini index 52c50199..802ce253 100644 --- a/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.sys.ini +++ b/src/packages/plg_system_mokowaas/language/en-US/plg_system_mokowaas.sys.ini @@ -15,5 +15,5 @@ ; Variables: (none) ; ----------------------------------------------------------------------------- -PLG_SYSTEM_MOKOWAAS="System - MokoWaaS" -PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform." +PLG_SYSTEM_MOKOWAAS="System - MokoWaaS Core" +PLG_SYSTEM_MOKOWAAS_XML_DESCRIPTION="MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations." diff --git a/src/packages/plg_system_mokowaas/mokowaas.xml b/src/packages/plg_system_mokowaas/mokowaas.xml index 1d69c8f7..78e8e452 100644 --- a/src/packages/plg_system_mokowaas/mokowaas.xml +++ b/src/packages/plg_system_mokowaas/mokowaas.xml @@ -22,7 +22,7 @@ NOTE: Defines installation metadata, files, and configuration for Joomla --> - System - MokoWaaS + System - MokoWaaS Core mokowaas Moko Consulting 2026-05-22 @@ -31,7 +31,7 @@ hello@mokoconsulting.tech https://mokoconsulting.tech 02.34.05-dev - This plugin rebrands the Joomla system interface with MokoWaaS identity. It applies language overrides and ensures consistent branding across the platform. + MokoWaaS core system plugin — coordinates feature plugins, master user management, event routing, and admin customizations. Moko\Plugin\System\MokoWaaS script.php diff --git a/src/packages/plg_system_mokowaas/script.php b/src/packages/plg_system_mokowaas/script.php index 1a297836..cf832550 100644 --- a/src/packages/plg_system_mokowaas/script.php +++ b/src/packages/plg_system_mokowaas/script.php @@ -127,7 +127,6 @@ class plgSystemMokoWaaSInstallerScript implements InstallerScriptInterface $this->ensureMokoCassiopeia(); $this->installLanguageOverrides(); $this->updateLoginSupportUrls(); - $this->updateAtumBranding(); $this->registerActionLogExtension(); $this->provisionHealthEndpoint(); $this->sendInstallNotification($type); @@ -552,7 +551,6 @@ class plgSystemMokoWaaSInstallerScript implements InstallerScriptInterface $params = $this->getPluginParams(); return [ - '{{BRAND_NAME}}' => $params->get('brand_name', 'MokoWaaS'), '{{COMPANY_NAME}}' => $params->get('company_name', 'Moko Consulting'), '{{SUPPORT_URL}}' => $params->get('support_url', 'https://mokoconsulting.tech/support'), ]; @@ -727,75 +725,6 @@ class plgSystemMokoWaaSInstallerScript implements InstallerScriptInterface ); } - /** - * Set Atum admin template branding params at install time. - * - * @return void - * - * @since 02.01.08 - */ - private function updateAtumBranding() - { - $mediaBase = 'media/plg_system_mokowaas/'; - - $expected = [ - 'logoBrandLarge' => $mediaBase . 'logo.png', - 'logoBrandSmall' => $mediaBase . 'favicon_256.png', - 'loginLogo' => $mediaBase . 'logo.png', - 'logoBrandLargeAlt' => '', - 'logoBrandSmallAlt' => '', - 'loginLogoAlt' => '', - 'emptyLogoBrandLargeAlt' => '1', - 'emptyLogoBrandSmallAlt' => '1', - 'emptyLoginLogoAlt' => '1', - 'hue' => 'hsl(219, 44%, 18%)', - 'special-color' => '#1a2744', - 'link-color' => '#0051ad', - ]; - - $db = Factory::getDbo(); - $query = $db->getQuery(true) - ->select([$db->quoteName('id'), $db->quoteName('params')]) - ->from($db->quoteName('#__template_styles')) - ->where($db->quoteName('template') . ' = ' - . $db->quote('atum')) - ->where($db->quoteName('client_id') . ' = 1'); - - $db->setQuery($query); - $styles = $db->loadObjectList(); - - if (empty($styles)) - { - return; - } - - foreach ($styles as $style) - { - $params = new \Joomla\Registry\Registry( - $style->params ?: '{}' - ); - - foreach ($expected as $key => $value) - { - $params->set($key, $value); - } - - $update = $db->getQuery(true) - ->update($db->quoteName('#__template_styles')) - ->set($db->quoteName('params') . ' = ' - . $db->quote($params->toString())) - ->where($db->quoteName('id') . ' = ' - . (int) $style->id); - - $db->setQuery($update); - $db->execute(); - } - - Factory::getApplication()->enqueueMessage( - 'Updated Atum template branding.', 'message' - ); - } - /** * Register the plugin in #__action_logs_extensions so it appears * as a filterable extension in System > Action Logs.