0 Replies Latest reply on Feb 4, 2009 3:19 PM by Kevin Taylor

    dataTable and toolTip question?

    Kevin Taylor Newbie

      would the following be possible: I would like to have another bean pull the data for a tooltip whenever the user mouses over an item. Is this possible or is the tooltip only populated when the dataTable is being populated?

      <rich:dataTable value="#{toolTipData.vehicles}" width="400" var="vehicle" rowKeyVar="row">
       <rich:column>
       <f:facet name="header">
       <h:outputText value="##"/>
       </f:facet>
       <h:outputText value="#{row+1}" />
       </rich:column>
       <rich:column>
       <f:facet name="header">
       <h:outputText value="Make"/>
       </f:facet>
       <h:outputText id="make" value="#{vehicle.make}" >
       <rich:toolTip direction="top-right" mode="ajax" delay="30" styleClass="tooltip" immediate="true" layout="block">
       <a4j:actionparam name="key" value="#{row}" assignTo="#{alternateBean.currentVehicleIndex}" />
      
       <h:panelGrid columns="4">
       <f:facet name="header">
       <h:outputText value="Vehicle details:" />
       </f:facet>
       <h:outputText value="make:" />
       <h:outputText value="#{alternateBean.make}" styleClass="tooltipData" />
       <h:outputText value="model:" />
       <h:outputText value="#{alternateBean.model}" styleClass="tooltipData" />
       <h:outputText value="year:" />
       <h:outputText value="#{alternateBean.year}" styleClass="tooltipData" />
       <h:outputText value="milage:" />
       <h:outputText value="#{alternateBean.milage}" styleClass="tooltipData" />
       <h:outputText value="zip:" />
       <h:outputText value="#{alternateBean.zip}" styleClass="tooltipData" />
       <h:outputText value="listed:" />
       <h:outputText value="#{alternateBean.listed}" styleClass="tooltipData" >
       <f:convertDateTime dateStyle="short"/>
       </h:outputText>
       <f:facet name="footer">
       <h:panelGroup>
       <h:outputText value="vin: " />
       <h:outputText value="#{alternateBean.vin}" styleClass="tooltipData" />
       </h:panelGroup>
       </f:facet>
      
       </h:panelGrid>
       </rich:toolTip>
       </h:outputText>
       </rich:column>
       <rich:column>
       <f:facet name="header">
       <h:outputText value="Model"/>
       </f:facet>
       <h:outputText value="#{vehicle.model}" />
       </rich:column>
       <rich:column>
       <f:facet name="header">
       <h:outputText value="Year"/>
       </f:facet>
       <h:outputText value="#{vehicle.year}" />
       </rich:column>