in umbraco 7.12 the User section has had a little update and you no longer get tick boxes to allow you to choose which sections you want a user to have access to.
how would you go about giving a user permission to access a custom section in this new layout?
i also notice that UserService.AddSectionToAllUsers("sectionAlias") is no longer part of the API.
is there any documentation on custom sections in light of these new changes?
I am not sure if there is any documentation updates for this - but with the advent of the user groups, you add the section to the AllowedSections list on a group - the below will add a custom section to the admin group (post v7.7):
private void AddSectionSevenSeven(string alias)
{
var adminGroup = _userService.GetUserGroupByAlias("admin");
if (adminGroup != null)
{
if (!adminGroup.AllowedSections.Contains(alias))
{
adminGroup.AddAllowedSection(alias);
_userService.Save(adminGroup);
}
}
}
umbraco 7.12 adding user to custom section
in umbraco 7.12 the User section has had a little update and you no longer get tick boxes to allow you to choose which sections you want a user to have access to. how would you go about giving a user permission to access a custom section in this new layout?
i also notice that
UserService.AddSectionToAllUsers("sectionAlias")
is no longer part of the API.is there any documentation on custom sections in light of these new changes?
Thanks
Hi Simon,
I am not sure if there is any documentation updates for this - but with the advent of the user groups, you add the section to the
AllowedSections
list on a group - the below will add a custom section to the admin group (post v7.7):thanks so much Kevin, this is exactly what i was looking for
is working on a reply...