-
1. Re: cc.attrs.invalid is evaluated as true even if input field is valid
bleathem Jul 5, 2011 10:09 AM (in response to mpevec99)What version of Seam Faces are you using?
Do you have this same problem if you use the provided sc:inputContainer implementation?
-
2. Re: cc.attrs.invalid is evaluated as true even if input field is valid
mpevec99 Jul 6, 2011 3:52 AM (in response to mpevec99)I am using 3.0.1.Final:
<dependency> <groupId>org.jboss.seam.faces</groupId> <artifactId>seam-faces</artifactId> <version>3.0.1.Final</version> </dependency>
If I use provided implementation the same problem exists, no validation error message is shown, action method is called, but cc.attrs.invalid is still evaluated as true, so my label has a styleClass set to:
label errors
. -
3. Re: cc.attrs.invalid is evaluated as true even if input field is valid
bleathem Jul 6, 2011 4:56 PM (in response to mpevec99)Can you try 3.0.2? It included some fixes to the inputContainer that may resolve your problem.
-
4. Re: cc.attrs.invalid is evaluated as true even if input field is valid
mpevec99 Jul 6, 2011 6:28 PM (in response to mpevec99)Ok, i've tried, but with no success, styleClass
label errors
still exists. -
5. Re: cc.attrs.invalid is evaluated as true even if input field is valid
bleathem Jul 7, 2011 2:36 AM (in response to mpevec99)Ok, thanks for trying. Would you mind filing a jira issue for this?
Thanks
-
6. Re: cc.attrs.invalid is evaluated as true even if input field is valid
mpevec99 Jul 7, 2011 5:24 AM (in response to mpevec99)Ok, issue https://issues.jboss.org/browse/SEAMFACES-47 is already filed by someone else. Thnx.
-
7. Re: cc.attrs.invalid is evaluated as true even if input field is valid
figwam Apr 13, 2012 2:13 PM (in response to mpevec99)Hi Milan,
the topic is old, but the Problem still exists and is still not fixed
I did spend more than 2 hours to find the solution for this problem.
But now found one:
1. download the seam sources
2. copy the files into your project:
a. org.jboss.seam.faces.component.ValueExpressionAnalyzer
b. org.jboss.seam.faces.component.UIInputContainer
3. do change the following lines in org.jboss.seam.faces.component.UIInputContainer
a. public static final String COMPONENT_TYPE = "org.jboss.seam.faces.InputContainer"; to public static final String COMPONENT_TYPE = "org.jboss.seam.faces.mod.InputContainer";
b. this is the fix in seam itself:
in method public void encodeBegin(final FacesContext context) throws IOException {...} add an 'else' to
if (elements.hasValidationError()) {
getAttributes().put(getInvalidAttributeName(), true);
} else {
getAttributes().put(getInvalidAttributeName(), false);
}
4. use following componentType i your decorator:
<cc:interface componentType="org.jboss.seam.faces.mod.InputContainer">
It is a small fix in the seam.faces library, please guys put this fix into the next release (I use seam 3.1.0.Final), thx
regards
Alex
-
8. Re: cc.attrs.invalid is evaluated as true even if input field is valid
lightguard Apr 13, 2012 2:26 PM (in response to figwam)Create a JIRA and attach the patch, or fork and pull request please.
-
9. Re: cc.attrs.invalid is evaluated as true even if input field is valid
pacificshark May 11, 2012 9:52 AM (in response to figwam)thanks Alex, it is solved.