mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Rescoping where allroles is created in post
This commit is contained in:
@@ -119,9 +119,6 @@ namespace Orchard.ContentPermissions.Drivers {
|
||||
}
|
||||
|
||||
protected override DriverResult Editor(ContentPermissionsPart part, IUpdateModel updater, dynamic shapeHelper) {
|
||||
|
||||
var allRoles = _roleService.GetRoles().Select(x => x.Name).OrderBy(x => x).ToList();
|
||||
|
||||
var model = new ContentPermissionsPartViewModel();
|
||||
|
||||
if (!updater.TryUpdateModel(model, Prefix, null, null)) {
|
||||
@@ -142,6 +139,8 @@ namespace Orchard.ContentPermissions.Drivers {
|
||||
|
||||
var settings = part.Settings.TryGetModel<ContentPermissionsPartSettings>();
|
||||
|
||||
var allRoles = _roleService.GetRoles().Select(x => x.Name).OrderBy(x => x).ToList();
|
||||
|
||||
OverrideDefaultPermissions(part, allRoles, settings);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user