aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-11-24 14:55:39 -0800
committerzotlabs <mike@macgirvin.com>2017-11-24 14:55:39 -0800
commitfda5231a719025c0e2d7cc3954ebbab5b0d53586 (patch)
tree010ad3c43aaa5e5637e6ead7abbad681da32eca2 /Zotlabs/Module
parent874cff1a873c306f4174b4910b02de5795a037ca (diff)
downloadvolse-hubzilla-fda5231a719025c0e2d7cc3954ebbab5b0d53586.tar.gz
volse-hubzilla-fda5231a719025c0e2d7cc3954ebbab5b0d53586.tar.bz2
volse-hubzilla-fda5231a719025c0e2d7cc3954ebbab5b0d53586.zip
default profile assign
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Settings/Channel.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/Zotlabs/Module/Settings/Channel.php b/Zotlabs/Module/Settings/Channel.php
index 63370a141..db0f79060 100644
--- a/Zotlabs/Module/Settings/Channel.php
+++ b/Zotlabs/Module/Settings/Channel.php
@@ -2,6 +2,8 @@
namespace Zotlabs\Module\Settings;
+require_once('include/selectors.php');
+
class Channel {
@@ -148,7 +150,8 @@ class Channel {
$defpermcat = ((x($_POST,'defpermcat')) ? notags(trim($_POST['defpermcat'])) : 'default');
$cal_first_day = (((x($_POST,'first_day')) && (intval($_POST['first_day']) == 1)) ? 1: 0);
- $mailhost = ((array_key_exists('mailhost',$_POST)) ? notags(trim($_POST['mailhost'])) : '');
+ $mailhost = ((array_key_exists('mailhost',$_POST)) ? notags(trim($_POST['mailhost'])) : '');
+ $profile_assign = ((x($_POST,'profile_assign')) ? notags(trim($_POST['profile_assign'])) : '');
$pageflags = $channel['channel_pageflags'];
@@ -242,6 +245,7 @@ class Channel {
set_pconfig(local_channel(),'system','cal_first_day',$cal_first_day);
set_pconfig(local_channel(),'system','default_permcat',$defpermcat);
set_pconfig(local_channel(),'system','email_notify_host',$mailhost);
+ set_pconfig(local_channel(),'system','profile_assign',$profile_assign);
$r = q("update channel set channel_name = '%s', channel_pageflags = %d, channel_timezone = '%s', channel_location = '%s', channel_notifyflags = %d, channel_max_anon_mail = %d, channel_max_friend_req = %d, channel_expire_days = %d $set_perms where channel_id = %d",
dbesc($username),
@@ -515,6 +519,9 @@ class Channel {
'$permissions' => t('Default Privacy Group'),
'$permdesc' => t("\x28click to open/close\x29"),
'$aclselect' => populate_acl($perm_defaults, false, \Zotlabs\Lib\PermissionDescription::fromDescription(t('Use my default audience setting for the type of object published'))),
+ '$profseltxt' => t('Profile to assign new connections'),
+ '$profselect' => ((feature_enabled(local_channel(),'multi_profiles')) ? contact_profile_assign(get_pconfig(local_channel(),'system','profile_assign','')) : ''),
+
'$allow_cid' => acl2json($perm_defaults['allow_cid']),
'$allow_gid' => acl2json($perm_defaults['allow_gid']),
'$deny_cid' => acl2json($perm_defaults['deny_cid']),