Uploaded image for project: 'MyFaces Tobago'
  1. MyFaces Tobago
  2. TOBAGO-221

tc:sheet -> tc:column -> tc:out does not support f:convertNumber / convertDateTime

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Cannot Reproduce
    • 1.0.9
    • None
    • Core
    • None

    Description

      assuming following jsp-fragment

      <tc:sheet value="#

      {table22ListModel}

      " var="entry"
      state="#

      {table2SheetState}

      " columns="1*;1*;1*;1*;1*;1*;1*"
      rows="5" first="0" showDirectLinks="center" showPageRange="right"
      showRowRange="left" selectable="single">

      <tc:column label="Date" sortable="true">
      <tc:out value="#

      {entry.date}

      ">
      <f:convertDateTime pattern="yyyy/MM/dd"/>
      </tc:out>
      </tc:column>
      <tc:column label="Double" sortable="true">
      <tc:out value="#

      {entry.double}

      ">
      <f:convertNumber minFractionDigits="2" maxFractionDigits="3" />
      </tc:out>
      </tc:column>
      ..........

      an Exception occures

      javax.faces.convert.ConverterException: java.lang.IllegalArgumentException: Cannot format given Object as a Date
      javax.faces.convert.DateTimeConverter.getAsString(DateTimeConverter.java:369)
      org.apache.myfaces.tobago.component.ComponentUtil.currentValue(ComponentUtil.java:420)
      org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.OutRenderer.encodeEnd(OutRenderer.java:44)
      javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:740)
      org.apache.myfaces.tobago.renderkit.RenderUtil.encode(RenderUtil.java:84)
      org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.SheetRenderer.renderSheet(SheetRenderer.java:394)
      org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.SheetRenderer.encodeEnd(SheetRenderer.java:132)
      javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:740)
      org.apache.myfaces.tobago.component.UIData.encodeEnd(UIData.java:111)

      Attachments

        Activity

          People

            Unassigned Unassigned
            rohloff Rainer Rohloff
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: