/**
  * @param $pipelineId
  * @param $propertyId
  * @param $value
  * @return null|Pipeline_Model_PipelinePropertyValues
  *
  */
 protected function _createPropertyValue($pipelineId, $propertyId, $value)
 {
     $pipelinePropertyValueMapper = new Pipeline_Model_Mapper_PipelinePropertyValues();
     $pipelinePropertyValue = new Pipeline_Model_PipelinePropertyValues();
     $pipelinePropertyValue->setOptions(array('pipelineId' => $pipelineId, 'propertyId' => $propertyId, 'value' => $value));
     $pipelinePropertyValueMapper->save($pipelinePropertyValue);
     $newPropertyValue = $pipelinePropertyValueMapper->findByKey($pipelinePropertyValue->getPipelineId(), $pipelinePropertyValue->getPropertyId(), new Pipeline_Model_PipelinePropertyValues());
     return $newPropertyValue;
 }
 /**
  * @param $propertyId
  * @return null|Pipeline_Model_PipelinePropertyValues
  */
 protected function _createNewPropertyValue($propertyId)
 {
     $request = $this->getRequest();
     $pipelinePropertyValueMapper = new Pipeline_Model_Mapper_PipelinePropertyValues();
     $pipelinePropertyValue = new Pipeline_Model_PipelinePropertyValues();
     $pipelinePropertyValue->setOptions(array('pipelineId' => $request->getParam('pipelineId'), 'propertyId' => $propertyId, 'value' => $request->getParam('newPropertyValue')));
     $pipelinePropertyValueMapper->save($pipelinePropertyValue);
     $newPropertyValue = $pipelinePropertyValueMapper->findByKey($pipelinePropertyValue->getPipelineId(), $pipelinePropertyValue->getPropertyId(), new Pipeline_Model_PipelinePropertyValues());
     return $newPropertyValue;
 }