[evolvis-commits] r17748: - Sry forgot about the Copyright ; ) Now its merge able :D

messer at evolvis.org messer at evolvis.org
Wed Nov 30 19:15:29 CET 2011


Author: messer
Date: 2011-11-30 19:15:29 +0100 (Wed, 30 Nov 2011)
New Revision: 17748

Added:
   branches/messer-51-suche/src/common/advanced_search/ASFusionForgeParser.class.php
   branches/messer-51-suche/src/common/advanced_search/AdvancedSearch.class.php
Modified:
   branches/messer-51-suche/src/common/advanced_search/ASInputAnalyzer.class.php
   branches/messer-51-suche/src/common/advanced_search/ASToken.class.php
   branches/messer-51-suche/src/common/advanced_search/ASTokenizer.class.php
   branches/messer-51-suche/src/common/advanced_search/EASToken.enum.php
   branches/messer-51-suche/src/common/advanced_search/FusionForgeDFIProvider.class.php
   branches/messer-51-suche/src/common/advanced_search/IDFIProvider.interface.php
   branches/messer-51-suche/src/www/tracker/search.php
Log:
- Sry forgot about the Copyright ;) Now its merge able :D

Added: branches/messer-51-suche/src/common/advanced_search/ASFusionForgeParser.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/ASFusionForgeParser.class.php	                        (rev 0)
+++ branches/messer-51-suche/src/common/advanced_search/ASFusionForgeParser.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -0,0 +1,390 @@
+<?php
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
+ */
+require_once "ASTokenizer.class.php";
+
+class ASFusionForgeParserTracker {
+	protected $tokens;
+	protected $parameters;
+	protected $ArtifactType;
+	
+	/**
+	 * This function returns the artifact array.
+	 * 
+	 * @param string $inputString
+	 */
+	public function parse($inputString, $artifactType) {
+		//Parameters for db_query_params.
+		$params 	       = array();
+		$paramcount 	   = 1;
+		$extraFieldCounter = 0;
+		$curTokenPointer   = 0;
+		$bDone             = false;
+		
+		//First tokenize the input string.
+		$this->tokens = ASTokenizer::tokenize($inputString, $this->params);
+		
+		if($this->tokens === false) {
+			return null;
+		}
+		
+		//Go trough all tokens and build the query
+		$selectsql = 'SELECT DISTINCT ON (group_artifact_id, artifact_id) artifact_vw.* FROM artifact_vw';
+		$wheresql  = ' WHERE group_artifact_id=$'.$paramcount++.' AND';
+		 
+		$params[] = $this->parameters['tracker_id'];
+		$curToken = $this->tokens[0];
+
+		//Check if the first token is an DFI. If not return an error.
+		if($curToken->getType() !== EASToken::AS_DFI) {
+			return false;	
+		}
+		
+		while(!$bDone) {
+			$curType = $curToken->getType();
+
+			if($curType === EASToken::AS_DFI) {
+				
+				//Check if the DFI is a Standard field. This is nowhere defined!
+				$dfiName = $curToken->getData();
+
+				if($dfiName == 'ID'          ||
+				   $dfiName == 'Open Date'   ||
+				   $dfiName == 'Close Date'  ||
+				   $dfiName == 'Assigned to' || 
+				   $dfiName == 'Submitted by') {
+				   	//Get the next token. This has to be an operator!
+					$curTokenPointer++;
+				    $curToken = $this->tokens[$curTokenPointer];
+					$curType  = $curToken->getType();
+					
+					//We go a Standard field. Standard fields are not stored as extra fields!
+					$wheresql .= $this->_generateStdFieldWhereSQL($dfiName, $curType, &$curTokenPointer, &$paramcount, &$params);
+				} else {
+					//We got an extra field. First get it's id.
+					$result = db_query_params('SELECT extra_field_id FROM artifact_extra_field_list WHERE group_artifact_id=$1 AND field_name=$2;',
+									          array($this->parameters['tracker_id'],
+									          $curToken->getData()));
+
+					$field_id = db_result($result, 0, 'extra_field_id');
+					
+					$selectsql .= ', artifact_extra_field_data aefd'.$extraFieldCounter;
+					$wheresql .= ' (aefd'.$extraFieldCounter.'.extra_field_id=$'.$paramcount++ ;
+					$params[] = $field_id;
+					
+					// Hack: Determine the type of the element to get the right search query.
+					$res = db_query_params ('SELECT field_type FROM artifact_extra_field_list WHERE extra_field_id=$1', array($field_id)) ;
+					$type = db_result($res,0,'field_type');
+					
+					//Get the next token. This has to be an operator!
+					$curTokenPointer++;
+				    $curToken = $this->tokens[$curTokenPointer];
+					$curType  = $curToken->getType();
+					
+					if ($type == 4 or $type == 6) {
+						//We got a String as type. This means greater and less have to operate on string length.
+						//Get the next token and check the operation.
+						if($curType === EASToken::AS_OP_EQUALS) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data = $'.$paramcount++ ;
+							$params[] = $curToken->getData();
+						}
+						else if($curType === EASToken::AS_OP_NOT) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data != $'.$paramcount++ ;
+							$params[] = $curToken->getData();
+						}
+						else if($curType === EASToken::AS_OP_GREATER) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data > $'.$paramcount++ ;
+							$params[] = $curToken->getData();
+						}
+						else if($curType === EASToken::AS_OP_LESS) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data < $'.$paramcount++ ;
+							$params[] = $curToken->getData();
+						}
+						else if($curType === EASToken::AS_OP_LIKE) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data LIKE $'.$paramcount++ ;
+							$params[] = $curToken->getData();
+						}
+					} else {
+						//We got any other type. Mostly this types are
+						//enums. this means we have to do another query to get the corresponding
+						//field data id.
+						//Get the next token and check the operation.
+						if($curType === EASToken::AS_OP_EQUALS) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							if(strtoupper($curToken->getData()) == 'NONE') {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data = $'.$paramcount++ ;
+								$params[] = '100';
+							} else {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.
+								             '.field_data = (SELECT element_id FROM artifact_extra_field_elements WHERE extra_field_id='.$field_id.
+							             	 ' AND element_name=$'.$paramcount++.')';
+								$params[] = $curToken->getData();
+							}
+						}
+						else if($curType === EASToken::AS_OP_NOT) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							if(strtoupper($curToken->getData()) == 'NONE') {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data != $'.$paramcount++ ;
+								$params[] = '100';
+							} else {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.
+								             '.field_data = (SELECT element_id FROM artifact_extra_field_elements WHERE extra_field_id='.$field_id.
+							             	 ' AND element_name=$'.$paramcount++.')';
+								$params[] = $curToken->getData();
+							}
+						}
+						else if($curType === EASToken::AS_OP_GREATER) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							if(strtoupper($curToken->getData()) == 'NONE') {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data > $'.$paramcount++ ;
+								$params[] = '100';
+							} else {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.
+								             '.field_data = (SELECT element_id FROM artifact_extra_field_elements WHERE extra_field_id='.$field_id.
+							             	 ' AND element_name=$'.$paramcount++.')';
+								$params[] = $curToken->getData();
+							}
+						}
+						else if($curType === EASToken::AS_OP_LESS) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							if(strtoupper($curToken->getData()) == 'NONE') {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data < $'.$paramcount++ ;
+								$params[] = '100';
+							} else {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.
+								             '.field_data = (SELECT element_id FROM artifact_extra_field_elements WHERE extra_field_id='.$field_id.
+							             	 ' AND element_name=$'.$paramcount++.')';
+								$params[] = $curToken->getData();
+							}
+						}
+						else if($curType === EASToken::AS_OP_LIKE) {
+							//Get the next token. This has to be the data!
+							$curTokenPointer++;
+				    		$curToken = $this->tokens[$curTokenPointer];
+							$curType  = $curToken->getType();
+							
+							if(strtoupper($curToken->getData()) == 'NONE') {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.'.field_data LIKE $'.$paramcount++ ;
+								$params[] = '100';
+							} else {
+								$wheresql .= ' AND aefd'.$extraFieldCounter.
+								             '.field_data = (SELECT element_id FROM artifact_extra_field_elements WHERE extra_field_id='.$field_id.
+							             	 ' AND element_name=$'.$paramcount++.')';
+								$params[] = $curToken->getData();
+							}
+						}
+					}
+					$wheresql .= ' AND aefd'.$extraFieldCounter.'.artifact_id=artifact_vw.artifact_id)' ;
+					$extraFieldCounter++;
+				}
+			}
+			
+			$curTokenPointer++;
+			if(!key_exists($curTokenPointer, $this->tokens)) {
+				$bDone = true;
+			}
+			else {
+				//This is an AND or OR operator. Add it to the wheresql
+				if($this->tokens[$curTokenPointer]->getType() === EASToken::AS_OP_AND) {
+					$wheresql .= ' AND';
+				}
+				else {
+					$wheresql .= ' OR';
+				}
+				$curTokenPointer++;
+				$curToken = $this->tokens[$curTokenPointer];
+			}
+		}
+
+		$result = db_query_params ('SELECT * FROM (' . $selectsql . $wheresql . ') AS Artifacts;',
+					   $params) ;
+		$rows = db_numrows($result);
+
+		$artifacts = array();
+		
+		if (db_error()) {
+			return false;
+		} else {
+			while ($arr = db_fetch_array($result)) {
+				$artifacts[] = new Artifact($artifactType, $arr);
+			}
+		}
+
+		return $artifacts;
+	}
+	
+	public function setParam($name, $value) {
+		$this->parameters[$name] = $value;
+	}
+	
+	public function getParam($name) {
+		if(key_exists($name, $this->parameters)) {
+			return $this->parameters[$name];
+		}
+		
+		return null;
+	}
+	
+	protected function _generateStdFieldWhereSQL($fieldName, $curType, &$curTokenPointer, &$paramcount, &$params) {
+		$wheresql    = '';
+		$field_alias = '';
+		$is_date     = false;
+		
+		//NOTE: We have to thread dates as a special type.
+		//      We have to convert it to a string with an like operation
+		//      and the input has to be converted if we use greater less or equals.
+		//      It also seems like there is no possibility for a custom field to be a date field.
+		
+		if($fieldName == 'ID') {
+			$field_alias = 'artifact_id';
+		}
+		else if($fieldName == 'Submitted by') {
+			$field_alias = 'submitted_realname';
+		}
+		else if($fieldName == 'Assigned to') {
+			$field_alias = 'assigned_realname';
+		}
+		else if($fieldName == 'Open Date') {
+			$is_date = true;
+			$field_alias = 'open_date';
+		}
+		else if($fieldName == 'Close Date') {
+			$is_date = true;
+			$field_alias = 'close_date';
+		}
+		
+		if($curType === EASToken::AS_OP_EQUALS) {
+			//Get the next token. This has to be the data!
+			$curTokenPointer ++;
+			$curToken = $this->tokens [$curTokenPointer];
+			$curType = $curToken->getType ();
+			
+			$wheresql .= ' '.$field_alias.' = $' . $paramcount ++;
+			
+			if($is_date) {
+				$params [] = strtotime($curToken->getData());
+			} else {
+				$params [] = $curToken->getData ();
+			}
+		} else if ($curType === EASToken::AS_OP_NOT) {
+			//Get the next token. This has to be the data!
+			$curTokenPointer ++;
+			$curToken = $this->tokens [$curTokenPointer];
+			$curType = $curToken->getType ();
+			
+			$wheresql .= ' '.$field_alias.' != $' . $paramcount ++;
+			
+			if($is_date) {
+				$params [] = strtotime($curToken->getData());
+			} else {
+				$params [] = $curToken->getData ();	
+			}
+			
+		} else if ($curType === EASToken::AS_OP_GREATER) {
+			//Get the next token. This has to be the data!
+			$curTokenPointer ++;
+			$curToken = $this->tokens [$curTokenPointer];
+			$curType = $curToken->getType ();
+			
+			$wheresql .= ' '.$field_alias.' > $' . $paramcount ++;
+			
+			if($is_date) {
+				$params [] = strtotime($curToken->getData());
+			} else {
+				$params [] = $curToken->getData ();
+			}
+		} else if ($curType === EASToken::AS_OP_LESS) {
+			//Get the next token. This has to be the data!
+			$curTokenPointer ++;
+			$curToken = $this->tokens [$curTokenPointer];
+			$curType = $curToken->getType ();
+
+			$wheresql .= ' '.$field_alias.' < $' . $paramcount ++;
+			
+			if($is_date) {
+				$params [] = strtotime($curToken->getData());
+			} else {
+				$params [] = $curToken->getData ();
+			}
+		} else if ($curType === EASToken::AS_OP_LIKE) {
+			//Get the next token. This has to be the data!
+			$curTokenPointer ++;
+			$curToken = $this->tokens [$curTokenPointer];
+			$curType = $curToken->getType ();
+			
+			if($is_date) {
+				//Convert unix timestamp to postgres date and then to string.
+				$wheresql .= ' to_char((SELECT TIMESTAMP \'epoch\' + '.$field_alias.' * INTERVAL \'1 second\'), \'YYYY-MM-DD HH24:MI\') LIKE $' . $paramcount ++;
+				
+			} else {
+				$wheresql .= ' '.$field_alias.' LIKE $' . $paramcount ++;
+			}
+			
+			$params [] = $curToken->getData ();
+		}
+		
+		return $wheresql;
+	}
+}
\ No newline at end of file

