MyFaces Trinidad
  1. MyFaces Trinidad
  2. TRINIDAD-886

Add the ability to the show* components to always get their disclosed property from EL

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.5-core, 1.2.5-core
    • Fix Version/s: 1.0.5-core, 1.2.5-core
    • Component/s: Components
    • Labels:
      None

      Description

      The disclosed property of showDetail components are updated by the renderers. It would be extremely helpful to stop this behavior so that EL is always used.

      Example of someone wanting to disclose only one item:
      public class Bean {
      private int disclosedIndex = -1;
      public void handleDisclose(DisclosureEvent event)

      { // manually update the index }

      ...
      }

      <tr:iterator var="_item" value="#

      {bean.items}

      " varStatus="_varStatus">
      <tr:showDetail disclosedText="#{_item.title}" undisclosedText="#{_item.title}":
      disclosed="#

      {bean.disclosedItem eq _varStatus.index}

      "
      disclosureListener="#

      {bean.handleDisclose}

      ">
      <af:outputFormatted value="#{_item.desc}"/>
      </af:showDetail>
      </af:iterator>

      Proposal:

      A new attribute to be added to showDetial* components:
      public boolean isDisclosedTransient() {}

      This should default to false. If set, the renderer should never set the disclosed property locally, or the faces bean property value should ignore sets. This way the disclosed property set in the UI would always be used to determine disclosed state.

        Activity

        Hide
        Andrew Robinson added a comment -

        Added 1.2.5 to fix versions

        Show
        Andrew Robinson added a comment - Added 1.2.5 to fix versions
        Hide
        Andrew Robinson added a comment -

        Committed revision 610278 in the 1.2 trunk

        Show
        Andrew Robinson added a comment - Committed revision 610278 in the 1.2 trunk
        Hide
        Andrew Robinson added a comment -

        Committed revision 610275 in the trunk

        Show
        Andrew Robinson added a comment - Committed revision 610275 in the trunk

          People

          • Assignee:
            Andrew Robinson
            Reporter:
            Andrew Robinson
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development