* */ namespace Combodo\iTop\Application\Search; use ApplicationContext; use AttributeDefinition; use AttributeExternalField; use AttributeFriendlyName; use AttributeSubItem; use CMDBObjectSet; use Combodo\iTop\Application\Search\CriterionConversion\CriterionToSearchForm; use CoreException; use DBObjectSearch; use DBObjectSet; use Dict; use Exception; use Expression; use FieldExpression; use IssueLog; use MetaModel; use MissingQueryArgument; use TrueExpression; use utils; use WebPage; class SearchForm { /** * @param \WebPage $oPage * @param \CMDBObjectSet $oSet * @param array $aExtraParams * * @return string * @throws \CoreException * @throws \DictExceptionMissingString * @throws \Exception */ public function GetSearchForm(WebPage $oPage, CMDBObjectSet $oSet, $aExtraParams = array()) { $sHtml = ''; $oAppContext = new ApplicationContext(); $sClassName = $oSet->GetFilter()->GetClass(); $aListParams = array(); foreach($aExtraParams as $key => $value) { $aListParams[$key] = $value; } // Simple search form if (isset($aExtraParams['currentId'])) { $sSearchFormId = $aExtraParams['currentId']; } else { $iSearchFormId = $oPage->GetUniqueId(); $sSearchFormId = 'SimpleSearchForm'.$iSearchFormId; $sHtml .= "