diff --git a/administrator/components/com_cck/models/search.php b/administrator/components/com_cck/models/search.php index bd0f08d8c..21e31b17c 100644 --- a/administrator/components/com_cck/models/search.php +++ b/administrator/components/com_cck/models/search.php @@ -181,7 +181,13 @@ public function postStore( $pk ) if ( isset( $raw_data['ffp'] ) ) { $data['ffp'] = $raw_data['ffp']; } - + if ( !isset( $data['ff'] ) ) { + $data['ff'] = array(); + } + if ( !isset( $data['ffp'] ) ) { + $data['ffp'] = array(); + } + $this->storeMore( $pk, $data['client'], $data['ff'], $data['ffp'] ); if ( isset( $data['cck_type'] ) && $data['cck_type'] != '' ) { @@ -249,6 +255,7 @@ protected function storeMore( $searchId, $client, $fields, $params ) $method = 'gm_getConstruction_Values_Search'; JCckDatabase::execute( 'DELETE FROM #__cck_core_'.$table.' WHERE searchid = '.(int)$searchId . ' AND client = "'.$client.'"' ); + if ( count( $fields ) ) { $assigned = ''; $ordering = 1;