Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Per the conversation between Neil, Jorge, and I.

      Here you go.

      TODO:
      Needs an Icon/styling for the filter in page.jsp. (Nate please)
      Optional: only present filter to administrations (whomever.. I don't know the appropriate if logic here)

      2 filtes affected. pretty minor edits:

      Index: /work/projects/liferay/portal/trunk/portal-web/docroot/html/js/liferay/dock.js
      ===================================================================
      — /work/projects/liferay/portal/trunk/portal-web/docroot/html/js/liferay/dock.js (revision 8930)
      +++ /work/projects/liferay/portal/trunk/portal-web/docroot/html/js/liferay/dock.js (working copy)
      @@ -144,6 +144,8 @@
      heading.toggleClass('hide');
      }
      );
      + this.toggleEmptyPlacesFilter(false);
      +
      },

      _toggle: function(event, state)

      { @@ -172,5 +174,32 @@ var myPlacesList = myPlaces.find('> ul'); myPlacesList.toggleClass('show-my-places'); - }

      + },
      +
      + toggleEmptyPlacesFilter: function(show) {
      +
      + if (show == undefined) show = this._emptyFilterOn;
      + if (show ) {
      + jQuery(".my-places-toggle").each(function(idx)

      { + var li = jQuery(this).parent(); + li.show(); + li.find('.public,.private').show(); + + }

      );
      + this._emptyFilterOn=false;
      + } else {
      + jQuery(".my-places-toggle").each(function(idx){
      + var li = jQuery(this).parent();
      + var empty = li.find(".page-count:contains('(0)')");
      + if (empty.length==2)

      { + li.hide(); + }


      + empty.parents('.public,.private').hide();
      +
      + });
      + this._emptyFilterOn=true;
      + }
      + },
      +
      + _emptyFilterOn:true
      };
      \ No newline at end of file

      Index: /work/projects/liferay/portal/trunk/portal-web/docroot/html/taglib/ui/my_places/page.jsp
      ===================================================================
      — /work/projects/liferay/portal/trunk/portal-web/docroot/html/taglib/ui/my_places/page.jsp (revision 8821)
      +++ /work/projects/liferay/portal/trunk/portal-web/docroot/html/taglib/ui/my_places/page.jsp (working copy)
      @@ -25,8 +25,11 @@
      <%@ include file="/html/taglib/ui/my_places/init.jsp" %>

      <c:if test="<%= themeDisplay.isSignedIn() %>">
      +
      <ul>
      -
      + <%//todo check for admin logic %>
      + <div class="my-places-filter" onclick="Liferay.Dock.toggleEmptyPlacesFilter();" style="cursor:hand">Filter icon</div>
      +
      <%
      PortletURL portletURL = new PortletURLImpl(request, PortletKeys.MY_PLACES, plid.longValue(), true);

        Attachments

          Activity

            People

            • Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              atul.ducati@gmail.com atul patel (Inactive)
              Participants of an Issue:
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:

                Packages

                Version Package