From f088acf5e39019c8ceb3f43a60d5b853fd97ce50 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Tue, 23 Feb 2010 04:57:37 +0000 Subject: [PATCH] BUGFIX Fixed MemberTableField limiting of , wasnt taking children groups into account (regression from r99684) (from r99706) git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/branches/2.4@99713 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- code/MemberTableField.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/MemberTableField.php b/code/MemberTableField.php index d6090c3f..3873f8b8 100755 --- a/code/MemberTableField.php +++ b/code/MemberTableField.php @@ -103,7 +103,10 @@ class MemberTableField extends ComplexTableField { } if($this->group) { - $this->sourceFilter[] = sprintf('"Group_Members"."GroupID" = %d', $this->group->ID); + $this->sourceFilter[] = sprintf( + '"Group_Members"."GroupID" IN (%s)', + implode(',', array_merge($this->group->AllChildren()->column('ID'), array($this->group->ID))) + ); } $this->sourceJoin = " INNER JOIN \"Group_Members\" ON \"MemberID\"=\"Member\".\"ID\"";