Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 1.8.2
-
Fix Version/s: 1.8.2-EE-GA, 1.8.3
-
Component/s: ICE-Components
-
Labels:None
-
Environment:All
Description
Selecting an odd date (not even) on a selectInputDate triggers validation of the other fields in the page when immediate is set to true. The same thing happens for the "Show previous month" and "Show previous year" buttons. When selecting an even date, "Show next month" or "Show next year" everything works as expected.
main.xhtml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
xmlns:ice="http://www.icesoft.com/icefaces/component">
<head>
<title>Test</title>
<ice:outputStyle href="xmlhttp/css/rime/rime.css" />
</head>
<body>
<ice:form partialSubmit="false" id="Form">
<ice:panelGrid columns="3">
<ice:inputText value="#{bean.text}" id="Text" required="true">
<f:validateLength minimum="2" />
</ice:inputText>
<ice:selectInputDate value="#{bean.date}" renderAsPopup="false" partialSubmit="false" id="Date" immediate="true" />
<ice:selectOneListbox value="#{bean.item}" size="1" required="true" id="Combo">
<f:selectItem itemLabel="Select..." itemValue="-1" />
<f:selectItem itemLabel="0" itemValue="0" />
<f:selectItem itemLabel="1" itemValue="1" />
<f:selectItem itemLabel="2" itemValue="2" />
<f:validateLongRange minimum="0" />
</ice:selectOneListbox>
</ice:panelGrid>
<ice:commandButton actionListener="#{bean.submit}" value="Submit" />
<br />
<ice:outputText value="Text: #{bean.text}<br/>Date: #{bean.date}<br/>Item: #{bean.item}" escape="false" />
</ice:form>
<ice:messages />
</body>
</html>
Bean.java
package org.local.test;
import java.util.Date;
import javax.faces.event.ActionEvent;
public class Bean {
private String text;
private Date date;
private Integer item;
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
public Date getDate() {
return date;
}
public void setDate(Date date) {
this.date = date;
}
public Integer getItem() {
return item;
}
public void setItem(Integer item) {
this.item = item;
}
public void submit(ActionEvent ae) {
System.err.println("submit");
}
}
main.xhtml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
xmlns:ice="http://www.icesoft.com/icefaces/component">
<head>
<title>Test</title>
<ice:outputStyle href="xmlhttp/css/rime/rime.css" />
</head>
<body>
<ice:form partialSubmit="false" id="Form">
<ice:panelGrid columns="3">
<ice:inputText value="#{bean.text}" id="Text" required="true">
<f:validateLength minimum="2" />
</ice:inputText>
<ice:selectInputDate value="#{bean.date}" renderAsPopup="false" partialSubmit="false" id="Date" immediate="true" />
<ice:selectOneListbox value="#{bean.item}" size="1" required="true" id="Combo">
<f:selectItem itemLabel="Select..." itemValue="-1" />
<f:selectItem itemLabel="0" itemValue="0" />
<f:selectItem itemLabel="1" itemValue="1" />
<f:selectItem itemLabel="2" itemValue="2" />
<f:validateLongRange minimum="0" />
</ice:selectOneListbox>
</ice:panelGrid>
<ice:commandButton actionListener="#{bean.submit}" value="Submit" />
<br />
<ice:outputText value="Text: #{bean.text}<br/>Date: #{bean.date}<br/>Item: #{bean.item}" escape="false" />
</ice:form>
<ice:messages />
</body>
</html>
Bean.java
package org.local.test;
import java.util.Date;
import javax.faces.event.ActionEvent;
public class Bean {
private String text;
private Date date;
private Integer item;
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
public Date getDate() {
return date;
}
public void setDate(Date date) {
this.date = date;
}
public Integer getItem() {
return item;
}
public void setItem(Integer item) {
this.item = item;
}
public void submit(ActionEvent ae) {
System.err.println("submit");
}
}
Activity
- All
- Comments
- History
- Activity
- Remote Attachments
- Subversion
Dumitru Ban
created issue -
Dumitru Ban
made changes -
Field | Original Value | New Value |
---|---|---|
Attachment | SelectInputDateRenderer.patch.txt [ 12102 ] |
Ken Fyten
made changes -
Salesforce Case | [] | |
Fix Version/s | 1.8.2-EE-GA [ 10216 ] | |
Fix Version/s | 1.8.3 [ 10211 ] | |
Assignee Priority | P1 | |
Assignee | Yip Ng [ yip.ng ] |
yip.ng
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
Assignee Priority | P1 | |
Assignee | Yip Ng [ yip.ng ] |