Liferay DXP 7.2: Add Permissions/Roles Of Viewing Different Pages To An Organization - liferay

I have a single site in Liferay DXP 7.2, and I would like to know what is the best way to add permissions/roles of viewing different pages to an organization.
Requirements:
This site will be owned/shared by 2 organizations.
Each organization has a number of site roles.
Each site role consists of permissions for viewing different sets of pages. For example, Role 1 can view page A and page B, whereas Role 2 can view page C and page D.
Desired Outcome:
Roles:
Role 1: view public page only.
Role 2: view public and admin pages only.
Role 3: view private page only.
Organizations:
Organization 1 has Role 1 and Role 2, which can be assigned to members within Organization 1.
Organization 2 has Role 1 and Role 3, which can be assigned to members within Organization 2.
Encountered Problems:
Permissions of viewing different pages are categorized as site roles. Site roles can only be applied to a particular site, and cannot be assigned to an organization.
Organizations are required to simplify user management within the site.
I prefer not to separate it into 2 different sites.
What is the best way to achieve the desired outcome? Also, do correct me if I made wrong assumptions about how roles work in Liferay. Thank you.

Related

Restrict Sharepoint List Items

I have a web part on my home page for SharePoint announcements. On my announcements I have a public / private option.
I want my web part to show private options to users who are a member of a certain permission group.
how would I do this?
You would have to do two web parts on the same page and set the audience targeting on the web part to cover the two groups. The user should only see the web part if they're a member of whichever group. As an example (with made up group names) a web part might target members of 'Managers' the other would target 'Employees'. Each would only see one web part.
If the two groups aren't separate presently, you'd have to go through Central Admin to create any missing audiences that include or exclude users as necessary.

Liferay Page Administrator

I need that each page is administered by one person or group of persons.
Do I need to create one role each for every page I have to administer(Page1 administrator, page 2 administrator) or can I just create one generic role named "Page Administrator" and have some thing like a user having Page Administrator role can manage only page1 and similarly another user having the same "Page Administrator" can only manage "page2"? This is to avoid creating as many roles as there are pages in the system.
it depends... The easiest and most maintainable way to assign permissions in Liferay is through roles per site. If you have 1 page per site, you're good to go with a site role. You can build the navigation from many different sites, an example is this POC app by yours truly.
If you create roles (or teams) per page, be aware that page management is a different beast than content management: All of the pages of one site share the same content. Thus it might be hard to solve, if you also want the page administrators to maintain the content.

How can I decouple a group from the related organization

I have an organization in which I created a site. So the site belongs to the organization, as stated in the Site Memberships page:
This site belongs to Jobyourself which is an organization of type booster-club. All users of Jobyourself are automatically members of the site and site roles are automatically assigned to them based on the organization roles they have in Jobyourself as shown in the table below.
I would now like to delete the organization, but keep the site. How can I decouple the group from the related organization (programmatically or through the control panel) ?
I am using liferay 6.1 GA3.
Best regards,
Alain
Alain, From Control Panel navigate to your Site which you want to decouple, From Action button click on Site Membership you should see Organization Tab where you can remove the organization linking.. Hope this helps.

Liferay 6.1 customizing role and permission for different user in document and media portlet

I am new to liferay. I have one issue. I have 3 sub organizations (org A, B and C) each has each individual users. For exampla UA1, UB2, UC3 respectively.
Now I want to customize the permission of document and media portlet in such a way that UA1 can upload/ download his documents. But another User in Org A for example UA4 cannot access UA1's document. In the meanwhile Users UB2 and UC3 can see user UA1's document or add new document for her.
Can I achieve this my creating roles and permission? I have tried many combinations but it's not working.
How can I achieve this. Please do let me know. thanks
Here we have 2 cases
1. User of same organization can't view the image added by other user of same org.It can be achieved by creating an custom resource-action say (SCOPE_INDIVIDUAL) and manage it permission.
2.User of other organization can view the content can me manage by creating one role and define permission to it .

Changing the default page based on security group in SharePoint

We have a SharePoint site collection. In this site collection we have a home site and 6 other sites. Each of these sites belongs to a department in our company. Right now if you are a member of department A security group you would see homepage and your department site/tab when you navigate to the site. What they want me to do is to redirect the users directly to the department site/tab whenever they navigate to the site.
Is there any way to do this without coding or with coding?
With coding, you could write a very simple web control and include that on the home page. It would test which group a user belongs to and then redirect accordingly.
There are various ways to check if a user belongs to a group. One method is to get a reference to each SPGroup object and use SPGroup.ContainsCurrentUser.
You might also like to consider creating a custom list that maps SPGroup name against department URL, so you can manage behaviour of the control through the SharePoint UI.

Resources