In my Liferay site, Power Users are getting permission for changing Configuration options like; Look and Feel, Configuration and Export/Import options. I don't know how this is coming. Guessing that some permissions issue. But couldn't fix it. I didn't make any changes in Power User role.
I just want to hide this Configuration option for Power user.
The portlet was added by that particular user. So that that configuration option is coming.. So if we don't want to give that permission, the portlet should be added by the admin.
Related
I have a demo page for a web part, so I want a permission level where user can modify web parts using tool part but cannot delete it so other users will also be able to see it. And I also don't want them to access site settings and contents.
I think best way is to create target audience rules and compile them. As the rules may either ON security group membership or user profile property values.
In order to learn more check the Overview section in the following link :
https://support.office.com/en-us/article/Target-content-to-specific-audiences-33d84cb6-14ed-4e53-a426-74c38ea32293
What is the code to configure these configurations from the coding site in liferay java? Without going through the settings in admin's panel?
To configure restrictions using code. At MAIN MENU- CONFIGURATION from the admin site. But how to configure each permission for owner, portal content reviewer, portal user and others for add to page, configuration, view and permissions using code either in controller or xml?
For example to restrict view, certain page, or others.
Thanks.
I have created a separate module for creating and assigning users for site admin/owners. So I don't want to show the "Site Membership" option under Users tab for both Site admin and owner.
How can I hide the Site Membership option?
Is there any way that the permission or configuration will do the
required change? Or do I need to create the hook?
Any suggestions please?
Rather than changing the semantics of Liferay's built-in roles, rather introduce your own custom roles and define the permissions that you want them to have. Create a "site role", choose "Define Permissions" and add what you need.
From your comment I understand that you want to use Site Admin, just not with everything this role comes with. It sounds strange to me that you're demanding a certain solution and favor one that doesn't work, but so be it.
You can check if it's possible to remove some permissions from the "Site Admin" role, but I'd expect a very hard-to-maintain-system resulting from this. Liferay has no means of "maintaining only the users that a certain Administrator has created". What you can do is: An Organization Administrator can administer all users in the organizations they're administering. This might be another solution for you.
Or alternatively, implement your own UI and do your custom (non-Liferay-based) permission checks in it. This UI will then enable your custom admins to administer the users that the UI provides for them.
But if you're stuck to a certain solution, you might be out of luck. Give us more details of your problem and we might come up with a solution unless you insist that your solution is the way to go.
With Permissions, no you can't. You can't change the permissions of the LR default role by UI at least.
You might have to go with hook or ext. One other way around is to do it with the theme. You might have to hook into Liferay's control panel theme.
I've created a Regular User Role in my Liferay Portal titled Announcement Poster - the purpose of this role is to give all normal, non-administrative users the ability to add only the Announcement and the Alert Liferay out-of-the-box portlets to a page, as well as modify and delete those portlets as needed.
According to this post pertaining to Liferay 6.1, this can be done very simply by defining a Role's permissions and I've seen other users have success with the method, however in Liferay 6.2 I cannot achieve this - With my current settings, the user can still see the Edit and Preview options as well as the Portlet Configuration option. I simply want only the Add option to be displayed to a user assigned to this role.
My defined role permissions are as follows:
So far I've tried many combinations of Site, Site Setting & Application permissions but can't achieve the desired outcome; has anyone had any luck with this or a similar situation?
Subsequent Liferay forum post https://www.liferay.com/community/forums/-/message_boards/message/43455741
I don't think it is a Liferay bug, simply those buttons are not under permission system. You can hide them via css, or better, you can hook the dockbar JSP and render them with your own conditions.
EDIT:
When I say "those buttons are not under permission system" i mean singly.
I am developing a sharepoint 2010 visual webpart that will show some sort of ajax content.
I have a property on the webpart for the refresh rate, but I want this property to be set only by an Administrator (or any specific group).
What is the best way to achieve this?
Thank you.
In our organization, everyone by default is granted "Read" permission to our SharePoint sites through an "All Employees" Active Directory group. This allows users to browse the pages, but not edit them; and if you can't edit a page, you can't edit any web parts on the page.
Those who should have elevated privileges are added to other AD groups (you could use SharePoint groups too), and those groups are granted appropriate permissions.
You could create a custom Toolpart. Take a look at this example for a tutorial on how to create one.
Overall, your general steps will be:
Create your custom Toolpart class inheriting from Microsoft.SharePoint.WebPartPages.ToolPart
In your custom Toolpart, override CreateChildControls, write the code to display your textbox as long as the current user has permission (based on whatever rules you choose, ex: SharePoint group).
In your webpart, override GetToolParts and add your custom ToolPart so that it shows up in the right hand side