Create permission not working correctly -- only works with Create Anywhere?

Joe Krill asked on December 5, 2014 20:23

I'm trying to setup permissioning to allow users to create events under a specific page. So I have a Calendar page, for which the user has "Create" permission checked in the Security tab. In the Permissions application, the user has "Create" permission for the Event page type. However, when I try to create a page with that user, I get the error:

The current page cannot contain any child pages. Either its page type has no allowed child types or the page type scope applied to this page has no allowed page types. 

However, if I give that user "Create Anywhere" permission for the Event page type, it works, and allows the user to create a document here. This is contrary to the documentation for the "Create" permission which says:

Allows members of the role to create documents of this type. With this permission, users must also have the Create document-level permission on the parent document under which they want the new document to be created.

Is this a bug? Or am I missing something herE?

Recent Answers


Brenden Kehren answered on December 5, 2014 21:08

Your first error is because the doc type you're creating in the content tree doesn't have permissions to be placed below the parent doc type. You can find this the doc type (page type) under the Allowed Types tab.

0 votesVote for this answer Mark as a Correct answer

Joe Krill answered on December 5, 2014 21:17

The doc type is definitely allowed under that parent doc type. As I said, it works fine when the "Create Anywhere" permission is given to the user, so the issue isn't with the page type itself not being allowed.

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on December 6, 2014 11:37

Hi Joe,

In this case, what are the user permissions? Is the user allowed to create pages in given section of the site? More details about the entire security setup would be much appreciated.

Best regards, Juraj Ondrus

0 votesVote for this answer Mark as a Correct answer

Joe Krill answered on December 8, 2014 13:18

Hi Juraj,

Here's my setup:

From the User application: the user has a Privilege level of "Editor", and is in the role "Role A".

From the Permissions application: My site is selected in the first dropdown; "Page Type" is selected, and "Event (booking system)" is selected. "Role A" has "Create" permissions checked.

From the Pages application: Using the Security tab of my "Calendar" page, "Role A" has "Create" permissions (I've also tried giving the user Create permissions directly, with the same result).

Now, when the user tries to add an Event (booking system) under the Calendar page, it fails with the error I posted earlier ("The current page cannot contain any child pages..."). However, if I go to the Permissions application and give "Role A" the "Create Anywhere" permission, the user is then able to add an event under the Calendar. The problem is, I don't want them to have Create Anywhere permissions -- I want them limited to just creating events under my "Calendar" page.

Let me know if there's more specific information I can give.

Thanks,

Joe

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on December 9, 2014 10:17

Hi,

Thank you for the details. I am using Kentico 8.1.15 and I have this setup:

User has editor privilege level. User is in role A (in my case the default CMSEditors role) Permissions: Module -> Content: This role has NO create permission Page Type -> Event booking system: This role has Create permission allowed.

Content tree: I have set the page level permissions on the root - added the role and denied permissions to create, modify, etc. Just the read and browse tree are allowed. I have created a test document. I have broken the parent level permissions and set the role to have create permission.

Now, I am logged in as this editor user and I am able to create the page of given type only under this test document.

Could you please make sure that the Event booking system page type is allowed to be created under given page's type?

Best regards,
Juraj Ondrus

0 votesVote for this answer Mark as a Correct answer

Joe Krill answered on December 9, 2014 16:41

OK, thanks -- when I followed what you've done this seems to be working correctly now.

The problem may have been that I never broke the parent permissions. However, I never put any explicit "Deny" permissions on the parent or root, either.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.