ez projects / extract / forum / general / sckenhancedselection datatype
You need to be logged in to post messages in the forums. New users may register here.
Member since: Posts: 46 |
Wednesday 27 May 2009 4:56:18 am Here's a patch for adding the sckenhancedselection datatype:
Index: settings/csv.ini.append.php =================================================================== --- settings/csv.ini.append.php (revision 2527) +++ settings/csv.ini.append.php (revision 2528) @@ -16,6 +16,7 @@ ExportableDatatypes[]=ezidentifier ExportableDatatypes[]=ezenhancedobjectrelation ExportableDatatypes[]=ezenhancedselection +ExportableDatatypes[]=sckenhancedselection ExportableDatatypes[]=ezselection ExportableDatatypes[]=ezenum ExportableDatatypes[]=ezcountry @@ -36,6 +37,10 @@ HandlerFile=ezstringhandler.php HandlerClass=eZStringHandler +[sckenhancedselection] +HandlerFile=sckenhancedselectionhandler.php +HandlerClass=sckEnhancedSelectionHandler + [ezinteger] HandlerFile=ezintegerhandler.php HandlerClass=eZIntegerHandler Index: classes/parsers/sckenhancedselectionhandler.php =================================================================== --- classes/parsers/sckenhancedselectionhandler.php (revision 0) +++ classes/parsers/sckenhancedselectionhandler.php (revision 2528) @@ -0,0 +1,12 @@ +<? + +class sckEnhancedSelectionHandler extends BaseHandler{ + + function exportAttribute( &$attribute ) + { + $content = $attribute->content(); + $content = (is_array($content) and count($content) == 1) ? $attribute->metaData() : $attribute->isA(); + return $this->escape( (is_string($content)) ? $content : $content[1]['text'] ); + } +} +?> |
|
Member since: Posts: 47 |
Friday 29 May 2009 2:39:20 pm please send to patch to bjoern at xrow de
copy and paste is a pain in here Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs |
You need to be logged in to post messages in the forums. New users may register here.