Adventure PHP Framework Issue Management

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000318Adventure PHP FrameworkBugpublic2017-07-24 21:192017-08-06 22:22
Assigned ToChristianAchatz 
Product Version3.3 
Target Version3.4Fixed in Version3.4 
Summary0000318: Listener tags not notified in case of multiple listeners
DescriptionActual behavior:
In case a form features multiple form validation listener tags, only the last listener is notifier to display form control specific error messages.

Expected behavior:
All validation listeners are notified.
Steps To ReproduceForm:

<@controller class="test\pres\controller\TestController"@>

<html:form name="test">
    <form:text name="test1"/><form:listener control="test1">Test1</form:listener>

    <form:text name="test2"/><form:listener control="test2">Test2</form:listener>

    <form:addvalidator class="APF\tools\form\validator\TextLengthValidator" button="send" control="test1|test2"/>
    <form:button name="send" value="GO"/>


namespace test\pres\controller;

use APF\core\pagecontroller\BaseDocumentController;

class TestController extends BaseDocumentController {
    public function transformContent() {
        $form = $this->getForm('test');
TagsNo tags attached.
Codereferenz: ([Datei]:[Zeile])
Attached Files

- Relationships

-  Notes
ChristianAchatz (administrator)
2017-07-24 21:39


Validation listener 1 has never been notified due to the fact that form validation (recursive calling of isValid() on all form controls) has been omitted for any further form control in case one form control has assumed invalid state. This not only affected validation listeners but also form control marking (CSS class).


Along with fixing the logic glitch in HtmlFormTag the reference operators in FormValidator and FormFilter have been removed to fix the reference issue leading to only the last validation listener has been notified.
ChristianAchatz (administrator)
2017-07-24 21:51

Fix pushed under https://github.com/AdventurePHP/code/commit/99dd8b1f5d7bd2ae47817031e15eb57fa4378f5d. [^]

Documentation update and change log entry required.
ChristianAchatz (administrator)
2017-07-25 22:08

Added further unit tests to ensure validator is created correctly.
ChristianAchatz (administrator)
2017-08-06 22:22

Completed documentation work. Closing issue.

- Issue History
Date Modified Username Field Change
2017-07-24 21:19 ChristianAchatz New Issue
2017-07-24 21:19 ChristianAchatz Status new => assigned
2017-07-24 21:19 ChristianAchatz Assigned To => ChristianAchatz
2017-07-24 21:39 ChristianAchatz Note Added: 0000771
2017-07-24 21:51 ChristianAchatz Note Added: 0000772
2017-07-25 22:08 ChristianAchatz Note Added: 0000773
2017-08-06 22:22 ChristianAchatz Note Added: 0000774
2017-08-06 22:22 ChristianAchatz Status assigned => resolved
2017-08-06 22:22 ChristianAchatz Fixed in Version => 3.4
2017-08-06 22:22 ChristianAchatz Resolution open => fixed

Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker