Exemplo n.º 1
0
 /**
  * Check if children of an element are valid
  * Element's children will always be valid before the formContext is validated
  * @param string|Element $elementName public name of the element or instance of the element
  * @return bool
  * @throws \UForm\Exception
  */
 public function childrenAreValid($elementName)
 {
     if (is_string($elementName)) {
         $validation = $this->chainValidation->getValidationByName($elementName);
         if ($validation) {
             return $validation->childrenAreValid();
         } else {
             return true;
         }
     } else {
         return $this->chainValidation->elementChildrenAreValid($elementName);
     }
 }
Exemplo n.º 2
0
 /**
  * Check if children of an element are valid
  * Element's children will always be valid before the formContext is validated
  * @param $elementName
  * @return bool
  * @throws \UForm\Exception
  */
 public function childrenAreValid($elementName)
 {
     return $this->chainValidation->elementChildrenAreValid($elementName);
 }