Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Liferay 6.1: How to customize which portlets to show in "Add more portlets" Prakash Khanchandani May 23, 2012 3:43 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Bart Simpson May 19, 2012 6:55 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Prakash Khanchandani June 5, 2012 8:07 PM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Chintan Akhani June 5, 2012 11:38 PM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Bart Simpson June 21, 2012 6:56 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Dhrutika Vyas June 6, 2012 12:00 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Chintan Akhani June 6, 2012 12:08 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Prakash Khanchandani June 7, 2012 12:42 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Chintan Akhani June 8, 2012 2:26 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Chintan Akhani June 8, 2012 2:50 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Prakash Khanchandani June 21, 2012 10:45 PM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Daniel Kiyotomo Ozeki September 21, 2012 10:48 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Prakash Khanchandani September 24, 2012 6:41 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Nagendra Kumar Busam August 15, 2014 9:53 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl David H Nebinger August 15, 2014 10:24 AM
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl Nagendra Kumar Busam August 15, 2014 11:38 AM
Prakash Khanchandani
Liferay 6.1: How to customize which portlets to show in "Add more portlets"
May 23, 2012 3:43 AM
Answer

Prakash Khanchandani

Rank: Expert

Posts: 329

Join Date: February 10, 2011

Recent Posts

I need to customize as to which portlets appear in the "Add more portlet menu" as shown in the image below.

I need to restrict the number of portlets displayed in this menu based on the logged-in user or site community. So that Community owner or admin will be able to add only those portlets to their pages which the omni-admin decides for them.

Does Liferay provide any such functionality (through configuration or something) or do I have to create a new portlet and a hook to achieve this?

Any idea would be very much appreciated.

Thank You
Attachment

Attachments: add-more-menu.png (38.3k)
Bart Simpson
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
May 19, 2012 6:55 AM
Answer

Bart Simpson

Rank: Liferay Master

Posts: 524

Join Date: August 29, 2011

Recent Posts

You should be able to achieve this by defining permissions in control panel.
Create / edit a specific role then define permissions for that role. There should be an action for Add to page on these specific portlets.
Prakash Khanchandani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 5, 2012 8:07 PM
Answer

Prakash Khanchandani

Rank: Expert

Posts: 329

Join Date: February 10, 2011

Recent Posts

I am not able to achieve this through the ADD_TO_PAGE permissions you mentioned, I guess this is because of this issue
Chintan Akhani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 5, 2012 11:38 PM
Answer

Chintan Akhani

Rank: Regular Member

Posts: 111

Join Date: March 13, 2008

Recent Posts

Hi Prakash,

By changing the category type you can achieve this, for this change you need to modify liferay-display.xml file, if you want to do it for liferay existing portlet than you can achieve it through ext plugin.

Change the category name to "category.hidden". In this case only omniAdmin (portal admin) will be able to access these portlets in control panel.

Hope this helps.
Thanks,
Chintan
Dhrutika Vyas
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 6, 2012 12:00 AM
Answer

Dhrutika Vyas

Rank: Expert

Posts: 438

Join Date: February 9, 2009

Recent Posts

Hi Pratap,

Portlets other than defined in below property and which is not having category as hidden will come under 'add more' menu.
dockbar.add.portlets=56,101,110,71

To have site based add application menu,you need to do code customization in layout_configuration > view_category.jsp

Regards,
Dhrutika
Chintan Akhani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 6, 2012 12:08 AM
Answer

Chintan Akhani

Rank: Regular Member

Posts: 111

Join Date: March 13, 2008

Recent Posts

I believe dockbar.add.portlets contains list of portlet ids which will be displayed directly in Add Application option (not under Add More option)
Prakash Khanchandani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 7, 2012 12:42 AM
Answer

Prakash Khanchandani

Rank: Expert

Posts: 329

Join Date: February 10, 2011

Recent Posts

Thanks Dhrutika and Chintan.

But the suggestions does not help with customizing the Add Menu.

And yes Chintan you are absolutely right about the property: dockbar.add.portlets
Chintan Akhani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 8, 2012 2:26 AM
Answer

Chintan Akhani

Rank: Regular Member

Posts: 111

Join Date: March 13, 2008

Recent Posts

