Release of v3.2.1-alpha3

Fix plugin code display when methods and properties are missing.
This commit is contained in:
2024-04-09 13:44:08 +02:00
parent 4c7b4f11a4
commit a66e099a73
43 changed files with 3639 additions and 3695 deletions

View File

@ -62,12 +62,17 @@ class JFormFieldPluginsclassmethods extends JFormFieldList
}
$db->setQuery((string)$query);
$items = $db->loadObjectList();
$options = array();
$options = [];
if ($items)
{
$options[] = Html::_('select.option', '', 'Select a method');
foreach($items as $item)
{
if (!isset($item->visibility))
{
continue;
}
// we are using this code in more then one field JCB custom_code
if ('method' === 'method')
{
@ -77,6 +82,7 @@ class JFormFieldPluginsclassmethods extends JFormFieldList
{
$select = $item->visibility . ' $' . $item->method_name;
}
$options[] = Html::_('select.option', $item->id, $select);
}
}

View File

@ -62,12 +62,17 @@ class JFormFieldPluginsclassproperties extends JFormFieldList
}
$db->setQuery((string)$query);
$items = $db->loadObjectList();
$options = array();
$options = [];
if ($items)
{
$options[] = Html::_('select.option', '', 'Select a property');
foreach($items as $item)
{
if (!isset($item->visibility))
{
continue;
}
// we are using this code in more then one field JCB custom_code
if ('method' === 'property')
{
@ -77,6 +82,7 @@ class JFormFieldPluginsclassproperties extends JFormFieldList
{
$select = $item->visibility . ' $' . $item->property_name;
}
$options[] = Html::_('select.option', $item->id, $select);
}
}

View File

@ -62,12 +62,17 @@ class JFormFieldPowersclassmethods extends JFormFieldList
}
$db->setQuery((string)$query);
$items = $db->loadObjectList();
$options = array();
$options = [];
if ($items)
{
$options[] = Html::_('select.option', '', 'Select a method');
foreach($items as $item)
{
if (!isset($item->visibility))
{
continue;
}
// we are using this code in more then one field JCB custom_code
if ('method' === 'method')
{
@ -77,6 +82,7 @@ class JFormFieldPowersclassmethods extends JFormFieldList
{
$select = $item->visibility . ' $' . $item->method_name;
}
$options[] = Html::_('select.option', $item->id, $select);
}
}

View File

@ -62,12 +62,17 @@ class JFormFieldPowersclassproperties extends JFormFieldList
}
$db->setQuery((string)$query);
$items = $db->loadObjectList();
$options = array();
$options = [];
if ($items)
{
$options[] = Html::_('select.option', '', 'Select a property');
foreach($items as $item)
{
if (!isset($item->visibility))
{
continue;
}
// we are using this code in more then one field JCB custom_code
if ('method' === 'property')
{
@ -77,6 +82,7 @@ class JFormFieldPowersclassproperties extends JFormFieldList
{
$select = $item->visibility . ' $' . $item->property_name;
}
$options[] = Html::_('select.option', $item->id, $select);
}
}