[Fusionforge-commits] r12228 - branches/Branch_5_1/src/plugins/oslc/include/oslc-zend/application/controllers

Olivier Berger olberger at libremir.placard.fr.eu.org
Thu Feb 10 16:11:51 CET 2011


Author: olberger
Date: 2011-02-10 16:11:51 +0100 (Thu, 10 Feb 2011)
New Revision: 12228

Modified:
   branches/Branch_5_1/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php
Log:
Adding filtering on dc:title / summary

Modified: branches/Branch_5_1/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php
===================================================================
--- branches/Branch_5_1/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php	2011-02-10 15:11:46 UTC (rev 12227)
+++ branches/Branch_5_1/src/plugins/oslc/include/oslc-zend/application/controllers/FusionForgeOSLCConnector.php	2011-02-10 15:11:51 UTC (rev 12228)
@@ -151,9 +151,13 @@
 
 		if(array_key_exists('where', $filter))	{
 			foreach($filter['where']['terms'] as $term)	{
-				if($term[0]=='=')	{	
+			  // equality
+				if($term[0] == '=')	{	
 					$term[2] = str_replace("\"", "", $term[2]);
 					switch($term[1])	{
+					case 'dc:title':
+					  $query['summary'] = $term[2];
+					  break;
 						case 'helios_bt:status':
 							if (array_key_exists($term[2],self::$status_arr))	{
 								$query['status'] = self::$status_arr[$term[2]];
@@ -285,7 +289,7 @@
 		$af->order_col = $query['order_col'];
 		
 		// Can add here values for 'details' and 'summary'. Values comes from oslc_searchTerms
-		//$af->summary = $query['search'];
+		$af->summary = $query['summary'];
 		//$af->details =	$query['search'];
 		
 		// query the DB for requested artifacts 




More information about the Fusionforge-commits mailing list