aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/actions
diff options
context:
space:
mode:
authormarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-04-24 12:51:26 +0000
committermarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-04-24 12:51:26 +0000
commita489cdae5b58ac27858e03921441a4f6e150a6d6 (patch)
tree8eb1d365169250aaf80c694553f288c55cd2f3a3 /mod/groups/actions
parentf64a66a816e3bedfb37b29ac3946e83f8c0aa087 (diff)
downloadelgg-a489cdae5b58ac27858e03921441a4f6e150a6d6.tar.gz
elgg-a489cdae5b58ac27858e03921441a4f6e150a6d6.tar.bz2
Closes #969: Admin option to allow the setting of certain access controls on a group
git-svn-id: https://code.elgg.org/elgg/trunk@3234 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/groups/actions')
-rw-r--r--mod/groups/actions/edit.php14
1 files changed, 12 insertions, 2 deletions
diff --git a/mod/groups/actions/edit.php b/mod/groups/actions/edit.php
index f32af9eb3..be8d250da 100644
--- a/mod/groups/actions/edit.php
+++ b/mod/groups/actions/edit.php
@@ -61,8 +61,18 @@
default: $group->membership = ACCESS_PRIVATE;
}
- // Set access - all groups are public from elgg's point of view.
- $group->access_id = 2;
+ // Set access - all groups are public from elgg's point of view, unless the override is in place
+
+ if (get_plugin_setting('hidden_groups', 'groups') == 'yes')
+ {
+ $visibility = (int)get_input('vis','',false);
+
+ $group->access_id = $visibility;
+
+ $group->access_id;
+ }
+ else
+ $group->access_id = 2;
// Set group tool options
//$group->files_enable = get_input('files_enable', 'yes');