src/Easy/PickerForm.php
public function addToParent($recIds=null)
    {
    	if(!is_array($recIds))
    	{    		
    		$recIdArr = array();
    		$recIdArr[] = $recIds;
    	}else{
    		$recIdArr = $recIds;
    	}
    	
    	/* @var $parentForm EasyForm */
    	$parentForm = Openbizx::getObject($this->parentFormName);
    	foreach($recIdArr as $recId)
    	{
	               	        	
	        //clear parent form search rules
	        $this->searchRule="";
	        $parentForm->getDataObj()->clearSearchRule();
	        
	        $do = $this->getDataObj();
	        $baseSearchRule = $do->baseSearchRule;
	        $do->baseSearchRule = "";
	        $do->clearSearchRule();	        	        
	        $rec = $do->fetchById($recId);	
			$do->baseSearchRule = $baseSearchRule;
			
			if(!$rec){
				$rec= Openbizx::getObject($do->objectName,1)->fetchById($recId);
			}
			
	        // add record to parent form's dataObj who is M-M or M-1/1-1 to its parent dataobj
	        $ok = $parentForm->getDataObj()->addRecord($rec, $bPrtObjUpdated);
	        if (!$ok){	        	
	            return $parentForm->processDataObjError($ok);
	        }
    	}   
        
        $this->close();

        $parentForm->rerender();
		if($parentForm->parentFormName){
			$parentForm->renderParent();
		}
    }
public function addToParent($recIds=null)
    {
    	if(!is_array($recIds))
    	{    		
    		$recIdArr = array();
    		$recIdArr[] = $recIds;
    	}else{
    		$recIdArr = $recIds;
    	}
    	
    	/* @var $parentForm EasyForm */
    	$parentForm = Openbizx::getObject($this->parentFormName);
    	foreach($recIdArr as $recId)
    	{
	               	        	
	        //clear parent form search rules
	        $this->searchRule="";
	        $parentForm->getDataObj()->clearSearchRule();
	        
	        $do = $this->getDataObj();
	        $baseSearchRule = $do->baseSearchRule;
	        $do->baseSearchRule = "";
	        $do->clearSearchRule();	        	        
	        $rec = $do->fetchById($recId);	
			$do->baseSearchRule = $baseSearchRule;
			
			if(!$rec){
				$rec= Openbizx::getObject($do->objectName,1)->fetchById($recId);
			}
			
	        // add record to parent form's dataObj who is M-M or M-1/1-1 to its parent dataobj
	        $ok = $parentForm->getDataObj()->addRecord($rec, $bPrtObjUpdated);
	        if (!$ok){	        	
	            return $parentForm->processDataObjError($ok);
	        }
    	}   
        
        $this->close();

        $parentForm->rerender();
		if($parentForm->parentFormName){
			$parentForm->renderParent();
		}
    }
Add a record (popup) to the parent form if OK button clicked, (M-M or M-1/1-1)

@return void