FIX: fix field class detection

using the action function that returns the class...
This commit is contained in:
colymba 2012-08-09 20:25:08 +03:00
parent b8a0a1e14f
commit 4e5271f527

View File

@ -56,14 +56,13 @@ class GridFieldBulkEditingHelper {
unset( $dataFields[str_ireplace('ID', '', $config['imageFieldName']) ] ); unset( $dataFields[str_ireplace('ID', '', $config['imageFieldName']) ] );
} }
} }
//if class blacklist filter //if class blacklist filter
if ( count($config['fieldsClassBlacklist']) > 0 ) if ( count($config['fieldsClassBlacklist']) > 0 )
{ {
foreach ($dataFields as $fieldName => $field) foreach ($dataFields as $fieldName => $field)
{ {
//@TODO find PHP function that return the classname if ( in_array(get_class($field), $config['fieldsClassBlacklist']) )
if ( in_array($field->ClassName, $config['fieldsClassBlacklist']) )
{ {
array_push($config['fieldsNameBlacklist'], $fieldName); array_push($config['fieldsNameBlacklist'], $fieldName);
} }