ICEfaces-EE
  1. ICEfaces-EE
  2. IPCK-134

f:convertNumber does not work with ice-cc:textColumn in non-edit mode

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.2.GA_P01
    • Fix Version/s: EE-1.8.2.GA_P03
    • Component/s: Facelet Components
    • Labels:
      None
    • Environment:
      All

      Description

      When using a f:convertNumber tag inside an ice-cc:textColumn tag, the converted output is not displayed when in non-edit mode. If the row is set to be editable then the converted info is displayed.

      Sample Code:
      <ice-cc:textColumn id="amountField"
                                             property="amount"
                                             title="Amount">
            <f:convertNumber currencySymbol="$"
                                               type="currency"/>
      </ice-cc:textColumn>

      1. edit.JPG
        21 kB
      2. non-edit.JPG
        13 kB

        Activity

        Hide
        Arran Mccullough added a comment -

        Testing with the ice-cc:column component shows the converted output properly.

        Show
        Arran Mccullough added a comment - Testing with the ice-cc:column component shows the converted output properly.
        Hide
        Brad Kroeger added a comment -

        When in edit mode the following is rendered:

        <ice:inputText id="#

        {property}

        "
        autocomplete="#

        {autocomplete}

        "
        disabled="#

        {disabled}

        "
        readonly="#

        {readonly}

        "
        styleClass="#

        {styleClass}

        "
        value="#

        {bean.selectedRowEdits[row][property]}

        "
        rendered="#

        {bean.selectedRows[row]}

        "
        style="width:#

        {width};"
        required="#{required}">
        <ui:insert/>
        </ice:inputText>

        When in regular mode this is rendered:

        <ice:outputText value="#{row[property]}"
        rendered="#{not bean.selectedRows[row]}"
        style="width:#{width}

        ;"/>

        If I change it to include the nested content in the ice-cc:textColumn:

        <ice:outputText value="#

        {row[property]}

        "
        rendered="#

        {not bean.selectedRows[row]}

        "
        style="width:#

        {width}

        ;">
        <ui:insert/>
        </ice:outputText>

        An exception is thrown on all the ice-cc:textColumn components with nested validators as you cannot nest a validator in an ice:outputText component.

        The only solution I can think of is to use an ice:inputText component instead of an outputText component. This would require making the inputText component look like an outputText component.

        Show
        Brad Kroeger added a comment - When in edit mode the following is rendered: <ice:inputText id="# {property} " autocomplete="# {autocomplete} " disabled="# {disabled} " readonly="# {readonly} " styleClass="# {styleClass} " value="# {bean.selectedRowEdits[row][property]} " rendered="# {bean.selectedRows[row]} " style="width:# {width};" required="#{required}"> <ui:insert/> </ice:inputText> When in regular mode this is rendered: <ice:outputText value="#{row[property]}" rendered="#{not bean.selectedRows[row]}" style="width:#{width} ;"/> If I change it to include the nested content in the ice-cc:textColumn: <ice:outputText value="# {row[property]} " rendered="# {not bean.selectedRows[row]} " style="width:# {width} ;"> <ui:insert/> </ice:outputText> An exception is thrown on all the ice-cc:textColumn components with nested validators as you cannot nest a validator in an ice:outputText component. The only solution I can think of is to use an ice:inputText component instead of an outputText component. This would require making the inputText component look like an outputText component.
        Hide
        Philip Breau added a comment -

        resolved in svn rev 25100

        • editable table columns now allow for named 'converter' and 'validator' <ui:define/> tags, for which the converter is applied to both input and output states, and which the validator is applied to only the input state.
        • added new column to the editable table demo using currency converter
        Show
        Philip Breau added a comment - resolved in svn rev 25100 editable table columns now allow for named 'converter' and 'validator' <ui:define/> tags, for which the converter is applied to both input and output states, and which the validator is applied to only the input state. added new column to the editable table demo using currency converter
        Hide
        Ken Fyten added a comment -

        We will need to review this fix as we need to maintain backwards API compatibility with previous releases as much as possible.

        Also note that the commit for rvn 25099 and 25100 were reverted on the icepack/branches/icepack-1.8.2.GA_P02 staging branch for P02 release (so this change is not included in P02).

        Show
        Ken Fyten added a comment - We will need to review this fix as we need to maintain backwards API compatibility with previous releases as much as possible. Also note that the commit for rvn 25099 and 25100 were reverted on the icepack/branches/icepack-1.8.2.GA_P02 staging branch for P02 release (so this change is not included in P02).

          People

          • Assignee:
            Brad Kroeger
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: