Fixed the access filter in query. Fixed the array to int helper use. Added the correct language strings to category and access filters. gh-378
This commit is contained in:
parent
4339ca00b3
commit
83e4562d62
@ -144,11 +144,11 @@ TODO
|
|||||||
+ *Author*: [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
+ *Author*: [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
||||||
+ *Name*: [Component Builder](https://github.com/vdm-io/Joomla-Component-Builder)
|
+ *Name*: [Component Builder](https://github.com/vdm-io/Joomla-Component-Builder)
|
||||||
+ *First Build*: 30th April, 2015
|
+ *First Build*: 30th April, 2015
|
||||||
+ *Last Build*: 1st December, 2020
|
+ *Last Build*: 3rd December, 2020
|
||||||
+ *Version*: 2.11.7
|
+ *Version*: 2.11.7
|
||||||
+ *Copyright*: Copyright (C) 2015 - 2020 Vast Development Method. All rights reserved.
|
+ *Copyright*: Copyright (C) 2015 - 2020 Vast Development Method. All rights reserved.
|
||||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||||
+ *Line count*: **284731**
|
+ *Line count*: **285207**
|
||||||
+ *Field count*: **1537**
|
+ *Field count*: **1537**
|
||||||
+ *File count*: **1799**
|
+ *File count*: **1799**
|
||||||
+ *Folder count*: **304**
|
+ *Folder count*: **304**
|
||||||
|
@ -144,11 +144,11 @@ TODO
|
|||||||
+ *Author*: [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
+ *Author*: [Llewellyn van der Merwe](mailto:llewellyn@joomlacomponentbuilder.com)
|
||||||
+ *Name*: [Component Builder](https://github.com/vdm-io/Joomla-Component-Builder)
|
+ *Name*: [Component Builder](https://github.com/vdm-io/Joomla-Component-Builder)
|
||||||
+ *First Build*: 30th April, 2015
|
+ *First Build*: 30th April, 2015
|
||||||
+ *Last Build*: 1st December, 2020
|
+ *Last Build*: 3rd December, 2020
|
||||||
+ *Version*: 2.11.7
|
+ *Version*: 2.11.7
|
||||||
+ *Copyright*: Copyright (C) 2015 - 2020 Vast Development Method. All rights reserved.
|
+ *Copyright*: Copyright (C) 2015 - 2020 Vast Development Method. All rights reserved.
|
||||||
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
+ *License*: GNU General Public License version 2 or later; see LICENSE.txt
|
||||||
+ *Line count*: **284731**
|
+ *Line count*: **285207**
|
||||||
+ *Field count*: **1537**
|
+ *Field count*: **1537**
|
||||||
+ *File count*: **1799**
|
+ *File count*: **1799**
|
||||||
+ *Folder count*: **304**
|
+ *Folder count*: **304**
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerAdmin_views extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Admin_views');
|
$model = $this->getModel('Admin_views');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerClass_methods extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Class_methods');
|
$model = $this->getModel('Class_methods');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerClass_properties extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Class_properties');
|
$model = $this->getModel('Class_properties');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerCustom_admin_views extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Custom_admin_views');
|
$model = $this->getModel('Custom_admin_views');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerCustom_codes extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Custom_codes');
|
$model = $this->getModel('Custom_codes');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerDynamic_gets extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Dynamic_gets');
|
$model = $this->getModel('Dynamic_gets');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerFields extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Fields');
|
$model = $this->getModel('Fields');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerFieldtypes extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Fieldtypes');
|
$model = $this->getModel('Fieldtypes');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerHelp_documents extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Help_documents');
|
$model = $this->getModel('Help_documents');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerJoomla_components extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Joomla_components');
|
$model = $this->getModel('Joomla_components');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerLanguage_translations extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Language_translations');
|
$model = $this->getModel('Language_translations');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerLanguages extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Languages');
|
$model = $this->getModel('Languages');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerLayouts extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Layouts');
|
$model = $this->getModel('Layouts');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerPlaceholders extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Placeholders');
|
$model = $this->getModel('Placeholders');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerServers extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Servers');
|
$model = $this->getModel('Servers');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerSite_views extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Site_views');
|
$model = $this->getModel('Site_views');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerSnippets extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Snippets');
|
$model = $this->getModel('Snippets');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerTemplates extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Templates');
|
$model = $this->getModel('Templates');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -55,7 +55,7 @@ class ComponentbuilderControllerValidation_rules extends JControllerAdmin
|
|||||||
$input = JFactory::getApplication()->input;
|
$input = JFactory::getApplication()->input;
|
||||||
$pks = $input->post->get('cid', array(), 'array');
|
$pks = $input->post->get('cid', array(), 'array');
|
||||||
// Sanitize the input
|
// Sanitize the input
|
||||||
ArrayHelper::toInteger($pks);
|
$pks = ArrayHelper::toInteger($pks);
|
||||||
// Get the model
|
// Get the model
|
||||||
$model = $this->getModel('Validation_rules');
|
$model = $this->getModel('Validation_rules');
|
||||||
// get the data to export
|
// get the data to export
|
||||||
|
@ -2929,7 +2929,7 @@ class Structure extends Get
|
|||||||
/**
|
/**
|
||||||
* set the Joomla Version Data
|
* set the Joomla Version Data
|
||||||
*
|
*
|
||||||
* @return oject The version data
|
* @return object The version data
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private function setJoomlaVersionData()
|
private function setJoomlaVersionData()
|
||||||
|
@ -393,12 +393,12 @@ class Fields extends Structure
|
|||||||
// add metadata to the view
|
// add metadata to the view
|
||||||
if (isset($view['metadata']) && $view['metadata'])
|
if (isset($view['metadata']) && $view['metadata'])
|
||||||
{
|
{
|
||||||
$this->metadataBuilder[$nameSingleCode] = $nameSingleCode;
|
$this->metadataBuilder[$nameSingleCode] = $nameListCode;
|
||||||
}
|
}
|
||||||
// add access to the view
|
// add access to the view
|
||||||
if (isset($view['access']) && $view['access'])
|
if (isset($view['access']) && $view['access'])
|
||||||
{
|
{
|
||||||
$this->accessBuilder[$nameSingleCode] = $nameSingleCode;
|
$this->accessBuilder[$nameSingleCode] = $nameListCode;
|
||||||
}
|
}
|
||||||
// main lang prefix
|
// main lang prefix
|
||||||
$langView = $this->langPrefix . '_'
|
$langView = $this->langPrefix . '_'
|
||||||
@ -5628,7 +5628,7 @@ class Fields extends Structure
|
|||||||
$field_filter_sets[] = $this->_t(3) . 'type="category"';
|
$field_filter_sets[] = $this->_t(3) . 'type="category"';
|
||||||
$field_filter_sets[] = $this->_t(3) . 'name="category_id"';
|
$field_filter_sets[] = $this->_t(3) . 'name="category_id"';
|
||||||
$field_filter_sets[] = $this->_t(3)
|
$field_filter_sets[] = $this->_t(3)
|
||||||
. 'label="JOPTION_FILTER_CATEGORY"';
|
. 'label="' . $this->categoryBuilder[$nameListCode]['name'] . '"';
|
||||||
$field_filter_sets[] = $this->_t(3)
|
$field_filter_sets[] = $this->_t(3)
|
||||||
. 'description="JOPTION_FILTER_CATEGORY_DESC"';
|
. 'description="JOPTION_FILTER_CATEGORY_DESC"';
|
||||||
$field_filter_sets[] = $this->_t(3) . 'multiple="true"';
|
$field_filter_sets[] = $this->_t(3) . 'multiple="true"';
|
||||||
@ -5654,9 +5654,9 @@ class Fields extends Structure
|
|||||||
$field_filter_sets[] = $this->_t(3) . 'type="accesslevel"';
|
$field_filter_sets[] = $this->_t(3) . 'type="accesslevel"';
|
||||||
$field_filter_sets[] = $this->_t(3) . 'name="access"';
|
$field_filter_sets[] = $this->_t(3) . 'name="access"';
|
||||||
$field_filter_sets[] = $this->_t(3)
|
$field_filter_sets[] = $this->_t(3)
|
||||||
. 'label="JOPTION_FILTER_ACCESS"';
|
. 'label="JFIELD_ACCESS_LABEL"';
|
||||||
$field_filter_sets[] = $this->_t(3)
|
$field_filter_sets[] = $this->_t(3)
|
||||||
. 'description="JOPTION_FILTER_ACCESS_DESC"';
|
. 'description="JFIELD_ACCESS_DESC"';
|
||||||
$field_filter_sets[] = $this->_t(3) . 'multiple="true"';
|
$field_filter_sets[] = $this->_t(3) . 'multiple="true"';
|
||||||
$field_filter_sets[] = $this->_t(3)
|
$field_filter_sets[] = $this->_t(3)
|
||||||
. 'class="multipleAccessLevels"';
|
. 'class="multipleAccessLevels"';
|
||||||
|
@ -10581,7 +10581,7 @@ class Interpretation extends Fields
|
|||||||
if (1)
|
if (1)
|
||||||
{
|
{
|
||||||
// https://github.com/joomla/joomla-cms/blob/3.10.0-alpha3/installation/sql/mysql/joomla.sql#L22
|
// https://github.com/joomla/joomla-cms/blob/3.10.0-alpha3/installation/sql/mysql/joomla.sql#L22
|
||||||
// Checked 1st December 2020
|
// Checked 1st December 2020 (let us know if this changes)
|
||||||
$db .= PHP_EOL;
|
$db .= PHP_EOL;
|
||||||
$db .= PHP_EOL . '--';
|
$db .= PHP_EOL . '--';
|
||||||
$db .= PHP_EOL
|
$db .= PHP_EOL
|
||||||
@ -10594,13 +10594,13 @@ class Interpretation extends Fields
|
|||||||
. "ALTER TABLE `#__assets` CHANGE `rules` `rules` varchar(5120) NOT NULL COMMENT 'JSON encoded access control.';";
|
. "ALTER TABLE `#__assets` CHANGE `rules` `rules` varchar(5120) NOT NULL COMMENT 'JSON encoded access control.';";
|
||||||
}
|
}
|
||||||
|
|
||||||
// check if this component used larger rules
|
// check if this component used larger names
|
||||||
// now revert them back on uninstall
|
// now revert them back on uninstall
|
||||||
// TODO still adding to GUI the needed switches and code
|
// TODO still adding to GUI the needed switches and code
|
||||||
if (1)
|
if (1)
|
||||||
{
|
{
|
||||||
// https://github.com/joomla/joomla-cms/blob/3.10.0-alpha3/installation/sql/mysql/joomla.sql#L20
|
// https://github.com/joomla/joomla-cms/blob/3.10.0-alpha3/installation/sql/mysql/joomla.sql#L20
|
||||||
// Checked 1st December 2020
|
// Checked 1st December 2020 (let us know if this changes)
|
||||||
$db .= PHP_EOL;
|
$db .= PHP_EOL;
|
||||||
$db .= PHP_EOL . '--';
|
$db .= PHP_EOL . '--';
|
||||||
$db .= PHP_EOL
|
$db .= PHP_EOL
|
||||||
@ -14310,14 +14310,35 @@ class Interpretation extends Fields
|
|||||||
. "\$query->select('ag.title AS access_level');";
|
. "\$query->select('ag.title AS access_level');";
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
. "\$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');";
|
. "\$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');";
|
||||||
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
// check if the access field was over ridden
|
||||||
. " Filter by access level.";
|
if (!isset($this->fieldsNames[$nameSingleCode]['access']))
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
{
|
||||||
. "if (\$access = \$this->getState('filter.access'))";
|
// component helper name
|
||||||
$query .= PHP_EOL . $this->_t(2) . "{";
|
$Helper = $this->fileContentStatic[$this->hhh . 'Component'
|
||||||
$query .= PHP_EOL . $this->_t(3)
|
. $this->hhh] . 'Helper';
|
||||||
. "\$query->where('a.access = ' . (int) \$access);";
|
// load the access filter query code
|
||||||
$query .= PHP_EOL . $this->_t(2) . "}";
|
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
||||||
|
. " Filter by access level.";
|
||||||
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
|
. "\$_access = \$this->getState('filter.access');";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "if (\$_access && is_numeric(\$_access))";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "{";
|
||||||
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
|
. "\$query->where('a.access = ' . (int) \$_access);";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "}";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "elseif ("
|
||||||
|
. $Helper . "::checkArray(\$_access))";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "{";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "//"
|
||||||
|
. $this->setLine(__LINE__) . " Secure the array for the query";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "\$_access = ArrayHelper::toInteger(\$_access);";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "//"
|
||||||
|
. $this->setLine(__LINE__) . " Filter by the Access Array.";
|
||||||
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
|
. "\$query->where('a.access IN (' . implode(',', \$_access) . ')');";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "}";
|
||||||
|
}
|
||||||
|
// TODO the following will fight against the above access filter
|
||||||
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
||||||
. " Implement View Level Access";
|
. " Implement View Level Access";
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
@ -14733,7 +14754,7 @@ class Interpretation extends Fields
|
|||||||
. "\$pks = \$input->post->get('cid', array(), 'array');";
|
. "\$pks = \$input->post->get('cid', array(), 'array');";
|
||||||
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
||||||
. " Sanitize the input";
|
. " Sanitize the input";
|
||||||
$method[] = $this->_t(3) . "ArrayHelper::toInteger(\$pks);";
|
$method[] = $this->_t(3) . "\$pks = ArrayHelper::toInteger(\$pks);";
|
||||||
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
||||||
. " convert to string";
|
. " convert to string";
|
||||||
$method[] = $this->_t(3) . "\$ids = implode('_', \$pks);";
|
$method[] = $this->_t(3) . "\$ids = implode('_', \$pks);";
|
||||||
@ -15075,7 +15096,7 @@ class Interpretation extends Fields
|
|||||||
. "\$pks = \$input->post->get('cid', array(), 'array');";
|
. "\$pks = \$input->post->get('cid', array(), 'array');";
|
||||||
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
||||||
. " Sanitize the input";
|
. " Sanitize the input";
|
||||||
$method[] = $this->_t(3) . "ArrayHelper::toInteger(\$pks);";
|
$method[] = $this->_t(3) . "\$pks = ArrayHelper::toInteger(\$pks);";
|
||||||
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
$method[] = $this->_t(3) . "//" . $this->setLine(__LINE__)
|
||||||
. " Get the model";
|
. " Get the model";
|
||||||
$method[] = $this->_t(3) . "\$model = \$this->getModel('"
|
$method[] = $this->_t(3) . "\$model = \$this->getModel('"
|
||||||
@ -15415,14 +15436,35 @@ class Interpretation extends Fields
|
|||||||
. "\$query->select('ag.title AS access_level');";
|
. "\$query->select('ag.title AS access_level');";
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
. "\$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');";
|
. "\$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');";
|
||||||
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
// check if the access field was over ridden
|
||||||
. " Filter by access level.";
|
if (!isset($this->fieldsNames[$nameSingleCode]['access']))
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
{
|
||||||
. "if (\$access = \$this->getState('filter.access'))";
|
// component helper name
|
||||||
$query .= PHP_EOL . $this->_t(2) . "{";
|
$Helper = $this->fileContentStatic[$this->hhh . 'Component'
|
||||||
$query .= PHP_EOL . $this->_t(3)
|
. $this->hhh] . 'Helper';
|
||||||
. "\$query->where('a.access = ' . (int) \$access);";
|
// load the access filter query code
|
||||||
$query .= PHP_EOL . $this->_t(2) . "}";
|
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
||||||
|
. " Filter by access level.";
|
||||||
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
|
. "\$_access = \$this->getState('filter.access');";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "if (\$_access && is_numeric(\$_access))";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "{";
|
||||||
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
|
. "\$query->where('a.access = ' . (int) \$_access);";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "}";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "elseif ("
|
||||||
|
. $Helper . "::checkArray(\$_access))";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "{";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "//"
|
||||||
|
. $this->setLine(__LINE__) . " Secure the array for the query";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "\$_access = ArrayHelper::toInteger(\$_access);";
|
||||||
|
$query .= PHP_EOL . $this->_t(3) . "//"
|
||||||
|
. $this->setLine(__LINE__) . " Filter by the Access Array.";
|
||||||
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
|
. "\$query->where('a.access IN (' . implode(',', \$_access) . ')');";
|
||||||
|
$query .= PHP_EOL . $this->_t(2) . "}";
|
||||||
|
}
|
||||||
|
// TODO the following will fight against the above access filter
|
||||||
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
$query .= PHP_EOL . $this->_t(2) . "//" . $this->setLine(__LINE__)
|
||||||
. " Implement View Level Access";
|
. " Implement View Level Access";
|
||||||
$query .= PHP_EOL . $this->_t(2)
|
$query .= PHP_EOL . $this->_t(2)
|
||||||
@ -15467,7 +15509,7 @@ class Interpretation extends Fields
|
|||||||
. "elseif (is_array(\$categoryId))";
|
. "elseif (is_array(\$categoryId))";
|
||||||
$query .= PHP_EOL . $this->_t(2) . "{";
|
$query .= PHP_EOL . $this->_t(2) . "{";
|
||||||
$query .= PHP_EOL . $this->_t(3)
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
. "ArrayHelper::toInteger(\$categoryId);";
|
. "\$categoryId = ArrayHelper::toInteger(\$categoryId);";
|
||||||
$query .= PHP_EOL . $this->_t(3)
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
. "\$categoryId = implode(',', \$categoryId);";
|
. "\$categoryId = implode(',', \$categoryId);";
|
||||||
$query .= PHP_EOL . $this->_t(3)
|
$query .= PHP_EOL . $this->_t(3)
|
||||||
@ -20259,12 +20301,13 @@ class Interpretation extends Fields
|
|||||||
/**
|
/**
|
||||||
* set the filter fields
|
* set the filter fields
|
||||||
*
|
*
|
||||||
* @param string $nameListCode The list view name
|
* @param string $nameSingleCode The single view name
|
||||||
|
* @param string $nameListCode The list view name
|
||||||
*
|
*
|
||||||
* @return string The code for the filter fields array
|
* @return string The code for the filter fields array
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function setFilterFieldsArray(&$nameListCode)
|
public function setFilterFieldsArray(&$nameSingleCode, &$nameListCode)
|
||||||
{
|
{
|
||||||
// keep track of all fields already added
|
// keep track of all fields already added
|
||||||
$donelist = array('id' => true, 'search' => true,
|
$donelist = array('id' => true, 'search' => true,
|
||||||
@ -20273,9 +20316,9 @@ class Interpretation extends Fields
|
|||||||
// default filter fields
|
// default filter fields
|
||||||
$fields = "'a.id','id'";
|
$fields = "'a.id','id'";
|
||||||
$fields .= "," . PHP_EOL . $this->_t(4) . "'a.published','published'";
|
$fields .= "," . PHP_EOL . $this->_t(4) . "'a.published','published'";
|
||||||
if (isset($this->accessBuilder[$nameListCode])
|
if (isset($this->accessBuilder[$nameSingleCode])
|
||||||
&& ComponentbuilderHelper::checkString(
|
&& ComponentbuilderHelper::checkString(
|
||||||
$this->accessBuilder[$nameListCode]
|
$this->accessBuilder[$nameSingleCode]
|
||||||
))
|
))
|
||||||
{
|
{
|
||||||
$fields .= "," . PHP_EOL . $this->_t(4) . "'a.access','access'";
|
$fields .= "," . PHP_EOL . $this->_t(4) . "'a.access','access'";
|
||||||
@ -20381,12 +20424,13 @@ class Interpretation extends Fields
|
|||||||
/**
|
/**
|
||||||
* set the sotred ids
|
* set the sotred ids
|
||||||
*
|
*
|
||||||
* @param string $nameListCode The list view name
|
* @param string $nameSingleCode The single view name
|
||||||
|
* @param string $nameListCode The list view name
|
||||||
*
|
*
|
||||||
* @return string The code for the populate state
|
* @return string The code for the populate state
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function setStoredId(&$nameListCode)
|
public function setStoredId(&$nameSingleCode, &$nameListCode)
|
||||||
{
|
{
|
||||||
// keep track of all fields already added
|
// keep track of all fields already added
|
||||||
$donelist = array('id' => true, 'search' => true,
|
$donelist = array('id' => true, 'search' => true,
|
||||||
@ -20400,9 +20444,9 @@ class Interpretation extends Fields
|
|||||||
. "\$id .= ':' . \$this->getState('filter.search');";
|
. "\$id .= ':' . \$this->getState('filter.search');";
|
||||||
$stored .= PHP_EOL . $this->_t(2)
|
$stored .= PHP_EOL . $this->_t(2)
|
||||||
. "\$id .= ':' . \$this->getState('filter.published');";
|
. "\$id .= ':' . \$this->getState('filter.published');";
|
||||||
if (isset($this->accessBuilder[$nameListCode])
|
if (isset($this->accessBuilder[$nameSingleCode])
|
||||||
&& ComponentbuilderHelper::checkString(
|
&& ComponentbuilderHelper::checkString(
|
||||||
$this->accessBuilder[$nameListCode]
|
$this->accessBuilder[$nameSingleCode]
|
||||||
))
|
))
|
||||||
{
|
{
|
||||||
$stored .= PHP_EOL . $this->_t(2)
|
$stored .= PHP_EOL . $this->_t(2)
|
||||||
@ -21895,26 +21939,92 @@ class Interpretation extends Fields
|
|||||||
{
|
{
|
||||||
// check that the filter type is the new filter option
|
// check that the filter type is the new filter option
|
||||||
if (isset($this->adminFilterType[$nameListCode])
|
if (isset($this->adminFilterType[$nameListCode])
|
||||||
&& $this->adminFilterType[$nameListCode] == 2
|
&& $this->adminFilterType[$nameListCode] == 2)
|
||||||
&& isset($this->filterBuilder[$nameListCode])
|
|
||||||
&& ComponentbuilderHelper::checkArray(
|
|
||||||
$this->filterBuilder[$nameListCode]
|
|
||||||
))
|
|
||||||
{
|
{
|
||||||
foreach ($this->filterBuilder[$nameListCode] as $filter)
|
// add category switch
|
||||||
|
$add_category = false;
|
||||||
|
if (isset($this->categoryBuilder[$nameListCode])
|
||||||
|
&& ComponentbuilderHelper::checkArray(
|
||||||
|
$this->categoryBuilder[$nameListCode]
|
||||||
|
)
|
||||||
|
&& isset($this->categoryBuilder[$nameListCode]['extension']))
|
||||||
{
|
{
|
||||||
// we need this only for filters that are multi
|
// is found so add it
|
||||||
if (isset($filter['multi'])
|
$add_category = true;
|
||||||
&& $filter['multi'] == 2)
|
}
|
||||||
|
// add accessLevels switch
|
||||||
|
$add_access_levels = false;
|
||||||
|
if (in_array($nameListCode, $this->accessBuilder))
|
||||||
|
{
|
||||||
|
// is found so add it
|
||||||
|
$add_access_levels = true;
|
||||||
|
}
|
||||||
|
// check if this view have filters
|
||||||
|
if (isset($this->filterBuilder[$nameListCode])
|
||||||
|
&& ComponentbuilderHelper::checkArray(
|
||||||
|
$this->filterBuilder[$nameListCode]
|
||||||
|
))
|
||||||
|
{
|
||||||
|
foreach ($this->filterBuilder[$nameListCode] as $filter)
|
||||||
{
|
{
|
||||||
// add the header
|
// we need this only for filters that are multi
|
||||||
$headers[]
|
if (isset($filter['multi'])
|
||||||
= 'JHtml::_(\'formbehavior.chosen\', \'.multiple'
|
&& $filter['multi'] == 2)
|
||||||
. $filter['class']
|
{
|
||||||
. '\', null, array(\'placeholder_text_multiple\' => \'- \' . JText::_(\''
|
// add the header
|
||||||
. $filter['lang_select'] . '\') . \' -\'));';
|
$headers[]
|
||||||
|
= 'JHtml::_(\'formbehavior.chosen\', \'.multiple'
|
||||||
|
. $filter['class']
|
||||||
|
. '\', null, array(\'placeholder_text_multiple\' => \'- \' . JText::_(\''
|
||||||
|
. $filter['lang_select'] . '\') . \' -\'));';
|
||||||
|
// check if this was an access field
|
||||||
|
if ($filter['type'] === 'accesslevel')
|
||||||
|
{
|
||||||
|
// already added here so no need to add again
|
||||||
|
$add_access_levels = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
elseif ($add_category && $filter['type'] === 'category')
|
||||||
|
{
|
||||||
|
// add the header
|
||||||
|
$headers[]
|
||||||
|
= 'JHtml::_(\'formbehavior.chosen\', \'.multipleCategories'
|
||||||
|
. '\', null, array(\'placeholder_text_multiple\' => \'- \' . JText::_(\''
|
||||||
|
. $filter['lang_select'] . '\') . \' -\'));';
|
||||||
|
// already added here so no need to add again
|
||||||
|
$add_category = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// add category if not already added
|
||||||
|
if ($add_category)
|
||||||
|
{
|
||||||
|
// add the header
|
||||||
|
$headers[]
|
||||||
|
= 'JHtml::_(\'formbehavior.chosen\', \'.multipleCategories'
|
||||||
|
. '\', null, array(\'placeholder_text_multiple\' => \'- \' . JText::_(\''
|
||||||
|
. $this->categoryBuilder[$nameListCode]['name']
|
||||||
|
. '\') . \' -\'));';
|
||||||
|
}
|
||||||
|
// add accessLevels if not already added
|
||||||
|
if ($add_access_levels)
|
||||||
|
{
|
||||||
|
// set the language strings for selection
|
||||||
|
$filter_name_select = 'Select Access';
|
||||||
|
$filter_name_select_lang = $this->langPrefix . '_FILTER_'
|
||||||
|
. ComponentbuilderHelper::safeString(
|
||||||
|
$filter_name_select, 'U'
|
||||||
|
);
|
||||||
|
// and to translation
|
||||||
|
$this->setLangContent(
|
||||||
|
$this->lang, $filter_name_select_lang, $filter_name_select
|
||||||
|
);
|
||||||
|
// add the header
|
||||||
|
$headers[]
|
||||||
|
= 'JHtml::_(\'formbehavior.chosen\', \'.multipleAccessLevels'
|
||||||
|
. '\', null, array(\'placeholder_text_multiple\' => \'- \' . JText::_(\''
|
||||||
|
. $filter_name_select_lang . '\') . \' -\'));';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -819,13 +819,16 @@ class Infusion extends Interpretation
|
|||||||
$this->fileContentDynamic[$nameListCode][$this->hhh
|
$this->fileContentDynamic[$nameListCode][$this->hhh
|
||||||
. 'FILTER_FIELDS' . $this->hhh]
|
. 'FILTER_FIELDS' . $this->hhh]
|
||||||
= $this->setFilterFieldsArray(
|
= $this->setFilterFieldsArray(
|
||||||
|
$nameSingleCode,
|
||||||
$nameListCode
|
$nameListCode
|
||||||
);
|
);
|
||||||
|
|
||||||
// STOREDID <<<DYNAMIC>>>
|
// STOREDID <<<DYNAMIC>>>
|
||||||
$this->fileContentDynamic[$nameListCode][$this->hhh
|
$this->fileContentDynamic[$nameListCode][$this->hhh
|
||||||
. 'STOREDID' . $this->hhh]
|
. 'STOREDID' . $this->hhh]
|
||||||
= $this->setStoredId($nameListCode);
|
= $this->setStoredId(
|
||||||
|
$nameSingleCode, $nameListCode
|
||||||
|
);
|
||||||
|
|
||||||
// POPULATESTATE <<<DYNAMIC>>>
|
// POPULATESTATE <<<DYNAMIC>>>
|
||||||
$this->fileContentDynamic[$nameListCode][$this->hhh
|
$this->fileContentDynamic[$nameListCode][$this->hhh
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelAdmin_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -276,9 +277,17 @@ class ComponentbuilderModelAdmin_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -608,6 +617,7 @@ class ComponentbuilderModelAdmin_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelAdmins_custom_tabs extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelAdmins_custom_tabs extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelAdmins_custom_tabs extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelAdmins_fields extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelAdmins_fields extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelAdmins_fields extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelAdmins_fields_conditions extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelAdmins_fields_conditions extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelAdmins_fields_conditions extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelAdmins_fields_relations extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelAdmins_fields_relations extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelAdmins_fields_relations extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelClass_extendings extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -194,9 +195,17 @@ class ComponentbuilderModelClass_extendings extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -260,6 +269,7 @@ class ComponentbuilderModelClass_extendings extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelClass_methods extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -218,9 +219,17 @@ class ComponentbuilderModelClass_methods extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -429,6 +438,7 @@ class ComponentbuilderModelClass_methods extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelClass_properties extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -218,9 +219,17 @@ class ComponentbuilderModelClass_properties extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -427,6 +436,7 @@ class ComponentbuilderModelClass_properties extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_admin_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_admin_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_admin_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_config extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_config extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_config extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_custom_admin_menus extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_custom_admin_menus extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_custom_admin_menus extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_custom_admin_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_custom_admin_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_custom_admin_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_dashboard extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_dashboard extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_dashboard extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_files_folders extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_files_folders extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_files_folders extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_modules extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_modules extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_modules extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_mysql_tweaks extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_mysql_tweaks extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_mysql_tweaks extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_placeholders extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_placeholders extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_placeholders extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_plugins extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_plugins extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_plugins extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_site_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_site_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_site_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelComponents_updates extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelComponents_updates extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelComponents_updates extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelCustom_admin_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -227,9 +228,17 @@ class ComponentbuilderModelCustom_admin_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -473,6 +482,7 @@ class ComponentbuilderModelCustom_admin_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelCustom_codes extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -255,9 +256,17 @@ class ComponentbuilderModelCustom_codes extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -513,6 +522,7 @@ class ComponentbuilderModelCustom_codes extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelDynamic_gets extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -215,9 +216,17 @@ class ComponentbuilderModelDynamic_gets extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -436,6 +445,7 @@ class ComponentbuilderModelDynamic_gets extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelFields extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -294,9 +295,17 @@ class ComponentbuilderModelFields extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -421,7 +430,7 @@ class ComponentbuilderModelFields extends JModelList
|
|||||||
}
|
}
|
||||||
elseif (is_array($categoryId))
|
elseif (is_array($categoryId))
|
||||||
{
|
{
|
||||||
ArrayHelper::toInteger($categoryId);
|
$categoryId = ArrayHelper::toInteger($categoryId);
|
||||||
$categoryId = implode(',', $categoryId);
|
$categoryId = implode(',', $categoryId);
|
||||||
$query->where('a.catid IN (' . $categoryId . ')');
|
$query->where('a.catid IN (' . $categoryId . ')');
|
||||||
}
|
}
|
||||||
@ -588,6 +597,7 @@ class ComponentbuilderModelFields extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -288,9 +288,17 @@ class ComponentbuilderModelFieldtype extends JModelAdmin
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelFieldtypes extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -172,9 +173,17 @@ class ComponentbuilderModelFieldtypes extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -214,7 +223,7 @@ class ComponentbuilderModelFieldtypes extends JModelList
|
|||||||
}
|
}
|
||||||
elseif (is_array($categoryId))
|
elseif (is_array($categoryId))
|
||||||
{
|
{
|
||||||
ArrayHelper::toInteger($categoryId);
|
$categoryId = ArrayHelper::toInteger($categoryId);
|
||||||
$categoryId = implode(',', $categoryId);
|
$categoryId = implode(',', $categoryId);
|
||||||
$query->where('a.catid IN (' . $categoryId . ')');
|
$query->where('a.catid IN (' . $categoryId . ')');
|
||||||
}
|
}
|
||||||
@ -365,6 +374,7 @@ class ComponentbuilderModelFieldtypes extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_components extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -2206,9 +2207,17 @@ class ComponentbuilderModelJoomla_components extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -2475,6 +2484,7 @@ class ComponentbuilderModelJoomla_components extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_modules extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -196,9 +197,17 @@ class ComponentbuilderModelJoomla_modules extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -262,6 +271,7 @@ class ComponentbuilderModelJoomla_modules extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_modules_files_folders_urls extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelJoomla_modules_files_folders_urls extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelJoomla_modules_files_folders_urls extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_modules_updates extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelJoomla_modules_updates extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelJoomla_modules_updates extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_plugin_groups extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -141,9 +142,17 @@ class ComponentbuilderModelJoomla_plugin_groups extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -207,6 +216,7 @@ class ComponentbuilderModelJoomla_plugin_groups extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_plugins extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -340,9 +341,17 @@ class ComponentbuilderModelJoomla_plugins extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -423,6 +432,7 @@ class ComponentbuilderModelJoomla_plugins extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_plugins_files_folders_urls extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelJoomla_plugins_files_folders_urls extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelJoomla_plugins_files_folders_urls extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelJoomla_plugins_updates extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelJoomla_plugins_updates extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelJoomla_plugins_updates extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLanguage_translations extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -208,9 +209,17 @@ class ComponentbuilderModelLanguage_translations extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -430,6 +439,7 @@ class ComponentbuilderModelLanguage_translations extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLanguages extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -281,9 +282,17 @@ class ComponentbuilderModelLanguages extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -452,6 +461,7 @@ class ComponentbuilderModelLanguages extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLayouts extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -204,9 +205,17 @@ class ComponentbuilderModelLayouts extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -413,6 +422,7 @@ class ComponentbuilderModelLayouts extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLibraries extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -241,9 +242,17 @@ class ComponentbuilderModelLibraries extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -341,6 +350,7 @@ class ComponentbuilderModelLibraries extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLibraries_config extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelLibraries_config extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelLibraries_config extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelLibraries_files_folders_urls extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by'
|
'a.modified_by','modified_by'
|
||||||
@ -154,9 +155,17 @@ class ComponentbuilderModelLibraries_files_folders_urls extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -188,6 +197,7 @@ class ComponentbuilderModelLibraries_files_folders_urls extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelPlaceholders extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -160,9 +161,17 @@ class ComponentbuilderModelPlaceholders extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -333,6 +342,7 @@ class ComponentbuilderModelPlaceholders extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -224,9 +224,17 @@ class ComponentbuilderModelServer extends JModelAdmin
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelServers extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -193,9 +194,17 @@ class ComponentbuilderModelServers extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -448,6 +457,7 @@ class ComponentbuilderModelServers extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelSite_views extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -231,9 +232,17 @@ class ComponentbuilderModelSite_views extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -477,6 +486,7 @@ class ComponentbuilderModelSite_views extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelSnippet_types extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -158,9 +159,17 @@ class ComponentbuilderModelSnippet_types extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -207,6 +216,7 @@ class ComponentbuilderModelSnippet_types extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelSnippets extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -292,9 +293,17 @@ class ComponentbuilderModelSnippets extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -499,6 +508,7 @@ class ComponentbuilderModelSnippets extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelTemplates extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -204,9 +205,17 @@ class ComponentbuilderModelTemplates extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -413,6 +422,7 @@ class ComponentbuilderModelTemplates extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -26,6 +26,7 @@ class ComponentbuilderModelValidation_rules extends JModelList
|
|||||||
$config['filter_fields'] = array(
|
$config['filter_fields'] = array(
|
||||||
'a.id','id',
|
'a.id','id',
|
||||||
'a.published','published',
|
'a.published','published',
|
||||||
|
'a.access','access',
|
||||||
'a.ordering','ordering',
|
'a.ordering','ordering',
|
||||||
'a.created_by','created_by',
|
'a.created_by','created_by',
|
||||||
'a.modified_by','modified_by',
|
'a.modified_by','modified_by',
|
||||||
@ -158,9 +159,17 @@ class ComponentbuilderModelValidation_rules extends JModelList
|
|||||||
$query->select('ag.title AS access_level');
|
$query->select('ag.title AS access_level');
|
||||||
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
$query->join('LEFT', '#__viewlevels AS ag ON ag.id = a.access');
|
||||||
// Filter by access level.
|
// Filter by access level.
|
||||||
if ($access = $this->getState('filter.access'))
|
$_access = $this->getState('filter.access');
|
||||||
|
if ($_access && is_numeric($_access))
|
||||||
{
|
{
|
||||||
$query->where('a.access = ' . (int) $access);
|
$query->where('a.access = ' . (int) $_access);
|
||||||
|
}
|
||||||
|
elseif (ComponentbuilderHelper::checkArray($_access))
|
||||||
|
{
|
||||||
|
// Secure the array for the query
|
||||||
|
$_access = ArrayHelper::toInteger($_access);
|
||||||
|
// Filter by the Access Array.
|
||||||
|
$query->where('a.access IN (' . implode(',', $_access) . ')');
|
||||||
}
|
}
|
||||||
// Implement View Level Access
|
// Implement View Level Access
|
||||||
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
if (!$user->authorise('core.options', 'com_componentbuilder'))
|
||||||
@ -331,6 +340,7 @@ class ComponentbuilderModelValidation_rules extends JModelList
|
|||||||
$id .= ':' . $this->getState('filter.id');
|
$id .= ':' . $this->getState('filter.id');
|
||||||
$id .= ':' . $this->getState('filter.search');
|
$id .= ':' . $this->getState('filter.search');
|
||||||
$id .= ':' . $this->getState('filter.published');
|
$id .= ':' . $this->getState('filter.published');
|
||||||
|
$id .= ':' . $this->getState('filter.access');
|
||||||
$id .= ':' . $this->getState('filter.ordering');
|
$id .= ':' . $this->getState('filter.ordering');
|
||||||
$id .= ':' . $this->getState('filter.created_by');
|
$id .= ':' . $this->getState('filter.created_by');
|
||||||
$id .= ':' . $this->getState('filter.modified_by');
|
$id .= ':' . $this->getState('filter.modified_by');
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<extension type="component" version="3.2" method="upgrade">
|
<extension type="component" version="3.2" method="upgrade">
|
||||||
<name>COM_COMPONENTBUILDER</name>
|
<name>COM_COMPONENTBUILDER</name>
|
||||||
<creationDate>1st December, 2020</creationDate>
|
<creationDate>3rd December, 2020</creationDate>
|
||||||
<author>Llewellyn van der Merwe</author>
|
<author>Llewellyn van der Merwe</author>
|
||||||
<authorEmail>llewellyn@joomlacomponentbuilder.com</authorEmail>
|
<authorEmail>llewellyn@joomlacomponentbuilder.com</authorEmail>
|
||||||
<authorUrl>http://www.joomlacomponentbuilder.com</authorUrl>
|
<authorUrl>http://www.joomlacomponentbuilder.com</authorUrl>
|
||||||
|
Loading…
Reference in New Issue
Block a user