Fórumok

Create URL to Asset Publisher with category id

Gwowen Fu, módosítva 11 év-val korábban

Create URL to Asset Publisher with category id

Expert Bejegyzések: 315 Csatlakozás dátuma: 2010.12.27. Legújabb bejegyzések
Hi,
In web content, I want to have a URL link that will open asset publisher in current page or different page that shows documents tagged by category ID passed from the URL link.

The Java code I found for this is something like this:

PortletURL portletURL = PortletURLFactoryUtil.create(request, PortletKeys.ASSET_PUBLISHER, plid, PortletRequest.RENDER_PHASE);
portletURL.setPortletMode(PortletMode.VIEW);
portletURL.setWindowState(WindowState.NORMAL);
portletURL.setParameter("struts_action", "/asset_publisher/view_content");
portletURL.setParameter("type", assetRendererFactory.getType());
portletURL.setParameter("urlTitle", assetRenderer.getUrlTitle());


How do I set the category ID for asset publish through PortletURL?

Thanks for any help!
Gwowen
thumbnail
Pablo Rendón, módosítva 11 év-val korábban

RE: Create URL to Asset Publisher with category id

New Member Bejegyzések: 8 Csatlakozás dátuma: 2011.12.29. Legújabb bejegyzések
You can find an example of how to filter the asset publisher by category or tag dynamically and the creation of the URL in a hook here:

http://www.rotterdam-cs.com/blogs/-/blogs/how-to-filter-the-asset-publisher-by-category-dynamicall-1?_33_redirect=http%3A%2F%2Fwww.rotterdam-cs.com%2Fblogs%3Fp_p_id%3D33%26p_p_lifecycle%3D0%26p_p_state%3Dnormal%26p_p_mode%3Dview%26p_p_col_id%3D_118_INSTANCE_HwrUZetgi0eN__column-1%26p_p_col_count%3D1

however you can apply the same concept in a portlet or in a theme...
I hope this helps....