diff --git a/CHANGELOG.md b/CHANGELOG.md
index f9cb19948..c588683eb 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,9 @@
+# v3.2.1-rc1
+
+- Improved the Schema Table update engine (more)
+- Fix autoloader timing, and loading.
+- Implement the Joomla Powers in JCB code, to move away from JClasses.
+
# v3.2.1-beta3
- Fix version_update column size.
diff --git a/README.md b/README.md
index 1162ef525..9cc32291f 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ The Component Builder for [Joomla](https://extensions.joomla.org/extension/compo
Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will save you lots of time and money. A real must have!
-You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.2.1-beta3) with **ALL** its features and **ALL** concepts totally open-source and free!
+You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.2.1-rc1) with **ALL** its features and **ALL** concepts totally open-source and free!
> Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
@@ -144,13 +144,13 @@ TODO
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Component Builder](https://git.vdm.dev/joomla/Component-Builder)
+ *First Build*: 30th April, 2015
-+ *Last Build*: 24th April, 2024
-+ *Version*: 3.2.1-beta3
++ *Last Build*: 27th April, 2024
++ *Version*: 3.2.1-rc1
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
-+ *Line count*: **764955**
++ *Line count*: **764912**
+ *Field count*: **2097**
-+ *File count*: **5382**
++ *File count*: **5383**
+ *Folder count*: **471**
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
diff --git a/admin/README.txt b/admin/README.txt
index 1162ef525..9cc32291f 100644
--- a/admin/README.txt
+++ b/admin/README.txt
@@ -9,7 +9,7 @@ The Component Builder for [Joomla](https://extensions.joomla.org/extension/compo
Whether you're a seasoned [Joomla](https://extensions.joomla.org/extension/component-builder/) developer, or have just started, Component Builder will save you lots of time and money. A real must have!
-You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.2.1-beta3) with **ALL** its features and **ALL** concepts totally open-source and free!
+You can install it quite easily and with no limitations. On [gitea](https://git.vdm.dev/joomla/Component-Builder/tags) is the latest release (3.2.1-rc1) with **ALL** its features and **ALL** concepts totally open-source and free!
> Watch Quick Build of a Hello World component in [JCB on Youtube](https://www.youtube.com/watch?v=IQfsLYIeblk&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&index=45)
@@ -144,13 +144,13 @@ TODO
+ *Author*: [Llewellyn van der Merwe](mailto:joomla@vdm.io)
+ *Name*: [Component Builder](https://git.vdm.dev/joomla/Component-Builder)
+ *First Build*: 30th April, 2015
-+ *Last Build*: 24th April, 2024
-+ *Version*: 3.2.1-beta3
++ *Last Build*: 27th April, 2024
++ *Version*: 3.2.1-rc1
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
-+ *Line count*: **764955**
++ *Line count*: **764912**
+ *Field count*: **2097**
-+ *File count*: **5382**
++ *File count*: **5383**
+ *Folder count*: **471**
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
diff --git a/admin/compiler/joomla_3/Helper.php b/admin/compiler/joomla_3/Helper.php
index 5df959fc1..72aa952ad 100644
--- a/admin/compiler/joomla_3/Helper.php
+++ b/admin/compiler/joomla_3/Helper.php
@@ -17,12 +17,7 @@ defined('_JEXEC') or die('Restricted access');
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project admin area.
-$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_###component###/helpers/powerloader.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###CUSTOM_POWER_AUTOLOADER###
###ADMIN_HELPER_CLASS_HEADER###
diff --git a/admin/compiler/joomla_3/Helper_site.php b/admin/compiler/joomla_3/Helper_site.php
index d773a70df..d4a7811e4 100644
--- a/admin/compiler/joomla_3/Helper_site.php
+++ b/admin/compiler/joomla_3/Helper_site.php
@@ -17,12 +17,7 @@ defined('_JEXEC') or die('Restricted access');
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project site area.
-$power_autoloader = JPATH_SITE . '/components/com_###component###/helpers/powerloader.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###SITE_CUSTOM_POWER_AUTOLOADER###
###SITE_HELPER_CLASS_HEADER###
diff --git a/admin/compiler/joomla_3/component_admin.php b/admin/compiler/joomla_3/component_admin.php
index f4f64bed3..b422d08cb 100644
--- a/admin/compiler/joomla_3/component_admin.php
+++ b/admin/compiler/joomla_3/component_admin.php
@@ -17,12 +17,7 @@ defined('_JEXEC') or die('Restricted access');
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project admin area.
-$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_###component###/helpers/powerloader.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###CUSTOM_POWER_AUTOLOADER###
###ADMIN_COMPONENT_HEADER###
diff --git a/admin/compiler/joomla_3/component_site.php b/admin/compiler/joomla_3/component_site.php
index 99dd26f53..e95ccf8ef 100644
--- a/admin/compiler/joomla_3/component_site.php
+++ b/admin/compiler/joomla_3/component_site.php
@@ -17,12 +17,7 @@ defined('_JEXEC') or die('Restricted access');
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project site area.
-$power_autoloader = JPATH_SITE . '/components/com_###component###/helpers/powerloader.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###SITE_CUSTOM_POWER_AUTOLOADER###
###SITE_COMPONENT_HEADER###
diff --git a/admin/compiler/joomla_4/ADMIN_HELPER_CLASS.php b/admin/compiler/joomla_4/ADMIN_HELPER_CLASS.php
index 3318da99a..cb34191e0 100644
--- a/admin/compiler/joomla_4/ADMIN_HELPER_CLASS.php
+++ b/admin/compiler/joomla_4/ADMIN_HELPER_CLASS.php
@@ -15,12 +15,7 @@ defined('_JCB_TEMPLATE') or die;
###BOM###
namespace ###NAMESPACEPREFIX###\Component\###ComponentNamespace###\Administrator\Helper;
-// The power autoloader for this project admin area.
-$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_###component###/src/Helper/PowerloaderHelper.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###CUSTOM_POWER_AUTOLOADER###
###ADMIN_HELPER_CLASS_HEADER###
diff --git a/admin/compiler/joomla_4/ADMIN_PROVIDER.php b/admin/compiler/joomla_4/ADMIN_PROVIDER.php
index 4bd2aa763..69377b780 100644
--- a/admin/compiler/joomla_4/ADMIN_PROVIDER.php
+++ b/admin/compiler/joomla_4/ADMIN_PROVIDER.php
@@ -14,12 +14,7 @@ defined('_JCB_TEMPLATE') or die;
?>
###BOM###
-// The power autoloader for this project admin area.
-$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_###component###/src/Helper/PowerloaderHelper.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###CUSTOM_POWER_AUTOLOADER###
// (soon) use Joomla\CMS\Association\AssociationExtensionInterface;
use Joomla\CMS\Categories\CategoryFactoryInterface;
diff --git a/admin/compiler/joomla_4/SITE_HELPER_CLASS.php b/admin/compiler/joomla_4/SITE_HELPER_CLASS.php
index 7dad6f100..0ab20f8f2 100644
--- a/admin/compiler/joomla_4/SITE_HELPER_CLASS.php
+++ b/admin/compiler/joomla_4/SITE_HELPER_CLASS.php
@@ -15,12 +15,7 @@ defined('_JCB_TEMPLATE') or die;
###BOM###
namespace ###NAMESPACEPREFIX###\Component\###ComponentNamespace###\Site\Helper;
-// The power autoloader for this project site area.
-$power_autoloader = JPATH_SITE . '/components/com_###component###/src/Helper/PowerloaderHelper.php';
-if (file_exists($power_autoloader))
-{
- require_once $power_autoloader;
-}
+###SITE_CUSTOM_POWER_AUTOLOADER###
###SITE_HELPER_CLASS_HEADER###
diff --git a/admin/componentbuilder.php b/admin/componentbuilder.php
index 73a661884..b845430d9 100644
--- a/admin/componentbuilder.php
+++ b/admin/componentbuilder.php
@@ -12,7 +12,7 @@
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project admin area.
+// The power autoloader for this project (JPATH_ADMINISTRATOR) area.
$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_componentbuilder/helpers/powerloader.php';
if (file_exists($power_autoloader))
{
diff --git a/admin/controllers/admin_views.php b/admin/controllers/admin_views.php
index 8b95dbb06..8c99d98c7 100644
--- a/admin/controllers/admin_views.php
+++ b/admin/controllers/admin_views.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Admin_views Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerAdmin_views extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=admin_views', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=admin_views', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -136,7 +137,7 @@ class ComponentbuilderControllerAdmin_views extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/compiler.php b/admin/controllers/compiler.php
index e46145a32..622c810f9 100644
--- a/admin/controllers/compiler.php
+++ b/admin/controllers/compiler.php
@@ -22,6 +22,7 @@ use VDM\Joomla\Componentbuilder\Compiler\Factory as CFactory;
use Joomla\CMS\Version;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Compiler Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerCompiler extends AdminController
$redirect_url = Route::_('index.php?option=com_componentbuilder&view=compiler', false);
if (($pos = strpos($model->compiler->filepath['component'], "/tmp/")) !== FALSE)
{
- $url = \JUri::root() . substr($model->compiler->filepath['component'], $pos + 1);
+ $url = Uri::root() . substr($model->compiler->filepath['component'], $pos + 1);
}
// check if we have plugins
$add_plugin_install = UtilitiesArrayHelper::check($model->compiler->filepath['plugins'], true);
@@ -210,7 +211,7 @@ class ComponentbuilderControllerCompiler extends AdminController
$message[] = 'Module Path: ' . $module_path . '
';
if (($pos = strpos($module_path, "/tmp/")) !== FALSE)
{
- $module_urls[$module_id] = \JUri::root() . substr($module_path, $pos + 1);
+ $module_urls[$module_id] = Uri::root() . substr($module_path, $pos + 1);
$message[] = 'Module URL: ' . $module_urls[$module_id] . '
';
}
}
@@ -226,7 +227,7 @@ class ComponentbuilderControllerCompiler extends AdminController
$message[] = 'Plugin Path: ' . $plugin_path . '
';
if (($pos = strpos($plugin_path, "/tmp/")) !== FALSE)
{
- $plugin_urls[$plugin_id] = \JUri::root() . substr($plugin_path, $pos + 1);
+ $plugin_urls[$plugin_id] = Uri::root() . substr($plugin_path, $pos + 1);
$message[] = 'Plugin URL: ' . $plugin_urls[$plugin_id] . '
';
}
}
@@ -532,7 +533,7 @@ class ComponentbuilderControllerCompiler extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=compiler', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=compiler', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -541,7 +542,7 @@ class ComponentbuilderControllerCompiler extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/custom_codes.php b/admin/controllers/custom_codes.php
index efa3af237..84b7c9a61 100644
--- a/admin/controllers/custom_codes.php
+++ b/admin/controllers/custom_codes.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Custom_codes Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerCustom_codes extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=custom_codes', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=custom_codes', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -136,7 +137,7 @@ class ComponentbuilderControllerCustom_codes extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/dynamic_gets.php b/admin/controllers/dynamic_gets.php
index 8c49894be..e9fa22845 100644
--- a/admin/controllers/dynamic_gets.php
+++ b/admin/controllers/dynamic_gets.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Dynamic_gets Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerDynamic_gets extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=dynamic_gets', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=dynamic_gets', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -136,7 +137,7 @@ class ComponentbuilderControllerDynamic_gets extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/fields.php b/admin/controllers/fields.php
index acaa65876..79da8d760 100644
--- a/admin/controllers/fields.php
+++ b/admin/controllers/fields.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Fields Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerFields extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=fields', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=fields', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -136,7 +137,7 @@ class ComponentbuilderControllerFields extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/joomla_components.php b/admin/controllers/joomla_components.php
index 42091f0b5..1d6062886 100644
--- a/admin/controllers/joomla_components.php
+++ b/admin/controllers/joomla_components.php
@@ -22,6 +22,7 @@ use VDM\Joomla\Componentbuilder\Package\Factory as PackageFactory;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Joomla_components Admin Controller
@@ -128,7 +129,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=joomla_components', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=joomla_components', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -137,7 +138,7 @@ class ComponentbuilderControllerJoomla_components extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/joomla_plugins.php b/admin/controllers/joomla_plugins.php
index bdc218298..0c23e39d4 100644
--- a/admin/controllers/joomla_plugins.php
+++ b/admin/controllers/joomla_plugins.php
@@ -19,6 +19,7 @@ use Joomla\Utilities\ArrayHelper;
use Joomla\CMS\Router\Route;
use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Joomla_plugins Admin Controller
@@ -62,7 +63,7 @@ class ComponentbuilderControllerJoomla_plugins extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=joomla_plugins', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=joomla_plugins', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -71,7 +72,7 @@ class ComponentbuilderControllerJoomla_plugins extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
@@ -102,7 +103,7 @@ class ComponentbuilderControllerJoomla_plugins extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=joomla_plugins', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=joomla_plugins', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_GET_BOILERPLATE_MODULE');
// check if this user has the right to run expansion
diff --git a/admin/controllers/powers.php b/admin/controllers/powers.php
index 15907cc25..c66cfcd6e 100644
--- a/admin/controllers/powers.php
+++ b/admin/controllers/powers.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\StringHelper;
use VDM\Joomla\Componentbuilder\Power\Factory as PowerFactory;
use VDM\Joomla\Utilities\GetHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Powers Admin Controller
@@ -64,7 +65,7 @@ class ComponentbuilderControllerPowers extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=powers', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=powers', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -73,7 +74,7 @@ class ComponentbuilderControllerPowers extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/controllers/validation_rules.php b/admin/controllers/validation_rules.php
index 69c81f4d9..f2f78f12d 100644
--- a/admin/controllers/validation_rules.php
+++ b/admin/controllers/validation_rules.php
@@ -21,6 +21,7 @@ use Joomla\CMS\Session\Session;
use VDM\Joomla\Utilities\ArrayHelper as UtilitiesArrayHelper;
use VDM\Joomla\Utilities\ObjectHelper;
use VDM\Joomla\Utilities\StringHelper;
+use Joomla\CMS\Uri\Uri;
/**
* Validation_rules Admin Controller
@@ -127,7 +128,7 @@ class ComponentbuilderControllerValidation_rules extends AdminController
// check if user has the right
$user = Factory::getUser();
// set page redirect
- $redirect_url = \JRoute::_('index.php?option=com_componentbuilder&view=validation_rules', false);
+ $redirect_url = Route::_('index.php?option=com_componentbuilder&view=validation_rules', false);
// set massage
$message = Text::_('COM_COMPONENTBUILDER_YOU_DO_NOT_HAVE_PERMISSION_TO_RUN_THE_EXPANSION_MODULE');
// check if this user has the right to run expansion
@@ -136,7 +137,7 @@ class ComponentbuilderControllerValidation_rules extends AdminController
// set massage
$message = Text::_('COM_COMPONENTBUILDER_EXPANSION_FAILED_PLEASE_CHECK_YOUR_SETTINGS_IN_THE_GLOBAL_OPTIONS_OF_JCB_UNDER_THE_DEVELOPMENT_METHOD_TAB');
// run expansion via API
- $result = ComponentbuilderHelper::getFileContents(\JUri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
+ $result = ComponentbuilderHelper::getFileContents(Uri::root() . 'index.php?option=com_componentbuilder&task=api.expand');
// is there a message returned
if (!is_numeric($result) && StringHelper::check($result))
{
diff --git a/admin/helpers/componentbuilder.php b/admin/helpers/componentbuilder.php
index b1a970aff..620e4d854 100644
--- a/admin/helpers/componentbuilder.php
+++ b/admin/helpers/componentbuilder.php
@@ -12,7 +12,7 @@
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
-// The power autoloader for this project admin area.
+// The power autoloader for this project (JPATH_ADMINISTRATOR) area.
$power_autoloader = JPATH_ADMINISTRATOR . '/components/com_componentbuilder/helpers/powerloader.php';
if (file_exists($power_autoloader))
{
@@ -61,6 +61,7 @@ use VDM\Joomla\Utilities\String\PluginHelper;
use VDM\Joomla\Utilities\GuidHelper;
use VDM\Joomla\Utilities\Component\Helper;
use VDM\Joomla\Utilities\FormHelper;
+use Joomla\CMS\Router\Route;
/**
* Componentbuilder component helper.
@@ -2751,7 +2752,7 @@ abstract class ComponentbuilderHelper
// get the global settings
if (!ObjectHelper::check(self::$params))
{
- self::$params = \JComponentHelper::getParams('com_componentbuilder');
+ self::$params = ComponentHelper::getParams('com_componentbuilder');
}
self::$gitHubAccessToken = self::$params->get('github_access_token', null);
}
@@ -3254,7 +3255,7 @@ abstract class ComponentbuilderHelper
$script['view'][] = PHP_EOL . "";
$script['view'][] = "";
$script['view'][] = PHP_EOL . "