formData; } /** * @param $formData * @return $this */ public function setFormData($formData) { foreach($formData as $key => &$value) { $this->updateEntity($value); } $this->formData = $formData; return $this; } /** * @param null $entity */ public function updateEntity(&$entity = null) { if(is_array($entity)) { foreach ($entity as $key => &$value) { $this->updateEntity($value); } }elseif(is_object($entity)) { }else{ $entity = html_entity_decode($entity, ENT_QUOTES); } } }