forked from joomla/Component-Builder
Release of v4.0.2
Fix site view form missing classes in J4+. Fix permissions tab in items in J4+. Fix site display controller checkEditId function in J4+. Add class methods to the HtmlView classes in J4+. Fix broken toolbar call in HtmlView in J4+. Fix missing scripts and styles fields and methods in the site admin view model. Update subform field layout across JCB for cleaner look. Remove expansion feature. Fix helper area. Fix database mySql update in J4+. Remove phpspreadsheet completely from Joomla 4+. Add option to use powers in preflight event in the installer class. Fix abstract schema class function check default index warring. Fix dynamicGet so that the table values will load again. #1155. Add more pure JS to the dynamic get area. Add native plugin builder for Joomla 4 & 5. Add basic API for admin views.
This commit is contained in:
parent
277d6e8355
commit
b8b885444c
57
CHANGELOG.md
57
CHANGELOG.md
@ -1,14 +1,4 @@
|
||||
# v4.0.2-beta4
|
||||
|
||||
- Add native plugin builder for Joomla 4 & 5
|
||||
|
||||
# v4.0.2-beta
|
||||
|
||||
- Fix abstract schema class function check default index warring
|
||||
- Fix dynamicGet so that the table values will load again. #1155
|
||||
- Add more pure JS to the dynamic get area
|
||||
|
||||
# v4.0.2-alpha
|
||||
# v4.0.2
|
||||
|
||||
- Fix site view form missing classes in J4+
|
||||
- Fix permissions tab in items in J4+
|
||||
@ -22,6 +12,11 @@
|
||||
- Fix database mySql update in J4+
|
||||
- Remove phpspreadsheet completely from Joomla 4+
|
||||
- Add option to use powers in preflight event in the installer class
|
||||
- Fix abstract schema class function check default index warring
|
||||
- Fix dynamicGet so that the table values will load again. #1155
|
||||
- Add more pure JS to the dynamic get area
|
||||
- Add native plugin builder for Joomla 4 & 5
|
||||
- Add basic API for admin views
|
||||
|
||||
# v4.0.1
|
||||
|
||||
@ -94,27 +89,21 @@
|
||||
- Add the BaseDatabaseModel use statement to custom site view controller. #1119
|
||||
- Fix the customfolderlist field. #1120
|
||||
|
||||
# v3.2.2
|
||||
# v3.2.3
|
||||
|
||||
- Fix auto build from SQL in Joomla 4 and 5.
|
||||
- Fix permission issue for admin views.
|
||||
- Add extending options to interfaces.
|
||||
- Update the Schema class to also update null mismatching if needed
|
||||
- Add repositories for better integration with gitea
|
||||
- Refactored the Data classes
|
||||
- Add new Data classes
|
||||
- Add new subform classes
|
||||
- Fix registry class methods return type
|
||||
- Update all list and custom fields to use the new layouts
|
||||
- Add push options to Joomla Power
|
||||
- Complete the Joomla Power Init and Reset features
|
||||
- Fix Gitea Contents class functions
|
||||
- Fix subform set methods
|
||||
- Improved the Joomla Power Push path
|
||||
- Fix the metadata, metadesc, metakey database issue
|
||||
- Fix function mismatch call in the compiler power class.
|
||||
- Fix init feature to only add missing powers
|
||||
- Fix controller postSaveHook function, for correct model class in Joomla 4 and 5
|
||||
- Fix app instances (mismatch) in the install script and schema class when installing from CLI
|
||||
- Add option to use placeholders in Joomla Power namespaces.
|
||||
- Fix subform layout of uikit in JCB
|
||||
- Fix site view form missing classes in J4+
|
||||
- Fix permissions tab in items in J4+
|
||||
- Fix site display controller checkEditId function in J4+
|
||||
- Add class methods to the HtmlView classes in J4+
|
||||
- Fix broken toolbar call in HtmlView in J4+
|
||||
- Fix missing scripts and styles fields and methods in the site admin view model
|
||||
- Update subform field layout across JCB for cleaner look
|
||||
- Remove expansion feature
|
||||
- Fix helper area
|
||||
- Fix database mySql update in J4+
|
||||
- Remove phpspreadsheet completely from Joomla 4+
|
||||
- Add option to use powers in preflight event in the installer class
|
||||
- Fix abstract schema class function check default index warring
|
||||
- Fix dynamicGet so that the table values will load again. #1155
|
||||
- Keep jQuery in dynamicGet area for Joomla 3
|
||||
- Add native plugin builder for Joomla 4 & 5
|
@ -3270,7 +3270,7 @@ class Com_ComponentbuilderInstallerScript implements InstallerScriptInterface
|
||||
echo '<div style="background-color: #fff;" class="alert alert-info"><a target="_blank" href="https://dev.vdm.io" title="Component Builder">
|
||||
<img src="components/com_componentbuilder/assets/images/vdm-component.jpg"/>
|
||||
</a>
|
||||
<h3>Upgrade to Version 4.0.2-beta4 Was Successful! Let us know if anything is not working as expected.</h3></div>';
|
||||
<h3>Upgrade to Version 4.0.2 Was Successful! Let us know if anything is not working as expected.</h3></div>';
|
||||
|
||||
// Add/Update component in the action logs extensions table.
|
||||
$this->setActionLogsExtensions();
|
||||
|
12
README.md
12
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 (4.0.2-beta4) 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 (4.0.2) 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*: 14th August, 2024
|
||||
+ *Version*: 4.0.2-beta4
|
||||
+ *Last Build*: 16th August, 2024
|
||||
+ *Version*: 4.0.2
|
||||
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||
+ *Line count*: **823989**
|
||||
+ *Field count*: **2093**
|
||||
+ *File count*: **5734**
|
||||
+ *Line count*: **824275**
|
||||
+ *Field count*: **2094**
|
||||
+ *File count*: **5732**
|
||||
+ *Folder count*: **606**
|
||||
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
|
||||
|
@ -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 (4.0.2-beta4) 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 (4.0.2) 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*: 14th August, 2024
|
||||
+ *Version*: 4.0.2-beta4
|
||||
+ *Last Build*: 16th August, 2024
|
||||
+ *Version*: 4.0.2
|
||||
+ *Copyright*: Copyright (C) 2015 Vast Development Method. All rights reserved.
|
||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||
+ *Line count*: **823989**
|
||||
+ *Field count*: **2093**
|
||||
+ *File count*: **5734**
|
||||
+ *Line count*: **824275**
|
||||
+ *Field count*: **2094**
|
||||
+ *File count*: **5732**
|
||||
+ *Folder count*: **606**
|
||||
|
||||
> This **component** was build with a [Joomla](https://extensions.joomla.org/extension/component-builder/) [Automated Component Builder](https://www.joomlacomponentbuilder.com).
|
||||
|
@ -680,6 +680,24 @@
|
||||
description="COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_PORT_DESCRIPTION"
|
||||
class="inputbox"
|
||||
/>
|
||||
<!-- Add_api Field. Type: List. (joomla) -->
|
||||
<field
|
||||
type="list"
|
||||
name="add_api"
|
||||
label="COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADD_API_LABEL"
|
||||
description="COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADD_API_DESCRIPTION"
|
||||
layout="joomla.form.field.list-fancy-select"
|
||||
multiple="false">
|
||||
<!-- Option Set. -->
|
||||
<option value="0">
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_NONE</option>
|
||||
<option value="1">
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_LIST</option>
|
||||
<option value="3">
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ITEM</option>
|
||||
<option value="2">
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOTH</option>
|
||||
</field>
|
||||
<!-- Filter Field. Type: List. (joomla) -->
|
||||
<field
|
||||
type="list"
|
||||
|
@ -2271,6 +2271,8 @@ COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADDADMIN_VIEWS_DESCRIPTION="Setup the
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADDADMIN_VIEWS_LABEL="Admin Views"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADDMENU="Add+Menu"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADDRESS="Address"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADD_API_DESCRIPTION="add API option to this admin view. (only Joomla 4+)"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADD_API_LABEL="API"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADMINVIEW="Adminview"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADMINVIEW_DESCRIPTION="Select an admin view"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ADMINVIEW_LABEL="View"
|
||||
@ -2301,6 +2303,7 @@ COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BASKET="Basket"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOOK="Book"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOOKMARK="Bookmark"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOOKMARK_2="Bookmark 2"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOTH="Both"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOX_ADD="Box Add"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BOX_REMOVE="Box Remove"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_BRIEFCASE="Briefcase"
|
||||
@ -2403,6 +2406,7 @@ COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_IMAGE="Image"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_IMAGES="Images"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_INFO="Info"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_INFO_CIRCLE="Info Circle"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_ITEM="Item"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_JOOMLA="Joomla"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_JOOMLA_COMPONENT_DESCRIPTION="Select a Joomla Component"
|
||||
COM_COMPONENTBUILDER_COMPONENT_ADMIN_VIEWS_JOOMLA_COMPONENT_LABEL="Component"
|
||||
|
@ -1 +0,0 @@
|
||||
|
@ -1 +0,0 @@
|
||||
|
@ -1 +0,0 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
@ -1 +0,0 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
@ -1 +0,0 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
@ -1 +0,0 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
@ -1,15 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<extension type="component" version="4.0" method="upgrade">
|
||||
<name>COM_COMPONENTBUILDER</name>
|
||||
<creationDate>14th August, 2024</creationDate>
|
||||
<creationDate>16th August, 2024</creationDate>
|
||||
<author>Llewellyn van der Merwe</author>
|
||||
<authorEmail>joomla@vdm.io</authorEmail>
|
||||
<authorUrl>https://dev.vdm.io</authorUrl>
|
||||
<copyright>Copyright (C) 2015 Vast Development Method. All rights reserved.</copyright>
|
||||
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
|
||||
<version>4.0.2-beta4</version>
|
||||
<version>4.0.2</version>
|
||||
<description><![CDATA[
|
||||
<h1>Component Builder (v.4.0.2-beta4)</h1>
|
||||
<h1>Component Builder (v.4.0.2)</h1>
|
||||
<div style="clear: both;"></div>
|
||||
<p>The Component Builder for [Joomla](https://extensions.joomla.org/extension/component-builder/) is highly advanced tool that is truly able to build extremely complex components in a fraction of the time.
|
||||
|
||||
|
@ -5,10 +5,10 @@
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>3.2.2</version>
|
||||
<version>3.2.3</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v3.2.2.zip</downloadurl>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v3.2.3.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>stable</tag>
|
||||
@ -59,49 +59,13 @@
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>4.0.2-alpha</version>
|
||||
<version>4.0.2</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v4.0.2-alpha3.zip</downloadurl>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v4.0.2.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>alpha</tag>
|
||||
</tags>
|
||||
<maintainer>Llewellyn van der Merwe</maintainer>
|
||||
<maintainerurl>https://dev.vdm.io</maintainerurl>
|
||||
<targetplatform name="joomla" version="4\.[01234]"/>
|
||||
</update>
|
||||
<update>
|
||||
<name>Component Builder</name>
|
||||
<description>Builds Complex Joomla Components</description>
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>4.0.2-beta</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v4.0.2-beta4.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>beta</tag>
|
||||
</tags>
|
||||
<maintainer>Llewellyn van der Merwe</maintainer>
|
||||
<maintainerurl>https://dev.vdm.io</maintainerurl>
|
||||
<targetplatform name="joomla" version="4\.[01234]"/>
|
||||
</update>
|
||||
<update>
|
||||
<name>Component Builder</name>
|
||||
<description>Builds Complex Joomla Components</description>
|
||||
<element>pkg_component_builder</element>
|
||||
<type>package</type>
|
||||
<client>site</client>
|
||||
<version>4.0.2-beta4</version>
|
||||
<infourl title="Component Builder!">https://dev.vdm.io</infourl>
|
||||
<downloads>
|
||||
<downloadurl type="full" format="zip">https://git.vdm.dev/api/v1/repos/joomla/pkg-component-builder/archive/v4.0.2-beta4.zip</downloadurl>
|
||||
</downloads>
|
||||
<tags>
|
||||
<tag>beta</tag>
|
||||
<tag>stable</tag>
|
||||
</tags>
|
||||
<maintainer>Llewellyn van der Merwe</maintainer>
|
||||
<maintainerurl>https://dev.vdm.io</maintainerurl>
|
||||
|
@ -157,6 +157,7 @@ final class Structuremultiple
|
||||
|
||||
$config = [];
|
||||
$checkin = false;
|
||||
$api = null;
|
||||
|
||||
foreach ($this->component->get('admin_views') as $view)
|
||||
{
|
||||
@ -174,8 +175,16 @@ final class Structuremultiple
|
||||
$checkin = true;
|
||||
$this->config->set('add_checkin', $checkin);
|
||||
}
|
||||
|
||||
if (($target = $this->hasApi($view)) > 0)
|
||||
{
|
||||
$this->buildApi($view, $config, $target);
|
||||
$api = 1;
|
||||
}
|
||||
}
|
||||
|
||||
$this->config->set('add_api', $api);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -265,6 +274,25 @@ final class Structuremultiple
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the view has an API
|
||||
*
|
||||
* @param array $view
|
||||
*
|
||||
* @return int
|
||||
* @since 5.0.2
|
||||
*/
|
||||
private function hasApi(array $view): int
|
||||
{
|
||||
// only for Joomla 4 and above
|
||||
if ($this->config->get('joomla_version', 3) < 4 || !isset($view['add_api']))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
return (int) $view['add_api'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the view is a valid view
|
||||
*
|
||||
@ -333,6 +361,35 @@ final class Structuremultiple
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Build the api
|
||||
*
|
||||
* @param array $view
|
||||
* @param array $config
|
||||
* @param int $targetArea
|
||||
*
|
||||
* @return void
|
||||
* @since 5.0.2
|
||||
*/
|
||||
private function buildApi(array $view, array $config, int $targetArea)
|
||||
{
|
||||
$settings = $view['settings'];
|
||||
|
||||
// build the api
|
||||
if ($settings->name_single != 'null' && $targetArea !== 1)
|
||||
{
|
||||
$target = ['api' => $settings->name_single];
|
||||
$this->structure->build($target, 'single', false, $config);
|
||||
}
|
||||
|
||||
// build the list view
|
||||
if ($settings->name_list != 'null' && $targetArea !== 3)
|
||||
{
|
||||
$target = ['api' => $settings->name_list];
|
||||
$this->structure->build($target, 'list', false, $config);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Build the custom view
|
||||
*
|
||||
|
@ -132,6 +132,12 @@ class Compiler extends Infusion
|
||||
);
|
||||
CFactory::_('Utilities.File')->write($xmlPath, $componentXML);
|
||||
}
|
||||
// remove API
|
||||
if (CFactory::_('Config')->get('add_api') === null)
|
||||
{
|
||||
// first remove the files and folders
|
||||
CFactory::_('Utilities.Folder')->remove(CFactory::_('Utilities.Paths')->component_path . '/api');
|
||||
}
|
||||
|
||||
// Trigger Event: jcb_ce_onBeforeUpdateFiles
|
||||
CFactory::_('Event')->trigger(
|
||||
|
@ -668,6 +668,7 @@ class Infusion extends Interpretation
|
||||
$nameSingleCode
|
||||
)
|
||||
);
|
||||
|
||||
// ADMIN_VIEW_MODEL_HEADER <<<DYNAMIC>>> add the header details for the model
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameSingleCode . '|ADMIN_VIEW_MODEL_HEADER',
|
||||
CFactory::_('Header')->get(
|
||||
@ -687,6 +688,22 @@ class Infusion extends Interpretation
|
||||
)
|
||||
);
|
||||
|
||||
// API_VIEW_CONTROLLER_HEADER <<<DYNAMIC>>> add the header details for the controller
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameSingleCode . '|API_VIEW_CONTROLLER_HEADER',
|
||||
CFactory::_('Header')->get(
|
||||
'api.view.controller',
|
||||
$nameSingleCode
|
||||
)
|
||||
);
|
||||
|
||||
// API_VIEW_JSON_HEADER <<<DYNAMIC>>> add the header details for the controller
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameSingleCode . '|API_VIEW_JSON_HEADER',
|
||||
CFactory::_('Header')->get(
|
||||
'api.view.json',
|
||||
$nameSingleCode
|
||||
)
|
||||
);
|
||||
|
||||
// JQUERY <<<DYNAMIC>>>
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameSingleCode . '|JQUERY',
|
||||
$this->setJquery(
|
||||
@ -1028,6 +1045,20 @@ class Infusion extends Interpretation
|
||||
)
|
||||
);
|
||||
|
||||
// API_VIEWS_CONTROLLER_HEADER <<<DYNAMIC>>> add the header details for the controller
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameListCode . '|API_VIEWS_CONTROLLER_HEADER',
|
||||
CFactory::_('Header')->get(
|
||||
'api.views.controller', $nameListCode
|
||||
)
|
||||
);
|
||||
|
||||
// API_VIEWS_JSON_HEADER <<<DYNAMIC>>> add the header details for the controller
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameListCode . '|API_VIEWS_JSON_HEADER',
|
||||
CFactory::_('Header')->get(
|
||||
'api.views.json', $nameListCode
|
||||
)
|
||||
);
|
||||
|
||||
// JQUERY <<<DYNAMIC>>>
|
||||
CFactory::_('Compiler.Builder.Content.Multi')->set($nameListCode . '|JQUERY',
|
||||
$this->setJquery(
|
||||
|
@ -565,6 +565,20 @@ final class Header implements HeaderInterface
|
||||
$headers[] = 'use Joomla\DI\Container;';
|
||||
break;
|
||||
|
||||
case 'api.view.controller':
|
||||
case 'api.views.controller':
|
||||
$headers = [];
|
||||
$headers[] = 'use Joomla\CMS\Factory;';
|
||||
$headers[] = 'use Joomla\CMS\MVC\Controller\ApiController;';
|
||||
break;
|
||||
|
||||
case 'api.view.json':
|
||||
case 'api.views.json':
|
||||
$headers = [];
|
||||
$headers[] = 'use Joomla\CMS\Factory;';
|
||||
$headers[] = 'use Joomla\CMS\MVC\View\JsonApiView as BaseApiView;';
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -565,6 +565,20 @@ final class Header implements HeaderInterface
|
||||
$headers[] = 'use Joomla\DI\Container;';
|
||||
break;
|
||||
|
||||
case 'api.view.controller':
|
||||
case 'api.views.controller':
|
||||
$headers = [];
|
||||
$headers[] = 'use Joomla\CMS\Factory;';
|
||||
$headers[] = 'use Joomla\CMS\MVC\Controller\ApiController;';
|
||||
break;
|
||||
|
||||
case 'api.view.json':
|
||||
case 'api.views.json':
|
||||
$headers = [];
|
||||
$headers[] = 'use Joomla\CMS\Factory;';
|
||||
$headers[] = 'use Joomla\CMS\MVC\View\JsonApiView as BaseApiView;';
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user