Refactored the compiler list view body builder, in preparation of the relation fields. Added more options to the relation admin fields. gh-287
This commit is contained in:
@ -87,26 +87,6 @@ class ComponentbuilderModelAdmin_fields_relations extends JModelAdmin
|
||||
$addrelations = new Registry;
|
||||
$addrelations->loadString($item->addrelations);
|
||||
$item->addrelations = $addrelations->toArray();
|
||||
}
|
||||
|
||||
// check what type of conditions array we have here (should be subform... but just incase)
|
||||
// This could happen due to huge data sets
|
||||
if (isset($item->addconditions) && isset($item->addconditions['target_field']))
|
||||
{
|
||||
$bucket = array();
|
||||
foreach($item->addconditions as $option => $values)
|
||||
{
|
||||
foreach($values as $nr => $value)
|
||||
{
|
||||
$bucket['addconditions'.$nr][$option] = $value;
|
||||
}
|
||||
}
|
||||
$item->addconditions = $bucket;
|
||||
// update the fields
|
||||
$conditionsUpdate = new stdClass();
|
||||
$conditionsUpdate->id = (int) $item->id;
|
||||
$conditionsUpdate->addconditions = json_encode($bucket);
|
||||
$this->_db->updateObject('#__componentbuilder_admin_fields_conditions', $conditionsUpdate, 'id');
|
||||
}
|
||||
|
||||
if (!empty($item->id))
|
||||
|
Reference in New Issue
Block a user