Hi Prakash,

You can achieve this by modifying view.jsp of "dockbar" portlet, and as it's an out of the box portlet, you have to create a hook. Please let me know if it works.
Chintan Akhani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 8, 2012 2:50 AM
Answer

Chintan Akhani

Rank: Regular Member

Posts: 111

Join Date: March 13, 2008

Recent Posts

Hi Prakash,

if you want to change list of portlets which are displayed along with More option than you need to modify dockbar portlet's view.jsp.

But if you want to manage portlets which are displayed in a "more applications" popup, based on permission than "layout_configuration" portlet's view.jsp needs to be modifed so in this case you need to create a hook for layout_configuration.
Bart Simpson
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 21, 2012 6:56 AM
Answer

Bart Simpson

Rank: Liferay Master

Posts: 524

Join Date: August 29, 2011

Recent Posts

Prakash ,
It's been a while since I accessed the form, from the issue you indicated I see http://issues.liferay.com/browse/LPS-24695?focusedCommentId=167067&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-167067

may be you can give it a try as commented.
Prakash Khanchandani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
June 21, 2012 10:45 PM
Answer

Prakash Khanchandani

Rank: Expert

Posts: 329

Join Date: February 10, 2011

Recent Posts

Thanks, will try to work on this.
Daniel Kiyotomo Ozeki
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
September 21, 2012 10:48 AM
Answer

Daniel Kiyotomo Ozeki

LIFERAY STAFF

Rank: New Member

Posts: 15

Join Date: March 1, 2012

Recent Posts

hi Prakash,

I don't know if you have solved this issue but you can limit what portlets can be added to the page from the administration side and not have to do it through development. You will need to create a role however and add everyone on it. Here were my steps in achieving this:

1) Have the user be part of the organization or site that you want them to add portlets to.
2) Go to "Roles" in control panel and make a regular role (not organization or site role)
2) In define permissions drop down menu go to Portal -> Site -> Page -> and check Update as a defined permission
3) Go to define permissions drop down menu again and go to Site Application ->(Portlet Name that you want your user to only add) -> Add to page
4) Repeat Step 3if necessary if there are other portlets you want them to add
5) Add this role to your user: Go to User and Organizations. Click on your User and go to "Roles"
6)Finally you need to go to Server Administration and execute the "Clean Up Permissions" as indicated in the ticket you posted.

This should now make it so that whatever user is attached to this role they will see an "Add" button on the left hand corner and will only be able to add portlets you specify in the role permissions.

Let me know if that helps
Prakash Khanchandani
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
September 24, 2012 6:41 AM
Answer

Prakash Khanchandani

Rank: Expert

Posts: 329

Join Date: February 10, 2011

Recent Posts

Thanks Daniel Kiyotomo Ozeki for your answer, will check and let you know. I have also posted your answer here.

Thanks, it worked.
Nagendra Kumar Busam
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
August 15, 2014 9:53 AM
Answer

Nagendra Kumar Busam

Rank: Liferay Master

Posts: 653

Join Date: July 7, 2009

Recent Posts

I have similar requirement (not exactly same though) - I was able to configure portlets for my custom role as per steps mentioned able, I am seeing portlets perfectly fine if I login with user having that role.

I don't want user with my custom role to see Edit Page in 6.2 (themes, layouts & other sections under ). Can somebody point out whether this can be done with permissions

Mapping to Edit Page in 6.2 to 6.1 is Manage (my custom role in 6.1 seeing Page, Page Layout,Page Customizations) at dock bar level.

Any pointers are much welcome
David H Nebinger
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
August 15, 2014 10:24 AM
Answer

David H Nebinger

Community Moderator

Rank: Liferay Legend

Posts: 11511

Join Date: September 1, 2006

Recent Posts

Please don't revive a dead thread, post a new one instead.
Nagendra Kumar Busam
RE: Liferay 6.1: How to customize which portlets to show in "Add more portl
August 15, 2014 11:38 AM
Answer

Nagendra Kumar Busam

Rank: Liferay Master

Posts: 653

Join Date: July 7, 2009

Recent Posts

sorry about that, I posted in a new thread

https://www.liferay.com/community/forums/-/message_boards/message/41476214