Form element message not filled during form validation. #12395

Closed
lisek2000 opened this Issue Nov 4, 2016 · 1 comment

Projects

None yet

2 participants

@lisek2000
lisek2000 commented Nov 4, 2016 edited

Hello,

as in the topic - messages in elements are not filled after form validation.

Short example:

class Element
{
    public function render()
    {
        return $this->hasMessages() ? "yes" : "no";
    }
}

$form = isValid($_POST); // assuming that error occurs
echo $form->get("elementName")->render() // echo "no";
echo $form->hasMessagesFor("elementName") ? "yes" : "no"; //echo"yes";

Expected behaviour: after isValid() called on $form, all messages related to elements in that form will be setted also in element.

Details

  • Phalcon version: 3.0.1
  • PHP Version: 5.6.24
  • Installation type: Compiling from source
  • Server: Apache
@mbrostami mbrostami referenced this issue Dec 13, 2016
Merged

Form validation some fixes #12466

3 of 3 tasks complete
@sergeyklay sergeyklay added this to the 3.0.3 milestone Dec 20, 2016
@sergeyklay
Collaborator

Fixed in the 3.0.x branch. Thanks you

@sergeyklay sergeyklay closed this Dec 20, 2016
@sergeyklay sergeyklay self-assigned this Dec 24, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment