Details
-
Type: Bug
-
Status: Open
-
Priority: Major
-
Resolution: Unresolved
-
Affects Version/s: 4.2
-
Fix Version/s: None
-
Component/s: ACE-Components
-
Labels:None
-
Environment:Tomcat-9.0.8
Java 1.8
-
ICEsoft Forum Reference:
-
Support Case References:
Description
Created a datatable and in the header I need to have a list with items that can be selected by the checkbox group. I followed the use case selected in the link http://icefaces-showcase.icesoft.org/showcase.jsf?grp=ace:dataTable&exp=Filtering for the column chassis. I need to create a similar functionality. I tried various values but column is still shown as a text box to me rather than the drop down list with the check box with values.
Activity
Manish Sharma
created issue -
Manish Sharma
made changes -
Field | Original Value | New Value |
---|---|---|
Comment |
[ package com.demo.test;
import java.util.ArrayList; import java.util.List; import javax.faces.bean.CustomScoped; import javax.faces.bean.ManagedBean; @ManagedBean(name= "TestModel") @CustomScoped(value = "session") public class TestModel { private List<Car> carList; private List<String> siteIdFilterValues = new ArrayList<String>(); public List<Car> getCarList() { return carList; } public void setCarList(List<Car> carList) { this.carList = carList; } //Constructor will be called when the object is created public TestModel() { CarGenerator generator = new CarGenerator(); carList = generator.getCarList(50); } public List<String> getSiteIdFilterValues(){ siteIdFilterValues.add("COR"); siteIdFilterValues.add("ADD"); siteIdFilterValues.add("GAT"); siteIdFilterValues.add("PAT"); return siteIdFilterValues; } } Model class ] |
Manish Sharma
made changes -
Attachment | Infaces4.2.2.zip [ 22911 ] |
Manish Sharma
made changes -
Comment |
[ package com.demo.test;
import java.util.ArrayList; import java.util.List; import javax.faces.bean.CustomScoped; import javax.faces.bean.ManagedBean; @ManagedBean(name= "TestModel") @CustomScoped(value = "session") public class TestModel { private List<Car> carList; private List<String> siteIdFilterValues = new ArrayList<String>(); public List<Car> getCarList() { return carList; } public void setCarList(List<Car> carList) { this.carList = carList; } //Constructor will be called when the object is created public TestModel() { CarGenerator generator = new CarGenerator(); carList = generator.getCarList(50); } public List<String> getSiteIdFilterValues(){ siteIdFilterValues.add("ONE"); siteIdFilterValues.add("TWO"); siteIdFilterValues.add("THREE"); siteIdFilterValues.add("FOUR"); return siteIdFilterValues; } } ] |
Manish Sharma
made changes -
Comment |
[ <!DOCTYPE html>
<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:icecore="http://www.icefaces.org/icefaces/core" xmlns:ace="http://www.icefaces.org/icefaces/components" xmlns:mv="http://www.metavante.com/jsf"> <h:head> <meta name="viewport" content="width=device-width, initial-scale=1" /> <link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css" /> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" /> <meta charset="ISO-8859-1"></meta> <title>Progress Monitoring</title> </h:head> <h:body> <h:form id="form"> <ace:dataTable id="carTableSingleRow" value="#{TestModel.carList}" var="car"> <ace:column id="name" headerText="Name of Car" filterBy="#{car.name}" filterMatchMode="contains" filterValues="#{TestModel.siteIdFilterValues}"> <f:facet name="filter"> <h:panelGrid columns="2"> <ace:checkboxButton id="cb2"> <ace:ajax execute="@form" render="@form" /> </ace:checkboxButton> <h:outputText value="Name" /> <ace:checkboxButton id="cb3"> <ace:ajax execute="@form" render="@form" /> </ace:checkboxButton> <h:outputText value="Make" /> </h:panelGrid> </f:facet> <h:outputText id="nameId" value="#{car.name}" /> </ace:column> <ace:column headerText="Make"> <h:outputText id="makeId" value="#{car.make}" /> </ace:column> </ace:dataTable> </h:form> </h:body> </html> Xhtml page. ] |
Added the eclipse project here. Removing the library attachments.