mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX: Fixed Permission::get_members_by_permission() for DB abstractions (from r97653)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102523 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
2ff50a6fe9
commit
fdce2dfc22
@ -451,12 +451,12 @@ class Permission extends DataObject {
|
||||
|
||||
// Via Roles are groups that have the permission via a role
|
||||
return DataObject::get('Group',
|
||||
"PermissionRoleCode.`Code` IN ('$SQL_codes') OR Permission.`Code` IN ('$SQL_codes')",
|
||||
"\"PermissionRoleCode\".\"Code\" IN ('$SQL_codes') OR \"Permission\".\"Code\" IN ('$SQL_codes')",
|
||||
"",
|
||||
"LEFT JOIN Permission ON Permission.GroupID = `Group`.ID
|
||||
LEFT JOIN Group_Roles ON Group_Roles.GroupID = `Group`.ID
|
||||
LEFT JOIN PermissionRole ON Group_Roles.PermissionRoleID = PermissionRole.ID
|
||||
LEFT JOIN PermissionRoleCode ON PermissionRoleCode.RoleID = PermissionRole.ID");
|
||||
"LEFT JOIN \"Permission\" ON \"Permission\".\"GroupID\" = \"Group\".\"ID\"
|
||||
LEFT JOIN \"Group_Roles\" ON \"Group_Roles\".\"GroupID\" = \"Group\".\"ID\"
|
||||
LEFT JOIN \"PermissionRole\" ON \"Group_Roles\".\"PermissionRoleID\" = \"PermissionRole\".\"ID\"
|
||||
LEFT JOIN \"PermissionRoleCode\" ON \"PermissionRoleCode\".\"RoleID\" = \"PermissionRole\".\"ID\"");
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user