Modified: branches/messer-51-suche/src/common/advanced_search/ASInputAnalyzer.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/ASInputAnalyzer.class.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/ASInputAnalyzer.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,14 +1,32 @@
 <?php
-
-/**
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  * The ASInputAnalyzer is able to analyze the current input and can
  * return the next possible string identifier of a token in the current
  * input. This can be used to give the user some feedback about their
  * search query entered.
- * 
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
  */
+
 require_once "ASTokenizer.class.php";
 
 class ASInputAnalyzer {

Modified: branches/messer-51-suche/src/common/advanced_search/ASToken.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/ASToken.class.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/ASToken.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,7 +1,26 @@
 <?php
-/**
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  */
 
 class ASToken {

Modified: branches/messer-51-suche/src/common/advanced_search/ASTokenizer.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/ASTokenizer.class.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/ASTokenizer.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,10 +1,28 @@
 <?php
-/**
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  * The Tokenizer converts an string into the correpsonding tokens.
  * Not reckognized tokens are automatically deleted.
- * 
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
  */
 
 require_once "EASToken.enum.php";

Added: branches/messer-51-suche/src/common/advanced_search/AdvancedSearch.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/AdvancedSearch.class.php	                        (rev 0)
+++ branches/messer-51-suche/src/common/advanced_search/AdvancedSearch.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -0,0 +1,88 @@
+<?php
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
+ */
+class AdvancedSearch {
+	public static function renderSearchBar($searchActionUrl, $ajaxRequestUrl, $searchValue, $queryName) {
+		echo "<script>
+//<![CDATA[
+
+	jQuery(function() {
+		function split( val ) {
+			return val.split( / \s*/ );
+		}
+		function extractLast( term ) {
+			return split( term ).pop();
+		}
+
+		jQuery( \"#advanced_search\" )
+			// don't navigate away from the field on tab when selecting an item
+			.bind( \"keydown\", function( event ) {
+				if ( event.keyCode === jQuery.ui.keyCode.TAB &&
+						jQuery( this ).data( \"autocomplete\" ).menu.active ) {
+					event.preventDefault();
+				}
+			})
+			.autocomplete({
+				source: function( request, response ) {
+					jQuery.getJSON( \"$ajaxRequestUrl\" + request.term, {
+						term: extractLast( request.term )
+					}, response );
+				},
+				search: function() {
+					// custom minLength
+					var term = extractLast( this.value );
+					if ( term.length < 0 ) {
+						return false;
+					}
+				},
+				focus: function() {
+					// prevent value inserted on focus
+					return false;
+				},
+				select: function( event, ui ) {
+					var terms = split( this.value );
+					// remove the current input
+					terms.pop();
+					// add the selected item
+					terms.push( ui.item.value );
+					terms.push( \"\" );
+					this.value = terms.join( \" \" );
+					return false;
+				}
+			});
+	});
+	//]]>
+	</script>
+	<span class=\"ui-widget\"> 
+		<form id=\"advanced_search_form\" method=\"post\" action=\"$searchActionUrl\">
+			<input type=\"hidden\" name=\"set\" value=\"advanced\" />
+			<label for=\"advanced_search\"><?php echo _('Search').':';?> </label>
+			<input id=\"advanced_search\" name=\"advanced_search\" style=\"width: 500px; font-size: 12px;\" value=\"$searchValue\"/>
+			<input id=\"search_submit\" name=\"search_submit\" type=\"submit\" value=\""._('Search')."\"/>
+			<input id=\"save_advanced_query\" name=\"save_advanced_query\" type=\"checkbox\" value=\"true\">"._('Save Query as ')."</input><input type=\"textbox\" name=\"save_as\" id=\"save_as\" value=\"$queryName\"/>
+		</form>
+	</span>";
+	}
+}
+

Modified: branches/messer-51-suche/src/common/advanced_search/EASToken.enum.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/EASToken.enum.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/EASToken.enum.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,9 +1,26 @@
 <?php
-/**
- * Enumeration of Advanced Search tokens.
- * 
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  */
 
 final class EASToken {

Modified: branches/messer-51-suche/src/common/advanced_search/FusionForgeDFIProvider.class.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/FusionForgeDFIProvider.class.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/FusionForgeDFIProvider.class.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,7 +1,26 @@
 <?php
-/**
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  */
 
 require_once "IDFIProvider.interface.php";

Modified: branches/messer-51-suche/src/common/advanced_search/IDFIProvider.interface.php
===================================================================
--- branches/messer-51-suche/src/common/advanced_search/IDFIProvider.interface.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/common/advanced_search/IDFIProvider.interface.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,10 +1,28 @@
 <?php
-/**
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
  * This interface is used to give the user of this library the possibility to
  * define his own DFIs. This interface has to be reimplement per application.
- * 
- * Copyright (c) 2011
- *      Mike Esser <m.esser at tarent.de>
  */
 
 interface IDFIProvider {

Modified: branches/messer-51-suche/src/www/tracker/search.php
===================================================================
--- branches/messer-51-suche/src/www/tracker/search.php	2011-11-30 18:04:26 UTC (rev 17747)
+++ branches/messer-51-suche/src/www/tracker/search.php	2011-11-30 18:15:29 UTC (rev 17748)
@@ -1,4 +1,27 @@
 <?php
+/*-
+ * Advanced Search
+ *
+ * Copyright © 2011
+ *	Mike Esser <m.esser at tarent.de>
+ * All rights reserved.
+ *
+ * This file is part of FusionForge. FusionForge is free software;
+ * you can redistribute it and/or modify it under the terms of the
+ * GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the Licence, or (at your option)
+ * any later version.
+ *
+ * FusionForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with FusionForge; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *-
+ */
 
 require_once '/usr/share/gforge/common/advanced_search/FusionForgeDFIProvider.class.php';
 require_once '/usr/share/gforge/common/advanced_search/ASInputAnalyzer.class.php';



More information about the evolvis-commits mailing list