From 945da1afe0b3315a289f9694311ff878b5a65a7b Mon Sep 17 00:00:00 2001 From: marcus Date: Fri, 13 Feb 2009 14:03:40 +0000 Subject: Closes #761, #718: Group permissions now made much much simpler. git-svn-id: https://code.elgg.org/elgg/trunk@2744 36083f99-b078-4883-b0ff-0f9b5a30f544 --- mod/groups/actions/edit.php | 10 ++++------ mod/groups/languages/en.php | 8 +++++++- mod/groups/views/default/forms/groups/edit.php | 9 ++------- 3 files changed, 13 insertions(+), 14 deletions(-) (limited to 'mod/groups') diff --git a/mod/groups/actions/edit.php b/mod/groups/actions/edit.php index e30fc7fee..6b66ab9f1 100644 --- a/mod/groups/actions/edit.php +++ b/mod/groups/actions/edit.php @@ -57,14 +57,12 @@ // Group membership - should these be treated with same constants as access permissions? switch (get_input('membership')) { - case 0: $group->membership = ACCESS_PRIVATE; - case 1 :$group->membership = ACCESS_LOGGED_IN; break; - case 2: - default: $group->membership = ACCESS_PUBLIC; + case 2: $group->membership = ACCESS_PUBLIC; break; + default: $group->membership = ACCESS_PRIVATE; } - // Get access - $group->access_id = get_input('access_id', ACCESS_PRIVATE); + // Set access - all groups are public from elgg's point of view. + $group->access_id = 2; // Set group tool options $group->files_enable = get_input('files_enable', 'yes'); diff --git a/mod/groups/languages/en.php b/mod/groups/languages/en.php index 5f216a9b8..3b678b16a 100644 --- a/mod/groups/languages/en.php +++ b/mod/groups/languages/en.php @@ -32,7 +32,7 @@ 'groups:interests' => 'Interests', 'groups:website' => 'Website', 'groups:members' => 'Group members', - 'groups:membership' => "Membership", + 'groups:membership' => "Group membership permissions", 'groups:access' => "Access permissions", 'groups:owner' => "Owner", 'groups:widget:num_display' => 'Number of groups to display', @@ -58,6 +58,12 @@ 'groupforumtopic:new' => "New forum post", + /* + * Access + */ + 'groups:access:private' => 'Closed - Users must be invited', + 'groups:access:public' => 'Open - Any user may join', + /* Group tools */ diff --git a/mod/groups/views/default/forms/groups/edit.php b/mod/groups/views/default/forms/groups/edit.php index 2841c9dfe..5a0976cc7 100644 --- a/mod/groups/views/default/forms/groups/edit.php +++ b/mod/groups/views/default/forms/groups/edit.php @@ -49,16 +49,11 @@

-

- -

+