Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
chandrajeet padhy
default landing page
October 19, 2011 2:04 PM
Answer

chandrajeet padhy

Rank: New Member

Posts: 5

Join Date: January 5, 2011

Recent Posts

Hi,

I have two organizations created and each having an user role with few users under each organization.

I want when a user of a specific organization logs in, he should see the organization's public page
and similarly a user belonging to the other organization should see that organization's public page on landing after login.

How do I?

Thanks
Sandeep Nair
RE: default landing page
October 19, 2011 10:56 PM
Answer

Sandeep Nair

Rank: Liferay Legend

Posts: 1721

Join Date: November 5, 2008

Recent Posts

Try creating a login post hook. Someone has already created hook, you can see if it suits your need.

http://www.liferay.com/downloads/liferay-portal/community-plugins/-/software_catalog/products/6837361?_98_redirect=%2Fdownloads%2Fliferay-portal%2Fcommunity-plugins

If not you can customize the above

Regards,
Sandeep
Sagar A Vyas
RE: default landing page
October 20, 2011 12:22 AM
Answer

Sagar A Vyas

Rank: Liferay Master

Posts: 657

Join Date: April 17, 2009

Recent Posts

Hi Sandeep,

Here, I am bit confuse.

As per my knowledge we can do it by setting up role and permission - Correct me if I am wrong.

I have seen in other post also which recommend hook here,

Is there any special benefit with hook or only this solution is available ?

Thanks,
Sagar Vyas
Arvind Mishra
RE: default landing page
October 20, 2011 6:50 AM
Answer

Arvind Mishra

Rank: Regular Member

Posts: 226

Join Date: February 13, 2008

Recent Posts

Hi Sagar

What he is looking for is to redirect user to different Organization landing pages, based on user's access to that particular organization. You cant do it using roles/permissions etc.
Thumb rule is , whenever you have to redirect users to different login pages based on certain logic, you have to extend LandingPageAction.

Thanks
Arvind
Nisarg Parikh
RE: default landing page
October 20, 2011 6:57 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Hi,

You can see below action class.

/com/liferay/portlet/login/action/LoginAction.java

in that file there is a code for redirecting user to specific page. once successfully login you can get User information from session and then
check the organization and redirect accordingly.

Hope that might help you.

-Nisarg
Sagar A Vyas
RE: default landing page
October 20, 2011 11:49 PM
Answer

Sagar A Vyas

Rank: Liferay Master

Posts: 657

Join Date: April 17, 2009

Recent Posts

Arvind Mishra:
Hi Sagar

What he is looking for is to redirect user to different Organization landing pages, based on user's access to that particular organization. You cant do it using roles/permissions etc.
Thumb rule is , whenever you have to redirect users to different login pages based on certain logic, you have to extend LandingPageAction.

Thanks
Arvind


Thank you Arvind for elaborating this.

It helps emoticon

Thanks,
Sagar Vyas