Hello,
It's a pretty hackish solution, but you can do it using CUSTOM HTML and play around with javascript. Of course you may have to update this code if you don't use the default theme or if confluence changes it's default layout.
<script>
AJS.toInit(function() {
if (AJS.params.formName === "createpageform" )
AJS.$.post(
AJS.params.baseUrl + '/pages/setcontentpermissions.action',
{viewPermissionsUsers:AJS.params.remoteUserKey, editPermissionsUsers:AJS.params.remoteUserKey, viewPermissionsGroups:"", editPermissionsGroups:"", contentId: AJS.params.contentId, atl_token:AJS.params.atlToken},
function() {}
);
});
</script>
Hi Dmitry,
i couldnt get this to work , i have added this in the HTML macro in a template, so whenever a page is created from template it should change the restrictions automatically , but somehow missing something. do we have to change the baseUrl ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The simple answer is no. There is no native way to do this. instead, you have to hack a nonscalable solution or pay over 2K ( for 100 users) for a plugin to accomplish something that from best security practice should be native design.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi all, I just tested a complete solution and it works as expected, so any new page is created with custom restriction, in my case only the author can see and edit.
The solution is possible thanks to an addon, "Comala Workflow"
https://marketplace.atlassian.com/apps/142/comala-workflows?hosting=server&tab=overview
Thanks to this addon is possible to create a simple workflow with just one state (I called PRIVATE) where is possible to create a trigger to add a restriction on page creation. Herebelow the advanced configuration to set at the workflow level
{workflow:name=Restrictions}
{description}
PRIVATE: only author can view and edit
{description}
{state:Private|colour=#FFAB00}
{state}
{trigger:pagecreated}
{add-restriction:type=view|user=@creator}
{trigger}
{workflow}
Thanks to @Bill Bailey who suggested this strategy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Other than creating your own plugin, you could use comalatech workflows to construct a workflow that triggers on page creation which can set editing and view restrictions. It could also be used to send an email to an admin. Of course, you could build a more complex workflow with it.
I have written some complex doc processes using this plugin, having it set page permissions at various states, depending upon a set of conditions. So entirely doable.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
By default all new pages are unrestricted, but take on the restrictions of their parent page and the permissions of the space.
There is no way to set restrictions when either the Create or create from template buttons are used. You can use an add-on to create pages with a specific restriction, but the the user will have to click a button or link that the add-on generates.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You need to make sure users are added into groups that do not allow them to have such access.
Users might not have permission individually but might be a member of a specific group that has permissions to create pages.
Also when creating a space on confluence, Take a look in Browse > Space Admin > Permissions and make sure when creating the space, only the person who created it can only have full admin rights
Cheers,
Jason
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.