erge remote-tracking branch 'mike/master' into dev

This commit is contained in:
Mario Vavti 2018-02-28 13:02:22 +01:00
commit 029d155a07
4 changed files with 58 additions and 28 deletions

View File

@ -61,7 +61,8 @@ class Featured {
$tpl = get_markup_template("settings_addons.tpl"); $tpl = get_markup_template("settings_addons.tpl");
$o .= replace_macros($tpl, array( $o .= replace_macros($tpl, array(
'$form_security_token' => get_form_security_token("settings_featured"), '$form_security_token' => get_form_security_token("settings_featured"),
'$title' => t('Feature/Addon Settings'), '$title' => t('Addon Settings'),
'$descrip' => t('Please save/submit changes to any panel before opening another.'),
'$settings_addons' => $settings_addons '$settings_addons' => $settings_addons
)); ));
return $o; return $o;

View File

@ -54,7 +54,7 @@ class Settings_menu {
} }
$tabs[] = array( $tabs[] = array(
'label' => t('Feature/Addon settings'), 'label' => t('Addon settings'),
'url' => z_root().'/settings/featured', 'url' => z_root().'/settings/featured',
'selected' => ((argv(1) === 'featured') ? 'active' : ''), 'selected' => ((argv(1) === 'featured') ? 'active' : ''),
); );
@ -79,7 +79,7 @@ class Settings_menu {
'selected' => '' 'selected' => ''
); );
if(get_account_techlevel() > 0) { if(feature_enabled(local_channel(),'oauth_clients')) {
$tabs[] = array( $tabs[] = array(
'label' => t('Connected apps'), 'label' => t('Connected apps'),
'url' => z_root() . '/settings/oauth', 'url' => z_root() . '/settings/oauth',
@ -87,7 +87,7 @@ class Settings_menu {
); );
} }
if(get_account_techlevel() > 2) { if(feature_enabled(local_channel(),'access_tokens')) {
$tabs[] = array( $tabs[] = array(
'label' => t('Guest Access Tokens'), 'label' => t('Guest Access Tokens'),
'url' => z_root() . '/settings/tokens', 'url' => z_root() . '/settings/tokens',

View File

@ -54,14 +54,6 @@ function get_features($filtered = true) {
t('General Features'), t('General Features'),
[
'multi_profiles',
t('Multiple Profiles'),
t('Ability to create multiple profiles'),
false,
get_config('feature_lock','multi_profiles'),
feature_level('multi_profiles',3),
],
[ [
'advanced_profiles', 'advanced_profiles',
@ -163,14 +155,6 @@ function get_features($filtered = true) {
feature_level('ajaxchat',1), feature_level('ajaxchat',1),
], ],
[
'permcats',
t('Permission Groups'),
t('Provide alternate connection permission roles.'),
false,
get_config('feature_lock','permcats'),
feature_level('permcats',2),
],
[ [
'smart_birthdays', 'smart_birthdays',
@ -219,6 +203,58 @@ function get_features($filtered = true) {
], ],
], ],
'access_control' => [
t('Access Control and Permissions'),
[
'groups',
t('Privacy Groups'),
t('Enable management and selection of privacy groups'),
true,
get_config('feature_lock','groups'),
feature_level('groups',0),
],
[
'multi_profiles',
t('Multiple Profiles'),
t('Ability to create multiple profiles'),
false,
get_config('feature_lock','multi_profiles'),
feature_level('multi_profiles',3),
],
[
'permcats',
t('Permission Groups'),
t('Provide alternate connection permission roles.'),
false,
get_config('feature_lock','permcats'),
feature_level('permcats',2),
],
[
'oauth_clients',
t('OAuth Clients'),
t('Manage authenticatication tokens for mobile and remote apps.'),
false,
get_config('feature_lock','oauth_clients'),
feature_level('oauth_clients',1),
],
[
'access_tokens',
t('Access Tokens'),
t('Create access tokens so that non-members can access private content.'),
false,
get_config('feature_lock','access_tokens'),
feature_level('access_tokens',2),
],
],
// Post composition // Post composition
'composition' => [ 'composition' => [
@ -312,14 +348,6 @@ function get_features($filtered = true) {
feature_level('archives',1), feature_level('archives',1),
], ],
[
'groups',
t('Privacy Groups'),
t('Enable management and selection of privacy groups'),
true,
get_config('feature_lock','groups'),
feature_level('groups',0),
],
[ [
'savedsearch', 'savedsearch',

View File

@ -1,5 +1,6 @@
<div class="generic-content-wrapper"> <div class="generic-content-wrapper">
<div class="section-title-wrapper"> <div class="section-title-wrapper">
<div class="descriptive-text pull-right">{{$descrip}}</div>
<h2>{{$title}}</h2> <h2>{{$title}}</h2>
</div> </div>
<form action="settings/featured" method="post" autocomplete="off"> <form action="settings/featured" method="post" autocomplete="off">