facelets
  1. facelets
  2. FACELETS-328

varStatus implementation for UIRepeat

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: ALL
    • Fix Version/s: 1.1.15
    • Component/s: jsf
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      328

      Description

      I have seen a number of posts about using varStatus in a ui:repeat tag. After
      running into this myself, I decided that it is probably something that should be
      included in future releases of Facelets. There is obviously interest, and I
      can't imagine any reason not to include it.

        Activity

        Hide
        mojavelinux added a comment -

        Created an attachment (id=129)
        Patch for UIRepeat to support varStatus property and enhancement to IterationStatus

        Show
        mojavelinux added a comment - Created an attachment (id=129) Patch for UIRepeat to support varStatus property and enhancement to IterationStatus
        Hide
        mojavelinux added a comment -

        It turns out to be quite straightforward to implement varStatus in the ui:repeat
        component. Most of the groundwork was already in place. I attached a proposed
        patch above. I reused the IterationStatus model object used by the
        ForEachHandler. In addition, I enhanced the class by adding isEven() and isOdd()
        properties which are useful for alternating row styling. Finally, I fixed a bug
        in the implementation when using offset and size. It was rendering one extra row.

        Show
        mojavelinux added a comment - It turns out to be quite straightforward to implement varStatus in the ui:repeat component. Most of the groundwork was already in place. I attached a proposed patch above. I reused the IterationStatus model object used by the ForEachHandler. In addition, I enhanced the class by adding isEven() and isOdd() properties which are useful for alternating row styling. Finally, I fixed a bug in the implementation when using offset and size. It was rendering one extra row.
        Hide
        mojavelinux added a comment -

        Created an attachment (id=130)
        Updated that saves and restores the state of new properties

        Show
        mojavelinux added a comment - Created an attachment (id=130) Updated that saves and restores the state of new properties
        Show
        Ed Burns added a comment - https://facelets.dev.java.net/issues/show_bug.cgi?id=328
        Hide
        Ed Burns added a comment -
            • Issue 208 has been marked as a duplicate of this issue. ***
        Show
        Ed Burns added a comment - Issue 208 has been marked as a duplicate of this issue. ***
        Hide
        Ed Burns added a comment -
        Show
        Ed Burns added a comment - Fixed in JSF impl at < https://javaserverfaces-spec-public.dev.java.net/issues/show_bug.cgi?id=521 >.
        Hide
        Ed Burns added a comment -

        I am no longer tracking progress of these projects on java.net.

        Show
        Ed Burns added a comment - I am no longer tracking progress of these projects on java.net.

          People

          • Assignee:
            Ed Burns
            Reporter:
            dgreenbean
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: