From b85a18f32b0dcd501ce73dca39e15660d6860217 Mon Sep 17 00:00:00 2001 From: Llewellyn van der Merwe Date: Mon, 10 Jan 2022 16:13:13 +0200 Subject: [PATCH] update - v1.0.9 --- componentbuilderheaderscompiler.php | 90 ++++++++++++++++++- componentbuilderheaderscompiler.xml | 4 +- ...ension_componentbuilderheaderscompiler.ini | 2 +- ...on_componentbuilderheaderscompiler.sys.ini | 2 +- script.php | 11 ++- 5 files changed, 101 insertions(+), 8 deletions(-) diff --git a/componentbuilderheaderscompiler.php b/componentbuilderheaderscompiler.php index f9004b7..9aa6142 100644 --- a/componentbuilderheaderscompiler.php +++ b/componentbuilderheaderscompiler.php @@ -22,7 +22,7 @@ JLoader::register('ComponentbuilderHelper', JPATH_ADMINISTRATOR . '/components/c * Extension - Componentbuilder Headers Compiler plugin. * * @package ComponentbuilderHeadersCompiler - * @since 1.0.8 + * @since 1.0.9 */ class PlgExtensionComponentbuilderHeadersCompiler extends CMSPlugin { @@ -214,6 +214,94 @@ class PlgExtensionComponentbuilderHeadersCompiler extends CMSPlugin 'view' => 'ajax' ) ), + 'dynamic_get_headers' => + array( + 'add_site_view_model' => array( + 'field' => 'site_view_model', + 'context' => 'site.view.model', + 'view' => 'code' + ), + 'add_site_view' => array( + 'field' => 'site_view', + 'context' => 'site.view', + 'view' => 'code' + ), + 'add_site_view_html' => array( + 'field' => 'site_view_html', + 'context' => 'site.view.html', + 'view' => 'code' + ), + 'add_site_view_controller' => array( + 'field' => 'site_view_controller', + 'context' => 'site.view.controller', + 'view' => 'code' + ), + 'add_site_views_model' => array( + 'field' => 'site_views_model', + 'context' => 'site.views.model', + 'view' => 'code' + ), + 'add_site_views' => array( + 'field' => 'site_views', + 'context' => 'site.views', + 'view' => 'code' + ), + 'add_site_views_html' => array( + 'field' => 'site_views_html', + 'context' => 'site.views.html', + 'view' => 'code' + ), + 'add_site_views_controller' => array( + 'field' => 'site_views_controller', + 'context' => 'site.views.controller', + 'view' => 'code' + ), + 'add_custom_admin_view_model' => array( + 'field' => 'custom_admin_view_model', + 'context' => 'custom.admin.view.model', + 'view' => 'code' + ), + 'add_custom_admin_view' => array( + 'field' => 'custom_admin_view', + 'context' => 'custom.admin.view', + 'view' => 'code' + ), + 'add_custom_admin_view_html' => array( + 'field' => 'custom_admin_view_html', + 'context' => 'custom.admin.view.html', + 'view' => 'code' + ), + 'add_custom_admin_view_controller' => array( + 'field' => 'custom_admin_view_controller', + 'context' => 'custom.admin.view.controller', + 'view' => 'code' + ), + 'add_custom_admin_views_model' => array( + 'field' => 'custom_admin_views_model', + 'context' => 'custom.admin.views.model', + 'view' => 'code' + ), + 'add_custom_admin_views' => array( + 'field' => 'custom_admin_views', + 'context' => 'custom.admin.views', + 'view' => 'code' + ), + 'add_custom_admin_views_html' => array( + 'field' => 'custom_admin_views_html', + 'context' => 'custom.admin.views.html', + 'view' => 'code' + ), + 'add_custom_admin_views_controller' => array( + 'field' => 'custom_admin_views_controller', + 'context' => 'custom.admin.views.controller', + 'view' => 'code' + ), + 'add_ajax_model' => array( + 'field' => 'ajax_model', + 'context' => 'ajax.admin.model', + 'view' => 'ajax' + ) + ), 'component_dashboard_headers' => array( 'add_dashboard_model' => array( diff --git a/componentbuilderheaderscompiler.xml b/componentbuilderheaderscompiler.xml index d27188c..3481a54 100644 --- a/componentbuilderheaderscompiler.xml +++ b/componentbuilderheaderscompiler.xml @@ -1,13 +1,13 @@ PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER - 7th January, 2022 + 10th January, 2022 Llewellyn van der Merwe joomla@vdm.io https://dev.vdm.io Copyright (C) 2015 Vast Development Method. All rights reserved. GNU General Public License version 2 or later; see LICENSE.txt - 1.0.8 + 1.0.9 PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_XML_DESCRIPTION diff --git a/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.ini b/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.ini index 32eed19..a0c4450 100644 --- a/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.ini +++ b/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.ini @@ -2,6 +2,6 @@ PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER="Extension - Componentbuilder Head PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_DESCRIPTION="This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. Also be sure to set your code where you would like to set Custom Headers." -PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_XML_DESCRIPTION="

Extension - Componentbuilder Headers Compiler (v.1.0.8)

This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. +PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_XML_DESCRIPTION="

Extension - Componentbuilder Headers Compiler (v.1.0.9)

This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. Also be sure to set your code where you would like to set Custom Headers.

Created by Llewellyn van der Merwe
Development started 24th May, 2020

" \ No newline at end of file diff --git a/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.sys.ini b/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.sys.ini index 32eed19..a0c4450 100644 --- a/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.sys.ini +++ b/language/en-GB/en-GB.plg_extension_componentbuilderheaderscompiler.sys.ini @@ -2,6 +2,6 @@ PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER="Extension - Componentbuilder Head PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_DESCRIPTION="This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. Also be sure to set your code where you would like to set Custom Headers." -PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_XML_DESCRIPTION="

Extension - Componentbuilder Headers Compiler (v.1.0.8)

This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. +PLG_EXTENSION_COMPONENTBUILDERHEADERSCOMPILER_XML_DESCRIPTION="

Extension - Componentbuilder Headers Compiler (v.1.0.9)

This plugin is used to set the custom headers for your classes during compilation. To activate it you must first enable it here. Then open your JCB component global options, and under the Global tab, select this plugin in the Activate Compiler Plugins field. Also be sure to set your code where you would like to set Custom Headers.

Created by Llewellyn van der Merwe
Development started 24th May, 2020

" \ No newline at end of file diff --git a/script.php b/script.php index 82334bf..75621c8 100644 --- a/script.php +++ b/script.php @@ -61,8 +61,13 @@ class plgExtensionComponentbuilderHeadersCompilerInstallerScript { // get the version $jcbVersion = explode('.', $manifest->version); - // check that we have JCB 3 or higher installed - if (count($jcbVersion) == 3 && $jcbVersion[0] >= 3) + // check that we have JCB 3.0.6 or higher installed + if (count($jcbVersion) == 3 && $jcbVersion[0] >= 3 && + ( + ($jcbVersion[0] == 3 && $jcbVersion[1] == 0 && $jcbVersion[2] >= 6) || + ($jcbVersion[0] == 3 && $jcbVersion[1] > 0) || + $jcbVersion[0] > 3) + ) { $blockInstall = false; } @@ -70,7 +75,7 @@ class plgExtensionComponentbuilderHeadersCompilerInstallerScript // allow install if all conditions are met if ($blockInstall) { - $app->enqueueMessage('Please upgrade to JCB-Pro v3.0.0 or higher before installing this plugin.', 'error'); + $app->enqueueMessage('Please upgrade to JCB-Pro v3.0.6 or higher before installing this plugin.', 'error'); return false; } }