Version 4.7.0

This commit is contained in:
Neo committed 2025-12-19 16:00:35 -08:00
1 parent 517a5e1f70
commit 8ba7d43898
1933 files changed
+65613 -11332

No files matched your search

+134 -53
View File
@@ -173,11 +173,6 @@ class _Application extends \IPS\Application
\IPS\core\Achievements\Rule::importXml( $this->getApplicationPath() . "/data/achievements/rules.xml" );
\IPS\core\Achievements\Rank::importXml( $this->getApplicationPath() . "/data/achievements/ranks.xml" );
\IPS\core\Achievements\Badge::importXml( $this->getApplicationPath() . "/data/achievements/badges.xml" );
if ( \IPS\CIC2 )
{
\IPS\Cicloud\postInstall();
}
}
/**
@@ -199,7 +194,11 @@ class _Application extends \IPS\Application
or
(
$module->key == 'contact' and $controller == 'contact'
);
)
or
(
$module->key == 'discover' and \in_array( $controller, array( 'rss', 'streams' ) )
);
}
/**
@@ -375,7 +374,7 @@ class _Application extends \IPS\Application
$subprocessors = array();
/* Analytics */
if ( \IPS\Settings::i()->ipbseo_ga_provider == 'ga' )
if ( \IPS\Settings::i()->ga_enabled )
{
$subprocessors[] = array(
'title' => \IPS\Member::loggedIn()->language()->addToStack('enhancements__core_GoogleAnalytics'),
@@ -383,11 +382,11 @@ class _Application extends \IPS\Application
'privacyUrl' => 'https://www.google.com/intl/en/policies/privacy/'
);
}
else if ( \IPS\Settings::i()->ipbseo_ga_provider == 'piwik' )
if ( \IPS\Settings::i()->matomo_enabled )
{
$subprocessors[] = array(
'title' => \IPS\Member::loggedIn()->language()->addToStack('analytics_provider_piwik'),
'description' => \IPS\Member::loggedIn()->language()->addToStack('pp_desc_Piwik'),
'title' => \IPS\Member::loggedIn()->language()->addToStack('analytics_provider_matomo'),
'description' => \IPS\Member::loggedIn()->language()->addToStack('pp_desc_Matomo'),
'privacyUrl' => 'https://matomo.org/privacy-policy/'
);
}
@@ -450,6 +449,12 @@ class _Application extends \IPS\Application
'privacyUrl' => 'https://www.keycaptcha.com'
);
break;
case 'hcaptcha':
$subprocessors[] = array(
'title' => \IPS\Member::loggedIn()->language()->addToStack('captcha_type_hcaptcha'),
'description' => \IPS\Member::loggedIn()->language()->addToStack('hcaptcha_privacy'),
'privacyUrl' => 'https://www.hcaptcha.com/privacy'
);
}
}
@@ -489,49 +494,6 @@ class _Application extends \IPS\Application
return $return;
}
/**
* Return an array of specific links to add to the sitemap
*
* @return array
*/
public function sitemapLinks()
{
$return = array(
\IPS\Http\Url::internal( 'app=core&module=system&controller=cookies', 'front', 'cookies' ),
\IPS\Http\Url::internal( 'app=core&module=system&controller=terms', 'front', 'terms' ),
);
if( \IPS\Settings::i()->gl_type != 'none' )
{
$return[] = \IPS\Http\Url::internal( 'app=core&module=system&controller=guidelines', 'front', 'guidelines' );
}
if( \IPS\Settings::i()->privacy_type != 'none' )
{
$return[] = \IPS\Http\Url::internal( 'app=core&module=system&controller=privacy', 'front', 'privacy' );
}
$guest = new \IPS\Member;
if( $guest->canAccessModule( \IPS\Application\Module::get( 'core', 'staffdirectory', 'front' ) ) )
{
$return[] = \IPS\Http\Url::internal( 'app=core&module=staffdirectory&controller=directory', 'front', 'staffdirectory' );
}
if ( \IPS\Settings::i()->reputation_enabled and \IPS\Settings::i()->reputation_leaderboard_on )
{
$return[] = \IPS\Http\Url::internal( 'app=core&module=discover&controller=popular&tab=leaderboard', 'front', 'leaderboard_leaderboard' );
$return[] = \IPS\Http\Url::internal( 'app=core&module=discover&controller=popular&tab=history', 'front', 'leaderboard_history' );
$return[] = \IPS\Http\Url::internal( 'app=core&module=discover&controller=popular&tab=members', 'front', 'leaderboard_members' );
}
if ( \IPS\Settings::i()->clubs )
{
$return[] = \IPS\Http\Url::internal( 'app=core&module=clubs&controller=directory', 'front', 'clubs_list' );
}
return $return;
}
/**
* Get AdminCP Menu Count for resource updates
*
@@ -552,6 +514,11 @@ class _Application extends \IPS\Application
case 'applications':
foreach( \IPS\Application::applications() as $app )
{
if ( \IPS\CIC AND \IPS\IPS::isManaged() AND \in_array( $app->directory, \IPS\IPS::$ipsApps ) )
{
continue;
}
if( \count( $app->availableUpgrade( TRUE ) ) )
{
$count++;
@@ -602,4 +569,118 @@ class _Application extends \IPS\Application
\IPS\Data\Store::i()->$key = $count;
return (int) \IPS\Data\Store::i()->$key;
}
/**
* Returns a list of all existing webhooks and their payload in this app.
*
* @return array
*/
public function getWebhooks() : array
{
return array_merge( [
'club_created' => \IPS\Member\Club::class,
'club_deleted' => \IPS\Member\Club::class,
'club_member_added' => ['club' => \IPS\Member\Club::class, 'member' => \IPS\Member::class, 'status' => "string" ],
'club_member_removed' => ['club' => \IPS\Member\Club::class, 'member' => \IPS\Member::class ],
'member_create' => \IPS\Member::class,
'member_edited' => [ 'member' => \IPS\Member::class, 'changes' => "array" ],
'member_delete' => \IPS\Member::class,
], parent::getWebhooks() );
}
/**
* Do Member Check
*
* @return \IPS\Http\Url|NULL
*/
public function doMemberCheck(): ?\IPS\Http\Url
{
/* Need their name or email... */
if( ( \IPS\Member::loggedIn()->real_name === '' or !\IPS\Member::loggedIn()->email ) and \IPS\Dispatcher::i()->controller !== 'register' and \IPS\Dispatcher::i()->controller !== 'login' )
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=register&do=complete' )->setQueryString( 'ref', base64_encode( \IPS\Request::i()->url() ) );
}
/* Need them to validate... */
elseif(
\IPS\Member::loggedIn()->members_bitoptions['validating'] and
\IPS\Dispatcher::i()->controller !== 'register' and
\IPS\Dispatcher::i()->controller !== 'login' and
\IPS\Dispatcher::i()->controller != 'redirect' and
\IPS\Dispatcher::i()->controller !== 'store' and
\IPS\Dispatcher::i()->controller !== 'checkout'
)
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=register&do=validating', 'front', 'register' );
}
/* Need them to reconfirm terms/privacy policy... */
elseif ( ( \IPS\Member::loggedIn()->members_bitoptions['must_reaccept_privacy'] or \IPS\Member::loggedIn()->members_bitoptions['must_reaccept_terms'] ) and \IPS\Dispatcher::i()->controller !== 'register' and \IPS\Dispatcher::i()->controller !== 'ajax' )
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=register&do=reconfirm', 'front', 'register' )->setQueryString( 'ref', base64_encode( \IPS\Request::i()->url() ) );
}
/* Have required profile actions that need completing */
else if (
\IPS\Settings::i()->quick_register AND
!\IPS\Member::loggedIn()->members_bitoptions['profile_completed'] AND
!\in_array( \IPS\Dispatcher::i()->controller, array( 'register', 'login', 'redirect', 'ajax', 'settings', 'checkout', 'pixabay', 'editor' ) ) AND
$completion = \IPS\Member::loggedIn()->profileCompletion() AND
\count( $completion['required'] )
)
{
foreach( $completion['required'] AS $id => $completed )
{
if ( $completed === FALSE )
{
return \IPS\Http\Url::internal( "app=core&module=system&controller=register&do=finish&_new=1", 'front', 'register' )->setQueryString( 'ref', base64_encode( \IPS\Request::i()->url() ) );
}
}
}
/* Need to set up MFA... */
if ( !\in_array( \IPS\Dispatcher::i()->controller, array( 'register', 'login', 'redirect', 'ajax', 'settings', 'embed' ) ) )
{
$haveAcceptableHandlers = FALSE;
$haveConfiguredHandler = FALSE;
foreach ( \IPS\MFA\MFAHandler::handlers() as $key => $handler )
{
if ( $handler->isEnabled() and $handler->memberCanUseHandler( \IPS\Member::loggedIn() ) )
{
$haveAcceptableHandlers = TRUE;
if ( $handler->memberHasConfiguredHandler( \IPS\Member::loggedIn() ) )
{
$haveConfiguredHandler = TRUE;
break;
}
}
}
if ( !$haveConfiguredHandler and $haveAcceptableHandlers )
{
if ( \IPS\Settings::i()->mfa_required_groups == '*' or \IPS\Member::loggedIn()->inGroup( explode( ',', \IPS\Settings::i()->mfa_required_groups ) ) )
{
if ( \IPS\Settings::i()->mfa_required_prompt === 'immediate' )
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=settings&do=initialMfa', 'front', 'settings' )->setQueryString( 'ref', base64_encode( \IPS\Request::i()->url() ) );
}
}
elseif ( \IPS\Settings::i()->mfa_optional_prompt === 'immediate' and !\IPS\Member::loggedIn()->members_bitoptions['security_questions_opt_out'] )
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=settings&do=initialMfa', 'front', 'settings' )->setQueryString( 'ref', base64_encode( \IPS\Request::i()->url() ) );
}
}
}
/* Need to reset password */
if ( \IPS\Dispatcher::i()->controller !== 'settings' AND ( !isset( \IPS\Request::i()->area ) OR \IPS\Request::i()->area !== 'password' ) )
{
foreach( \IPS\Login::methods() AS $method )
{
if ( $url = $method->forcePasswordResetUrl( \IPS\Member::loggedIn(), \IPS\Request::i()->url() ) )
{
return $url;
}
}
}
return NULL;
}
}
@@ -36,8 +36,6 @@ abstract class _Mutation
'follow' => new \IPS\core\api\GraphQL\Mutations\Follow(),
'unfollow' => new \IPS\core\api\GraphQL\Mutations\Unfollow(),
'markNotificationRead' => new \IPS\core\api\GraphQL\Mutations\MarkNotificationRead(),
'sessionStart' => new \IPS\core\api\GraphQL\Mutations\SessionStart(),
'sessionEnd' => new \IPS\core\api\GraphQL\Mutations\SessionEnd(),
'uploadAttachment' => new \IPS\core\api\GraphQL\Mutations\UploadAttachment(),
'deleteAttachment' => new \IPS\core\api\GraphQL\Mutations\DeleteAttachment(),
'ignoreMember' => new \IPS\core\api\GraphQL\Mutations\IgnoreUser(),
@@ -1,102 +0,0 @@
<?php
/**
* @brief GraphQL: End a session for the user
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @since 02 Apr 2019
* @version SVN_VERSION_NUMBER
*/
namespace IPS\core\api\GraphQL\Mutations;
use GraphQL\Type\Definition\ObjectType;
use IPS\Api\GraphQL\TypeRegistry;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Register a push token for a specific user
*/
class _SessionEnd
{
/*
* @brief Query description
*/
public static $description = "End a user session";
/*
* Mutation arguments
*/
public function args()
{
return [
'token' => TypeRegistry::string()
];
}
/**
* Return the mutation return type
*/
public function type()
{
return \IPS\core\Api\GraphQL\TypeRegistry::member();
}
/**
* Resolves this mutation
* @todo this is basically copied and pasted from notifications.php which isn't ideal, so we
* might want to consider refactoring to abstract this functionality.
*
* @param mixed Value passed into this resolver
* @param array Arguments
* @param array Context values
* @return \IPS\forums\Forum
*/
public function resolve($val, $args)
{
if( !\IPS\Member::loggedIn()->member_id )
{
throw new \IPS\Api\GraphQL\SafeException( 'NOT_LOGGED_IN', 'GQL/0001/6', 403 );
}
\IPS\Db::i()->update( 'core_oauth_server_access_tokens', array( 'status' => 'revoked' ), array( 'member_id=? AND access_token=?', \IPS\Member::loggedIn()->member_id, \IPS\Dispatcher::i()->accessToken['access_token'] ) );
if ( isset( \IPS\Dispatcher::i()->accessToken['device_key'] ) )
{
\IPS\Db::i()->update( 'core_oauth_server_access_tokens', array( 'status' => 'revoked' ), array( 'member_id=? AND device_key=?', \IPS\Member::loggedIn()->member_id, \IPS\Dispatcher::i()->accessToken['device_key'] ) );
}
if ( isset( $args['token'] ) and $args['token'] )
{
try
{
$response = \IPS\Http\Url::ips('mobile/signout')->request()->login( \IPS\Settings::i()->mobile_app_id, \IPS\Settings::i()->mobile_app_secret )->post( array(
'member' => \IPS\Member::loggedIn()->member_id,
'token' => $args['token']
) )->decodeJson();
if ( $response->httpResponseCode != 200 )
{
throw new \DomainException( (string) $response );
}
if ( !$response['remainingDevices'] )
{
\IPS\Member::loggedIn()->members_bitoptions['mobile_notifications'] = FALSE;
\IPS\Member::loggedIn()->save();
}
}
catch ( \Exception $e )
{
\IPS\Log::log( $e, 'mobile-push-notifications' );
}
}
return \IPS\Member::loggedIn();
}
}
@@ -1,116 +0,0 @@
<?php
/**
* @brief GraphQL: Start a session for a user
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @since 20 Mar 2019
* @version SVN_VERSION_NUMBER
*/
namespace IPS\core\api\GraphQL\Mutations;
use GraphQL\Type\Definition\ObjectType;
use IPS\Api\GraphQL\TypeRegistry;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Register a push token for a specific user
*/
class _SessionStart
{
/*
* @brief Query description
*/
public static $description = "Start a session for an authenticated user";
/*
* Mutation arguments
*/
public function args()
{
return [
'token' => TypeRegistry::string()
];
}
/**
* Return the mutation return type
*/
public function type()
{
return \IPS\core\Api\GraphQL\TypeRegistry::member();
}
/**
* Resolves this mutation
* @todo this is basically copied and pasted from notifications.php which isn't ideal, so we
* might want to consider refactoring to abstract this functionality.
*
* @param mixed Value passed into this resolver
* @param array Arguments
* @param array Context values
* @return \IPS\forums\Forum
*/
public function resolve($val, $args)
{
if( !\IPS\Member::loggedIn()->member_id )
{
throw new \IPS\Api\GraphQL\SafeException( 'NOT_LOGGED_IN', 'GQL/0001/6', 403 );
}
if ( isset( $args['token'] ) and $args['token'] )
{
try
{
/* Register the token with the backend */
$response = \IPS\Http\Url::ips('mobile/signin')->request()->login( \IPS\Settings::i()->mobile_app_id, \IPS\Settings::i()->mobile_app_secret )->post( array(
'member' => \IPS\Member::loggedIn()->member_id,
'token' => $args['token']
) );
if ( !\in_array( $response->httpResponseCode, array( 200, 201 ) ) )
{
throw new \DomainException( (string) $response );
}
/* If we didn't already have notifications enabled, enable them and set the defaults */
if ( !\IPS\Member::loggedIn()->members_bitoptions['mobile_notifications'] )
{
\IPS\Member::loggedIn()->members_bitoptions['mobile_notifications'] = TRUE;
\IPS\Member::loggedIn()->save();
$notificationPreferences = \IPS\Db::i()->select( '*', 'core_notification_preferences', array( 'member_id=?', \IPS\Member::loggedIn()->member_id ) );
if ( \count( $notificationPreferences ) )
{
$keysToAddPushTo = array();
foreach ( $notificationPreferences as $row )
{
if ( \in_array( 'inline', explode( ',', $row['preference'] ) ) )
{
$keysToAddPushTo[] = $row['notification_key'];
}
}
if ( \count( $keysToAddPushTo ) )
{
\IPS\Db::i()->update( 'core_notification_preferences', "`preference` = IF( `preference` = '', 'push', CONCAT_WS( ',', `preference`, 'push' ) )", array( array( 'member_id=?', \IPS\Member::loggedIn()->member_id ), array( \IPS\Db::i()->in( 'notification_key', $keysToAddPushTo ) ) ) );
}
}
}
}
catch ( \Exception $e )
{
\IPS\Log::log( $e, 'mobile-push-notifications' );
}
}
return \IPS\Member::loggedIn();
}
}
@@ -1,81 +0,0 @@
<?php
/**
* @brief GraphQL: Mobile menu query
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @since 12 June 2019
* @version SVN_VERSION_NUMBER
*/
namespace IPS\core\api\GraphQL\Queries;
use GraphQL\Type\Definition\ObjectType;
use IPS\Api\GraphQL\TypeRegistry;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Mobile menu query for GraphQL API
*/
class _MobileMenu
{
/*
* @brief Query description
*/
public static $description = "Returns details of the mobile app menu";
/*
* Query arguments
*/
public function args()
{
return array();
}
/**
* Return the query return type
*/
public function type()
{
return TypeRegistry::listOf( \IPS\core\api\GraphQL\TypeRegistry::mobileMenu() );
}
/**
* Resolves this query
*
* @param mixed Value passed into this resolver
* @param array Arguments
* @param array Context values
* @return array
*/
public function resolve($val, $args, $context)
{
$return = array();
foreach ( \IPS\Db::i()->select( '*', 'core_mobileapp_menu', NULL, 'position' ) as $item )
{
if ( \IPS\Application::appIsEnabled( $item['app'] ) )
{
$class = 'IPS\\' . $item['app'] . '\extensions\core\MobileNavigation\\' . $item['extension'];
if ( class_exists( $class ) )
{
$object = new $class( json_decode( $item['config'], TRUE ), $item['id'], $item['permissions'] );
if ( $object->canView() )
{
$return[ $item['id'] ] = $object;
}
}
}
}
return $return;
}
}
-1
View File
@@ -46,7 +46,6 @@ abstract class _Query
'messengerConversation' => new \IPS\core\api\GraphQL\Queries\MessengerConversation(),
'messengerConversations' => new \IPS\core\api\GraphQL\Queries\MessengerConversations(),
'messengerFolders' => new \IPS\core\api\GraphQL\Queries\MessengerFolders(),
'mobileMenu' => new \IPS\core\api\GraphQL\Queries\MobileMenu(),
'notificationTypes' => new \IPS\core\api\GraphQL\Queries\NotificationTypes(),
'ourPicks' => new \IPS\core\api\GraphQL\Queries\OurPicks(),
'popularContributors' => new \IPS\core\api\GraphQL\Queries\PopularContributors(),
@@ -38,7 +38,6 @@ class _TypeRegistry
protected static $group;
protected static $ignoreOption;
protected static $member;
protected static $mobileMenu;
protected static $language;
protected static $login;
protected static $messengerConversation;
@@ -151,14 +150,6 @@ class _TypeRegistry
{
return self::$member ?: (self::$member = new \IPS\core\api\GraphQL\Types\MemberType());
}
/**
* @return MobileMenuType
*/
public static function mobileMenu()
{
return self::$mobileMenu ?: (self::$mobileMenu = new \IPS\core\api\GraphQL\Types\MobileMenuType());
}
/**
* @return LanguageType
@@ -499,7 +499,7 @@ class _MemberType extends ObjectType
/* Specify filter in where clause */
$where = array();
$where[] = array( "notification_app IN('" . implode( "','", array_keys( \IPS\Application::enabledApplications() ) ) . "')" );
$where[] = array( "member=?", \IPS\Member::loggedIn()->member_id );
$where[] = array( "`member`=?", \IPS\Member::loggedIn()->member_id );
/* Are we filtering by unread status? */
if( isset( $args['unread'] ) && $args['unread'] !== NULL )
@@ -1,81 +0,0 @@
<?php
/**
* @brief GraphQL: Mobile Menu Type
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Community Suite
* @since 12 June 2019
* @version SVN_VERSION_NUMBER
*/
namespace IPS\core\api\GraphQL\Types;
use GraphQL\Type\Definition\ObjectType;
use IPS\Api\GraphQL\TypeRegistry;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Mobile Menu Type for GraphQL API
*/
class _MobileMenuType extends ObjectType
{
/**
* Get object type
*
* @return ObjectType
*/
public function __construct()
{
$config = [
'name' => 'core_MobileMenu',
'description' => 'Mobile menu item type',
'fields' => function () {
return [
'id' => [
'type' => TypeRegistry::id(),
'description' => "Item ID",
'resolve' => function ( $item ) {
return $item->id;
}
],
'class' => [
'type' => TypeRegistry::string(),
'description' => "Class which handles this item",
'resolve' => function ( $item ) {
return \get_class( $item );
}
],
'title' => [
'type' => TypeRegistry::string(),
'description' => "Menu item title",
'resolve' => function ($item) {
return $item->title();
}
],
'icon' => [
'type' => TypeRegistry::string(),
'description' => "Icon key for this item",
'resolve' => function ($item) {
return $item->icon();
}
],
'url' => [
'type' => TypeRegistry::url(),
'description' => "URL to content",
'resolve' => function ( $item ) {
return $item->link();
}
]
];
}
];
parent::__construct($config);
}
}
@@ -104,7 +104,7 @@ class _NotificationTypeType extends ObjectType
'type' => \IPS\core\api\GraphQL\TypeRegistry::notificationMethod(),
'description' => "Push notification method",
'resolve' => function ($type) {
if ( !isset( $type['push'] ) || !\count( $type['push'] ) || !\IPS\Settings::i()->mobile_app_id || !\IPS\Member::loggedIn()->members_bitoptions['mobile_notifications'] )
if ( !isset( $type['push'] ) || !\count( $type['push'] ) || !\IPS\Member::loggedIn()->members_bitoptions['mobile_notifications'] )
{
return NULL;
}
@@ -126,7 +126,6 @@ class _PollQuestionType extends ObjectType
'description' => "The choices for this question",
'resolve' => function ($question) {
$choices = array();
$canViewCount = \IPS\Member::loggedIn()->modPermission('can_edit_poll_votes');
foreach( $question['data']['choice'] as $idx => $choice )
{
@@ -106,22 +106,6 @@ class _SettingsType extends ObjectType
return \IPS\GeoLocation::enabled();
}
],
'mobileHomeBlocks' => [
'type' => TypeRegistry::listOf( TypeRegistry::string() ),
'resolve' => function () {
try
{
$parsed = json_decode( \IPS\Settings::i()->mobile_app_home_blocks_order, TRUE );
$blocksToShow = array_filter( $parsed );
return array_keys( $blocksToShow );
}
catch (\Exception $e)
{
return array("new_content", "active_users", "our_picks", "popular_contributors");
}
}
],
'version' => [
'type' => TypeRegistry::int(),
'resolve' => function () {
@@ -41,14 +41,16 @@ class _StatsType extends ObjectType
'type' => TypeRegistry::int(),
'description' => "Content count",
'resolve' => function () {
return ( isset( \IPS\Settings::i()->mobile_app_hide_stats ) && \IPS\Settings::i()->mobile_app_hide_stats ) ? NULL : static::getContentCount();
// Return null for now until GQL is fleshed out
return NULL;
}
],
'memberCount' => [
'type' => TypeRegistry::int(),
'description' => 'Member count',
'resolve' => function () {
return ( isset( \IPS\Settings::i()->mobile_app_hide_stats ) && \IPS\Settings::i()->mobile_app_hide_stats ) ? NULL : static::getMemberCount();
// Return null for now until GQL is fleshed out
return NULL;
}
]
];
+16 -3
View File
@@ -28,7 +28,8 @@ class _clubs extends \IPS\Api\Controller
*
* @apiparam int page Page number
* @apiparam int perPage Number of results per page - defaults to 25
* @note For requests using an OAuth Access Token for a particular member, only clubs the authorized user can view will be included
* @apiparam int member_id Member ID to return only clubs the member is allowed to view.
* @note For requests using an OAuth Access Token for a particular member, only clubs the authorized user can view will be included and the member_id parameter will be ignored.
* @return \IPS\Api\PaginatedResponse<IPS\Member\Club>
*/
public function GETindex()
@@ -36,13 +37,25 @@ class _clubs extends \IPS\Api\Controller
$page = isset( \IPS\Request::i()->page ) ? \IPS\Request::i()->page : 1;
$perPage = isset( \IPS\Request::i()->perPage ) ? \IPS\Request::i()->perPage : 25;
$forMember = $this->member;
if( !$this->member AND isset( \IPS\Request::i()->member_id ) )
{
$forMember = \IPS\Member::load( \IPS\Request::i()->member_id );
if( !$forMember->member_id )
{
$forMember = NULL;
}
}
/* Return */
return new \IPS\Api\PaginatedResponse(
200,
\IPS\Member\Club::clubs( $this->member ?: NULL, array( ( $page - 1 ) * $perPage, $perPage ), 'created' ),
\IPS\Member\Club::clubs( $forMember, array( ( $page - 1 ) * $perPage, $perPage ), 'created' ),
$page,
'IPS\Member\Club',
\IPS\Member\Club::clubs( $this->member ?: NULL, array( ( $page - 1 ) * $perPage, $perPage ), 'created', FALSE, array(), NULL, TRUE ),
\IPS\Member\Club::clubs( $forMember, array( ( $page - 1 ) * $perPage, $perPage ), 'created', FALSE, array(), NULL, TRUE ),
$this->member,
$perPage
);
+6
View File
@@ -79,6 +79,7 @@ class _groups extends \IPS\Api\Controller
*
* @apiclientonly
* @param int $id ID Number
* @throws 2C358/3 CANNOT_DELETE The group can't be deleted
* @throws 1C358/2 INVALID_ID The group ID does not exist
* @return void
*/
@@ -92,6 +93,11 @@ class _groups extends \IPS\Api\Controller
throw new \OutOfRangeException;
}
if( !$group->canDelete() )
{
throw new \IPS\Api\Exception( 'CANNOT_DELETE', '2C358/3', 403 );
}
$group->delete();
return new \IPS\Api\Response( 200, NULL );
+1 -1
View File
@@ -37,7 +37,7 @@ class _hello extends \IPS\Api\Controller
return new \IPS\Api\Response( 200, array(
'communityName' => \IPS\Settings::i()->board_name,
'communityUrl' => \IPS\Settings::i()->base_url,
'ipsApplications' => \IPS\Application::load('core')->version,
'ipsVersion' => \IPS\Application::load('core')->version,
'ipsApplications' => array_filter( array_keys( \IPS\Application::applications() ), function( $k ) { return \in_array( $k, \IPS\IPS::$ipsApps ); } )
) );
}
+8 -12
View File
@@ -570,7 +570,7 @@ class _members extends \IPS\Api\Controller
{
$classToFollow = 'IPS\\' . \IPS\Request::i()->followApp . '\\' . mb_ucfirst( \IPS\Request::i()->followArea );
if( !class_exists( $classToFollow ) or !array_key_exists( \IPS\Request::i()->follow_app, \IPS\Application::applications() ) )
if( !class_exists( $classToFollow ) or !array_key_exists( \IPS\Request::i()->followApp, \IPS\Application::applications() ) )
{
throw new \OutOfRangeException;
}
@@ -1193,19 +1193,15 @@ class _members extends \IPS\Api\Controller
/**
* POST /core/members/{id}/achievements/{badge}/awardbadge
* Acknowledge a warning
* Award a badge
*
* @param int $id ID Number
* @reqapiparam int $badgeId Badge to award
* @param int $logId The ID number of the log in core_achievements_log which will tell us specifically what ACTION caused this (eg what post was made)
* @param int $ruleId The ID number of the rule which matched that action which caused this badge to be awarded
* @param array $actor If member is 'subject', 'other' or both
* @param int $recognize The ID of the recognize table row (optional)
* @return \IPS\Member
* @throws 2C292/M INVALID_BADGE The badge could not be found //TODo error code
* @throws 2C292/N INVALID_ID The member could not be found //TODo error code
* @throws 2C292/13 INVALID_BADGE The badge could not be found
* @throws 2C292/14 INVALID_ID The member could not be found
*/
public function POSTitem_achievements_awardbadge( int $id, int $badgeId, int $logId, int $ruleId, array $actor, int $recognize=0 ): \IPS\Api\Response
public function POSTitem_achievements_awardbadge( int $id, int $badgeId ): \IPS\Api\Response
{
try
{
@@ -1223,15 +1219,15 @@ class _members extends \IPS\Api\Controller
}
catch( \OutOfRangeException $e )
{
throw new \IPS\Api\Exception( 'INVALID_BADGE', '2C292/W', 404 ); //TODO error code
throw new \IPS\Api\Exception( 'INVALID_BADGE', '2C292/13', 404 );
}
$member->awardBadge($id, $badgeId, $logId,$ruleId,$actor,$recognize);
$member->awardBadge($badge, 0, 0, ['subject'] );
return new \IPS\Api\Response( 200, $member->apiOutput( $this->member ) );
}
catch ( \OutOfRangeException $e )
{
throw new \IPS\Api\Exception( 'INVALID_ID', '2C292/N', 404 ); //TODO error code
throw new \IPS\Api\Exception( 'INVALID_ID', '2C292/14', 404 );
}
}
}
+1 -1
View File
@@ -62,7 +62,7 @@ class _webhooks extends \IPS\Api\Controller
/**
* DELETE /core/webhooks/{id}
* Deletes a webhooks
* Deletes a webhook
*
* @apiclientonly
* @param int $id ID Number
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="UTF-8"?>
<rules><rule><action>core_NewContentItem</action><filters/><milestone/><points_subject>10</points_subject><badge_subject/><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_Comment</action><filters/><milestone/><points_subject>5</points_subject><badge_subject/><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_FollowNode</action><filters/><milestone/><points_subject>2</points_subject><badge_subject/><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_FollowContentItem</action><filters/><milestone/><points_subject>2</points_subject><badge_subject/><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_FollowMember</action><filters/><milestone/><points_subject>2</points_subject><badge_subject/><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_Reaction</action><filters/><milestone/><points_subject>1</points_subject><badge_subject/><points_other>1</points_other><badge_other/><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_Comment</action><filters>{"milestone":1}</filters><milestone>1</milestone><points_subject>0</points_subject><badge_subject>6087eca35e0df</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Making your first post</award_subject_lang><award_other_lang/></rule><rule><action>core_NewContentItem</action><filters>{"milestone":1}</filters><milestone>1</milestone><points_subject>0</points_subject><badge_subject>6087eca35e1ea</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Started a discussion</award_subject_lang><award_other_lang/></rule><rule><action>core_Comment</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>6087eca35e304</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Making your 10th post</award_subject_lang><award_other_lang/></rule><rule><action>core_Reaction</action><filters>{"milestone":5}</filters><milestone>5</milestone><points_subject>0</points_subject><badge_subject/><points_other>0</points_other><badge_other>6087eca35e3b2</badge_other><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_FollowMember</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>6087eca35e557</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Got 10 followers!</award_subject_lang><award_other_lang/></rule><rule><action>forums_AnswerMarkedBest</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>6087eca35e6c4</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Solved 10 topics</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_concurrent":7}</filters><milestone/><points_subject>0</points_subject><badge_subject>6087eca35e776</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Visited daily for a week</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":7}</filters><milestone/><points_subject>0</points_subject><badge_subject>6087eca35e81a</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>A week since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":30}</filters><milestone/><points_subject>0</points_subject><badge_subject>6087eca35e932</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>A month since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":365}</filters><milestone/><points_subject>0</points_subject><badge_subject>6087eca35e9cb</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>A year since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_Reaction</action><filters>{"milestone":100}</filters><milestone>100</milestone><points_subject>0</points_subject><badge_subject>6087eca35ea70</badge_subject><points_other>0</points_other><badge_other/><enabled>1</enabled><award_subject_lang>Got 100 reactions</award_subject_lang><award_other_lang/></rule><rule><action>core_Comment</action><filters>{"milestone":500}</filters><milestone>500Line truncated
<rules><rule><action>core_NewContentItem</action><filters/><milestone>0</milestone><points_subject>10</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_Comment</action><filters/><milestone>0</milestone><points_subject>5</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Making your first post</award_subject_lang><award_other_lang/></rule><rule><action>core_FollowNode</action><filters/><milestone>0</milestone><points_subject>2</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Started a discussion</award_subject_lang><award_other_lang/></rule><rule><action>core_FollowContentItem</action><filters/><milestone>0</milestone><points_subject>2</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Making your 10th post</award_subject_lang><award_other_lang/></rule><rule><action>core_FollowMember</action><filters/><milestone>0</milestone><points_subject>2</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang/><award_other_lang/></rule><rule><action>core_Reaction</action><filters/><milestone>0</milestone><points_subject>1</points_subject><badge_subject>0</badge_subject><points_other>1</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Got 10 followers!</award_subject_lang><award_other_lang/></rule><rule><action>core_Comment</action><filters>{"milestone":1}</filters><milestone>1</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0b90</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Making your first post</award_subject_lang><award_other_lang/></rule><rule><action>core_NewContentItem</action><filters>{"milestone":1}</filters><milestone>1</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0bb4</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Started a discussion</award_subject_lang><award_other_lang/></rule><rule><action>core_Comment</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0bd6</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Making your 10th post</award_subject_lang><award_other_lang/></rule><rule><action>core_Reaction</action><filters>{"milestone":5}</filters><milestone>5</milestone><points_subject>0</points_subject><badge_subject>0</badge_subject><points_other>0</points_other><badge_other>61829d5ad0bfa</badge_other><enabled>1</enabled><award_subject_lang>A month since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_FollowMember</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0c1d</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Got 10 followers!</award_subject_lang><award_other_lang/></rule><rule><action>forums_AnswerMarkedBest</action><filters>{"milestone":10}</filters><milestone>10</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0c3f</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Solved 10 topics</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_concurrent":7}</filters><milestone>0</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0c62</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>Visited daily for a week</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":7}</filters><milestone>0</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0c84</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>A week since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":30}</filters><milestone>0</milestone><points_subject>0</points_subject><badge_subject>61829d5ad0ca7</badge_subject><points_other>0</points_other><badge_other>0</badge_other><enabled>1</enabled><award_subject_lang>A month since joining</award_subject_lang><award_other_lang/></rule><rule><action>core_SessionStartDaily</action><filters>{"milestone_registered":365}</filters><milestone>0</milestone><points_sLine truncated
+73 -23
View File
@@ -105,6 +105,13 @@
"controller": "advanced",
"do": "",
"restriction": "advanced_manage"
},
"dataLayer": {
"tab": "core",
"controller": "dataLayer",
"do": "",
"restriction": "dataLayer_manage",
"subcontrollers": ""
}
},
"discovery": {
@@ -141,12 +148,6 @@
"restriction": null,
"callback": "return ( ( !\\IPS\\CIC AND \\IPS\\Member::loggedIn()->hasAcpRestriction( 'core', 'promotion', 'seo_furls' ) ) or \\IPS\\Member::loggedIn()->hasAcpRestriction( 'core', 'promotion', 'seo_sitemap' ) or \\IPS\\Member::loggedIn()->hasAcpRestriction( 'core', 'promotion', 'seo_meta' ) );"
},
"analytics": {
"tab": "core",
"controller": "analytics",
"do": "",
"restriction": "analytics_manage"
},
"sharelinks": {
"tab": "core",
"controller": "sharelinks",
@@ -160,21 +161,6 @@
"restriction": "promote_manage"
}
},
"mobile": {
"menu": {
"tab": "core",
"controller": "menu",
"do": "",
"restriction": "menu_manage",
"callback": "return \\IPS\\Settings::i()->mobile_app_id;"
},
"mobile": {
"tab": "core",
"controller": "mobile",
"do": "",
"restriction": "mobile_manage"
}
},
"members": {
"members": {
"tab": "members",
@@ -348,6 +334,13 @@
"controller": "settings",
"do": "",
"restriction": "settings_manage"
},
"storedreplies": {
"tab": "customization",
"controller": "storedreplies",
"do": "",
"restriction": "stored_replies_manage",
"subcontrollers": ""
}
},
"languages": {
@@ -409,7 +402,21 @@
"tab": "stats",
"controller": "search",
"do": "",
"restriction": "search_manage",
"restriction": "search_stats_manage",
"subcontrollers": ""
},
"reports": {
"tab": "stats",
"controller": "reports",
"do": "",
"restriction": "reports_manage",
"subcontrollers": ""
},
"deletedcontent": {
"tab": "stats",
"controller": "deletedcontent",
"do": "",
"restriction": "deletedcontent_manage",
"subcontrollers": ""
}
},
@@ -426,7 +433,7 @@
"controller": "registrationstats",
"do": "",
"restriction": "registrations_manage",
"restriction_module": "members"
"restriction_module": "stats"
},
"membervisits": {
"tab": "stats",
@@ -465,6 +472,49 @@
"do": "",
"restriction": "overview_manage",
"subcontrollers": ""
},
"spam": {
"tab": "stats",
"controller": "spam",
"do": "",
"restriction": "spam_manage",
"subcontrollers": ""
},
"preferences": {
"tab": "stats",
"controller": "preferences",
"do": "",
"restriction": "preferences_manage",
"subcontrollers": ""
},
"referrals": {
"tab": "stats",
"controller": "referrals",
"do": "",
"restriction": "referrals_manage",
"subcontrollers": "",
"callback": "return \\IPS\\Settings::i()->ref_on;"
},
"follow": {
"tab": "stats",
"controller": "follow",
"do": "",
"restriction": "follow_manage",
"subcontrollers": ""
},
"warnings": {
"tab": "stats",
"controller": "warnings",
"do": "",
"restriction": "warnings_manage",
"subcontrollers": ""
},
"moderators": {
"tab": "stats",
"controller": "moderators",
"do": "",
"restriction": "moderatorstats_manage",
"subcontrollers": ""
}
},
"messengerstats": {
+37 -16
View File
@@ -33,7 +33,8 @@
"api_reference": "api_reference",
"api_logs": "api_logs",
"api_logs_settings": "api_logs_settings",
"api_logs_delete": "api_logs_delete"
"api_logs_delete": "api_logs_delete",
"webhooks_manage": "webhooks_manage"
},
"rss": {
"rss_manage": "rss_manage",
@@ -58,22 +59,11 @@
"advertisements_edit": "advertisements_edit",
"advertisements_delete": "advertisements_delete"
},
"analytics": {
"analytics_manage": "analytics_manage"
},
"promote": {
"promote_manage": "promote_manage",
"promote_logs": "promote_logs"
}
},
"mobile": {
"mobile": {
"mobile_manage": "mobile_manage"
},
"menu": {
"menu_manage": "menu_manage"
}
},
"settings": {
"login": {
"login_access": "login_access",
@@ -121,6 +111,11 @@
},
"mfa": {
"mfa_manage": "mfa_manage"
},
"dataLayer": {
"dataLayer_manage": "dataLayer_manage",
"dataLayer_handlers_edit": "dataLayer_handlers_edit",
"dataLayer_handlers_view": "dataLayer_handlers_view"
}
},
"discovery": {
@@ -169,9 +164,6 @@
"messages": {
"messages_manage": "messages_manage"
},
"registrations": {
"registrations_manage": "registrations_manage"
},
"promotions": {
"promotions_manage": "promotions_manage"
}
@@ -271,6 +263,9 @@
},
"settings": {
"settings_manage": "settings_manage"
},
"editor_stored_replies": {
"stored_replies_manage": "stored_replies_manage"
}
},
"customization": {
@@ -328,7 +323,6 @@
"support": {
"get_support": "get_support",
"diagnostic_log_settings": "diagnostic_log_settings",
"sql_toolbox": "sql_toolbox",
"system_logs_view": "system_logs_view",
"redis_data": "redis_data"
}
@@ -365,6 +359,27 @@
},
"overview": {
"overview_manage": "overview_manage"
},
"registrations": {
"registrations_manage": "registrations_manage"
},
"spamstats": {
"spamstats_manage": "spamstats_manage"
},
"preferences": {
"preferences_manage": "preferences_manage"
},
"referrals": {
"referrals_manage": "referrals_manage"
},
"follow": {
"follow_manage": "follow_manage"
},
"warnings": {
"warnings_manage": "warnings_manage"
},
"moderators": {
"moderatorstats_manage": "moderatorstats_manage"
}
},
"system": [],
@@ -420,6 +435,12 @@
},
"emailstats": {
"emailstats_manage": "emailstats_manage"
},
"reportstats": {
"reportstats_manage": "reportstats_manage"
},
"deletedcontent": {
"deletedcontent_manage": "deletedcontent_manage"
}
},
"marketplace": {
+201 -88
View File
@@ -66,7 +66,8 @@
"restriction": "api_manage",
"keywords": [
"api",
"rest api"
"rest api",
"webhook"
]
},
"app=core&module=applications&controller=api&tab=apiKeys": {
@@ -91,6 +92,20 @@
"api reference"
]
},
"app=core&module=applications&controller=api&tab=webhooks": {
"lang_key": "webhooks",
"restriction": "api_splash",
"keywords": [
"webhook"
]
},
"app=core&module=applications&controller=api&tab=webhooks&do=settings&searchResult=webhook_logs_success": {
"lang_key": "webhook_logs_success",
"restriction": "api_splash",
"keywords": [
"webhook"
]
},
"app=core&module=applications&controller=applications": {
"lang_key": "menu__core_applications_applications",
"restriction": "app_manage",
@@ -106,15 +121,25 @@
"lang_key": "menu__core_applications_enhancements",
"restriction": "enhancements_manage",
"keywords": [
"analytics",
"bulk mail",
"easypost",
"email",
"enhancements",
"enom",
"geo",
"giphy",
"indexnow",
"mapbox",
"maps",
"matomo",
"maxmind",
"omniture",
"piwik",
"pixabay",
"sendgrid",
"spam",
"tag manager",
"viglink",
"zapier"
]
@@ -136,6 +161,28 @@
"maps"
]
},
"app=core&module=applications&controller=enhancements&do=edit&id=core_ImageScanner": {
"lang_key": "menu__core_applications_enhancements",
"restriction": "enhancements_manage",
"keywords": [
"adult images",
"disturbing image filters",
"disturbing images filters",
"gore filters",
"gore image filters",
"gore images filters",
"image filters",
"image scanner",
"inappropriate image filters",
"inappropriate images filters",
"porn filters",
"porn images",
"pornographic images",
"violence filters",
"violent image filters",
"violent images filters"
]
},
"app=core&module=applications&controller=enhancements&do=edit&id=core_Pixabay": {
"lang_key": "menu__core_applications_enhancements",
"restriction": "enhancements_manage",
@@ -343,6 +390,14 @@
"search results"
]
},
"app=core&module=discovery&controller=streams&do=allActivitySettings": {
"lang_key": "menu__core_discovery_streams",
"restriction": "streams_manage",
"keywords": [
"stream subscriptions",
"streams"
]
},
"app=core&module=editor&controller=emoticons": {
"lang_key": "menu__core_editor_emoticons",
"restriction": "emoticons_manage",
@@ -402,6 +457,13 @@
"parse"
]
},
"app=core&module=editor&controller=storedreplies": {
"lang_key": "menu__core_editor_storedreplies",
"restriction": "stored_replies_manage",
"keywords": [
"stock replies"
]
},
"app=core&module=editor&controller=toolbar": {
"lang_key": "editor_customization",
"restriction": "toolbar_manage",
@@ -446,50 +508,6 @@
"groups"
]
},
"app=core&module=members&controller=groups&searchResult=g_promote_exclude": {
"lang_key": "g_promote_exclude",
"restriction": "groups_manage",
"keywords": [
"group promotion",
"member promotions",
"member upgrades"
]
},
"app=core&module=members&controller=groups&searchResult=g_upload_animated_photos": {
"lang_key": "g_upload_animated_photos",
"restriction": "groups_manage",
"keywords": [
"animated",
"photos"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_can_post_anonymously": {
"lang_key": "can_post_anonymously",
"restriction": "groups_manage",
"keywords": [
"anonymous",
"anonymously"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_hide_group": {
"lang_key": "gbw_hide_group",
"restriction": "groups_manage",
"keywords": [
"allow filtering",
"online users",
"search"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_post_highlight": {
"lang_key": "gbw_post_highlight",
"restriction": "groups_manage",
"keywords": [
"background",
"highlight",
"highlight post",
"replies"
]
},
"app=core&module=members&controller=groups&searchResult=g_access_offline": {
"lang_key": "g_access_offline",
"restriction": "groups_manage",
@@ -731,6 +749,15 @@
"group formatting"
]
},
"app=core&module=members&controller=groups&searchResult=g_promote_exclude": {
"lang_key": "g_promote_exclude",
"restriction": "groups_manage",
"keywords": [
"group promotion",
"member promotions",
"member upgrades"
]
},
"app=core&module=members&controller=groups&searchResult=g_rep_max_positive": {
"lang_key": "g_rep_max_positive",
"restriction": "groups_manage",
@@ -789,6 +816,14 @@
"ratings"
]
},
"app=core&module=members&controller=groups&searchResult=g_upload_animated_photos": {
"lang_key": "g_upload_animated_photos",
"restriction": "groups_manage",
"keywords": [
"animated",
"photos"
]
},
"app=core&module=members&controller=groups&searchResult=g_use_signatures": {
"lang_key": "g_use_signatures",
"restriction": "groups_manage",
@@ -824,6 +859,14 @@
"profile cover photo"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_can_post_anonymously": {
"lang_key": "can_post_anonymously",
"restriction": "groups_manage",
"keywords": [
"anonymous",
"anonymously"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_cannot_be_ignored": {
"lang_key": "can_be_ignored",
"restriction": "groups_manage",
@@ -858,6 +901,15 @@
"tags"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_hide_group": {
"lang_key": "gbw_hide_group",
"restriction": "groups_manage",
"keywords": [
"allow filtering",
"online users",
"search"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_no_status_import": {
"lang_key": "gbw_no_status_import",
"restriction": "groups_manage",
@@ -878,6 +930,16 @@
"statuses"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_post_highlight": {
"lang_key": "gbw_post_highlight",
"restriction": "groups_manage",
"keywords": [
"background",
"highlight",
"highlight post",
"replies"
]
},
"app=core&module=members&controller=groups&searchResult=gbw_view_reps": {
"lang_key": "gbw_view_reps",
"restriction": "groups_manage",
@@ -975,13 +1037,6 @@
"Reputation Level"
]
},
"app=core&module=members&controller=members&searchResult=form_member_title": {
"lang_key": "member_title",
"restriction": null,
"keywords": [
"Member Title"
]
},
"app=core&module=members&controller=members&searchResult=form_member_warnings": {
"lang_key": "member_warnings",
"restriction": null,
@@ -1089,13 +1144,6 @@
"pm popup window"
]
},
"app=core&module=membersettings&controller=notifications&do=method&id=inline&searchResult=notification_prefs_sound": {
"lang_key": "notification_prefs_sound",
"restriction": "notifications_manage",
"keywords": [
"notification sounds"
]
},
"app=core&module=membersettings&controller=notifications&do=pruneSettings&searchResult=form_prune_notifications": {
"lang_key": "prune_notifications",
"restriction": "notifications_prune",
@@ -1402,14 +1450,6 @@
"show reputation"
]
},
"app=core&module=membersettings&controller=reputation&searchResult=reputation_timezone": {
"lang_key": "reputation_timezone",
"restriction": "reps_manage",
"keywords": [
"leaderboard",
"timezone"
]
},
"app=core&module=membersettings&controller=reputation&tab=leaderboard&searchResult=reputation_leaderboard_on": {
"lang_key": "reputation_leaderboard_on",
"restriction": "reps_manage",
@@ -1432,6 +1472,14 @@
"winner"
]
},
"app=core&module=membersettings&controller=reputation&tab=leaderboard&searchResult=reputation_timezone": {
"lang_key": "reputation_timezone",
"restriction": "reps_manage",
"keywords": [
"leaderboard",
"timezone"
]
},
"app=core&module=messengerstats&controller=pmstats": {
"lang_key": "menu__core_members_pmstats",
"restriction": null,
@@ -1601,6 +1649,13 @@
"png"
]
},
"app=core&module=overview&controller=files&do=imagesettings&searchResult=imagick_strip_exif": {
"lang_key": "imagick_strip_exif",
"restriction": "files_view",
"keywords": [
"exif"
]
},
"app=core&module=overview&controller=files&do=settings": {
"lang_key": "menu__core_overview_files",
"restriction": "files_view",
@@ -1625,19 +1680,6 @@
"google"
]
},
"app=core&module=promotion&controller=analytics": {
"lang_key": "ipbseo_ga_enabled",
"restriction": "analytics_manage",
"keywords": [
"analytics",
"ga",
"google",
"google analytics",
"omniture",
"piwik",
"tracking"
]
},
"app=core&module=promotion&controller=promote": {
"lang_key": "menu__core_promotion_promote",
"restriction": "promote_manage",
@@ -1712,6 +1754,24 @@
"robots"
]
},
"app=core&module=promotion&controller=seo&tab=robotstxt": {
"lang_key": "seo_tab_robotstxt",
"restriction": null,
"keywords": [
"crawl",
"robots",
"robots.txt",
"seo"
]
},
"app=core&module=promotion&controller=seo&tab=robotstxt&searchResult=use_robotstxt": {
"lang_key": "use_robotstxt",
"restriction": null,
"keywords": [
"robots",
"robots.txt"
]
},
"app=core&module=promotion&controller=seo&tab=sitemap": {
"lang_key": "seo_tab_sitemap",
"restriction": "seo_sitemap",
@@ -1823,6 +1883,13 @@
"x-frame-options"
]
},
"app=core&module=settings&controller=advanced&tab=settings&searchResult=form_widget_cache_ttl": {
"lang_key": "widget_cache_ttl",
"restriction": "advanced_manage",
"keywords": [
"cache"
]
},
"app=core&module=settings&controller=advanced&tab=settings&searchResult=match_ipaddress": {
"lang_key": "match_ipaddress",
"restriction": "security_manage",
@@ -1857,6 +1924,60 @@
"contact us"
]
},
"app=core&module=settings&controller=dataLayer": {
"lang_key": "menu__core_settings_dataLayer",
"restriction": "dataLayer_manage",
"keywords": [
"data layer",
"datalayer",
"pii"
]
},
"app=core&module=settings&controller=dataLayer&tab=events": {
"lang_key": "_datalayer_events",
"restriction": "dataLayer_manage",
"keywords": [
"data layer events",
"datalayer events"
]
},
"app=core&module=settings&controller=dataLayer&tab=handlers": {
"lang_key": "_datalayer_handlers",
"restriction": "dataLayer_handlers_view",
"keywords": [
"data layer handlers",
"datalayer handlers"
]
},
"app=core&module=settings&controller=dataLayer&tab=main&searchResult=datalayer_general_core_datalayer_use_gtm": {
"lang_key": "core_datalayer_use_gtm",
"restriction": "dataLayer_manage",
"keywords": [
"google tag manager",
"gtm",
"tag manager"
]
},
"app=core&module=settings&controller=dataLayer&tab=pageContext": {
"lang_key": "_datalayer_pageContext",
"restriction": "dataLayer_manage",
"keywords": [
"context",
"data layer context",
"data layer page context",
"datalayer context",
"datalayer page context",
"page context"
]
},
"app=core&module=settings&controller=dataLayer&tab=properties": {
"lang_key": "_datalayer_properties",
"restriction": "dataLayer_manage",
"keywords": [
"data layer properties",
"datalayer properties"
]
},
"app=core&module=settings&controller=email": {
"lang_key": "menu__core_settings_email",
"restriction": "email_manage",
@@ -1977,14 +2098,6 @@
"reports"
]
},
"app=core&module=settings&controller=general&searchResult=form_show_home_link": {
"lang_key": "show_home_link",
"restriction": "general_manage",
"keywords": [
"breadcrumb",
"navigation"
]
},
"app=core&module=settings&controller=general&searchResult=form_site_address": {
"lang_key": "site_address",
"restriction": "general_manage",
+62 -29
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<build>
<module key="admin/overview"><![CDATA[{"default_controller":"dashboard","protected":0,"default":0}]]></module>
<module key="admin/overview"><![CDATA[{"default_controller":"dashboard","protected":0,"default":1}]]></module>
<module key="admin/system"><![CDATA[{"default_controller":"login","protected":1,"default":0}]]></module>
<module key="admin/applications"><![CDATA[{"default_controller":"applications","protected":0,"default":0}]]></module>
<module key="admin/settings"><![CDATA[{"default_controller":"general","protected":0,"default":0}]]></module>
@@ -23,7 +23,6 @@
<module key="admin/activitystats"><![CDATA[{"default_controller":"overview","protected":0,"default":0}]]></module>
<module key="admin/messengerstats"><![CDATA[{"default_controller":"","protected":0,"default":0}]]></module>
<module key="admin/moderation"><![CDATA[{"default_controller":"","protected":0,"default":0}]]></module>
<module key="admin/mobile"><![CDATA[{"default_controller":"multi","protected":0,"default":0}]]></module>
<module key="admin/marketplace"><![CDATA[{"default_controller":"","protected":0,"default":0}]]></module>
<module key="admin/achievements"><![CDATA[{"default_controller":"","protected":0,"default":0}]]></module>
<module key="front/system"><![CDATA[{"default_controller":"splash","protected":1,"default":0}]]></module>
@@ -39,8 +38,7 @@
<module key="front/staffdirectory"><![CDATA[{"default_controller":"directory","protected":0,"default":0}]]></module>
<module key="front/clubs"><![CDATA[{"default_controller":"directory","protected":0,"default":0}]]></module>
<module key="front/promote"><![CDATA[{"default_controller":"ourpicks","protected":0,"default":0}]]></module>
<module key="front/activity"><![CDATA[{"default":0,"default_controller":"","protected":0}]]></module>
<module key="front/dashboard"><![CDATA[{"default":0,"default_controller":"dashboard","protected":1}]]></module>
<module key="front/referral"><![CDATA[{"default":0,"default_controller":"","protected":0}]]></module>
<task frequency="P0Y0M0DT1H0M0S">profilesync</task>
<task frequency="P0Y0M1DT0H0M0S">updatecheck</task>
<task frequency="P0Y0M1DT0H0M0S">cleanup</task>
@@ -75,6 +73,8 @@
<task frequency="P0Y0M1DT0H0M0S">chunkcleanup</task>
<task frequency="P0Y0M0DT0H15M0S">s3Delete</task>
<task frequency="P0Y0M1DT0H0M0S">pwaprune</task>
<task frequency="P0Y0M0DT0H5M0S">dailyStreamSubscriptions</task>
<task frequency="P0Y0M0DT0H5M0S">weeklyStreamSubscriptions</task>
<setting key="achievements_enabled"><![CDATA[{"key":"achievements_enabled","default":"1","report":"full"}]]></setting>
<setting key="achievements_last_rebuilt"><![CDATA[{"key":"achievements_last_rebuilt","default":"0","report":"full"}]]></setting>
<setting key="achievements_rebuilding"><![CDATA[{"key":"achievements_rebuilding","default":"0","report":"full"}]]></setting>
@@ -84,6 +84,9 @@
<setting key="acp_notes"><![CDATA[{"key":"acp_notes","default":"","report":"none"}]]></setting>
<setting key="acp_notes_updated"><![CDATA[{"key":"acp_notes_updated","default":"","report":"full"}]]></setting>
<setting key="activity_stream_rss"><![CDATA[{"key":"activity_stream_rss","default":"1","report":"full"}]]></setting>
<setting key="activity_stream_subscriptions"><![CDATA[{"key":"activity_stream_subscriptions","default":"1","report":"full"}]]></setting>
<setting key="activity_stream_subscriptions_inactive_limit"><![CDATA[{"key":"activity_stream_subscriptions_inactive_limit","default":"60","report":"full"}]]></setting>
<setting key="activity_stream_subscriptions_max"><![CDATA[{"key":"activity_stream_subscriptions_max","default":"3","report":"full"}]]></setting>
<setting key="ads_circulation"><![CDATA[{"key":"ads_circulation","default":"random","report":"full"}]]></setting>
<setting key="ads_exist"><![CDATA[{"key":"ads_exist","default":"0","report":"full"}]]></setting>
<setting key="ads_force_sidebar"><![CDATA[{"key":"ads_force_sidebar","default":"0","report":"full"}]]></setting>
@@ -134,6 +137,7 @@
<setting key="ckeditor_permissions"><![CDATA[{"key":"ckeditor_permissions","default":"{}","report":"bool"}]]></setting>
<setting key="ckeditor_toolbars"><![CDATA[{"key":"ckeditor_toolbars","default":"{\"desktop\":[{\"name\":\"row1\",\"items\":[\"Bold\",\"Italic\",\"Underline\",\"Strike\",\"-\",\"ipsLink\",\"Ipsquote\",\"ipsCode\",\"ipsEmoticon\",\"-\",\"BulletedList\",\"NumberedList\",\"-\",\"JustifyLeft\",\"JustifyCenter\",\"JustifyRight\",\"-\",\"TextColor\",\"FontSize\",\"-\",\"ipsPreview\"]},\"\\\/\"],\"tablet\":[{\"name\":\"row1\",\"items\":[\"Bold\",\"Italic\",\"Underline\",\"-\",\"ipsLink\",\"Ipsquote\",\"ipsEmoticon\",\"-\",\"BulletedList\",\"NumberedList\",\"-\",\"ipsPreview\"]},\"\\\/\"],\"phone\":[{\"name\":\"row1\",\"items\":[\"Bold\",\"Italic\",\"Underline\",\"-\",\"ipsEmoticon\",\"-\",\"ipsLink\",\"-\",\"ipsPreview\"]},\"\\\/\"]}","report":"bool"}]]></setting>
<setting key="clickjackprevention"><![CDATA[{"key":"clickjackprevention","default":"xframe","report":"full"}]]></setting>
<setting key="club_max_cover"><![CDATA[{"key":"club_max_cover","default":"-1","report":"full"}]]></setting>
<setting key="club_nodes_in_apps"><![CDATA[{"key":"club_nodes_in_apps","default":"0","report":"full"}]]></setting>
<setting key="clubs"><![CDATA[{"key":"clubs","default":"0","report":"full"}]]></setting>
<setting key="clubs_allow_view_change"><![CDATA[{"key":"clubs_allow_view_change","default":"1","report":"full"}]]></setting>
@@ -158,7 +162,18 @@
<setting key="coppa_consent_extra"><![CDATA[{"key":"coppa_consent_extra","default":"","report":"bool"}]]></setting>
<setting key="coppa_fax"><![CDATA[{"key":"coppa_fax","default":"","report":"bool"}]]></setting>
<setting key="copyright_line"><![CDATA[{"key":"copyright_line","default":"","report":"bool"}]]></setting>
<setting key="core_datalayer_enabled"><![CDATA[{"key":"core_datalayer_enabled","default":"0","report":"none"}]]></setting>
<setting key="core_datalayer_events"><![CDATA[{"key":"core_datalayer_events","default":"{}","report":"none"}]]></setting>
<setting key="core_datalayer_gtmkey"><![CDATA[{"key":"core_datalayer_gtmkey","default":"window.dataLayer","report":"none"}]]></setting>
<setting key="core_datalayer_include_pii"><![CDATA[{"key":"core_datalayer_include_pii","default":"0","report":"none"}]]></setting>
<setting key="core_datalayer_member_pii_choice"><![CDATA[{"key":"core_datalayer_member_pii_choice","default":"0","report":"none"}]]></setting>
<setting key="core_datalayer_pii"><![CDATA[{"key":"core_datalayer_pii","default":"0","report":"none"}]]></setting>
<setting key="core_datalayer_properties"><![CDATA[{"key":"core_datalayer_properties","default":"{}","report":"none"}]]></setting>
<setting key="core_datalayer_replace_with_sso"><![CDATA[{"key":"core_datalayer_replace_with_sso","default":"0","report":"none"}]]></setting>
<setting key="core_datalayer_use_gtm"><![CDATA[{"key":"core_datalayer_use_gtm","default":"1","report":"none"}]]></setting>
<setting key="csp_header"><![CDATA[{"key":"csp_header","default":"","report":"bool"}]]></setting>
<setting key="custom_body_code"><![CDATA[{"key":"custom_body_code","default":"","report":"none"}]]></setting>
<setting key="custom_page_view_js"><![CDATA[{"key":"custom_page_view_js","default":"","report":"none"}]]></setting>
<setting key="dellog_retention_period"><![CDATA[{"key":"dellog_retention_period","default":"30","report":"full"}]]></setting>
<setting key="device_management"><![CDATA[{"key":"device_management","default":"1","report":"full"}]]></setting>
<setting key="diagnostics"><![CDATA[{"key":"diagnostics","default":"1","report":"full"}]]></setting>
@@ -174,6 +189,8 @@
<setting key="editor_paragraph_padding"><![CDATA[{"key":"editor_paragraph_padding","default":"1","report":"full"}]]></setting>
<setting key="editor_paste_behaviour"><![CDATA[{"key":"editor_paste_behaviour","default":"rich","report":"full"}]]></setting>
<setting key="email_color"><![CDATA[{"key":"email_color","default":"#177ec9","report":"bool"}]]></setting>
<setting key="email_filter_action"><![CDATA[{"key":"email_filter_action","default":"allow","report":"full"}]]></setting>
<setting key="email_filter_replace_text"><![CDATA[{"key":"email_filter_replace_text","default":"*****@*****.tld","report":"bool"}]]></setting>
<setting key="email_in"><![CDATA[{"key":"email_in","default":"","report":"bool"}]]></setting>
<setting key="email_logo"><![CDATA[{"key":"email_logo","default":"","report":"bool"}]]></setting>
<setting key="email_out"><![CDATA[{"key":"email_out","default":"","report":"bool"}]]></setting>
@@ -197,6 +214,8 @@
<setting key="flood_control"><![CDATA[{"key":"flood_control","default":"5","report":"full"}]]></setting>
<setting key="force_reg_terms"><![CDATA[{"key":"force_reg_terms","default":"0","report":"full"}]]></setting>
<setting key="furl_configuration"><![CDATA[{"key":"furl_configuration","default":"","report":"bool"}]]></setting>
<setting key="ga_code"><![CDATA[{"key":"ga_code","default":"","report":"none"}]]></setting>
<setting key="ga_enabled"><![CDATA[{"key":"ga_enabled","default":"0","report":"full"}]]></setting>
<setting key="giphy_apikey"><![CDATA[{"key":"giphy_apikey","default":"","report":"none"}]]></setting>
<setting key="giphy_apikey_default"><![CDATA[{"key":"giphy_apikey_default","default":"N74I5NtWXp00t2lOwOQn3XunASrJ9wLV","report":"none"}]]></setting>
<setting key="giphy_enabled"><![CDATA[{"key":"giphy_enabled","default":"","report":"full"}]]></setting>
@@ -210,13 +229,19 @@
<setting key="googleauth_groups"><![CDATA[{"key":"googleauth_groups","default":"*","report":"bool"}]]></setting>
<setting key="googlemaps"><![CDATA[{"key":"googlemaps","default":"1","report":"full"}]]></setting>
<setting key="googleplacesautocomplete"><![CDATA[{"key":"googleplacesautocomplete","default":"1","report":"full"}]]></setting>
<setting key="googletag_enabled"><![CDATA[{"key":"googletag_enabled","default":"0","report":"full"}]]></setting>
<setting key="googletag_head_code"><![CDATA[{"key":"googletag_head_code","default":"","report":"none"}]]></setting>
<setting key="googletag_noscript_code"><![CDATA[{"key":"googletag_noscript_code","default":"","report":"none"}]]></setting>
<setting key="group_formatting"><![CDATA[{"key":"group_formatting","default":"global","report":"full"}]]></setting>
<setting key="guest_captcha"><![CDATA[{"key":"guest_captcha","default":"1","report":"full"}]]></setting>
<setting key="guest_terms_bar"><![CDATA[{"key":"guest_terms_bar","default":"0","report":"full"}]]></setting>
<setting key="hcaptcha_secret"><![CDATA[{"key":"hcaptcha_secret","default":"","report":"none"}]]></setting>
<setting key="hcaptcha_sitekey"><![CDATA[{"key":"hcaptcha_sitekey","default":"","report":"bool"}]]></setting>
<setting key="htaccess_mod_rewrite"><![CDATA[{"key":"htaccess_mod_rewrite","default":"0","report":"full"}]]></setting>
<setting key="icons_apple_startup"><![CDATA[{"key":"icons_apple_startup","default":"","report":"bool"}]]></setting>
<setting key="icons_favicon"><![CDATA[{"key":"icons_favicon","default":"","report":"bool"}]]></setting>
<setting key="icons_homescreen"><![CDATA[{"key":"icons_homescreen","default":"","report":"bool"}]]></setting>
<setting key="icons_homescreen_maskable"><![CDATA[{"key":"icons_homescreen_maskable","default":"","report":"bool"}]]></setting>
<setting key="icons_mask_color"><![CDATA[{"key":"icons_mask_color","default":"FFFFFF","report":"bool"}]]></setting>
<setting key="icons_mask_icon"><![CDATA[{"key":"icons_mask_icon","default":"","report":"bool"}]]></setting>
<setting key="icons_sharer_logo"><![CDATA[{"key":"icons_sharer_logo","default":"","report":"bool"}]]></setting>
@@ -225,6 +250,8 @@
<setting key="image_png_quality_gd"><![CDATA[{"key":"image_png_quality_gd","default":"9","report":"full"}]]></setting>
<setting key="image_suite"><![CDATA[{"key":"image_suite","default":"imagemagick","report":"full"}]]></setting>
<setting key="imagick_strip_exif"><![CDATA[{"key":"imagick_strip_exif","default":"1","report":"full"}]]></setting>
<setting key="indexnow_enabled"><![CDATA[{"key":"indexnow_enabled","default":"0","report":"full"}]]></setting>
<setting key="indexnow_key"><![CDATA[{"key":"indexnow_key","default":"","report":"bool"}]]></setting>
<setting key="ip_address_prune"><![CDATA[{"key":"ip_address_prune","default":"","report":"full"}]]></setting>
<setting key="ipb_bruteforce_attempts"><![CDATA[{"key":"ipb_bruteforce_attempts","default":"3","report":"full"}]]></setting>
<setting key="ipb_bruteforce_period"><![CDATA[{"key":"ipb_bruteforce_period","default":"15","report":"full"}]]></setting>
@@ -235,9 +262,6 @@
<setting key="ipb_url_blacklist"><![CDATA[{"key":"ipb_url_blacklist","default":"","report":"bool"}]]></setting>
<setting key="ipb_url_filter_option"><![CDATA[{"key":"ipb_url_filter_option","default":"none","report":"full"}]]></setting>
<setting key="ipb_url_whitelist"><![CDATA[{"key":"ipb_url_whitelist","default":"","report":"bool"}]]></setting>
<setting key="ipbseo_ga_enabled"><![CDATA[{"key":"ipbseo_ga_enabled","default":"1","report":"full"}]]></setting>
<setting key="ipbseo_ga_paginatecode"><![CDATA[{"key":"ipbseo_ga_paginatecode","default":"","report":"bool"}]]></setting>
<setting key="ipbseo_ga_provider"><![CDATA[{"key":"ipbseo_ga_provider","default":"none","report":"full"}]]></setting>
<setting key="ips_cp_purchase"><![CDATA[{"key":"ips_cp_purchase","default":"0","report":"full"}]]></setting>
<setting key="ipseo_ga"><![CDATA[{"key":"ipseo_ga","default":"","report":"bool"}]]></setting>
<setting key="ipsgeoip"><![CDATA[{"key":"ipsgeoip","default":"1","report":"full"}]]></setting>
@@ -258,6 +282,8 @@
<setting key="mapbox_api_key"><![CDATA[{"key":"mapbox_api_key","default":"","report":"none"}]]></setting>
<setting key="match_browser"><![CDATA[{"key":"match_browser","default":"0","report":"full"}]]></setting>
<setting key="match_ipaddress"><![CDATA[{"key":"match_ipaddress","default":"1","report":"full"}]]></setting>
<setting key="matomo_code"><![CDATA[{"key":"matomo_code","default":"","report":"none"}]]></setting>
<setting key="matomo_enabled"><![CDATA[{"key":"matomo_enabled","default":"0","report":"full"}]]></setting>
<setting key="max_internalembed_width"><![CDATA[{"key":"max_internalembed_width","default":"500","report":"full"}]]></setting>
<setting key="max_internalembed_width_css"><![CDATA[{"key":"max_internalembed_width_css","default":"none","report":"none"}]]></setting>
<setting key="max_poll_choices"><![CDATA[{"key":"max_poll_choices","default":"20","report":"full"}]]></setting>
@@ -276,22 +302,12 @@
<setting key="mfa_required_prompt"><![CDATA[{"key":"mfa_required_prompt","default":"immediate","report":"full"}]]></setting>
<setting key="min_user_name_length"><![CDATA[{"key":"min_user_name_length","default":"3","report":"full"}]]></setting>
<setting key="minimum_age"><![CDATA[{"key":"minimum_age","default":"0","report":"full"}]]></setting>
<setting key="mobile_app_home_blocks_order"><![CDATA[{"key":"mobile_app_home_blocks_order","default":"{\"new_content\":true,\"active_users\":true,\"our_picks\":true,\"popular_contributors\":true}","report":"bool"}]]></setting>
<setting key="mobile_app_id"><![CDATA[{"key":"mobile_app_id","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_itunes_id"><![CDATA[{"key":"mobile_app_itunes_id","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_itunes_url"><![CDATA[{"key":"mobile_app_itunes_url","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_play_id"><![CDATA[{"key":"mobile_app_play_id","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_play_url"><![CDATA[{"key":"mobile_app_play_url","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_prompt"><![CDATA[{"key":"mobile_app_prompt","default":"0","report":"full"}]]></setting>
<setting key="mobile_app_redirect_scheme"><![CDATA[{"key":"mobile_app_redirect_scheme","default":"","report":"bool"}]]></setting>
<setting key="mobile_app_secret"><![CDATA[{"key":"mobile_app_secret","default":"","report":"none"}]]></setting>
<setting key="most_online"><![CDATA[{"key":"most_online","default":"{\"count\":0,\"time\":0}","report":"none"}]]></setting>
<setting key="mp_onboard_complete"><![CDATA[{"key":"mp_onboard_complete","default":"1","report":"none"}]]></setting>
<setting key="new_device_email"><![CDATA[{"key":"new_device_email","default":"0","report":"full"}]]></setting>
<setting key="new_reg_notify"><![CDATA[{"key":"new_reg_notify","default":"0","report":"full"}]]></setting>
<setting key="notification_prefs_one_per_view"><![CDATA[{"key":"notification_prefs_one_per_view","default":"0","report":"full"}]]></setting>
<setting key="notification_prefs_popup"><![CDATA[{"key":"notification_prefs_popup","default":"0","report":"full"}]]></setting>
<setting key="notification_prefs_sound"><![CDATA[{"key":"notification_prefs_sound","default":"1","report":"full"}]]></setting>
<setting key="onboard_complete"><![CDATA[{"key":"onboard_complete","default":"0","report":"none"}]]></setting>
<setting key="orig_tables_checked"><![CDATA[{"key":"orig_tables_checked","default":"0","report":"none"}]]></setting>
<setting key="our_picks_in_email"><![CDATA[{"key":"our_picks_in_email","default":"1","report":"none"}]]></setting>
@@ -370,6 +386,7 @@
<setting key="reputation_top_members_filters"><![CDATA[{"key":"reputation_top_members_filters","default":"*","report":"bool"}]]></setting>
<setting key="reputation_top_members_overview"><![CDATA[{"key":"reputation_top_members_overview","default":"pp_reputation_points,member_posts","report":"full"}]]></setting>
<setting key="reviews_rating_out_of"><![CDATA[{"key":"reviews_rating_out_of","default":"5","report":"full"}]]></setting>
<setting key="robots_txt"><![CDATA[{"key":"robots_txt","default":"default","report":"bool"}]]></setting>
<setting key="rules_exclude_groups"><![CDATA[{"key":"rules_exclude_groups","default":"[]","report":"none"}]]></setting>
<setting key="search_decay_days"><![CDATA[{"key":"search_decay_days","default":"120","report":"full"}]]></setting>
<setting key="search_decay_factor"><![CDATA[{"key":"search_decay_factor","default":"0.5","report":"full"}]]></setting>
@@ -383,6 +400,7 @@
<setting key="search_index_timeframe"><![CDATA[{"key":"search_index_timeframe","default":"0","report":"full"}]]></setting>
<setting key="search_method"><![CDATA[{"key":"search_method","default":"mysql","report":"full"}]]></setting>
<setting key="search_title_boost"><![CDATA[{"key":"search_title_boost","default":"5","report":"full"}]]></setting>
<setting key="searchlog_exclude_groups"><![CDATA[{"key":"searchlog_exclude_groups","default":"[2]","report":"bool"}]]></setting>
<setting key="security_questions_areas"><![CDATA[{"key":"security_questions_areas","default":"","report":"bool"}]]></setting>
<setting key="security_questions_enabled"><![CDATA[{"key":"security_questions_enabled","default":"0","report":"full"}]]></setting>
<setting key="security_questions_groups"><![CDATA[{"key":"security_questions_groups","default":"*","report":"bool"}]]></setting>
@@ -400,9 +418,12 @@
<setting key="signatures_guests"><![CDATA[{"key":"signatures_guests","default":"0","report":"full"}]]></setting>
<setting key="signatures_mobile"><![CDATA[{"key":"signatures_mobile","default":"0","report":"full"}]]></setting>
<setting key="site_address"><![CDATA[{"key":"site_address","default":"","report":"bool"}]]></setting>
<setting key="site_main_title"><![CDATA[{"key":"site_main_title","default":"","report":"bool"}]]></setting>
<setting key="site_main_url"><![CDATA[{"key":"site_main_url","default":"","report":"bool"}]]></setting>
<setting key="site_offline_message"><![CDATA[{"key":"site_offline_message","default":"","report":"bool"}]]></setting>
<setting key="site_online"><![CDATA[{"key":"site_online","default":"1","report":"full"}]]></setting>
<setting key="site_secret_key"><![CDATA[{"key":"site_secret_key","default":"","report":"none"}]]></setting>
<setting key="site_site_elsewhere"><![CDATA[{"key":"site_site_elsewhere","default":"0","report":"full"}]]></setting>
<setting key="site_social_profiles"><![CDATA[{"key":"site_social_profiles","default":"","report":"bool"}]]></setting>
<setting key="site_twitter_id"><![CDATA[{"key":"site_twitter_id","default":"","report":"bool"}]]></setting>
<setting key="sitemap_content_settings"><![CDATA[{"key":"sitemap_content_settings","default":"{}","report":"bool"}]]></setting>
@@ -458,6 +479,7 @@
<setting key="theme_designers_mode"><![CDATA[{"key":"theme_designers_mode","default":"0","report":"full"}]]></setting>
<setting key="theme_disk_cache_path"><![CDATA[{"key":"theme_disk_cache_path","default":"","report":"none"}]]></setting>
<setting key="theme_disk_cache_templates"><![CDATA[{"key":"theme_disk_cache_templates","default":"0","report":"full"}]]></setting>
<setting key="theme_editing_advanced_mode"><![CDATA[{"key":"theme_editing_advanced_mode","default":"0","report":"full"}]]></setting>
<setting key="topic_redirect_prune"><![CDATA[{"key":"topic_redirect_prune","default":"30","report":"full"}]]></setting>
<setting key="twitter_hashtag"><![CDATA[{"key":"twitter_hashtag","default":"","report":"bool"}]]></setting>
<setting key="updates_consent_default"><![CDATA[{"key":"updates_consent_default","default":"enabled","report":"full"}]]></setting>
@@ -511,14 +533,17 @@
<acpsearch key="app=core&amp;module=achievements&amp;controller=settings"><![CDATA[{"lang_key":"menu__core_achievements_settings","restriction":"settings_manage","keywords":["achievement","badge","rare badge"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=activitystats&amp;controller=communityactivity"><![CDATA[{"lang_key":"menu__core_activitystats_communityactivity","restriction":null,"keywords":["active members","activity","community activity","member activity","new posts"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=activitystats&amp;controller=keywords"><![CDATA[{"lang_key":"menu__core_activitystats_keywords","restriction":null,"keywords":["keyword tracking","keywords","tracking"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api"><![CDATA[{"lang_key":"menu__core_applications_api","restriction":"api_manage","keywords":["api","rest api"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api"><![CDATA[{"lang_key":"menu__core_applications_api","restriction":"api_manage","keywords":["api","rest api","webhook"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api&amp;tab=apiKeys"><![CDATA[{"lang_key":"api_keys","restriction":"api_manage","keywords":["api keys"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api&amp;tab=apiLogs"><![CDATA[{"lang_key":"api_logs","restriction":"api_logs","keywords":["api logs"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api&amp;tab=apiReference"><![CDATA[{"lang_key":"api_reference","restriction":"api_reference","keywords":["api documentation","api reference"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api&amp;tab=webhooks"><![CDATA[{"lang_key":"webhooks","restriction":"api_splash","keywords":["webhook"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=api&amp;tab=webhooks&amp;do=settings&amp;searchResult=webhook_logs_success"><![CDATA[{"lang_key":"webhook_logs_success","restriction":"api_splash","keywords":["webhook"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=applications"><![CDATA[{"lang_key":"menu__core_applications_applications","restriction":"app_manage","keywords":["applications","install","modules","offline","online"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements"><![CDATA[{"lang_key":"menu__core_applications_enhancements","restriction":"enhancements_manage","keywords":["bulk mail","email","enhancements","geo","giphy","maps","maxmind","sendgrid","spam","viglink","zapier"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements"><![CDATA[{"lang_key":"menu__core_applications_enhancements","restriction":"enhancements_manage","keywords":["analytics","bulk mail","easypost","email","enhancements","enom","geo","giphy","indexnow","mapbox","maps","matomo","maxmind","omniture","piwik","pixabay","sendgrid","spam","tag manager","viglink","zapier"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;id=core_FacebookPixel"><![CDATA[{"lang_key":"menu__core_applications_enhancements","restriction":"enhancements_manage","keywords":["facebook","facebook pixel","pixel"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;id=core_GoogleMaps&amp;searchResult=form_googlemaps"><![CDATA[{"lang_key":"googlemaps","restriction":"enhancements_manage","keywords":["google","maps"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;id=core_ImageScanner"><![CDATA[{"lang_key":"menu__core_applications_enhancements","restriction":"enhancements_manage","keywords":["adult images","disturbing image filters","disturbing images filters","gore filters","gore image filters","gore images filters","image filters","image scanner","inappropriate image filters","inappropriate images filters","porn filters","porn images","pornographic images","violence filters","violent image filters","violent images filters"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;id=core_Pixabay"><![CDATA[{"lang_key":"menu__core_applications_enhancements","restriction":"enhancements_manage","keywords":["photos","pixabay","stock","stock photo"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;id=core_Viglink&amp;searchResult=form_viglink_account_type"><![CDATA[{"lang_key":"viglink_account_type","restriction":"enhancements_manage","keywords":["advertising","viglink"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=applications&amp;controller=enhancements&amp;do=edit&amp;searchResult=pixabay_apikey"><![CDATA[{"lang_key":"pixabay_apikey","restriction":"enhancements_manage","keywords":["pixabay"]}]]></acpsearch>
@@ -542,6 +567,7 @@
<acpsearch key="app=core&amp;module=discovery&amp;controller=search"><![CDATA[{"lang_key":"menu__core_discovery_search","restriction":"search_manage","keywords":["rebuild search","rebuild search index","reindex","reindex search","reindex search results","search","search index","search index rebuild","searching"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=discovery&amp;controller=search&amp;searchResult=form_search_method"><![CDATA[{"lang_key":"search_method","restriction":"search_manage","keywords":["elastic","elasticsearch","mysql","search"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=discovery&amp;controller=search&amp;searchResult=search_index_timeframe"><![CDATA[{"lang_key":"search_index_timeframe","restriction":"search_manage","keywords":["search","search content","search cutoff","search limit","search results"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=discovery&amp;controller=streams&amp;do=allActivitySettings"><![CDATA[{"lang_key":"menu__core_discovery_streams","restriction":"streams_manage","keywords":["stream subscriptions","streams"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=emoticons"><![CDATA[{"lang_key":"menu__core_editor_emoticons","restriction":"emoticons_manage","keywords":["emoticons","smileys","smilies"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=emoticons&amp;tab=custom"><![CDATA[{"lang_key":"custom_emoji","restriction":"emoticons_manage","keywords":["emoticon","smiley","smilie"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=emoticons&amp;tab=standard"><![CDATA[{"lang_key":"standard_emoji","restriction":"emoticons_manage","keywords":["emoji"]}]]></acpsearch>
@@ -549,15 +575,11 @@
<acpsearch key="app=core&amp;module=editor&amp;controller=settings&amp;searchResult=form_editor_paragraph_padding"><![CDATA[{"lang_key":"editor_paragraph_padding","restriction":"settings_manage","keywords":["enter","paragraph","return"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=settings&amp;searchResult=form_editor_paste_behaviour"><![CDATA[{"lang_key":"editor_paste_behaviour","restriction":"settings_manage","keywords":["formatting","paste","posting","remove"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=settings&amp;searchResult=form_enable_bbcode"><![CDATA[{"lang_key":"enable_bbcode","restriction":"settings_manage","keywords":["bbcode","parse"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=storedreplies"><![CDATA[{"lang_key":"menu__core_editor_storedreplies","restriction":"stored_replies_manage","keywords":["stock replies"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=editor&amp;controller=toolbar"><![CDATA[{"lang_key":"editor_customization","restriction":"toolbar_manage","keywords":["bbcode","buttons","ckeditor","comment","editor","mobile","phone","plugins","post","responsive","tablet","toolbars","wysiwyg"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=languages&amp;controller=languages"><![CDATA[{"lang_key":"menu__core_languages_languages","restriction":null,"keywords":["languages","locales","translate","translations"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=languages&amp;controller=languages&amp;do=settings&amp;searchResult=form_lang_auto_detect"><![CDATA[{"lang_key":"lang_auto_detect","restriction":"lang_words","keywords":["detection","language"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups"><![CDATA[{"lang_key":"menu__core_members_groups","restriction":"groups_manage","keywords":["groups"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_promote_exclude"><![CDATA[{"lang_key":"g_promote_exclude","restriction":"groups_manage","keywords":["group promotion","member promotions","member upgrades"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_upload_animated_photos"><![CDATA[{"lang_key":"g_upload_animated_photos","restriction":"groups_manage","keywords":["animated","photos"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_can_post_anonymously"><![CDATA[{"lang_key":"can_post_anonymously","restriction":"groups_manage","keywords":["anonymous","anonymously"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_hide_group"><![CDATA[{"lang_key":"gbw_hide_group","restriction":"groups_manage","keywords":["allow filtering","online users","search"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_post_highlight"><![CDATA[{"lang_key":"gbw_post_highlight","restriction":"groups_manage","keywords":["background","highlight","highlight post","replies"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_access_offline"><![CDATA[{"lang_key":"g_access_offline","restriction":"groups_manage","keywords":["offline access","site offline"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_append_edit"><![CDATA[{"lang_key":"g_append_edit","restriction":"groups_manage","keywords":["edit","silent edit"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_attach"><![CDATA[{"lang_key":"g_attach","restriction":"groups_manage","keywords":["attachments","uploads"]}]]></acpsearch>
@@ -585,6 +607,7 @@
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_ppd_limit"><![CDATA[{"lang_key":"g_ppd_limit","restriction":"groups_manage","keywords":["content restriction","max content","max posts","per day","positing limit","positing restriction"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_ppd_unit"><![CDATA[{"lang_key":"g_ppd_unit","restriction":"groups_manage","keywords":["positing limit"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_prefixsuffix"><![CDATA[{"lang_key":"g_prefixsuffix","restriction":"groups_manage","keywords":["group color","group colour","group formatting"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_promote_exclude"><![CDATA[{"lang_key":"g_promote_exclude","restriction":"groups_manage","keywords":["group promotion","member promotions","member upgrades"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_rep_max_positive"><![CDATA[{"lang_key":"g_rep_max_positive","restriction":"groups_manage","keywords":["karma","like","reputation"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_search_flood"><![CDATA[{"lang_key":"g_search_flood","restriction":"groups_manage","keywords":["search flood control"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_sig_max_image_size"><![CDATA[{"lang_key":"g_sig_max_image_size","restriction":"groups_manage","keywords":["signature images","signatures"]}]]></acpsearch>
@@ -592,16 +615,20 @@
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_sig_max_lines"><![CDATA[{"lang_key":"g_sig_max_lines","restriction":"groups_manage","keywords":["signature length","signature size","signature text","signatures"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_sig_max_urls"><![CDATA[{"lang_key":"g_sig_max_urls","restriction":"groups_manage","keywords":["signature links","signatures"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_topic_rate_setting"><![CDATA[{"lang_key":"g_topic_rate_setting","restriction":"groups_manage","keywords":["rate","ratings"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_upload_animated_photos"><![CDATA[{"lang_key":"g_upload_animated_photos","restriction":"groups_manage","keywords":["animated","photos"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_use_signatures"><![CDATA[{"lang_key":"g_use_signatures","restriction":"groups_manage","keywords":["signatures"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_view_board"><![CDATA[{"lang_key":"g_view_board","restriction":"groups_manage","keywords":["access","allowed to enter community","allowed to enter site","allowed to view community","allowed to view site","ban","user access site"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=g_vote_polls"><![CDATA[{"lang_key":"g_vote_polls","restriction":"groups_manage","keywords":["polls"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_allow_upload_bgimage"><![CDATA[{"lang_key":"gbw_allow_upload_bgimage","restriction":"groups_manage","keywords":["cover photo","profile cover photo"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_can_post_anonymously"><![CDATA[{"lang_key":"can_post_anonymously","restriction":"groups_manage","keywords":["anonymous","anonymously"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_cannot_be_ignored"><![CDATA[{"lang_key":"can_be_ignored","restriction":"groups_manage","keywords":["ignore","ignored users"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_delete_attachments"><![CDATA[{"lang_key":"gbw_delete_attachments","restriction":"groups_manage","keywords":["attachments","delete attachments","uploads"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_disable_prefixes"><![CDATA[{"lang_key":"gbw_disable_prefixes","restriction":"groups_manage","keywords":["prefixes","tagging","tags"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_disable_tagging"><![CDATA[{"lang_key":"gbw_disable_tagging","restriction":"groups_manage","keywords":["tagging","tags"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_hide_group"><![CDATA[{"lang_key":"gbw_hide_group","restriction":"groups_manage","keywords":["allow filtering","online users","search"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_no_status_import"><![CDATA[{"lang_key":"gbw_no_status_import","restriction":"groups_manage","keywords":["facebook status","profile status","status updates","statuses","twitter status"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_no_status_update"><![CDATA[{"lang_key":"gbw_no_status_update","restriction":"groups_manage","keywords":["profile status","status updates","statuses"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_post_highlight"><![CDATA[{"lang_key":"gbw_post_highlight","restriction":"groups_manage","keywords":["background","highlight","highlight post","replies"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=gbw_view_reps"><![CDATA[{"lang_key":"gbw_view_reps","restriction":"groups_manage","keywords":["karma","like","reputation"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=groups&amp;searchResult=group_username"><![CDATA[{"lang_key":"group_username","restriction":"groups_manage","keywords":["display name changes","name changes","user name changes","username changes"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=ip"><![CDATA[{"lang_key":"menu__core_members_ip","restriction":"membertools_ip","keywords":["address","IP","lookup"]}]]></acpsearch>
@@ -613,7 +640,6 @@
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_ips_member_name"><![CDATA[{"lang_key":"ips_member_name","restriction":null,"keywords":["Display Name"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_member_content_items"><![CDATA[{"lang_key":"member_content_items","restriction":null,"keywords":["Content Item","Recount"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_member_reputation"><![CDATA[{"lang_key":"member_reputation","restriction":null,"keywords":["Recount","Reputation Level"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_member_title"><![CDATA[{"lang_key":"member_title","restriction":null,"keywords":["Member Title"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_member_warnings"><![CDATA[{"lang_key":"member_warnings","restriction":null,"keywords":["Warning Points"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_password"><![CDATA[{"lang_key":"password","restriction":null,"keywords":["Change Password","Password"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=members&amp;controller=members&amp;searchResult=form_secondary_groups"><![CDATA[{"lang_key":"secondary_groups","restriction":null,"keywords":["Secondary Groups"]}]]></acpsearch>
@@ -625,7 +651,6 @@
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=edit&amp;id=core_BulkMails"><![CDATA[{"lang_key":"notifications__core_BulkMails","restriction":"notifications_manage","keywords":["bulk mails","gdpr","mailing list","news and updates","news list","newsletter"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=edit&amp;id=core_Content"><![CDATA[{"lang_key":"notifications__core_Content","restriction":"notifications_manage","keywords":["automatically follow","email limit","follow","followed content","followed members","limit emails"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=edit&amp;id=core_Messenger"><![CDATA[{"lang_key":"notifications__core_Messenger","restriction":"notifications_manage","keywords":["messenger pop up window","messenger popup window","pm pop up window","pm popup window"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=method&amp;id=inline&amp;searchResult=notification_prefs_sound"><![CDATA[{"lang_key":"notification_prefs_sound","restriction":"notifications_manage","keywords":["notification sounds"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=pruneSettings&amp;searchResult=form_prune_notifications"><![CDATA[{"lang_key":"prune_notifications","restriction":"notifications_prune","keywords":["notifications","prune"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=notifications&amp;do=pruneSettings&amp;searchResult=prune_follows"><![CDATA[{"lang_key":"prune_follows","restriction":"notifications_prune","keywords":["follow","prune"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=profiles"><![CDATA[{"lang_key":"profile_fields","restriction":"profiles_manage","keywords":["custom fields","custom profile","custom profile fields","edit fields","edit profile fields","profile fields"]}]]></acpsearch>
@@ -659,10 +684,10 @@
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;searchResult=reputation_show_content"><![CDATA[{"lang_key":"reputation_show_content","restriction":"reps_settings","keywords":["show likes","show reputation"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;searchResult=reputation_show_days_won_trophy"><![CDATA[{"lang_key":"reputation_show_days_won_trophy","restriction":"reps_manage","keywords":["days won"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;searchResult=reputation_show_profile"><![CDATA[{"lang_key":"reputation_show_profile","restriction":"reps_manage","keywords":["show likes","show reputation"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;searchResult=reputation_timezone"><![CDATA[{"lang_key":"reputation_timezone","restriction":"reps_manage","keywords":["leaderboard","timezone"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;tab=leaderboard&amp;searchResult=reputation_leaderboard_on"><![CDATA[{"lang_key":"reputation_leaderboard_on","restriction":"reps_manage","keywords":["leaderboard"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;tab=leaderboard&amp;searchResult=reputation_max_members"><![CDATA[{"lang_key":"reputation_top_members_overview","restriction":"reps_manage","keywords":["top members"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;tab=leaderboard&amp;searchResult=reputation_show_days_won_trophy"><![CDATA[{"lang_key":"reputation_show_days_won_trophy","restriction":"reps_manage","keywords":["leaderboard","winner"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=membersettings&amp;controller=reputation&amp;tab=leaderboard&amp;searchResult=reputation_timezone"><![CDATA[{"lang_key":"reputation_timezone","restriction":"reps_manage","keywords":["leaderboard","timezone"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=messengerstats&amp;controller=pmstats"><![CDATA[{"lang_key":"menu__core_members_pmstats","restriction":null,"keywords":["message statistics","Messenger Statistics","private messages"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=moderation&amp;controller=reportedContent"><![CDATA[{"lang_key":"menu__core_moderation_reportedContent","restriction":"reportedContent_manage","keywords":["moderation","report","report types"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=moderation&amp;controller=reportedContentTypes"><![CDATA[{"lang_key":"menu__core_moderation_reportedContentTypes","restriction":null,"keywords":["report","report types"]}]]></acpsearch>
@@ -683,9 +708,9 @@
<acpsearch key="app=core&amp;module=overview&amp;controller=files&amp;do=imagesettings"><![CDATA[{"lang_key":"image_settings","restriction":"files_view","keywords":["gd","imagemagick"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=overview&amp;controller=files&amp;do=imagesettings&amp;searchResult=form_image_jpg_quality"><![CDATA[{"lang_key":"image_jpg_quality","restriction":"files_view","keywords":["jpeg","jpg"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=overview&amp;controller=files&amp;do=imagesettings&amp;searchResult=image_png_quality_gd"><![CDATA[{"lang_key":"image_png_quality_gd","restriction":"files_view","keywords":["png"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=overview&amp;controller=files&amp;do=imagesettings&amp;searchResult=imagick_strip_exif"><![CDATA[{"lang_key":"imagick_strip_exif","restriction":"files_view","keywords":["exif"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=overview&amp;controller=files&amp;do=settings"><![CDATA[{"lang_key":"menu__core_overview_files","restriction":"files_view","keywords":["amazon","files","ftp","photos","storage","uploads"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=advertisements"><![CDATA[{"lang_key":"menu__core_promotion_advertisements","restriction":"advertisements_manage","keywords":["ads","adsense","advertisements","adverts","adwords","google"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=analytics"><![CDATA[{"lang_key":"ipbseo_ga_enabled","restriction":"analytics_manage","keywords":["analytics","ga","google","google analytics","omniture","piwik","tracking"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=promote"><![CDATA[{"lang_key":"menu__core_promotion_promote","restriction":"promote_manage","keywords":["promote","promotion","sharing","social media"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=promote&amp;tab=facebook"><![CDATA[{"lang_key":"promote_tab_facebook","restriction":"promote_manage","keywords":["facebook"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=promote&amp;tab=internal"><![CDATA[{"lang_key":"promote_tab_internal","restriction":"promote_manage","keywords":["our picks"]}]]></acpsearch>
@@ -695,6 +720,8 @@
<acpsearch key="app=core&amp;module=promotion&amp;controller=promote&amp;tab=twitter"><![CDATA[{"lang_key":"promote_tab_twitter","restriction":"promote_manage","keywords":["twitter"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo"><![CDATA[{"lang_key":"menu__core_promotion_seo","restriction":"seo_manage","keywords":["analytics","furl","search","search engine optimization","seo"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo&amp;tab=metatags"><![CDATA[{"lang_key":"seo_tab_metatags","restriction":"seo_meta","keywords":["description","keywords","meta tags","robots"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo&amp;tab=robotstxt"><![CDATA[{"lang_key":"seo_tab_robotstxt","restriction":null,"keywords":["crawl","robots","robots.txt","seo"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo&amp;tab=robotstxt&amp;searchResult=use_robotstxt"><![CDATA[{"lang_key":"use_robotstxt","restriction":null,"keywords":["robots","robots.txt"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo&amp;tab=sitemap"><![CDATA[{"lang_key":"seo_tab_sitemap","restriction":"seo_sitemap","keywords":["google","priority","site map","sitemap","xml"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=seo&amp;tab=urls"><![CDATA[{"lang_key":"seo_tab_furls","restriction":"seo_furls","keywords":["friendly url","furls","htaccess","mod_rewrite","urls"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=promotion&amp;controller=sharelinks"><![CDATA[{"lang_key":"menu__core_promotion_sharelinks","restriction":"sharelinks_manage","keywords":["facebook","linkedin","reddit","share links","stumbleupon","twitter"]}]]></acpsearch>
@@ -706,10 +733,17 @@
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=datastore&amp;searchResult=cache_method"><![CDATA[{"lang_key":"cache_method","restriction":"datastore","keywords":["apc","memcached","redis","wincache","xcache"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=furl"><![CDATA[{"lang_key":"furls_customize","restriction":"advanced_manage_furls","keywords":["friendly","furl","seo"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=settings&amp;searchResult=form_clickjackprevention"><![CDATA[{"lang_key":"clickjackprevention","restriction":"advanced_manage","keywords":["clickjacking","content-security-policy","csp","iframe","x-frame-options"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=settings&amp;searchResult=form_widget_cache_ttl"><![CDATA[{"lang_key":"widget_cache_ttl","restriction":"advanced_manage","keywords":["cache"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=settings&amp;searchResult=match_ipaddress"><![CDATA[{"lang_key":"match_ipaddress","restriction":"security_manage","keywords":["ip address","session"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=settings&amp;searchResult=task_use_cron"><![CDATA[{"lang_key":"task_use_cron","restriction":"advanced_manage_server","keywords":["cron job","cronjob","tasks"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=advanced&amp;tab=settings&amp;searchResult=xforward_matching"><![CDATA[{"lang_key":"xforward_matching","restriction":"security_manage","keywords":["http_x_forwarded_for","ip address","proxies","proxy"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=contactus"><![CDATA[{"lang_key":"menu__core_settings_contactus","restriction":"contactus_manage","keywords":["contact us"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer"><![CDATA[{"lang_key":"menu__core_settings_dataLayer","restriction":"dataLayer_manage","keywords":["data layer","datalayer","pii"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer&amp;tab=events"><![CDATA[{"lang_key":"_datalayer_events","restriction":"dataLayer_manage","keywords":["data layer events","datalayer events"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer&amp;tab=handlers"><![CDATA[{"lang_key":"_datalayer_handlers","restriction":"dataLayer_handlers_view","keywords":["data layer handlers","datalayer handlers"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer&amp;tab=main&amp;searchResult=datalayer_general_core_datalayer_use_gtm"><![CDATA[{"lang_key":"core_datalayer_use_gtm","restriction":"dataLayer_manage","keywords":["google tag manager","gtm","tag manager"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer&amp;tab=pageContext"><![CDATA[{"lang_key":"_datalayer_pageContext","restriction":"dataLayer_manage","keywords":["context","data layer context","data layer page context","datalayer context","datalayer page context","page context"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=dataLayer&amp;tab=properties"><![CDATA[{"lang_key":"_datalayer_properties","restriction":"dataLayer_manage","keywords":["data layer properties","datalayer properties"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=email"><![CDATA[{"lang_key":"menu__core_settings_email","restriction":"email_manage","keywords":["address","email","email logo","mail","smtp"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=email&amp;do=errorLog"><![CDATA[{"lang_key":"emailerrorlogs","restriction":"email_errorlog","keywords":["email error logs","email logs","logs"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=email&amp;searchResult=email_log_do"><![CDATA[{"lang_key":"email_log_do","restriction":"email_manage","keywords":["email log","email statistics","statistics"]}]]></acpsearch>
@@ -724,7 +758,6 @@
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_board_name"><![CDATA[{"lang_key":"board_name","restriction":"general_manage","keywords":["community name","site name","website name"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_copyright_line"><![CDATA[{"lang_key":"copyright_line","restriction":"general_manage","keywords":["copyright","license"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_diagnostics_reporting"><![CDATA[{"lang_key":"diagnostics_reporting","restriction":"general_manage","keywords":["diagnostics","reports"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_show_home_link"><![CDATA[{"lang_key":"show_home_link","restriction":"general_manage","keywords":["breadcrumb","navigation"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_site_address"><![CDATA[{"lang_key":"site_address","restriction":"general_manage","keywords":["address","mail"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_site_online"><![CDATA[{"lang_key":"site_online","restriction":"general_manage","keywords":["offline","online"]}]]></acpsearch>
<acpsearch key="app=core&amp;module=settings&amp;controller=general&amp;searchResult=form_site_social_profiles"><![CDATA[{"lang_key":"site_social_profiles","restriction":"general_manage","keywords":["facebook","social profile","twitter"]}]]></acpsearch>
+1 -1
View File
@@ -26,7 +26,7 @@ class _Upgrade
/**
* ...
*
* @return array If returns TRUE, upgrader will proceed to next step. If it returns any other value, it will set this as the value of the 'extra' GET parameter and rerun this step (useful for loops)
* @return bool|array If returns TRUE, upgrader will proceed to next step. If it returns any other value, it will set this as the value of the 'extra' GET parameter and rerun this step (useful for loops)
*/
public function step1()
{
@@ -63,12 +63,13 @@ class _{class} extends \IPS\core\Achievements\Actions\AbstractAchievementAction
}
/**
* Get the labels for the people this action might give awards to
*
* @return array
*/
// You don't need to implement this if your action only gives points to the subject
// public function awardOptions(): array
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
// public function awardOptions( ?array $filters ): array
// {
// return [
// 'subject' => 'achievement_filter_{class}_receiver',
@@ -77,13 +78,13 @@ class _{class} extends \IPS\core\Achievements\Actions\AbstractAchievementAction
// }
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @return array
*/
// You don't need to implement this if your action only gives points to the subject
// public function awardOther( $extra = NULL ): array
* Get the "other" people we need to award =stuff to
*
* @param array|NULL $filters Current filter values
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @return array
*/
// public function awardOther(?array $filters, $extra = NULL ): array
// {
// return [ \IPS\Member::loggedIn() ];
// }
@@ -60,7 +60,7 @@ class _{class}
*/
public function edit()
{
$form = new \IPS\Helpers\Form;
$form = new \IPS\Helpers\Form;
//$form->add( ... );
if ( $form->values() )
{
@@ -44,6 +44,17 @@ class _{class}
*/
public function save( $values, &$group )
{
$group->example = $values['example'];
$group->example = $values['example'];
}
/**
* Can this group be deleted?
*
* @param \IPS\Member\Group $group The group
* @return void
*/
public function canDelete( $group ) : bool
{
return TRUE;
}
}
@@ -71,9 +71,10 @@ class _{class} extends \IPS\core\MemberACPProfile\Restriction
* Get details of a change to show on history
*
* @param array $changes Changes as set in save()
* @param array $row Row of data from member history table.
* @return array
*/
public static function changesForHistory( $changes )
public static function changesForHistory( array $changes, array $row ): array
{
$return = array();
@@ -1,98 +0,0 @@
<?php
/**
* @brief Mobile Navigation Extension: {class}
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
{subpackage}
* @since {date}
*/
namespace IPS\{app}\extensions\core\MobileNavigation;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Mobile Navigation Extension: {class}
*/
class _{class}
{
/**
* Get Type Title which will display in the AdminCP Menu Manager
*
* @return string
*/
public static function typeTitle()
{
return \IPS\Member::loggedIn()->language()->addToStack('frontnavigation_{app}');
}
/**
* Can this item be used at all?
* For example, if this will link to a particular feature which has been diabled, it should
* not be available, even if the user has permission
*
* @return bool
*/
public static function isEnabled()
{
return TRUE;
}
/**
* Can the currently logged in user access the content this item links to?
*
* @return bool
*/
public function canAccessContent()
{
return TRUE;
}
/**
* Get Title
*
* @return string
*/
public function title()
{
return \IPS\Member::loggedIn()->language()->addToStack('frontnavigation_{app}');
}
/**
* Get Link
*
* @return \IPS\Http\Url
*/
public function link()
{
return \IPS\Http\Url::internal( "app={app}" );
}
/**
* Is Active?
*
* @return bool
*/
public function active()
{
return \IPS\Dispatcher::i()->application->directory === '{app}';
}
/**
* Children
*
* @param bool $noStore If true, will skip datastore and get from DB (used for ACP preview)
* @return array
*/
public function children( $noStore=FALSE )
{
return NULL;
}
}
@@ -0,0 +1,38 @@
<?php
/**
* @brief Search Index
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
{subpackage}
* @since {date}
*/
namespace IPS\{app}\extensions\core\SearchIndex;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Search Index
*/
class _{class}
{
/**
* Alter index_content before it is stored
*
* @param \IPS\Content $object The class object (eg: \IPS\forums\Topic\Post)
* @param string $content The HTML stripped content
* @return string
*/
public function content( $object, $content ): string
{
return $content;
}
}
+251 -24
View File
@@ -459,9 +459,9 @@
{{if $content->author()->member_id}}
{$email->language->addToStack("email_new_content_unapproved", FALSE, array( 'sprintf' => array( $content->author()->url(), $content->author()->name, $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{{if $content instanceof \IPS\Content\Comment OR $content instanceof \IPS\Content\Review}}{$content->item()->mapped('title')}{{else}}{$content->mapped('title')}{{endif}}</a>
{{elseif $content->author()->real_name}}
{$email->language->addToStack("email_new_content_unapproved_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $content->author()->real_name ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{{if $content instanceof \IPS\Content\Comment OR $content instanceof \IPS\Content\Review}}{$content->item()->mapped('title')}{{else}}{$content->mapped('title')}{{endif}}</a>
{$email->language->addToStack("email_new_content_unapproved_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $content->author()->real_name ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{{if $content instanceof \IPS\Content\Comment OR $content instanceof \IPS\Content\Review}}{$content->item()->mapped('title')}{{else}}{$content->mapped('title')}{{endif}}</a>
{{else}}
{$email->language->addToStack("email_new_content_unapproved_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{{if $content instanceof \IPS\Content\Comment OR $content instanceof \IPS\Content\Review}}{$content->item()->mapped('title')}{{else}}{$content->mapped('title')}{{endif}}</a>
{$email->language->addToStack("email_new_content_unapproved_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{{if $content instanceof \IPS\Content\Comment OR $content instanceof \IPS\Content\Review}}{$content->item()->mapped('title')}{{else}}{$content->mapped('title')}{{endif}}</a>
{{endif}}
<br />
@@ -473,7 +473,7 @@
{{if $content->author()->member_id}}
{$email->language->addToStack("email_new_content_unapproved_plain", FALSE, array( 'htmlsprintf' => array( $content->author()->name, $content->indefiniteArticle( $email->language ) ) ) )} {$content->mapped('title')}
{{else}}
{$email->language->addToStack("email_new_content_unapproved_plain", FALSE, array( 'htmlsprintf' => array( $content->author()->real_name ? $email->language->addToStack( 'guest_name_shown', NULL, array( 'htmlsprintf' => array( $content->author()->real_name ) ) ) : $email->language->addToStack( 'guest_name_shown', NULL, array( 'htmlsprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} {$content->mapped('title')}
{$email->language->addToStack("email_new_content_unapproved_plain", FALSE, array( 'htmlsprintf' => array( $content->author()->real_name ? $email->language->addToStack( 'guest_name_shown', FALSE, array( 'htmlsprintf' => array( $content->author()->real_name ) ) ) : $email->language->addToStack( 'guest_name_shown', FALSE, array( 'htmlsprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} {$content->mapped('title')}
{{endif}}
@@ -598,8 +598,72 @@
{$email->language->addToStack( "notification__new_rank", FALSE, array( 'sprintf' => array( $email->language->addToStack( "core_member_rank_" . $rank->id ) ) ) )}
<table width='100%' cellpadding='0' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<table width='400px' cellpadding='0' cellspacing='0' border='0'>
<tr>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<img src='{$member->get_photo( true, true )}' width='80' height='80' style='border: 1px solid #777777; vertical-align: middle;'>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<span style="font-size:48px;">+</span>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<img src='{setting="base_url"}applications/core/interface/email/trophy.png' width='80' height='80' alt=''>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<span style="font-size:48px;">=</span>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<img src='{setting="base_url"}applications/core/interface/email/tada.png' width='80' height='80' alt=''>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
{{if $days = $member->daysSinceLastRank()}}
{{if $days < 365}}
{$email->language->addToStack("notification_email_days_rank_took_low", NULL, ['sprintf'=>[$days]])}
{{else}}
{$email->language->addToStack("notification_email_days_rank_took_high", NULL, ['sprintf'=>[$days]])}
{{endif}}
{{endif}}
<br><br>
{$email->language->addToStack("notification_email_keep_it_going")}
<br /><br />
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$rank, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack( "notification__new_rank", FALSE, array( 'sprintf' => array( $email->language->addToStack( "core_member_rank_" . $rank->id ) ) ) )}
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$rank, $member, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack( "notification__new_rank", FALSE, array( 'sprintf' => array( $email->language->addToStack( "core_member_rank_" . $rank->id ) ) ) )}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>acp_notification_License</template_name><template_content_html><![CDATA[
<br />
@@ -888,7 +952,118 @@
<br />
<em style='color: #8c8c8c'>&mdash; {$email->language->addToStack("onboard_email_tic", FALSE)}</em>]]></template_content_html><template_data>$email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("onboard_welcome_message_email")}
{$email->language->addToStack("onboard_finish_setup", FALSE)}: {url="app=core&module=overview&controller=onboard" base="admin" plain="true"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>contact_form</template_name><template_content_html><![CDATA[{$email->language->addToStack("email_contact_form", FALSE)}
{$email->language->addToStack("onboard_finish_setup", FALSE)}: {url="app=core&module=overview&controller=onboard" base="admin" plain="true"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>activity_stream_subscription</template_name><template_content_html><![CDATA[{{if $subscription['frequency'] == 'daily'}}
{$email->language->addToStack( 'email_core_activity_stream_subscription_daily', FALSE, ['sprintf' => $stream->_title])}
{{else}}
{$email->language->addToStack( 'email_core_activity_stream_subscription_weekly', FALSE, ['sprintf' => $stream->_title])}
{{endif}}
<br /><br />
<table width='100%' cellpadding='0' cellspacing='0' border='0'>
{{foreach $items as $item}}
{{$content = $item['object'];}}
<tr>
<td>
<table width='100%' cellpadding='0' cellspacing='0' border='0'>
<tr>
<td dir='{dir}' width='40' valign='top' class='hidePhone' style='width: 0; max-height: 0; overflow: hidden; float: left; padding-top: 15px'>
<img src='{$content->author()->get_photo( true, true )}' width='40' height='40' style='border: 1px solid #777777; vertical-align: middle;'>
</td>
<td dir='{dir}' width='30' valign='top' class='hidePhone' style='width: 0; max-height: 0; overflow: hidden; float: left;'>
<span style='display: block; width: 0px; height: 0px; border-width: 15px; border-color: transparent #f9f9f9 transparent transparent; border-style: solid; margin-top: 23px;'></span>
</td>
<td dir='{dir}' width='100%' valign='top' style='background: #f9f9f9;'>
<table width='100%' cellpadding='10' cellspacing='0' border='0'>
<tr>
<td width='100%'>
<table width='100%' cellpadding='5' cellspacing='0' border='0'>
<tr>
<td dir='{dir}' width='100%' style="font-family: 'Helvetica Neue', helvetica, sans-serif; color: #8d8d8d; font-size: 14px;">
{{$itemClass = $item['itemClass'];}}
<h2 style="color: #333333; font-weight: bold; line-height: 1.1; font-size: {{if !$item['indexData']['index_title']}}16px{{else}}20px{{endif}}; margin: 0 0 3px 0;">
<a href='{$content->url()}' style='text-decoration: none; color: #333333;'>{$item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['title'] ]}</a>
</h2>
{expression="$itemClass::searchResultSummaryLanguage( $item['authorData'], $itemClass::articlesFromIndexData( $itemClass, $item['containerData'] ), $item['indexData'], $item['itemData'], FALSE )"} <a href='{$item['containerUrl']}'>{$item['containerTitle']|raw}</a>
</td>
</tr>
<tr>
<td dir='{dir}' width='100%' style="font-family: 'Helvetica Neue', helvetica, sans-serif; color: #333; font-size: 15px;">
{{$emailContent = $email->parseTextForEmail( $content->content(), $email->language, ( \IPS\Settings::i()->email_truncate ? 150 : NULL ) );}}
{$emailContent|raw}{{if \IPS\Settings::i()->email_truncate AND \mb_strlen( $content->content() ) > 150}}...{{endif}}
</td>
</tr>
<tr>
<td width='100%'>
<table cellpadding='0' cellspacing='0' border='0'>
<tr>
<td style="font-family: 'Helvetica Neue', helvetica, sans-serif; font-size: 14px;">
<a href='{$content->url()}'>Read more</a>
</td>
<td>
<img src="{setting="base_url"}applications/core/interface/email/spacer.png" alt='' width="20" height="1" />
</td>
<td style="color: #8d8d8d; font-family: 'Helvetica Neue', helvetica, sans-serif; font-size: 14px;">
<img src="{setting="base_url"}applications/core/interface/email/clock.png" alt='' width="13" height="13" style="vertical-align: middle" />
<img src="{setting="base_url"}applications/core/interface/email/spacer.png" alt='' width="1" height="1" />
<a href='{$content->url()}' style='color: inherit; text-decoration: none;'>{expression="\IPS\DateTime::ts( $item['indexData']['index_date_created'] )->localeDate( $recipient )"}</a>
</td>
{{if isset( $itemClass::$databaseColumnMap['num_comments'] ) and isset( $item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['num_comments'] ] ) and $item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['num_comments'] ] > ( $itemClass::$firstCommentRequired ? 1 : 0 )}}
<td>
<img src="{setting="base_url"}applications/core/interface/email/spacer.png" alt='' width="20" height="1" />
</td>
<td style="color: #8d8d8d; font-family: 'Helvetica Neue', helvetica, sans-serif; font-size: 14px;">
<img src="{setting="base_url"}applications/core/interface/email/comment_alt.png" alt='' width="13" height="13" style="vertical-align: middle" />
<img src="{setting="base_url"}applications/core/interface/email/spacer.png" alt='' width="1" height="1" />
<a href='{$content->url()}' style='color: inherit; text-decoration: none;'>
{{if $itemClass::$firstCommentRequired}}
{expression="$item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['num_comments'] ]-1"}
{{else}}
{expression="$item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['num_comments'] ]"}
{{endif}}
</a>
</td>
{{endif}}
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td height="20">&nbsp;</td>
</tr>
{{endforeach}}
{{if $viewMoreLink}}
<tr>
<td dir='{dir}' align='center'>
<a href='{$stream->url()}' style="color: #ffffff; font-family: 'Helvetica Neue', helvetica, sans-serif; text-decoration: none; font-size: 14px; background: {setting="email_color"}; line-height: 32px; padding: 0 10px; display: inline-block; border-radius: 3px;">{$email->language->addToStack('stream_view_more', FALSE)}</a>
</td>
</tr>
{{endif}}
</table>]]></template_content_html><template_data>$stream, $items, $recipient, $subscription, $viewMore, $email</template_data><template_content_plaintext><![CDATA[{{if $subscription['frequency'] == 'daily'}}{$email->language->addToStack( 'email_core_activity_stream_subscription_daily', FALSE, ['sprintf' => $stream->_title])}{{else}}{$email->language->addToStack( 'email_core_activity_stream_subscription_weekly', FALSE, ['sprintf' => $stream->_title])}{{endif}}
{{foreach $items as $item}}{{$content = $item['object'];}}{{$itemClass = $item['itemClass'];}}
{$item['itemData'][ $itemClass::$databasePrefix . $itemClass::$databaseColumnMap['title'] ]}
{expression="\IPS\DateTime::ts( $item['indexData']['index_date_created'] )->localeDate( $recipient )"}: {expression="$itemClass::searchResultSummaryLanguage( $item['authorData'], $itemClass::articlesFromIndexData( $itemClass, $item['containerData'] ), $item['indexData'], $item['itemData'], FALSE )"} {expression="strip_tags( $item['containerTitle'] )"}
-------{{$emailContent = $email->parseTextForEmail( $content->content(), $email->language, ( \IPS\Settings::i()->email_truncate ? 150 : NULL ) );}}
{$emailContent|raw}{{if \IPS\Settings::i()->email_truncate AND \mb_strlen( $content->content() ) > 150}}...{{endif}}
-------
URL: {$content->url()}
=========================
{{endforeach}}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>contact_form</template_name><template_content_html><![CDATA[{$email->language->addToStack("email_contact_form", FALSE)}
<br />
<br />
@@ -1028,9 +1203,9 @@
{{if $content->author()->member_id}}
{$email->language->addToStack("email_new_content", FALSE, array( 'sprintf' => array( $content->author()->url(), $content->author()->name, $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{$content->mapped('title')}</a>
{{elseif $content->author()->real_name}}
{$email->language->addToStack("email_new_content_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $content->author()->real_name ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{$content->mapped('title')}</a>
{$email->language->addToStack("email_new_content_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $content->author()->real_name ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{$content->mapped('title')}</a>
{{else}}
{$email->language->addToStack("email_new_content_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{$content->mapped('title')}</a>
{$email->language->addToStack("email_new_content_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $content->indefiniteArticle( $email->language ) ) ) )} <a href='{$content->url()}'>{$content->mapped('title')}</a>
{{endif}}
<br />
@@ -1159,16 +1334,23 @@
{$email->language->addToStack("email_lost_pass", FALSE)}
<br /><br />
<table width='100%' cellpadding='15' cellspacing='0' border='0' style='background: #f9f9f9;'>
<tr>
<table width='100%' cellpadding='15' cellspacing='0' border='0'>
<tr style='background: #f9f9f9;'>
<td dir='{dir}' align='center'>
<a href='{url="app=core&module=system&controller=lostpass&do=validate&vid={$vid}&mid={$member->member_id}" seoTemplate="lostpassword" base="front"}' style="color: #ffffff; font-family: 'Helvetica Neue', helvetica, sans-serif; text-decoration: none; font-size: 14px; background: {setting="email_color"}; line-height: 32px; padding: 0 10px; display: inline-block; border-radius: 3px;">{$email->language->addToStack("email_reset_password", FALSE)}</a>
</td>
</tr>
<tr>
<td dir='{dir}' align='center' style="font-family: 'Helvetica Neue', helvetica, sans-serif; font-size: 10px;">
{$email->language->addToStack("email_lost_pass_timelimit", FALSE)}
</td>
</tr>
</table>]]></template_content_html><template_data>$member, $vid, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("email_lost_pass_plain", FALSE)}
=====
{$email->language->addToStack("email_reset_password", FALSE)}: {url="app=core&module=system&controller=lostpass&do=validate&vid={$vid}&mid={$member->member_id}" seoTemplate="lostpassword" plain="true" base="front"}
{$email->language->addToStack("email_lost_pass_timelimit", FALSE)}
=====
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>admin_reg</template_name><template_content_html><![CDATA[
@@ -1222,7 +1404,15 @@
{expression="$email->language->addToStack( 'email_go_to_site', FALSE, array( 'htmlsprintf' => array( \IPS\Settings::i()->board_name ) ) )" raw="true"}: {setting="base_url"}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_quote</template_name><template_content_html><![CDATA[
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>unsubscribeStream</template_name><template_content_html><![CDATA[<tr>
<td dir='{dir}' valign="top"><img src='{setting="base_url"}applications/core/interface/email/spacer.png' width='1' height='1' alt=''></td>
<td dir='{dir}' valign='middle' align='center' style="font-family: 'Helvetica Neue', helvetica, sans-serif; font-size: 12px; line-height: 18px; padding-left: 10px;">
{$email->language->addToStack("unsubscribe_blurb_stream", FALSE, array( 'sprintf' => array( $streamTitle )))}<br>
{$email->language->addToStack("unsubscribe_blurb", FALSE)} <a href="{url="app=core&module=discover&controller=streams&do=unsubscribeFromEmail&id={$streamId}&gkey={$key}" base="front"}" style='color: #4a8aca; text-decoration: none; display: inline-block'>{$email->language->addToStack( 'unsubscribe', FALSE )}</a>.
<br />
</td>
</tr>]]></template_content_html><template_data>$streamId, $streamTitle, $key, $member, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("unsubscribe_blurb_stream", FALSE, array( 'sprintf' => array( $streamTitle )))}
{$email->language->addToStack("unsubscribe_blurb", FALSE)} {$email->language->addToStack( 'unsubscribe', FALSE )}: {url="app=core&module=discover&controller=streams&do=unsubscribeFromEmail&id={$streamId}&gkey={$key}"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_quote</template_name><template_content_html><![CDATA[
{{$item = $comment instanceof \IPS\Content\Item ? $comment : $comment->item();}}
{$email->language->addToStack("email_quoted_you", FALSE, array( 'sprintf' => array( $comment->author()->url(), $comment->author()->name, $item->indefiniteArticle( $email->language ) ) ) )}
@@ -1715,7 +1905,7 @@
{$email->language->addToStack("set_password", FALSE)}: {url="app=core&module=system&controller=register&do=setPassword&mid={$member->member_id}&passkey={$key}" base="front" seoTemplate="register"}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_new_recognize</template_name><template_content_html><![CDATA[<br />
{$email->language->addToStack('notification_new_recognized_mail', NULL, [ 'sprintf' => [ $recognize->content()->url() ] ] )}
{$email->language->addToStack( 'notification_new_recognized_mail', FALSE, [ 'sprintf' => [ $recognize->content()->url() ] ] )}
{{if $recognize->message}}
<p style='border-bottom: 1px solid #e0e0e0;border-top: 1px solid #e0e0e0; padding: 10px 0px'>
<strong><em>{$recognize->message}</em></strong>
@@ -1737,7 +1927,7 @@
<img src="{file="$badge->image" extension="core_Badges"}">
{{endif}}
<br /><br />
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$badge, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("notification__new_recognized")}
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$member, $recognize, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("notification__new_recognized")}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_member_follow</template_name><template_content_html><![CDATA[{$email->language->addToStack("notification__member_follow", FALSE, array( 'sprintf' => array( $member->name ) ) )}
@@ -1900,9 +2090,9 @@
{{if $comment->author()->member_id}}
{$email->language->addToStack("email_new_review", FALSE, array( 'sprintf' => array( $comment->author()->url(), $comment->author()->name, $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{elseif $comment->author()->real_name}}
{$email->language->addToStack("email_new_review_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $comment->author()->real_name ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{$email->language->addToStack("email_new_review_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $comment->author()->real_name ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{else}}
{$email->language->addToStack("email_new_review_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{$email->language->addToStack("email_new_review_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{endif}}
<br />
@@ -1917,17 +2107,54 @@
{$comment->emailContent( $email, 'plaintext' )|raw}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_new_badge</template_name><template_content_html><![CDATA[<br />
{$email->language->addToStack("notification__new_badge")}
{$email->language->addToStack("notification__new_badge", NULL, [ 'sprintf' => [$badge->_title]])}
<br><br>
{$email->language->addToStack("notification_email_check_it_out")}
<br>
<br><strong>{$badge->_title}</strong>
<br>
<img src="{file="$badge->image" extension="core_Badges"}">
<table width='100%' cellpadding='0' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<table width='400px' cellpadding='0' cellspacing='0' border='0'>
<tr>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<img src='{$member->get_photo( true, true )}' width='80' height='80' style='border: 1px solid #777777; vertical-align: middle;'>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<span style="font-size:48px;">=</span>
</td>
</tr>
</table>
</td>
<td dir='{dir}' align='center'>
<table width='80' cellpadding='15' cellspacing='0' border='0'>
<tr>
<td dir='{dir}'>
<img src='{setting="base_url"}applications/core/interface/email/tada.png' width='80' height='80' alt=''>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
{{if $count = $badge->ownedByCount(TRUE)}}
{$email->language->addToStack("notification_email_did_you_know_count", NULL, ['sprintf'=>[$count]])}
{{endif}}
<br><br>
{$email->language->addToStack("notification_email_keep_it_going")}
<br /><br />
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$badge, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("notification__new_badge")}
<em style='color: #8c8c8c'>&mdash; {setting="board_name"}</em>]]></template_content_html><template_data>$member, $badge, $email</template_data><template_content_plaintext><![CDATA[{$email->language->addToStack("notification__new_badge")}
-- {setting="board_name"}]]></template_content_plaintext><template_pinned>0</template_pinned></template><template><template_app>core</template_app><template_name>notification_profile_reply</template_name><template_content_html><![CDATA[
{{$item = $comment->item();}}
@@ -2215,9 +2442,9 @@ ___digest___]]></template_content_plaintext><template_pinned>0</template_pinned>
{{if $comment->author()->member_id}}
{$email->language->addToStack("email_new_comment", FALSE, array( 'sprintf' => array( $comment->author()->url(), $comment->author()->name, $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{elseif $comment->author()->real_name}}
{$email->language->addToStack("email_new_comment_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $comment->author()->real_name ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{$email->language->addToStack("email_new_comment_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $comment->author()->real_name ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{else}}
{$email->language->addToStack("email_new_comment_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', NULL, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{$email->language->addToStack("email_new_comment_guest", FALSE, array( 'sprintf' => array( $email->language->addToStack( 'guest_name_shown', FALSE, array( 'sprintf' => array( $email->language->addToStack('guest') ) ) ), $item->indefiniteArticle( $email->language ) ) ) )} <a href='{$comment->item()->url()}'>{$comment->item()->mapped('title')}</a>
{{endif}}
<br />
+15 -7
View File
@@ -24,6 +24,7 @@
"Reports": "IPS\\core\\extensions\\core\\ModCp\\Reports",
"Members": "IPS\\core\\extensions\\core\\ModCp\\Members",
"Content": "IPS\\core\\extensions\\core\\ModCp\\Content",
"Alerts": "IPS\\core\\extensions\\core\\ModCp\\Alerts",
"Unapproved": "IPS\\core\\extensions\\core\\ModCp\\Unapproved",
"Warnings": "IPS\\core\\extensions\\core\\ModCp\\Warnings",
"Announcements": "IPS\\core\\extensions\\core\\ModCp\\Announcements"
@@ -93,6 +94,7 @@
"Promote": "IPS\\core\\extensions\\core\\FileStorage\\Promote",
"Icons": "IPS\\core\\extensions\\core\\FileStorage\\Icons",
"Profile": "IPS\\core\\extensions\\core\\FileStorage\\Profile",
"Ranks": "IPS\\core\\extensions\\core\\FileStorage\\Ranks",
"ReferralBanners": "IPS\\core\\extensions\\core\\FileStorage\\ReferralBanners",
"Imageproxycache": "IPS\\core\\extensions\\core\\FileStorage\\Imageproxycache",
"Attachment": "IPS\\core\\extensions\\core\\FileStorage\\Attachment",
@@ -108,9 +110,7 @@
"AuthenticateFrontKnown": "IPS\\core\\extensions\\core\\MFAArea\\AuthenticateFrontKnown"
},
"Sitemap": {
"Content": "IPS\\core\\extensions\\core\\Sitemap\\Content",
"Applications": "IPS\\core\\extensions\\core\\Sitemap\\Applications",
"Profiles": "IPS\\core\\extensions\\core\\Sitemap\\Profiles"
"Content": "IPS\\core\\extensions\\core\\Sitemap\\Content"
},
"GroupForm": {
"Content": "IPS\\core\\extensions\\core\\GroupForm\\Content",
@@ -122,6 +122,7 @@
"Messaging": "IPS\\core\\extensions\\core\\EditorLocations\\Messaging",
"Clubs": "IPS\\core\\extensions\\core\\EditorLocations\\Clubs",
"Reports": "IPS\\core\\extensions\\core\\EditorLocations\\Reports",
"Alert": "IPS\\core\\extensions\\core\\EditorLocations\\Alert",
"Members": "IPS\\core\\extensions\\core\\EditorLocations\\Members",
"Staffdirectory": "IPS\\core\\extensions\\core\\EditorLocations\\Staffdirectory",
"Meta": "IPS\\core\\extensions\\core\\EditorLocations\\Meta",
@@ -186,11 +187,15 @@
"GeoIP": "IPS\\core\\extensions\\core\\CommunityEnhancements\\GeoIP",
"Zapier": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Zapier",
"SpamMonitoring": "IPS\\core\\extensions\\core\\CommunityEnhancements\\SpamMonitoring",
"GoogleTagManager": "IPS\\core\\extensions\\core\\CommunityEnhancements\\GoogleTagManager",
"Pixabay": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Pixabay",
"Sendgrid": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Sendgrid",
"FacebookPixel": "IPS\\core\\extensions\\core\\CommunityEnhancements\\FacebookPixel",
"Mapbox": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Mapbox",
"Giphy": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Giphy"
"GoogleAnalytics": "IPS\\core\\extensions\\core\\CommunityEnhancements\\GoogleAnalytics",
"Matomo": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Matomo",
"Giphy": "IPS\\core\\extensions\\core\\CommunityEnhancements\\Giphy",
"IndexNow": "IPS\\core\\extensions\\core\\CommunityEnhancements\\IndexNow"
},
"GroupLimits": {
"GroupLimits": "IPS\\core\\extensions\\core\\GroupLimits\\GroupLimits"
@@ -244,18 +249,20 @@
"RebuildContainerCounts": "IPS\\core\\extensions\\core\\Queue\\RebuildContainerCounts",
"RebuildImageProxy": "IPS\\core\\extensions\\core\\Queue\\RebuildImageProxy",
"DeleteOrMoveContent": "IPS\\core\\extensions\\core\\Queue\\DeleteOrMoveContent",
"IndexNow": "IPS\\core\\extensions\\core\\Queue\\IndexNow",
"RebuildAchievements": "IPS\\core\\extensions\\core\\Queue\\RebuildAchievements",
"ForcePasswordReset": "IPS\\core\\extensions\\core\\Queue\\ForcePasswordReset",
"RestoreBrokenAttachments": "IPS\\core\\extensions\\core\\Queue\\RestoreBrokenAttachments"
},
"MobileNavigation": {
"CustomItem": "IPS\\core\\extensions\\core\\MobileNavigation\\CustomItem"
},
"MemberFilter": {
"Spammer": "IPS\\core\\extensions\\core\\MemberFilter\\Spammer",
"Achievements": "IPS\\core\\extensions\\core\\MemberFilter\\Achievements",
"ProfileFields": "IPS\\core\\extensions\\core\\MemberFilter\\ProfileFields",
"Twofactor": "IPS\\core\\extensions\\core\\MemberFilter\\Twofactor",
"Leaderboard": "IPS\\core\\extensions\\core\\MemberFilter\\Leaderboard",
"Group": "IPS\\core\\extensions\\core\\MemberFilter\\Group",
"Validating": "IPS\\core\\extensions\\core\\MemberFilter\\Validating",
"Banned": "IPS\\core\\extensions\\core\\MemberFilter\\Banned",
"Lastvisit": "IPS\\core\\extensions\\core\\MemberFilter\\Lastvisit",
"Bulkmail": "IPS\\core\\extensions\\core\\MemberFilter\\Bulkmail",
"Content": "IPS\\core\\extensions\\core\\MemberFilter\\Content",
@@ -270,6 +277,7 @@
"ProfileFields": "IPS\\core\\extensions\\core\\OverviewStatistics\\ProfileFields",
"Clubs": "IPS\\core\\extensions\\core\\OverviewStatistics\\Clubs",
"Devices": "IPS\\core\\extensions\\core\\OverviewStatistics\\Devices",
"DeletedContent": "IPS\\core\\extensions\\core\\OverviewStatistics\\DeletedContent",
"ContentActivity": "IPS\\core\\extensions\\core\\OverviewStatistics\\ContentActivity",
"RepReceived": "IPS\\core\\extensions\\core\\OverviewStatistics\\RepReceived",
"Followers": "IPS\\core\\extensions\\core\\OverviewStatistics\\Followers",
+12
View File
@@ -306,6 +306,10 @@
"friendly": "modcp/deleted",
"real": "app=core&module=modcp&controller=modcp&tab=deleted"
},
"modcp_alerts": {
"friendly": "modcp/alerts",
"real": "app=core&module=modcp&controller=modcp&tab=alerts"
},
/* Ignore */
"ignore": {
@@ -356,6 +360,10 @@
"friendly": "followed",
"real": "app=core&module=system&controller=followed"
},
"alert": {
"friendly": "alert/{#id}",
"real": "app=core&module=system&controller=alerts"
},
/* Search */
"search": {
@@ -455,6 +463,10 @@
"friendly": "topmembers",
"real": "app=core&module=discover&controller=popular&tab=members"
},
"leaderboard_trending": {
"friendly": "trending",
"real": "app=core&module=discover&controller=popular&tab=trending"
},
/* Clubs */
"clubs_list": {
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+2 -12
View File
@@ -3,7 +3,7 @@
"overview": {
"default_controller": "dashboard",
"protected": 0,
"default": 0
"default": 1
},
"system": {
"default_controller": "login",
@@ -115,11 +115,6 @@
"protected": 0,
"default": 0
},
"mobile": {
"default_controller": "multi",
"protected": 0,
"default": 0
},
"marketplace": {
"default_controller": "",
"protected": 0,
@@ -197,15 +192,10 @@
"protected": 0,
"default": 0
},
"activity": {
"referral": {
"default": 0,
"default_controller": "",
"protected": 0
},
"dashboard": {
"default": 0,
"default_controller": "dashboard",
"protected": 1
}
}
}
+2 -2
View File
@@ -1,7 +1,7 @@
{
"php": {
"required": "7.2.0",
"recommended": "7.4.0"
"required": "7.4.0",
"recommended": "8.0.0"
},
"mysql": {
"required": "5.5.3",
File diff suppressed because it is too large. Load diff
+175 -65
View File
@@ -44,6 +44,21 @@
"default": "1",
"report": "full"
},
{
"key": "activity_stream_subscriptions",
"default": "1",
"report": "full"
},
{
"key": "activity_stream_subscriptions_inactive_limit",
"default": "60",
"report": "full"
},
{
"key": "activity_stream_subscriptions_max",
"default": "3",
"report": "full"
},
{
"key": "ads_circulation",
"default": "random",
@@ -294,6 +309,11 @@
"default": "xframe",
"report": "full"
},
{
"key": "club_max_cover",
"default": "-1",
"report": "full"
},
{
"key": "club_nodes_in_apps",
"default": "0",
@@ -414,11 +434,66 @@
"default": "",
"report": "bool"
},
{
"key": "core_datalayer_enabled",
"default": "0",
"report": "none"
},
{
"key": "core_datalayer_events",
"default": "{}",
"report": "none"
},
{
"key": "core_datalayer_gtmkey",
"default": "window.dataLayer",
"report": "none"
},
{
"key": "core_datalayer_include_pii",
"default": "0",
"report": "none"
},
{
"key": "core_datalayer_member_pii_choice",
"default": "0",
"report": "none"
},
{
"key": "core_datalayer_pii",
"default": "0",
"report": "none"
},
{
"key": "core_datalayer_properties",
"default": "{}",
"report": "none"
},
{
"key": "core_datalayer_replace_with_sso",
"default": "0",
"report": "none"
},
{
"key": "core_datalayer_use_gtm",
"default": "1",
"report": "none"
},
{
"key": "csp_header",
"default": "",
"report": "bool"
},
{
"key": "custom_body_code",
"default": "",
"report": "none"
},
{
"key": "custom_page_view_js",
"default": "",
"report": "none"
},
{
"key": "dellog_retention_period",
"default": "30",
@@ -494,6 +569,16 @@
"default": "#177ec9",
"report": "bool"
},
{
"key": "email_filter_action",
"default": "allow",
"report": "full"
},
{
"key": "email_filter_replace_text",
"default": "*****@*****.tld",
"report": "bool"
},
{
"key": "email_in",
"default": "",
@@ -609,6 +694,16 @@
"default": "",
"report": "bool"
},
{
"key": "ga_code",
"default": "",
"report": "none"
},
{
"key": "ga_enabled",
"default": "0",
"report": "full"
},
{
"key": "giphy_apikey",
"default": "",
@@ -674,6 +769,21 @@
"default": "1",
"report": "full"
},
{
"key": "googletag_enabled",
"default": "0",
"report": "full"
},
{
"key": "googletag_head_code",
"default": "",
"report": "none"
},
{
"key": "googletag_noscript_code",
"default": "",
"report": "none"
},
{
"key": "group_formatting",
"default": "global",
@@ -689,6 +799,16 @@
"default": "0",
"report": "full"
},
{
"key": "hcaptcha_secret",
"default": "",
"report": "none"
},
{
"key": "hcaptcha_sitekey",
"default": "",
"report": "bool"
},
{
"key": "htaccess_mod_rewrite",
"default": "0",
@@ -709,6 +829,11 @@
"default": "",
"report": "bool"
},
{
"key": "icons_homescreen_maskable",
"default": "",
"report": "bool"
},
{
"key": "icons_mask_color",
"default": "FFFFFF",
@@ -749,6 +874,16 @@
"default": "1",
"report": "full"
},
{
"key": "indexnow_enabled",
"default": "0",
"report": "full"
},
{
"key": "indexnow_key",
"default": "",
"report": "bool"
},
{
"key": "ip_address_prune",
"default": "",
@@ -874,21 +1009,6 @@
"default": "",
"report": "bool"
},
{
"key": "ipbseo_ga_enabled",
"default": "1",
"report": "full"
},
{
"key": "ipbseo_ga_paginatecode",
"default": "",
"report": "bool"
},
{
"key": "ipbseo_ga_provider",
"default": "none",
"report": "full"
},
{
"key": "ips_cp_purchase",
"default": "0",
@@ -989,6 +1109,16 @@
"default": "1",
"report": "full"
},
{
"key": "matomo_code",
"default": "",
"report": "none"
},
{
"key": "matomo_enabled",
"default": "0",
"report": "full"
},
{
"key": "max_internalembed_width",
"default": "500",
@@ -1079,51 +1209,6 @@
"default": "0",
"report": "full"
},
{
"key": "mobile_app_home_blocks_order",
"default": "{\"new_content\":true,\"active_users\":true,\"our_picks\":true,\"popular_contributors\":true}",
"report": "bool"
},
{
"key": "mobile_app_id",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_itunes_id",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_itunes_url",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_play_id",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_play_url",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_prompt",
"default": "0",
"report": "full"
},
{
"key": "mobile_app_redirect_scheme",
"default": "",
"report": "bool"
},
{
"key": "mobile_app_secret",
"default": "",
"report": "none"
},
{
"key": "most_online",
"default": "{\"count\":0,\"time\":0}",
@@ -1154,11 +1239,6 @@
"default": "0",
"report": "full"
},
{
"key": "notification_prefs_sound",
"default": "1",
"report": "full"
},
{
"key": "onboard_complete",
"default": "0",
@@ -1549,6 +1629,11 @@
"default": "5",
"report": "full"
},
{
"key": "robots_txt",
"default": "default",
"report": "bool"
},
{
"key": "rules_exclude_groups",
"default": "[]",
@@ -1614,6 +1699,11 @@
"default": "5",
"report": "full"
},
{
"key": "searchlog_exclude_groups",
"default": "[2]",
"report": "bool"
},
{
"key": "security_questions_areas",
"default": "",
@@ -1699,6 +1789,16 @@
"default": "",
"report": "bool"
},
{
"key": "site_main_title",
"default": "",
"report": "bool"
},
{
"key": "site_main_url",
"default": "",
"report": "bool"
},
{
"key": "site_offline_message",
"default": "",
@@ -1714,6 +1814,11 @@
"default": "",
"report": "none"
},
{
"key": "site_site_elsewhere",
"default": "0",
"report": "full"
},
{
"key": "site_social_profiles",
"default": "",
@@ -1989,6 +2094,11 @@
"default": "0",
"report": "full"
},
{
"key": "theme_editing_advanced_mode",
"default": "0",
"report": "full"
},
{
"key": "topic_redirect_prune",
"default": "30",
+1 -1
View File
@@ -1 +1 @@
{"profilesync":"P0Y0M0DT1H0M0S","updatecheck":"P0Y0M1DT0H0M0S","cleanup":"P0Y0M1DT0H0M0S","sitemapgenerator":"P0Y0M0DT0H15M0S","queue":"P0Y0M0DT0H1M0S","pop":"P0Y0M0DT0H10M0S","digest":"P0Y0M0DT0H5M0S","publish":"P0Y0M0DT0H10M0S","clearcache":"P0Y0M0DT0H10M0S","clearsessions":"P0Y0M0DT0H30M0S","viewupdates":"P0Y0M0DT0H5M0S","cleanupattachments":"P0Y0M0DT12H0M0S","cleanupfiles":"P0Y0M1DT0H0M0S","unlockmembers":"P0Y0M0DT1H0M0S","leaderboard":"P0Y0M0DT6H0M0S","deletecontent":"P0Y0M1DT0H0M0S","clubrebuild":"P0Y0M0DT0H20M0S","onlineusers":"P0Y0M0DT0H15M0S","promote":"P0Y0M0DT0H5M0S","prunesearchindex":"P0Y0M1DT0H0M0S","prunesystemlogs":"P0Y0M1DT0H0M0S","automaticmoderation":"P0Y0M0DT0H10M0S","usagereporting":"P0Y0M7DT0H0M0S","userAgentStatistics":"P0Y0M0DT0H30M0S","pruneipaddresses":"P0Y0M1DT0H0M0S","clearelasticsearchtasks":"P0Y0M1DT0H0M0S","postBeforeRegisterFollowup":"P0Y0M0DT1H0M0S","weeklydigest":"P0Y0M0DT2H0M0S","clearincompletemembers":"P0Y0M0DT1H0M0S","rssimport":"P0Y0M0DT0H15M0S","webhooks":"P0Y0M0DT0H2M0S","chunkcleanup":"P0Y0M1DT0H0M0S","s3Delete":"P0Y0M0DT0H15M0S","pwaprune":"P0Y0M1DT0H0M0S"}
{"profilesync":"P0Y0M0DT1H0M0S","updatecheck":"P0Y0M1DT0H0M0S","cleanup":"P0Y0M1DT0H0M0S","sitemapgenerator":"P0Y0M0DT0H15M0S","queue":"P0Y0M0DT0H1M0S","pop":"P0Y0M0DT0H10M0S","digest":"P0Y0M0DT0H5M0S","publish":"P0Y0M0DT0H10M0S","clearcache":"P0Y0M0DT0H10M0S","clearsessions":"P0Y0M0DT0H30M0S","viewupdates":"P0Y0M0DT0H5M0S","cleanupattachments":"P0Y0M0DT12H0M0S","cleanupfiles":"P0Y0M1DT0H0M0S","unlockmembers":"P0Y0M0DT1H0M0S","leaderboard":"P0Y0M0DT6H0M0S","deletecontent":"P0Y0M1DT0H0M0S","clubrebuild":"P0Y0M0DT0H20M0S","onlineusers":"P0Y0M0DT0H15M0S","promote":"P0Y0M0DT0H5M0S","prunesearchindex":"P0Y0M1DT0H0M0S","prunesystemlogs":"P0Y0M1DT0H0M0S","automaticmoderation":"P0Y0M0DT0H10M0S","usagereporting":"P0Y0M7DT0H0M0S","userAgentStatistics":"P0Y0M0DT0H30M0S","pruneipaddresses":"P0Y0M1DT0H0M0S","clearelasticsearchtasks":"P0Y0M1DT0H0M0S","postBeforeRegisterFollowup":"P0Y0M0DT1H0M0S","weeklydigest":"P0Y0M0DT2H0M0S","clearincompletemembers":"P0Y0M0DT1H0M0S","rssimport":"P0Y0M0DT0H15M0S","webhooks":"P0Y0M0DT0H2M0S","chunkcleanup":"P0Y0M1DT0H0M0S","s3Delete":"P0Y0M0DT0H15M0S","pwaprune":"P0Y0M1DT0H0M0S","dailyStreamSubscriptions":"P0Y0M0DT0H5M0S","weeklyStreamSubscriptions":"P0Y0M0DT0H5M0S"}
File diff suppressed because it is too large. Load diff
+76 -1
View File
@@ -426,5 +426,80 @@
"106104": "4.6.0 Beta 3",
"106105": "4.6.0 Beta 3.1",
"106106": "4.6.0 Beta 4",
"106107": "4.6.0"
"106107": "4.6.0",
"106108": "4.6.0",
"106109": "4.6.0",
"106110": "4.6.1",
"106111": "4.6.1",
"106112": "4.6.1",
"106113": "4.6.2",
"106114": "4.6.2",
"106115": "4.6.2",
"106116": "4.6.3",
"106117": "4.6.3",
"106118": "4.6.4",
"106119": "4.6.4",
"106120": "4.6.4",
"106121": "4.6.4",
"106122": "4.6.5",
"106123": "4.6.5.1",
"106125": "4.6.5.1",
"106126": "4.6.5.1",
"106127": "4.6.5.1",
"106128": "4.6.5.1",
"106129": "4.6.5.1",
"106130": "4.6.5.1",
"106131": "4.6.5.1",
"106132": "4.6.6",
"106133": "4.6.6",
"106134": "4.6.7 Beta 1",
"106135": "4.6.7 Beta 2",
"106136": "4.6.7",
"106137": "4.6.7",
"106138": "4.6.8 Beta 1",
"106139": "4.6.8 Beta 2",
"106140": "4.6.8",
"106141": "4.6.8",
"106142": "4.6.8",
"106143": "4.6.8",
"106144": "4.6.9 Beta 1",
"106145": "4.6.9 Beta 2",
"106146": "4.6.9 Beta 3",
"106147": "4.6.9",
"106148": "4.6.9",
"106149": "4.6.10 Beta 1",
"106150": "4.6.10 Beta 2",
"106151": "4.6.10",
"106152": "4.6.10",
"106153": "4.6.10",
"106154": "4.6.10",
"106155": "4.6.10",
"106156": "4.6.11 Beta 1",
"106157": "4.6.11 Beta 1",
"106158": "4.6.11 Beta 2",
"106159": "4.6.11",
"106160": "4.6.11",
"106161": "4.6.12 Beta 1",
"106162": "4.6.12 Beta 1",
"106163": "4.6.12 Beta 2",
"106164": "4.6.12",
"106165": "4.6.12",
"106166": "4.6.12",
"106167": "4.6.12.1",
"106168": "4.6.13 Beta 1",
"107000": "4.7.0 Beta 1",
"107001": "4.7.0 Beta 1",
"107002": "4.7.0 Beta 2",
"107003": "4.7.0 Beta 2",
"107004": "4.7.0 Beta 3",
"107005": "4.7.0 Beta 4",
"107006": "4.7.0 Beta 4.1",
"107007": "4.7.0 Beta 5",
"107008": "4.7.0 Beta 6",
"107009": "4.7.0 Beta 7",
"107010": "4.7.0 Beta 8",
"107011": "4.7.0 Beta 9",
"107012": "4.7.0 Beta 10",
"107013": "4.7.0",
"107014": "4.7.0"
}
+171 -1
View File
@@ -1 +1,171 @@
{"activeUsers":{"class":"\\IPS\\Widget","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"stats":{"class":"\\IPS\\Widget\\StaticCache","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"relatedContent":{"class":"\\IPS\\Widget","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"recentStatusUpdates":{"class":"\\IPS\\Widget\\StaticCache","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"topContributors":{"class":"\\IPS\\Widget\\StaticCache","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"whosOnline":{"class":"\\IPS\\Widget","restrict":[],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"members":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"modal","embeddable":true},"guestSignUp":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":false,"menu_style":"modal","embeddable":true},"promoted":{"class":"\\IPS\\Widget\\PermissionCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"clubs":{"class":"\\IPS\\Widget","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"modal","embeddable":true},"newsletter":{"class":"\\IPS\\Widget","restrict":["sidebar","cms"],"default_area":"","allow_reuse":false,"menu_style":"modal","embeddable":true},"mostContributions":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"menu","embeddable":true},"twitter":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"modal","embeddable":true},"invite":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":false,"menu_style":"menu","embeddable":true},"stream":{"class":"\\IPS\\Widget\\PermissionCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"menu","embeddable":true},"mostSolved":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":false,"menu_style":"modal","embeddable":true},"achievements":{"class":"\\IPS\\Widget\\StaticCache","restrict":["sidebar","cms"],"default_area":"","allow_reuse":true,"menu_style":"menu","embeddable":true}}
{
"activeUsers": {
"class": "\\IPS\\Widget",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"stats": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"relatedContent": {
"class": "\\IPS\\Widget",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"recentStatusUpdates": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"topContributors": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"whosOnline": {
"class": "\\IPS\\Widget",
"restrict": [],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"members": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "modal",
"embeddable": true
},
"guestSignUp": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": false,
"menu_style": "modal",
"embeddable": true
},
"promoted": {
"class": "\\IPS\\Widget\\PermissionCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"clubs": {
"class": "\\IPS\\Widget",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "modal",
"embeddable": true
},
"newsletter": {
"class": "\\IPS\\Widget",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": false,
"menu_style": "modal",
"embeddable": true
},
"mostContributions": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "menu",
"embeddable": true
},
"twitter": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "modal",
"embeddable": true
},
"invite": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": false,
"menu_style": "menu",
"embeddable": true
},
"stream": {
"class": "\\IPS\\Widget\\PermissionCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "menu",
"embeddable": true
},
"mostSolved": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": false,
"menu_style": "modal",
"embeddable": true
},
"achievements": {
"class": "\\IPS\\Widget\\StaticCache",
"restrict": [
"sidebar",
"cms"
],
"default_area": "",
"allow_reuse": true,
"menu_style": "menu",
"embeddable": true
}
}
@@ -42,7 +42,7 @@ class _Comment extends \IPS\core\Achievements\Actions\AbstractContentAchievement
{
return FALSE;
}
if ( isset( $filters['milestone'] ) )
{
$count = 0;
@@ -50,14 +50,32 @@ class _Comment extends \IPS\core\Achievements\Actions\AbstractContentAchievement
$itemClassesToDeduct = [];
if ( isset( $filters['type'] ) )
{
if ( isset( $filters[ 'nodes_' . str_replace( '\\', '-', $filters['type'] ) ] ) )
$item = $extra->item();
if ( isset( $filters[ 'nodes_' . str_replace( '\\', '-', \get_class( $item ) ) ] ) )
{
$class = $filters['type'];
$where = [];
$where[] = [ $class::$databasePrefix . $class::$databaseColumnMap['author'] . '=?', $subject->member_id ];
$where[] = [ \IPS\Db::i()->in( $class::$databasePrefix . $class::$databaseColumnMap['container'] ), $filters[ 'nodes_' . str_replace( '\\', '-', $filters['type'] ) ] ];
$where = [ [ $class::$databasePrefix . $class::$databaseColumnMap['author'] . '=?', $subject->member_id ] ];
if ( isset( $extra::$databaseColumnMap['first'] ) )
{
$where[] = [ $class::$databasePrefix . $class::$databaseColumnMap['first'] . '=0' ];
}
if ( isset( $class::$databaseColumnMap['approved'] ) )
{
$where[] = [ $class::$databasePrefix . $class::$databaseColumnMap['approved'] . '=?', 1 ];
}
elseif ( isset( $class::$databaseColumnMap['hidden'] ) )
{
$where[] = [ $class::$databasePrefix . $class::$databaseColumnMap['hidden'] . '=?', 0 ];
}
$where[] = [ \IPS\Db::i()->in( $item::$databaseTable . '.' . $item::$databasePrefix . $item::$databaseColumnMap['container'] , $filters[ 'nodes_' . str_replace( '\\', '-', \get_class( $item ) ) ] ) ];
$count += \IPS\Db::i()->select( 'COUNT(*)', $class::$databaseTable, $where )->first();
$count += \IPS\Db::i()->select( 'COUNT(*)', $class::$databaseTable, $where )
->join( $item::$databaseTable, $item::$databasePrefix . $item::$databaseColumnId . '=' . $class::$databasePrefix . $class::$databaseColumnMap['item'] )
->first();
}
else
{
@@ -88,27 +106,30 @@ class _Comment extends \IPS\core\Achievements\Actions\AbstractContentAchievement
return TRUE;
}
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_Comment_author',
'other' => 'achievement_filter_Comment_item_author'
];
}
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra->item()->author() ];
}
@@ -127,6 +148,11 @@ class _Comment extends \IPS\core\Achievements\Actions\AbstractContentAchievement
$sprintf = [];
try
{
if( !\class_exists( $exploded[0] ) )
{
throw new \OutOfRangeException;
}
$comment = $exploded[0]::load( $exploded[1] );
$item = $comment->item();
$sprintf = [ 'htmlsprintf' => [
@@ -91,7 +91,7 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
if ( isset( $filters['milestone'] ) )
{
if ( ( $this->getQuery( 'COUNT(*)', $filters, $filters['promotype'], $subject )->first() + 1 ) < $filters['milestone'] )
if ( ( $this->getQuery( 'COUNT(*)', $filters, $extra['promotype'], $subject )->first() + 1 ) < $filters['milestone'] )
{
return FALSE;
}
@@ -248,7 +248,7 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
break;
case 'core_social_promote':
$promote = \IPS\core\Promote::load( $row['promote_id'] );
$promote->author()->achievementAction( 'core', 'ContentPromotion', [
$promote->object()->author()->achievementAction( 'core', 'ContentPromotion', [
'content' => $promote->object(),
'promotype' => 'promote'
] );
@@ -267,20 +267,24 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
* @param null|boolean $order
* @param null $limit
* @return \IPS\Db\Select
* @throws \InvalidArgumentException
*/
protected function getQuery( $select, $filters, $type, $subject=NULL, $lastId=NULL, $time=NULL, $order=NULL, $limit=NULL )
{
$itemClass = $filters['type'];
if ( isset( $itemClass::$databaseColumnMap['hidden'] ) )
if( isset( $filters['type'] ) )
{
$subWhere = [ [ $itemClass::$databaseColumnMap['hidden'] . '=0' ] ];
}
elseif ( isset( $itemClass::$databaseColumnMap['approved'] ) )
{
$subWhere = [ [ $itemClass::$databaseColumnMap['approved'] . '=1' ] ];
}
$itemClass = $filters['type'];
if ( isset( $itemClass::$databaseColumnMap['hidden'] ) )
{
$subWhere = [ [ $itemClass::$databaseColumnMap['hidden'] . '=0' ] ];
}
elseif ( isset( $itemClass::$databaseColumnMap['approved'] ) )
{
$subWhere = [ [ $itemClass::$databaseColumnMap['approved'] . '=1' ] ];
}
}
/* Recommended (but really called featured in the code just to confuse me) */
if ( $type === 'recommend' )
{
@@ -324,7 +328,7 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
$where[] = [ 'meta_item_id IN(?)', \IPS\Db::i()->select( $itemClass::$databaseColumnId, $itemClass::$databasePrefix . $itemClass::$databaseTable, $subWhere ) ];
}
$query = \IPS\Db::i()->select( $select, 'core_content_meta', $where );
return \IPS\Db::i()->select( $select, 'core_content_meta', $where );
}
else if ( $type === 'feature' )
{
@@ -362,7 +366,7 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
$where[] = [ 'feature_content_id IN(?)', \IPS\Db::i()->select( $itemClass::$databaseColumnId, $itemClass::$databasePrefix . $itemClass::$databaseTable, $subWhere ) ];
}
$query = \IPS\Db::i()->select( $select, 'core_content_featured', $where );
return \IPS\Db::i()->select( $select, 'core_content_featured', $where );
}
else if ( $type === 'promote' )
{
@@ -400,9 +404,9 @@ class _ContentPromotion extends \IPS\core\Achievements\Actions\AbstractContentAc
$where[] = [ 'promote_class_id IN(?)', \IPS\Db::i()->select( $itemClass::$databaseColumnId, $itemClass::$databasePrefix . $itemClass::$databaseTable, $subWhere ) ];
}
$query = \IPS\Db::i()->select( $select, 'core_social_promote', $where, $order, $limit );
return \IPS\Db::i()->select( $select, 'core_social_promote', $where, $order, $limit );
}
return $query;
throw new \InvalidArgumentException;
}
}
@@ -80,9 +80,11 @@ class _FollowContentItem extends \IPS\core\Achievements\Actions\AbstractContentA
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_FollowContentItem_follower',
@@ -93,10 +95,11 @@ class _FollowContentItem extends \IPS\core\Achievements\Actions\AbstractContentA
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra['author'] ];
}
@@ -199,7 +202,7 @@ class _FollowContentItem extends \IPS\core\Achievements\Actions\AbstractContentA
{
$className = 'IPS\\' . $row['follow_app'] . '\\' . mb_ucfirst( $row['follow_area'] );
if ( \in_array( 'IPS\Content\Item', class_parents( $className ) ) )
if ( class_exists( $className ) AND \in_array( 'IPS\Content\Item', class_parents( $className ) ) )
{
$item = $className::load( $row['follow_rel_id'] );
\IPS\Member::load( $row['follow_member_id'] )->achievementAction( 'core', 'FollowContentItem', [
@@ -74,7 +74,7 @@ class _FollowMember extends \IPS\core\Achievements\Actions\AbstractAchievementAc
if ( isset( $filters['milestone'] ) )
{
$where = [];
$where[] = [ 'follow_app=? and follow_area=? and follow_member_id=?', 'core', 'member', $subject->member_id ];
$where[] = [ 'follow_app=? and follow_area=? and follow_rel_id=?', 'core', 'member', $subject->member_id ];
$count = \IPS\Db::i()->select( 'COUNT(*)', 'core_follow', $where )->first();
@@ -90,9 +90,11 @@ class _FollowMember extends \IPS\core\Achievements\Actions\AbstractAchievementAc
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_FollowMember_receiver',
@@ -103,10 +105,11 @@ class _FollowMember extends \IPS\core\Achievements\Actions\AbstractAchievementAc
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra['giver'] ];
}
@@ -127,7 +127,7 @@ class _FollowNode extends \IPS\core\Achievements\Actions\AbstractNodeAchievement
public static function rebuildRow( $row, $data )
{
$class = 'IPS\\' . $row['follow_app'] . '\\' . mb_ucfirst( $row['follow_area'] );
if ( \in_array( 'IPS\Node\Model', class_parents( $class ) ) )
if ( class_exists( $class ) AND \in_array( 'IPS\Node\Model', class_parents( $class ) ) )
{
\IPS\Member::load( $row['follow_member_id'] )->achievementAction( 'core', 'FollowNode', $class::load( $row['follow_rel_id'] ) );
}
@@ -96,27 +96,30 @@ class _JoinClub extends \IPS\core\Achievements\Actions\AbstractAchievementAction
return TRUE;
}
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_JoinClub_joiner',
'other' => 'achievement_filter_JoinClub_owner'
];
}
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra->owner ];
}
@@ -98,6 +98,11 @@ class _NewContentItem extends \IPS\core\Achievements\Actions\AbstractContentAchi
$sprintf = [];
try
{
if( !\class_exists( $exploded[0] ) )
{
throw new \OutOfRangeException;
}
$item = $exploded[0]::load( $exploded[1] );
$sprintf = [ 'htmlsprintf' => [
\IPS\Theme::i()->getTemplate( 'global', 'core', 'global' )->basicUrl( $item->url(), TRUE, $item->mapped('title') ?: $item->indefiniteArticle(), FALSE )
@@ -40,6 +40,16 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
], NULL, \IPS\Member::loggedIn()->language()->addToStack( 'achievement_subfilter_Reaction_reaction_prefix' ) );
$return['reactions'] = $reactionFilter;
$return['milestone'] = new \IPS\Helpers\Form\Custom( 'achievement_filter_Reaction_nth', ( $filters and isset( $filters['milestone'] ) and $filters['milestone'] ) ? $filters['milestone'] : [], FALSE, array( 'getHtml' => function( $element )
{
/* 4.6.0 - 4.6.3 */
if ( \is_integer( $element->value ) )
{
$element->value = ['receiver', $element->value];
}
return \IPS\Theme::i()->getTemplate( 'achievements' )->milestoneWithSubjectSwitch( $element->name, $element->value );
} ), NULL, NULL, NULL, 'achievement_filter_Reaction_nth' );
return $return;
}
@@ -56,6 +66,7 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
{
$return['reactions'] = array_keys( $values['achievement_filter_Reaction_reaction'] );
}
return $return;
}
@@ -77,7 +88,7 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
{
return FALSE;
}
if ( isset( $filters['reactions'] ) )
{
if ( !\in_array( $extra['reaction']->id, $filters['reactions'] ) )
@@ -85,12 +96,26 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
return FALSE;
}
}
if ( isset( $filters['milestone'] ) )
{
$query = $this->getQuery( 'COUNT(*)', [ [ 'member_id=?', $subject->member_id ] ], NULL, $filters );
if ( ( $query->first() + 1 ) < $filters['milestone'] )
if ( isset( $filters['milestone'] ) and \is_array( $filters['milestone'] ) )
{
$field = ( $filters['milestone'][0] == 'giver' ) ? 'member_id' : 'member_received';
$member = ( $filters['milestone'][0] == 'giver' ) ? $extra['giver'] : $subject;
$milestone = $filters['milestone'][1];
}
else
{
/* 4.6.0 - 4.6.3 just had a milestone for member_received */
$field = 'member_received';
$milestone = $filters['milestone'];
$member = $subject;
}
$query = $this->getQuery( 'COUNT(*)', [ [ $field . '=?', $member->member_id ] ], NULL, $filters );
if ( ( $query->first() + 1 ) < $milestone )
{
return FALSE;
}
@@ -111,27 +136,30 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
{
return \get_class( $extra['content'] ) . ':' . $extra['content']->{$extra['content']::$databaseColumnId} . ':' . $extra['giver']->member_id;
}
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_Reaction_receiver',
'other' => 'achievement_filter_Reaction_giver'
'subject' => 'achievement_filter_Reaction_receiver',
'other' => 'achievement_filter_Reaction_giver'
];
}
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra['giver'] ];
}
@@ -181,9 +209,19 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
$conditions = [];
if ( isset( $rule->filters['milestone'] ) )
{
if ( \is_integer( $rule->filters['milestone'] ) )
{
/* 4.6.0 - 4.6.3 */
$milestone = $rule->filters['milestone'];
}
else
{
$milestone = $rule->filters['milestone'][1];
}
$conditions[] = \IPS\Member::loggedIn()->language()->addToStack( 'achievements_title_filter_milestone', FALSE, [
'htmlsprintf' => [
\IPS\Theme::i()->getTemplate( 'achievements' )->ruleDescriptionBadge( 'milestone', \IPS\Member::loggedIn()->language()->addToStack( 'achievements_title_filter_milestone_nth', FALSE, [ 'pluralize' => [ $rule->filters['milestone'] ] ] ) )
\IPS\Theme::i()->getTemplate( 'achievements' )->ruleDescriptionBadge( 'milestone', \IPS\Member::loggedIn()->language()->addToStack( 'achievements_title_filter_milestone_nth', FALSE, [ 'pluralize' => [ $milestone ] ] ) )
],
'sprintf' => \IPS\Member::loggedIn()->language()->addToStack('AchievementAction__Reaction_title_generic')
] );
@@ -219,7 +257,9 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
}
return \IPS\Theme::i()->getTemplate( 'achievements' )->ruleDescription(
\IPS\Member::loggedIn()->language()->addToStack( 'AchievementAction__Reaction_title' ),
( ( isset( $rule->filters['milestone'] ) and ( ( \is_array( $rule->filters['milestone'] ) and $rule->filters['milestone'][0] == 'giver' ) or \is_numeric( $rule->filters['milestone'] ) ) ) or ! isset( $rule->filters['milestone']) )
? \IPS\Member::loggedIn()->language()->addToStack( 'AchievementAction__Reaction_title' )
: \IPS\Member::loggedIn()->language()->addToStack( 'AchievementAction__Reaction_title_received' ),
$conditions
);
}
@@ -254,9 +294,27 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
return;
}
$object = $row['rep_class']::load( $row['item_id'] );
$object = $row['rep_class']::load( $row['type_id'] );
$reaction = \IPS\Content\Reaction::load( $row['reaction'] );
/* Give points */
static::getAuthor( $object )->achievementAction( 'core', 'Reaction', [
'giver' => \IPS\Member::load( $row['member_id'] ),
'content' => $object,
'reaction' => $reaction
] );
}
/**
* Get the author of the content / node
*
* @param $object
* @return \IPS\Member|null
*/
public static function getAuthor( $object ): ?\IPS\Member
{
$owner = NULL;
/* Figure out the owner of this - if it is content, it will be the author. If it is a node, then it will be the person who created it */
if ( $object instanceof \IPS\Content )
{
@@ -267,12 +325,7 @@ class _Reaction extends \IPS\core\Achievements\Actions\AbstractContentAchievemen
$owner = $object->owner();
}
/* Give points */
$owner->achievementAction( 'core', 'Reaction', [
'giver' => \IPS\Member::load( $row['member_id'] ),
'content' => $object,
'reaction' => $reaction
] );
return $owner;
}
/**
@@ -91,27 +91,30 @@ class _Review extends \IPS\core\Achievements\Actions\AbstractContentAchievementA
return TRUE;
}
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_Review_author',
'other' => 'achievement_filter_Review_item_author'
];
}
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra->item()->author() ];
}
@@ -126,7 +126,8 @@ class _SessionStartDaily extends \IPS\core\Achievements\Actions\AbstractAchievem
*/
public function logRow( string $identifier, array $actor ): string
{
return \IPS\Member::loggedIn()->language()->addToStack( 'AchievementAction__SessionStartDaily_log', FALSE, array( 'sprintf' => ( new \IPS\DateTime( $identifier ) )->dayAndMonth() ) );
list( $id, $time ) = explode( '.', $identifier );
return \IPS\Member::loggedIn()->language()->addToStack( 'AchievementAction__SessionStartDaily_log', FALSE, array( 'sprintf' => ( new \IPS\DateTime( $time ) )->dayAndMonth() ) );
}
/**
@@ -86,28 +86,30 @@ class _VotePoll extends \IPS\core\Achievements\Actions\AbstractAchievementAction
return TRUE;
}
/**
* Get the labels for the people this action might give awards to
*
* @param array|NULL $filters Current filter values
*
* @return array
*/
public function awardOptions(): array
public function awardOptions( ?array $filters ): array
{
return [
'subject' => 'achievement_filter_VotePoll_voter',
'other' => 'achievement_filter_VotePoll_author'
];
}
/**
* Get the "other" people we need to award =stuff to
*
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param mixed $extra Any additional information about what is happening (e.g. if a post is being made: the post object)
* @param array|NULL $filters Current filter values
* @return array
*/
public function awardOther( $extra = NULL ): array
public function awardOther( $extra = NULL, ?array $filters = NULL ): array
{
return [ $extra->author() ];
}
@@ -108,7 +108,8 @@ class _Bulletin extends \IPS\core\AdminNotification
{
try
{
$bulletin = \IPS\Http\Url::ips("bulletin/{$data['id']}")->request()->get()->decodeJson();
$response = \IPS\Http\Url::ips("bulletin/{$data['id']}")->request()->get();
$bulletin = $response->decodeJson();
if ( isset( $bulletin['title'] ) )
{
$data = array(
@@ -128,6 +129,12 @@ class _Bulletin extends \IPS\core\AdminNotification
}
else
{
if( (int) $response->httpResponseCode === 410 )
{
\IPS\Db::i()->delete( 'core_ips_bulletins', [ 'id=?', $this->extra ] );
$this->delete();
}
throw new \DomainException;
}
}
@@ -238,11 +245,7 @@ class _Bulletin extends \IPS\core\AdminNotification
return !@eval( $this->data()['conditions'] );
}
catch ( \Exception $e )
{
return FALSE;
}
catch ( \Throwable $e )
catch ( \Throwable | \Exception $e )
{
return FALSE;
}
@@ -548,6 +548,10 @@ class _ConfigurationError extends \IPS\core\AdminNotification
}
elseif ( $this->extra === 'cacheBroken' )
{
if( \IPS\CIC )
{
return \IPS\Member::loggedIn()->language()->addToStack('dashboard_invalid_cachesetup_desc_cic');
}
return \IPS\Member::loggedIn()->language()->addToStack('dashboard_invalid_cachesetup_desc');
}
elseif ( $this->extra === 'cicEmailQuota' )
@@ -60,6 +60,11 @@ class _NewVersion extends \IPS\core\AdminNotification
*/
public static function permissionCheck( \IPS\Member $member )
{
if ( \IPS\CIC AND \IPS\IPS::isManaged() )
{
return FALSE;
}
return $member->hasAcpRestriction( 'core', 'overview', 'upgrade_manage' );
}
@@ -163,4 +168,15 @@ class _NewVersion extends \IPS\core\AdminNotification
{
return \IPS\Http\Url::internal( 'app=core&module=system&controller=upgrade&_new=1', 'admin' );
}
/**
* Should this notification dismiss itself?
*
* @note This is checked every time the notification shows. Should be lightweight.
* @return bool
*/
public function selfDismiss()
{
return empty( $this->_details['version'] );
}
}
@@ -0,0 +1,127 @@
<?php
/**
* @brief Community Enhancements
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 13 Sep 2021
*/
namespace IPS\core\extensions\core\CommunityEnhancements;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Community Enhancement
*/
class _GoogleAnalytics
{
/**
* @brief Enhancement is enabled?
*/
public $enabled = FALSE;
/**
* @brief IPS-provided enhancement?
*/
public $ips = FALSE;
/**
* @brief Enhancement has configuration options?
*/
public $hasOptions = TRUE;
/**
* @brief Icon data
*/
public $icon = "google_analytics.png";
/**
* Constructor
*
* @return void
*/
public function __construct()
{
$this->enabled = ( \IPS\Settings::i()->ga_enabled and \IPS\Settings::i()->ga_code );
}
/**
* Edit
*
* @return void
*/
public function edit()
{
$validation = function( $val ) {
if ( $val and !\IPS\Request::i()->ga_code )
{
throw new \DomainException('ga_code_required');
}
};
$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\YesNo( 'ga_enabled', \IPS\Settings::i()->ga_enabled, FALSE, array(), $validation ) );
$form->add( new \IPS\Helpers\Form\Codemirror( 'ga_code', \IPS\Settings::i()->ga_code, FALSE, array( 'height' => 150, 'mode' => 'javascript' ), NULL, NULL, NULL, 'ga_code' ) );
if ( $form->values() )
{
try
{
$form->saveAsSettings();
\IPS\Output::i()->inlineMessage = \IPS\Member::loggedIn()->language()->addToStack('saved');
}
catch ( \LogicException $e )
{
$form->error = $e->getMessage();
}
}
\IPS\Output::i()->sidebar['actions'] = array(
'help' => array(
'title' => 'learn_more',
'icon' => 'question-circle',
'link' => \IPS\Http\Url::ips( 'docs/googleanalytics' ), //@todo
'target' => '_blank'
),
);
\IPS\Output::i()->output = \IPS\Theme::i()->getTemplate( 'global' )->block( 'enhancements__core_GoogleAnalytics', $form );
}
/**
* Enable/Disable
*
* @param $enabled bool Enable/Disable
* @return void
* @throws \LogicException
*/
public function toggle( $enabled )
{
if ( $enabled )
{
if ( \IPS\Settings::i()->ga_code )
{
\IPS\Settings::i()->changeValues( array( 'ga_enabled' => 1 ) );
}
else
{
throw new \DomainException;
}
}
else
{
\IPS\Settings::i()->changeValues( array( 'ga_enabled' => 0 ) );
}
}
}
@@ -0,0 +1,133 @@
<?php
/**
* @brief Community Enhancements
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 13 Sep 2021
*/
namespace IPS\core\extensions\core\CommunityEnhancements;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Community Enhancement
*/
class _GoogleTagManager
{
/**
* @brief Enhancement is enabled?
*/
public $enabled = FALSE;
/**
* @brief IPS-provided enhancement?
*/
public $ips = FALSE;
/**
* @brief Enhancement has configuration options?
*/
public $hasOptions = TRUE;
/**
* @brief Icon data
*/
public $icon = "google_tag_manager.png";
/**
* Constructor
*
* @return void
*/
public function __construct()
{
$this->enabled = ( \IPS\Settings::i()->googletag_enabled and \IPS\Settings::i()->googletag_head_code and \IPS\Settings::i()->googletag_noscript_code );
}
/**
* Edit
*
* @return void
*/
public function edit()
{
$validation = function( $val ) {
if ( $val and ( !\IPS\Request::i()->googletag_head_code or !\IPS\Request::i()->googletag_noscript_code ) )
{
throw new \DomainException('googletag_code_required');
}
};
$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\YesNo( 'googletag_enabled', \IPS\Settings::i()->googletag_enabled, FALSE, array(), $validation ) );
if ( \IPS\Settings::i()->core_datalayer_enabled )
{
$form->add( new \IPS\Helpers\Form\YesNo( 'core_datalayer_use_gtm', \IPS\Settings::i()->core_datalayer_use_gtm, FALSE ) );
$form->add( new \IPS\Helpers\Form\Text( 'core_datalayer_gtmkey', \IPS\Settings::i()->core_datalayer_gtmkey, FALSE ) );
}
$form->add( new \IPS\Helpers\Form\Codemirror( 'googletag_head_code', \IPS\Settings::i()->googletag_head_code, FALSE, array( 'height' => 150, 'mode' => 'javascript' ), NULL, NULL, NULL, 'googletag_head_code' ) );
$form->add( new \IPS\Helpers\Form\Codemirror( 'googletag_noscript_code', \IPS\Settings::i()->googletag_noscript_code, FALSE, array( 'height' => 150, 'mode' => 'javascript' ), NULL, NULL, NULL, 'googletag_noscript_code' ) );
if ( $form->values() )
{
try
{
$form->saveAsSettings();
\IPS\Output::i()->inlineMessage = \IPS\Member::loggedIn()->language()->addToStack('saved');
}
catch ( \LogicException $e )
{
$form->error = $e->getMessage();
}
}
\IPS\Output::i()->sidebar['actions'] = array(
'help' => array(
'title' => 'learn_more',
'icon' => 'question-circle',
'link' => \IPS\Http\Url::ips( 'docs/googletagmanager' ),
'target' => '_blank'
),
);
\IPS\Output::i()->output = \IPS\Theme::i()->getTemplate( 'global' )->block( 'enhancements__core_GoogleTagManager', $form );
}
/**
* Enable/Disable
*
* @param $enabled bool Enable/Disable
* @return void
* @throws \LogicException
*/
public function toggle( $enabled )
{
if ( $enabled )
{
if ( \IPS\Settings::i()->googletag_head_code and \IPS\Settings::i()->googletag_noscript_code )
{
\IPS\Settings::i()->changeValues( array( 'googletag_enabled' => 1 ) );
}
else
{
throw new \DomainException;
}
}
else
{
\IPS\Settings::i()->changeValues( array( 'googletag_enabled' => 0 ) );
}
}
}
@@ -0,0 +1,79 @@
<?php
/**
* @brief Community Enhancements
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 11 Jan 2022
*/
namespace IPS\core\extensions\core\CommunityEnhancements;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Community Enhancement
*/
class _IndexNow
{
/**
* @brief Enhancement is enabled?
*/
public $enabled = FALSE;
/**
* @brief IPS-provided enhancement?
*/
public $ips = FALSE;
/**
* @brief Enhancement has configuration options?
*/
public $hasOptions = FALSE;
/**
* @brief Icon data
*/
public $icon = "";
/**
* Constructor
*
* @return void
*/
public function __construct()
{
$this->enabled = \IPS\Settings::i()->indexnow_enabled;
}
/**
* Enable/Disable
*
* @param $enabled bool Enable/Disable
* @return void
* @throws \LogicException
*/
public function toggle( $enabled )
{
/* If we're disabling, just disable */
if( !$enabled )
{
\IPS\Settings::i()->changeValues( array( 'indexnow_enabled' => 0 ) );
\IPS\Settings::i()->changeValues( array( 'indexnow_key' => '' ) );
}
else
{
$key = \IPS\Login::generateRandomString();
\IPS\Settings::i()->changeValues( array( 'indexnow_enabled' => 1 ) );
\IPS\Settings::i()->changeValues( array( 'indexnow_key' => $key ) );
}
}
}
@@ -0,0 +1,127 @@
<?php
/**
* @brief Community Enhancements
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 13 Sep 2021
*/
namespace IPS\core\extensions\core\CommunityEnhancements;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Community Enhancement
*/
class _Matomo
{
/**
* @brief Enhancement is enabled?
*/
public $enabled = FALSE;
/**
* @brief IPS-provided enhancement?
*/
public $ips = FALSE;
/**
* @brief Enhancement has configuration options?
*/
public $hasOptions = TRUE;
/**
* @brief Icon data
*/
public $icon = "matomo.png";
/**
* Constructor
*
* @return void
*/
public function __construct()
{
$this->enabled = ( \IPS\Settings::i()->matomo_enabled and \IPS\Settings::i()->matomo_code );
}
/**
* Edit
*
* @return void
*/
public function edit()
{
$validation = function( $val ) {
if ( $val and !\IPS\Request::i()->matomo_code )
{
throw new \DomainException('matomo_code_required');
}
};
$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\YesNo( 'matomo_enabled', \IPS\Settings::i()->matomo_enabled, FALSE, array(), $validation ) );
$form->add( new \IPS\Helpers\Form\Codemirror( 'matomo_code', \IPS\Settings::i()->matomo_code, FALSE, array( 'height' => 150, 'mode' => 'javascript' ), NULL, NULL, NULL, 'matomo_code' ) );
if ( $form->values() )
{
try
{
$form->saveAsSettings();
\IPS\Output::i()->inlineMessage = \IPS\Member::loggedIn()->language()->addToStack('saved');
}
catch ( \LogicException $e )
{
$form->error = $e->getMessage();
}
}
\IPS\Output::i()->sidebar['actions'] = array(
'help' => array(
'title' => 'learn_more',
'icon' => 'question-circle',
'link' => \IPS\Http\Url::ips( 'docs/matomo' ),
'target' => '_blank'
),
);
\IPS\Output::i()->output = \IPS\Theme::i()->getTemplate( 'global' )->block( 'enhancements__core_Matomo', $form );
}
/**
* Enable/Disable
*
* @param $enabled bool Enable/Disable
* @return void
* @throws \LogicException
*/
public function toggle( $enabled )
{
if ( $enabled )
{
if ( \IPS\Settings::i()->matomo_code )
{
\IPS\Settings::i()->changeValues( array( 'matomo_enabled' => 1 ) );
}
else
{
throw new \DomainException;
}
}
else
{
\IPS\Settings::i()->changeValues( array( 'matomo_enabled' => 0 ) );
}
}
}
@@ -106,20 +106,7 @@ class _Viglink
}
else
{
$json = $this->_makeApiCall();
$form = new \IPS\Helpers\Form;
$form->attributes['data-controller'] = 'core.admin.core.viglink';
$form->attributes['data-viglinkUrl'] = $json['URL'];
$form->add( new \IPS\Helpers\Form\Radio( 'viglink_account_type', 'create', FALSE, array(
'options' => array(
'create' => 'viglink_account_type_create',
'existing' => 'viglink_account_existing'
),
'toggles' => array(
'existing' => array( 'viglink_api_key' ),
),
) ) );
$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\Text( 'viglink_api_key', NULL, FALSE, array(), function( $val ){
if( !$val && \IPS\Request::i()->viglink_account_type == 'existing' )
{
@@ -129,16 +116,7 @@ class _Viglink
if ( $values = $form->values() )
{
if ( $values['viglink_account_type'] == 'create' )
{
$values['viglink_api_key'] = $json['API_KEY'];
$values['viglink_subid'] = $json['SUBID'];
}
else
{
$values['viglink_subid'] = '';
}
$values['viglink_subid'] = '';
$values['viglink_enabled'] = TRUE;
unset( $values['viglink_account_type'] );
$form->saveAsSettings( $values );
@@ -150,45 +128,6 @@ class _Viglink
\IPS\Output::i()->output = $form;
}
/**
* Make call to IPS to get API keys
*
* @return array
*/
protected function _makeApiCall()
{
$subId = NULL;
if ( \IPS\Settings::i()->ipb_reg_number )
{
$exploded = explode( '-', \IPS\Settings::i()->ipb_reg_number );
if ( isset( $exploded[3] ) )
{
$subId = $exploded[3];
}
}
if ( $subId === NULL )
{
$subId = \IPS\Settings::i()->board_url;
if ( \strlen( $subId ) > 32 )
{
$subId = str_replace( array( 'http://', 'https://' ), '', $subId );
}
if ( \strlen( $subId ) > 32 )
{
$subId = md5( $subId );
}
}
try
{
return \IPS\Http\Url::ips( "viglink/{$subId}" )->request()->get()->decodeJson();
}
catch ( \IPS\Http\Url\Exception $e )
{
\IPS\Output::i()->error( 'viglink_error', '5S144/2', 500, '' );
}
}
/**
* Enable/Disable
*
@@ -28,14 +28,17 @@ class _Zapier
*
* @return array
*/
protected static function apiKeyPermissions()
public static function apiKeyPermissions()
{
$return = array(
'core/clubs/GETindex' => array( 'access' => TRUE ),
'core/clubs/GETitem' => array( 'access' => TRUE ),
'core/groups/GETindex' => array( 'access' => TRUE ),
'core/hello/GETindex' => array( 'access' => TRUE ),
'core/members/GETindex' => array( 'access' => TRUE ),
'core/members/GETitem' => array( 'access' => TRUE ),
'core/members/POSTindex' => array( 'access' => TRUE ),
'core/members/POSTitem' => array( 'access' => TRUE ),
'core/webhooks/POSTindex' => array( 'access' => TRUE ),
'core/webhooks/DELETEitem' => array( 'access' => TRUE ),
);
@@ -163,7 +166,7 @@ class _Zapier
*/
public static function isAvailable()
{
return \IPS\CIC;
return TRUE;
}
/**
@@ -275,19 +278,22 @@ class _Zapier
*/
protected function testSettings()
{
if ( \IPS\Request::i()->isCgi() )
{
throw new \DomainException( 'zapier_error_cgi' );
}
if ( !\IPS\Settings::i()->use_friendly_urls or !\IPS\Settings::i()->htaccess_mod_rewrite )
{
throw new \DomainException( 'zapier_error_friendly_urls' );
}
$url = \IPS\Http\Url::external( rtrim( \IPS\Settings::i()->base_url, '/' ) . '/api/core/hello' );
try
{
$response = $url->request()->login( 'test', '' )->get()->decodeJson();
if ( \IPS\Request::i()->isCgi() )
{
$response = $url->setQueryString( 'key', 'test' )->request()->get()->decodeJson();
}
else
{
$response = $url->request()->login( 'test', '' )->get()->decodeJson();
}
if ( isset( $response['errorMessage'] ) AND $response['errorMessage'] == 'IP_ADDRESS_BANNED' )
{
throw new \Exception;
@@ -36,7 +36,7 @@ class _Status
*/
public function __construct( $member = NULL )
{
if ( \IPS\Settings::i()->profile_comments and ( $member === NULL or $member->canAccessModule( \IPS\Application\Module::get( 'core', 'status', 'front' ) ) ) )
if ( \IPS\Settings::i()->profile_comments and ( $member === NULL or ( $member->canAccessModule( \IPS\Application\Module::get( 'core', 'members', 'front' ) ) AND $member->canAccessModule( \IPS\Application\Module::get( 'core', 'status', 'front' ) ) ) ) )
{
$this->classes[] = 'IPS\core\Statuses\Status';
}
@@ -116,6 +116,10 @@ class _Admin
case 'forumsSavedAction':
return \IPS\Http\Url::internal( 'app=forums&module=forums&controller=savedActions&do=form&id=' . $id1, 'admin' );
break;
case 'editor_stored_replies':
return \IPS\Http\Url::internal( 'app=core&module=editor&controller=storedreplies&do=form&id=' . $id1, 'admin' );
break;
}
return NULL;
@@ -0,0 +1,208 @@
<?php
/**
* @brief Editor Extension: Alerts
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 12 May 2022
*/
namespace IPS\core\extensions\core\EditorLocations;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Editor Extension: Alerts
*/
class _Alert
{
/**
* Can we use HTML in this editor?
*
* @param \IPS\Member $member The member
* @param \IPS\Helpers\Form\Editor $field The editor field
* @return bool|null NULL will cause the default value (based on the member's permissions) to be used, and is recommended in most cases. A boolean value will override that.
*/
public function canUseHtml( $member, $field )
{
return NULL;
}
/**
* Can we use attachments in this editor?
*
* @param \IPS\Member $member The member
* @param \IPS\Helpers\Form\Editor $field The editor field
* @return bool|null NULL will cause the default value (based on the member's permissions) to be used, and is recommended in most cases. A boolean value will override that.
*/
public function canAttach( $member, $field )
{
return NULL;
}
/**
* Permission check for attachments
*
* @param \IPS\Member $member The member
* @param int|null $id1 Primary ID
* @param int|null $id2 Secondary ID
* @param string|null $id3 Arbitrary data
* @param array $attachment The attachment data
* @param bool $viewOnly If true, just check if the user can see the attachment rather than download it
* @return bool
*/
public function attachmentPermissionCheck( $member, $id1, $id2, $id3, $attachment, $viewOnly=FALSE )
{
return \IPS\core\Alerts\Alert::load( $id1 )->canView( $member );
}
/**
* Attachment lookup
*
* @param int|null $id1 Primary ID
* @param int|null $id2 Secondary ID
* @param string|null $id3 Arbitrary data
* @return \IPS\Http\Url|\IPS\Content|\IPS\Node\Model
* @throws \LogicException
*/
public function attachmentLookup( $id1, $id2, $id3 )
{
return \IPS\core\Alerts\Alert::load( $id1 );
}
/**
* Rebuild attachment images in non-content item areas
*
* @param int|null $offset Offset to start from
* @param int|null $max Maximum to parse
* @return int Number completed
* @note This method is optional and will only be called if it exists
*/
public function rebuildAttachmentImages( $offset, $max )
{
return $this->performRebuild( $offset, $max, array( 'IPS\Text\Parser', 'rebuildAttachmentUrls' ) );
}
/**
* Rebuild content post-upgrade
*
* @param int|null $offset Offset to start from
* @param int|null $max Maximum to parse
* @return int Number completed
* @note This method is optional and will only be called if it exists
*/
public function rebuildContent( $offset, $max )
{
return $this->performRebuild( $offset, $max, array( 'IPS\Text\LegacyParser', 'parseStatic' ) );
}
/**
* @brief Use the cached image URL instead of the original URL
*/
protected $proxyUrl = FALSE;
/**
* Rebuild content to add or remove image proxy
*
* @param int|null $offset Offset to start from
* @param int|null $max Maximum to parse
* @param bool $proxyUrl Use the cached image URL instead of the original URL
* @return int Number completed
* @note This method is optional and will only be called if it exists
*/
public function rebuildImageProxy( $offset, $max, $proxyUrl = FALSE )
{
$this->proxyUrl = $proxyUrl;
return $this->performRebuild( $offset, $max, 'parseImageProxy' );
}
/**
* @brief Store lazy loading status ( true = enabled )
*/
protected $_lazyLoadStatus = null;
/**
* Rebuild content to add or remove lazy loading
*
* @param int|null $offset Offset to start from
* @param int|null $max Maximum to parse
* @param bool $status Enable/Disable lazy loading
* @return int Number completed
* @note This method is optional and will only be called if it exists
*/
public function rebuildLazyLoad( $offset, $max, $status=TRUE )
{
$this->_lazyLoadStatus = $status;
return $this->performRebuild( $offset, $max, 'parseLazyLoad' );
}
/**
* Perform rebuild - abstracted as the call for rebuildContent() and rebuildAttachmentImages() is nearly identical
*
* @param int|null $offset Offset to start from
* @param int|null $max Maximum to parse
* @param callable $callback Method to call to rebuild content
* @return int Number completed
*/
protected function performRebuild( $offset, $max, $callback )
{
$did = 0;
foreach( \IPS\Db::i()->select( '*', 'core_alerts', "alert_content IS NOT NULL", 'alert_id ASC', array( $offset, $max ) ) as $alert )
{
$did++;
/* Update */
try
{
if( $callback == 'parseImageProxy' )
{
$rebuilt = \IPS\Text\Parser::removeImageProxy( $alert['alert_content'], $this->proxyUrl );
}
elseif( $callback == 'parseLazyLoad' )
{
$rebuilt = \IPS\Text\Parser::parseLazyLoad( $alert['alert_content'], $this->_lazyLoadStatus );
}
else
{
$rebuilt = $callback( $alert['alert_content'], \IPS\Member::load( $alert['alert_member_id'] ), FALSE, 'core_Alert' );
}
}
catch( \InvalidArgumentException $e )
{
if( $callback[1] == 'parseStatic' AND $e->getcode() == 103014 )
{
$rebuilt = preg_replace( "#\[/?([^\]]+?)\]#", '', $alert['alert_content'] );
}
else
{
throw $e;
}
}
if( $rebuilt !== FALSE )
{
\IPS\Db::i()->update( 'core_alerts', array( 'alert_content' => $rebuilt ), array( 'alert_id=?', $alert['alert_id'] ) );
}
}
return $did;
}
/**
* Total content count to be used in progress indicator
*
* @return int Total Count
*/
public function contentCount()
{
return \IPS\Db::i()->select( 'COUNT(*) as count', 'core_alerts', "alert_content IS NOT NULL" )->first();
}
}
@@ -44,6 +44,37 @@ class _Members
{
return NULL;
}
/**
* Can whatever is posted in this editor be moderated?
* If this returns TRUE, we must ensure the content is ran through word, link and image filters
*
* @param \IPS\Member $member The member
* @param \IPS\Helpers\Form\Editor $field The editor field
* @return bool
*/
public function canBeModerated( $member, $field )
{
/* Creating/editing an status update */
if ( preg_match( '/^status(\d+)?(?:_\d+)?$/', $field->options['autoSaveKey'] ) )
{
return TRUE;
}
/* Creating/editing a reply to a status update */
elseif ( preg_match( '/^(?:reply|editComment)\-core\/members-(\d+)$/', $field->options['autoSaveKey'] ) )
{
return TRUE;
}
/* Unknown */
else
{
if ( \IPS\IN_DEV )
{
throw new \RuntimeException( 'Unknown canBeModerated: ' . $field->options['autoSaveKey'] );
}
return FALSE;
}
}
/**
* Permission check for attachments
@@ -0,0 +1,120 @@
<?php
/**
* @brief File Storage Extension: Ranks
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 25 Mar 2022
*/
namespace IPS\core\extensions\core\FileStorage;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* File Storage Extension: Ranks
*/
class _Ranks
{
/**
* Count stored files
*
* @return int
*/
public function count()
{
return \IPS\Db::i()->select( 'COUNT(*)', 'core_member_ranks', 'icon IS NOT NULL' )->first();
}
/**
* Move stored files
*
* @param int $offset This will be sent starting with 0, increasing to get all files stored by this extension
* @param int $storageConfiguration New storage configuration ID
* @param int|NULL $oldConfiguration Old storage configuration ID
* @throws \UnderflowException When file record doesn't exist. Indicating there are no more files to move
* @return void|int An offset integer to use on the next cycle, or nothing
*/
public function move( $offset, $storageConfiguration, $oldConfiguration=NULL )
{
$rankData = \IPS\Db::i()->select( '*', 'core_member_ranks', 'icon IS NOT NULL', 'id', array( $offset, 1 ) )->first();
try
{
$file = \IPS\File::get( $oldConfiguration ?: 'core_Ranks', $rankData['icon'] )->move( $storageConfiguration );
if ( (string) $file != $rankData['icon'] )
{
\IPS\Db::i()->update( 'core_member_ranks', array( 'icon' => (string) $file ), array( 'id=?', $rankData['id'] ) );
}
}
catch( \Exception $e )
{
/* Any issues are logged */
}
}
/**
* Fix all URLs
*
* @param int $offset This will be sent starting with 0, increasing to get all files stored by this extension
* @return void
*/
public function fixUrls( $offset )
{
$rankData = \IPS\Db::i()->select( '*', 'core_member_ranks', 'icon IS NOT NULL', 'id', array( $offset, 1 ) )->first();
try
{
if ( $new = \IPS\File::repairUrl( $rankData['icon'] ) )
{
\IPS\Db::i()->update( 'core_member_ranks', [ 'icon' => $new ], array( 'id=?', $rankData['id'] ) );
}
}
catch( \Exception $e ) { }
}
/**
* Check if a file is valid
*
* @param string $file The file path to check
* @return bool
*/
public function isValidFile( $file )
{
try
{
$rankData = \IPS\Db::i()->select( '*', 'core_member_ranks', array( 'icon=?', (string) $file ) )->first();
return TRUE;
}
catch ( \UnderflowException $e )
{
return FALSE;
}
}
/**
* Delete all stored files
*
* @return void
*/
public function delete()
{
foreach( \IPS\Db::i()->select( '*', 'core_member_ranks', 'icon IS NOT NULL' ) as $rankData )
{
try
{
\IPS\File::get( 'core_member_ranks', $rankData['icon'] )->delete();
}
catch( \Exception $e ){}
}
}
}
@@ -54,7 +54,7 @@ class _Reaction
/* Any issues are logged */
}
if ( $url != $reaction['reaction_icon'] )
if ( !empty( $url ) AND $url != $reaction['reaction_icon'] )
{
\IPS\Db::i()->update( 'core_reactions', array( 'reaction_icon' => $url ), array( 'reaction_id=?', $reaction['reaction_id'] ) );
unset( \IPS\Data\Store::i()->reactions );
@@ -180,6 +180,10 @@ class _Content
return \IPS\Theme::i()->getTemplate( 'members' )->moderationLimits( $element->name, $element->value );
} ), NULL, NULL, NULL, 'g_mod_post_unit' ) );
$form->add( new \IPS\Helpers\Form\YesNo( 'g_bypass_badwords', $group->g_bypass_badwords ) );
if ( \IPS\Settings::i()->ips_imagescanner_enable )
{
\IPS\Member::loggedIn()->language()->words['g_bypass_badwords'] = \IPS\Member::loggedIn()->language()->addToStack('g_bypass_badwords_images');
}
/* Promotion */
if( $group->g_id != \IPS\Settings::i()->guest_group )
@@ -45,7 +45,7 @@ class _GroupSettings
}
catch ( \Exception $e ) { }
}
$form->add( new \IPS\Helpers\Form\Upload( 'g_icon', $icon, FALSE, array( 'storageExtension' => 'core_Theme', 'allowedFileTypes' => array( 'gif', 'png', 'jpeg', 'jpg' ) ) ) );
$form->add( new \IPS\Helpers\Form\Upload( 'g_icon', $icon, FALSE, array( 'storageExtension' => 'core_Theme', 'allowedFileTypes' => \IPS\Image::supportedExtensions() ) ) );
/* Prefix/Suffix */
$form->add( new \IPS\Helpers\Form\Custom( 'g_prefixsuffix', array( 'prefix' => $group->prefix, 'suffix' => $group->suffix ), FALSE, array(
@@ -171,7 +171,7 @@ class _GroupSettings
/* Search */
if ( $group->canAccessModule( \IPS\Application\Module::get( 'core', 'search', 'front' ) ) )
{
$form->add( new \IPS\Helpers\Form\Interval( 'g_search_flood', $group->g_search_flood, FALSE, array( 'valueAs' => \IPS\Helpers\Form\Interval::SECONDS, 'unlimited' => 0 ) ) );
$form->add( new \IPS\Helpers\Form\Interval( 'g_search_flood', $group->g_id ? $group->g_search_flood : 0, FALSE, array( 'valueAs' => \IPS\Helpers\Form\Interval::SECONDS, 'unlimited' => 0 ) ) );
}
/* Privacy */
@@ -380,4 +380,19 @@ class _GroupSettings
$newGroup->save();
}
}
/**
* Can this group be deleted?
*
* @param \IPS\Member\Group $group The group
* @return void
*/
public function canDelete( $group ) : bool
{
if ( \in_array( $group->g_id, array( \IPS\Settings::i()->guest_group, \IPS\Settings::i()->member_group, \IPS\Settings::i()->admin_group ) ) )
{
return FALSE;
}
return TRUE;
}
}
@@ -59,25 +59,44 @@ class _Content extends \IPS\Content\ExtensionGenerator
public function findByIp( $ip, \IPS\Http\Url $baseUrl = NULL )
{
$class = $this->class;
if( !isset( $class::$databaseColumnMap['ip_address'] ) OR !$class::$databaseColumnMap['ip_address'] )
{
return NULL;
}
if ( ! \IPS\Application::appIsEnabled( $class::$application ) )
{
return NULL;
}
$where = array( "{$class::$databasePrefix}{$class::$databaseColumnMap['ip_address']} LIKE ?" , $ip );
/* Don't need Posts Before Registration */
if ( isset( $class::$databaseColumnMap['hidden'] ) )
{
$where[0] .= " AND {$class::$databasePrefix}{$class::$databaseColumnMap['hidden']} <> -3";
}
if ( isset( $class::$databaseColumnMap['approved'] ) )
{
$where[0] .= " AND {$class::$databasePrefix}{$class::$databaseColumnMap['approved']} <> -3";
}
/* Does the class have any filters? */
if( method_exists( $class,'findByIPWhere') )
{
$where[0] .= $class::findByIPWhere();
}
/* Return count */
if ( $baseUrl === NULL )
{
return \IPS\Db::i()->select( 'COUNT(*)', $class::$databaseTable, array( "{$class::$databasePrefix}{$class::$databaseColumnMap['ip_address']} LIKE ?", $ip ) )->first();
return \IPS\Db::i()->select( 'COUNT(*)', $class::$databaseTable, $where )->first();
}
/* Init Table */
$table = new \IPS\Helpers\Table\Db( $class::$databaseTable, $baseUrl, array( "{$class::$databasePrefix}{$class::$databaseColumnMap['ip_address']} LIKE ?", $ip ) );
$table = new \IPS\Helpers\Table\Db( $class::$databaseTable, $baseUrl, $where );
$table->tableTemplate = array( \IPS\Theme::i()->getTemplate( 'tables', 'core', 'admin' ), 'table' );
$table->rowsTemplate = array( \IPS\Theme::i()->getTemplate( 'tables', 'core', 'admin' ), 'rows' );
@@ -103,6 +103,22 @@ class _BasicInformation extends \IPS\core\MemberACPProfile\Block
'data' => array( 'ipsDialog' => '', 'ipsDialog-title' => \IPS\Member::loggedIn()->language()->addToStack('member_export_pi_title') )
);
}
/* Data Layer PII Option */
if (
\IPS\Settings::i()->core_datalayer_enabled AND
\IPS\Settings::i()->core_datalayer_include_pii AND
\IPS\Settings::i()->core_datalayer_member_pii_choice AND
( ( $this->member->isAdmin() AND \IPS\Member::loggedIn()->hasAcpRestriction('core', 'members', 'member_edit_admin' ) ) OR \IPS\Member::loggedIn()->hasAcpRestriction( 'core', 'members', 'member_edit' ) )
)
{
$enabled = $this->member->datalayer_collect_pii;
$accountActions[] = array(
'title' => $enabled ? 'datalayer_omit_member_pii' : 'datalayer_collect_member_pii',
'icon' => 'id-card',
'link' => \IPS\Http\Url::internal( "app=core&module=members&controller=members&do=toggleDataLayerPii&id={$this->member->member_id}" ),
);
}
$activeSubscription = FALSE;
if ( \IPS\Application::appIsEnabled('nexus') and \IPS\Settings::i()->nexus_subs_enabled ) // I know... this should really be a hook... I won't tell if you won't
@@ -41,14 +41,6 @@ class _OAuth extends \IPS\core\MemberACPProfile\Block
$client = \IPS\Api\OAuthClient::load( $token['client_id'] );
$title = $client->_title;
if ( $count === 1 and $token['issue_user_agent'] )
{
$agent = \IPS\Http\UserAgent::parse( $token['issue_user_agent'] );
if ( $agent->ipsApp )
{
$title = \IPS\Member::loggedIn()->language()->addToStack( 'mobile_app_user_agent', FALSE, array( 'sprintf' => array( $agent->browserVersion, $agent->platform ) ) );
}
}
$tokens[] = array(
'title' => $title,
@@ -46,11 +46,11 @@ class _Points extends \IPS\core\MemberACPProfile\Block
'icon' => 'pencil',
'link' => $this->member->acpUrl()->setQueryString('do', 'points')->csrf(),
'data' => array( 'ipsDialog' => '', 'ipsDialog-title' => \IPS\Member::loggedIn()->language()->addToStack('acp_profile_points_manage_title' ) ),
'title' => \IPS\Member::loggedIn()->language()->addToStack('acp_profile_edit_points', NULL, [ 'sprintf' => $this->member->name ] ),
'title' => \IPS\Member::loggedIn()->language()->addToStack( 'acp_profile_edit_points', FALSE, [ 'sprintf' => $this->member->name ] ),
);
}
$table = new \IPS\Helpers\Table\Db( 'core_points_log', $this->member->acpUrl()->setQueryString( array( 'do' => 'editBlock', 'block' => \get_class( $this ) ) ), [ [ 'member=?', $this->member->member_id ] ] );
$table = new \IPS\Helpers\Table\Db( 'core_points_log', $this->member->acpUrl()->setQueryString( array( 'do' => 'editBlock', 'block' => \get_class( $this ) ) ), [ [ '`member`=?', $this->member->member_id ] ] );
$table->joins[] = [
'select' => 'action,identifier',
'from' => 'core_achievements_log',
@@ -75,8 +75,14 @@ class _Points extends \IPS\core\MemberACPProfile\Block
if ( isset( $exploded[1] ) )
{
$extension = \IPS\Application::load( $exploded[0] )->extensions( 'core', 'AchievementAction' )[$exploded[1]];
return $extension->logRow( $row['identifier'], explode( ',', $row['actor'] ) );
try{
$extension = \IPS\Application::load( $exploded[0] )->extensions( 'core', 'AchievementAction' )[$exploded[1]];
return $extension->logRow( $row['identifier'], explode( ',', $row['actor'] ) );
}
catch( \OutOfRangeException $e )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'acp_points_rule_deleted');
}
}
else if ( isset( $row['rules'] ) and empty( $row['rules'] ) )
{
@@ -30,6 +30,11 @@ class _Referrals extends \IPS\core\MemberACPProfile\Block
*/
public function output( $edit = FALSE )
{
if( !\IPS\Settings::i()->ref_on )
{
return "";
}
$url = $this->member->acpUrl()->setQueryString( array( 'do' => 'editBlock', 'block' => \get_class( $this ) ) );
$referCount = \IPS\Db::i()->select( 'COUNT(*)', 'core_referrals', array( 'referred_by=?', $this->member->member_id ) )->first();
$referrals = new \IPS\Helpers\Table\Db( 'core_referrals', $url, array( 'referred_by=?', $this->member->member_id ) );
@@ -0,0 +1,362 @@
<?php
/**
* @brief Member filter extension: Achievements
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 14 Sept 2021
*/
namespace IPS\core\extensions\core\MemberFilter;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* @brief Member filter: Achievements
*/
class _Achievements
{
/**
* Determine if the filter is available in a given area
*
* @param string $area Area to check
* @return bool
*/
public function availableIn( $area )
{
return \in_array( $area, array( 'bulkmail', 'group_promotions', 'automatic_moderation' ) );
}
/**
* Get Setting Field
*
* @param mixed $criteria Value returned from the save() method
* @return array Array of form elements
*/
public function getSettingField( $criteria )
{
/* Get our badges */
$badges['options'] = [];
foreach( \IPS\core\Achievements\Badge::roots() as $badge )
{
$badges['options'][ $badge->id ] = $badge->_title;
}
/* If all *available* options are selected, we want to choose 'all' for consistency on create vs edit */
$_options = array_keys( $badges['options'] );
if( isset( $criteria['achievement_badges'] ) )
{
if( ! \count( array_diff( $_options, explode( ',', $criteria['achievement_badges'] ) ) ) )
{
$criteria['achievement_badges'] = 'all';
}
}
/* Get our ranks */
$ranks['options'] = [];
foreach( \IPS\core\Achievements\Rank::roots() as $rank )
{
$ranks['options'][ $rank->id ] = $rank->_title;
}
/* If all *available* options are selected, we want to choose 'all' for consistency on create vs edit */
$_options = array_keys( $ranks['options'] );
return array(
new \IPS\Helpers\Form\Custom( 'mf_points', array( 0 => isset( $criteria['achievement_points_operator'] ) ? $criteria['achievement_points_operator'] : NULL, 1 => isset( $criteria['achievement_points_value'] ) ? $criteria['achievement_points_value'] : NULL ), FALSE, array(
'getHtml' => function( $element )
{
return \IPS\Theme::i()->getTemplate( 'forms', 'core' )->select( "{$element->name}[0]", $element->value[0], $element->required, array(
'any' => \IPS\Member::loggedIn()->language()->addToStack('any'),
'gt' => \IPS\Member::loggedIn()->language()->addToStack('gt'),
'lt' => \IPS\Member::loggedIn()->language()->addToStack('lt'),
'eq' => \IPS\Member::loggedIn()->language()->addToStack('exactly'),
),
FALSE,
NULL,
FALSE,
array(
'any' => array(),
'gt' => array( 'elNumber_' . $element->name . '-qty' ),
'lt' => array( 'elNumber_' . $element->name . '-qty' ),
'eq' => array( 'elNumber_' . $element->name . '-qty' ),
) )
. ' '
. \IPS\Theme::i()->getTemplate( 'forms', 'core', 'global' )->number( "{$element->name}[1]", $element->value[1], $element->required, NULL, FALSE, NULL, NULL, NULL, 0, NULL, FALSE, NULL, array(), array(), array(), $element->name . '-qty' );
}
), NULL, NULL, NULL, 'mp_points' ),
new \IPS\Helpers\Form\YesNo( 'mf_badges_choose', ( isset( $criteria['achievement_badges'] ) AND $criteria['achievement_badges'] != 'ignore' ), FALSE, array(
'togglesOn' => [ 'mf_badges' ]
), NULL, NULL, NULL, 'mf_badges_choose' ),
new \IPS\Helpers\Form\CheckboxSet( 'mf_badges', ( isset( $criteria['achievement_badges'] ) AND $criteria['achievement_badges'] != 'ignore' ) ? explode( ',', $criteria['achievement_badges'] ) : [], FALSE, array(
'options' => $badges['options'],
'multiple' => TRUE,
'unlimited' => 'all',
'unlimitedLang' => 'mf_achievements_all_badges',
'impliedUnlimited' => TRUE
), NULL, NULL, NULL, 'mf_badges' ),
new \IPS\Helpers\Form\YesNo( 'mf_ranks_choose', ( isset( $criteria['achievement_ranks'] ) AND $criteria['achievement_ranks'] != 'ignore' ), FALSE, array(
'togglesOn' => [ 'mf_ranks' ]
), NULL, NULL, NULL, 'mf_ranks_choose' ),
new \IPS\Helpers\Form\CheckboxSet( 'mf_ranks', ( isset( $criteria['achievement_ranks'] ) AND $criteria['achievement_ranks'] != 'ignore' ) ? explode( ',', $criteria['achievement_ranks'] ) : [], FALSE, array(
'options' => $ranks['options'],
'multiple' => TRUE,
'unlimited' => 'all',
'unlimitedLang' => 'mf_achievements_all_ranks',
'impliedUnlimited' => TRUE
), NULL, NULL, NULL, 'mf_ranks' )
);
}
/**
* Save the filter data
*
* @param array $post Form values
* @return mixed False, or an array of data to use later when filtering the members
* @throws \LogicException
*/
public function save( $post )
{
return array(
'achievement_points_operator' => $post['mf_points'][0],
'achievement_points_value' => $post['mf_points'][1],
'achievement_badges' => ( $post['mf_badges_choose'] ) ? implode( ',', $post['mf_badges'] ) : 'ignore',
'achievement_ranks' => ( $post['mf_ranks_choose'] ) ? implode( ',', $post['mf_ranks'] ) : 'ignore'
);
}
/**
* Get where clause to add to the member retrieval database query
*
* @param mixed $data The array returned from the save() method
* @return array|NULL Where clause - must be a single array( "clause" )
*/
public function getQueryWhereClause( $data )
{
$where = [];
if ( $data['achievement_points_operator'] and $data['achievement_points_value'] )
{
switch ( $data['achievement_points_operator'] )
{
case 'gt':
$where[] = "achievements_points > " . (int) $data['achievement_points_value'];
break;
case 'lt':
$where[] = "achievements_points < " . (int) $data['achievement_points_value'];
break;
case 'eq':
$where[] = "achievements_points = " . (int) $data['achievement_points_value'];
break;
}
}
if ( $data['achievement_badges'] != 'ignore' )
{
$badgeSelect = \IPS\Db::i()->select( 'member', 'core_member_badges', \IPS\Db::i()->in( 'badge', explode( ',', $data['achievement_badges'] ) ), NULL, NULL, NULL, NULL, \IPS\Db::SELECT_DISTINCT );
$where[] = 'core_members.member_id IN(' . $badgeSelect . ')';
}
if ( $data['achievement_ranks'] != 'ignore' )
{
$ranks = \IPS\core\Achievements\Rank::getStore();
$rankWhere = [];
foreach( explode( ',', $data['achievement_ranks'] ) as $val )
{
$minPoints = 0;
$maxPoints = 0;
$minSet = FALSE;
foreach ( $ranks as $rank )
{
if ( !$minSet and $rank->id == $val )
{
$minPoints = $rank->points;
$minSet = TRUE;
}
if ( $minSet and $rank->points > $minPoints )
{
$maxPoints = $rank->points;
break;
}
}
if ( $minPoints and $maxPoints )
{
$rankWhere[] = '( achievements_points BETWEEN ' . $minPoints . ' AND ' . ( $maxPoints - 1 ) . ' )';
}
elseif ( $minPoints )
{
$rankWhere[] = '( achievements_points >= ' . $minPoints . ' )';
}
elseif ( $maxPoints )
{
$rankWhere[] = '( achievements_points < ' . $maxPoints . ' )';
}
}
if ( \count( $rankWhere ) )
{
$where[] = '(' . implode( ' OR ', $rankWhere ) . ')';
}
}
return \count( $where ) ? '(' . implode( ' AND ', $where ) . ')' : NULL;
}
/**
* Determine if a member matches specified filters
*
* @note This is only necessary if availableIn() includes group_promotions
* @param \IPS\Member $member Member object to check
* @param array $filters Previously defined filters
* @param object|NULL $object Calling class
* @return bool
*/
public function matches( \IPS\Member $member, $filters, $object=NULL )
{
if ( ( isset( $filters['achievement_points_operator'] ) and ( $filters['achievement_points_operator'] ) and $filters['achievement_points_operator'] != 'any' ) and ( isset( $filters['achievement_points_value'] ) ) )
{
$pass = FALSE;
switch ( $filters['achievement_points_operator'] )
{
case 'gt':
$pass = (bool) ( $member->achievements_points > (int) $filters['achievement_points_value'] );
break;
case 'lt':
$pass = (bool) ( $member->achievements_points < (int) $filters['achievement_points_value'] );
break;
case 'eq':
$pass = (bool) ( $member->achievements_points = (int) $filters['achievement_points_value'] );
break;
}
if ( $pass === FALSE )
{
/* They don't make it this far */
return FALSE;
}
}
/* Lets check badges */
if ( isset( $filters['achievement_badges'] ) and $filters['achievement_badges'] != 'ignore' )
{
if ( ! \IPS\Db::i()->select( 'COUNT(*)', 'core_member_badges', [ 'member=? AND ' . \IPS\Db::i()->in( 'badge', explode( ',', $filters['achievement_badges'] ) ), $member->member_id ] )->first() )
{
/* Did not find a badge, so they failed the match */
return FALSE;
}
}
/* Let's check ranks */
if ( isset( $filters['achievement_ranks'] ) and $filters['achievement_ranks'] != 'ignore' )
{
$ranks = \IPS\core\Achievements\Rank::getStore();
$pass = FALSE;
foreach( explode( ',', $filters['achievement_ranks'] ) as $val )
{
$minPoints = 0;
$maxPoints = 0;
$minSet = FALSE;
foreach ( $ranks as $rank )
{
if ( !$minSet and $rank->id == $val )
{
$minPoints = $rank->points;
$minSet = TRUE;
}
if ( $minSet and $rank->points > $minPoints )
{
$maxPoints = $rank->points;
break;
}
}
if ( $minPoints and $maxPoints )
{
$pass = (bool) $member->achievements_points >= $minPoints AND $member->achievements_points <= ($maxPoints - 1);
}
elseif ( $minPoints )
{
$pass = (bool) $member->achievements_points >= $minPoints;
}
elseif ( $maxPoints )
{
$pass = (bool) $member->achievements_points < $minPoints;
}
}
if ( $pass === FALSE )
{
/* They don't make it this far */
return FALSE;
}
}
/* If we are still here, then there wasn't an appropriate operator (maybe they selected 'any') so return true */
return TRUE;
}
/**
* Return a lovely human description for this rule if used
*
* @param mixed $filters The array returned from the save() method
* @return string|NULL
*/
public function getDescription( $filters )
{
$message = [];
if ( ! empty( $filters['achievement_points_value'] ) and $filters['achievement_points_value'] > 0 )
{
switch ( $filters['achievement_points_operator'] )
{
case 'gt':
$message[] = \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_cheev_points_gt_desc', FALSE, array( 'sprintf' => array( $filters['achievement_points_value'] ) ) );
break;
case 'lt':
$message[] = \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_cheev_points_lt_desc', FALSE, array( 'sprintf' => array( $filters['achievement_points_value'] ) ) );
break;
case 'eq':
$message[] = \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_cheev_points_eq_desc', FALSE, array( 'sprintf' => array( $filters['achievement_points_value'] ) ) );
break;
}
}
if ( $filters['achievement_badges'] != 'ignore' )
{
$count = \count( explode( ',', $filters['achievement_badges'] ) );
if( $count )
{
$message[] = \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_cheev_desc', FALSE, [
'sprintf' => [
\IPS\Member::loggedIn()->language()->addToStack( 'recognize_badges_pluralize', FALSE, ['sprintf' => [$count], 'pluralize' => [$count]] )
]] );
}
}
if ( $filters['achievement_ranks'] != 'ignore' )
{
$count = \count( explode( ',', $filters['achievement_badges'] ) );
if ( $count )
{
$message[] = \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_cheev_desc', FALSE, [
'sprintf' => [
\IPS\Member::loggedIn()->language()->addToStack( 'achievement_ranks_pluralize', FALSE, ['sprintf' => [$count], 'pluralize' => [$count]] )
]] );
}
}
return \count( $message ) ? implode( ', ', $message ) : NULL;
}
}
@@ -0,0 +1,116 @@
<?php
/**
* @brief Member Filter Extension
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 22 Sep 2021
*/
namespace IPS\core\extensions\core\MemberFilter;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Member Filter Extension
*/
class _Banned
{
/**
* Determine if the filter is available in a given area
*
* @param string $area Area to check
* @return bool
*/
public function availableIn( $area )
{
return \in_array( $area, array( 'group_promotions' ) );
}
/**
* Get Setting Field
*
* @param mixed $criteria Value returned from the save() method
* @return array Array of form elements
*/
public function getSettingField( $criteria )
{
$options = array( 'any' => 'any', 'banned' => 'mf_banned_banned', 'notbanned' => 'mf_banned_not_banned' );
return array(
new \IPS\Helpers\Form\Radio( 'mf_banned', isset( $criteria['banned'] ) ? $criteria['banned'] : 'any', FALSE, array( 'options' => $options ) ),
);
}
/**
* Determine if a member matches specified filters
*
* @note This is only necessary if availableIn() includes group_promotions
* @param \IPS\Member $member Member object to check
* @param array $filters Previously defined filters
* @param object|NULL $object Calling class
* @return bool
*/
public function matches( \IPS\Member $member, $filters, $object=NULL )
{
if( !isset( $filters['banned'] ) )
{
return TRUE;
}
switch ( $filters['banned'] )
{
case 'banned':
return ( (int) $member->temp_ban !== 0 );
break;
case 'notbanned':
return empty( $member->temp_ban );
break;
}
return FALSE;
}
/**
* Save the filter data
*
* @param array $post Form values
* @return mixed False, or an array of data to use later when filtering the members
* @throws \LogicException
*/
public function save( $post )
{
return ( isset( $post['mf_banned'] ) and \in_array( $post['mf_banned'], array( 'banned', 'notbanned' ) ) ) ? array( 'banned' => $post['mf_banned'] ) : FALSE;
}
/**
* Get where clause to add to the member retrieval database query
*
* @param mixed $data The array returned from the save() method
* @return array|NULL Where clause - must be a single array( "clause" )
*/
public function getQueryWhereClause( $data )
{
if ( isset( $data['banned'] ) )
{
switch ( $data['banned'] )
{
case 'banned':
return array( "temp_ban<>0" );
break;
case 'notbanned':
return array( "(temp_ban IS NULL OR temp_ban=0)" );
break;
}
}
return NULL;
}
}
@@ -153,13 +153,13 @@ class _Content
switch ( $filters['content_count_operator'] )
{
case 'gt':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_gt_desc', NULL, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_gt_desc', FALSE, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
break;
case 'lt':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_lt_desc', NULL, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_lt_desc', FALSE, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
break;
case 'eq':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_eq_desc', NULL, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_content_eq_desc', FALSE, array( 'sprintf' => array( $filters['content_count_score'] ) ) );
break;
}
}
@@ -94,7 +94,7 @@ class _Group
if ( \count( $humanGroups ) )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_group_desc', NULL, array( 'sprintf' => array( \IPS\Member::loggedIn()->language()->formatList( $humanGroups ) ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_group_desc', FALSE, array( 'sprintf' => array( \IPS\Member::loggedIn()->language()->formatList( $humanGroups ) ) ) );
}
}
@@ -246,16 +246,16 @@ class _Joined
if ( $start and $end )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_range_desc', NULL, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_range_desc', FALSE, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
}
}
elseif( !empty( $filters['days'] ) AND (int) $filters['days'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_days_desc', NULL, array( 'sprintf' => array( $filters['days'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_days_desc', FALSE, array( 'sprintf' => array( $filters['days'] ) ) );
}
elseif( !empty( $filters['days_lt'] ) AND (int) $filters['days_lt'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_days_lt_desc', NULL, array( 'sprintf' => array( $filters['days_lt'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_joined_days_lt_desc', FALSE, array( 'sprintf' => array( $filters['days_lt'] ) ) );
}
return NULL;
@@ -260,16 +260,16 @@ class _Lastpost
if ( $start and $end )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_range_desc', NULL, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_range_desc', FALSE, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
}
}
elseif( !empty( $filters['days'] ) AND (int) $filters['days'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_days_desc', NULL, array( 'sprintf' => array( $filters['days'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_days_desc', FALSE, array( 'sprintf' => array( $filters['days'] ) ) );
}
elseif( !empty( $filters['days_lt'] ) AND (int) $filters['days_lt'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_days_lt_desc', NULL, array( 'sprintf' => array( $filters['days_lt'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastpost_days_lt_desc', FALSE, array( 'sprintf' => array( $filters['days_lt'] ) ) );
}
return NULL;
@@ -245,16 +245,16 @@ class _Lastvisit
if ( $start and $end )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_range_desc', NULL, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_range_desc', FALSE, array( 'sprintf' => array( $start->localeDate(), $end->localeDate() ) ) );
}
}
elseif( !empty( $filters['days'] ) AND (int) $filters['days'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_days_desc', NULL, array( 'sprintf' => array( $filters['days'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_days_desc', FALSE, array( 'sprintf' => array( $filters['days'] ) ) );
}
elseif( !empty( $filters['days_lt'] ) AND (int) $filters['days_lt'] )
{
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_days_lt_desc', NULL, array( 'sprintf' => array( $filters['days_lt'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_lastvisit_days_lt_desc', FALSE, array( 'sprintf' => array( $filters['days_lt'] ) ) );
}
return NULL;
@@ -296,14 +296,9 @@ class _ProfileFields
}
break;
case 'IPS\Helpers\Form\Date':
if( !$profileFieldData['core_pfieldgroups_' . $group ][ $langKey ] )
{
return FALSE;
}
$start = NULL;
$end = NULL;
if ( $filters[ $langKey ]['start'] )
{
$start = ( new \IPS\DateTime( $filters[ $langKey ]['start'] ) )->getTimestamp();
@@ -313,6 +308,11 @@ class _ProfileFields
$end = ( new \IPS\DateTime( $filters[ $langKey ]['end'] ) )->getTimestamp();
}
if( ( $start OR $end ) AND !$profileFieldData['core_pfieldgroups_' . $group ][ $langKey ] )
{
return FALSE;
}
if( ( $start AND $start > $profileFieldData['core_pfieldgroups_' . $group ][ $langKey ] ) OR ( $end AND $end < $profileFieldData['core_pfieldgroups_' . $group ][ $langKey ] ) )
{
return FALSE;
@@ -153,13 +153,13 @@ class _Reputation
switch ( $filters['reputation_operator'] )
{
case 'gt':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_gt_desc', NULL, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_gt_desc', FALSE, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
break;
case 'lt':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_lt_desc', NULL, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_lt_desc', FALSE, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
break;
case 'eq':
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_eq_desc', NULL, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
return \IPS\Member::loggedIn()->language()->addToStack( 'member_filter_core_reputation_eq_desc', FALSE, array( 'sprintf' => array( $filters['reputation_score'] ) ) );
break;
}
}
@@ -0,0 +1,87 @@
<?php
/**
* @brief Member Filter Extension
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 22 Sep 2021
*/
namespace IPS\core\extensions\core\MemberFilter;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Member Filter Extension
*/
class _Spammer
{
/**
* Determine if the filter is available in a given area
*
* @param string $area Area to check
* @return bool
*/
public function availableIn( $area )
{
return \in_array( $area, array( 'group_promotions' ) );
}
/**
* Get Setting Field
*
* @param mixed $criteria Value returned from the save() method
* @return array Array of form elements
*/
public function getSettingField( $criteria )
{
$options = array( 'any' => 'any', 'spammer' => 'mf_spammer_spammer', 'notspammer' => 'mf_spammer_not_spammer' );
return array(
new \IPS\Helpers\Form\Radio( 'mf_spammer', isset( $criteria['spammer'] ) ? $criteria['spammer'] : 'any', FALSE, array( 'options' => $options ) ),
);
}
/**
* Save the filter data
*
* @param array $post Form values
* @return mixed False, or an array of data to use later when filtering the members
* @throws \LogicException
*/
public function save( $post )
{
return ( isset( $post['mf_spammer'] ) and \in_array( $post['mf_spammer'], array( 'spammer', 'notspammer' ) ) ) ? array( 'spammer' => $post['mf_spammer'] ) : FALSE;
}
/**
* Get where clause to add to the member retrieval database query
*
* @param mixed $data The array returned from the save() method
* @return array|NULL Where clause - must be a single array( "clause" )
*/
public function getQueryWhereClause( $data )
{
if ( isset( $data['spammer'] ) )
{
switch ( $data['spammer'] )
{
case 'spammer':
return array( \IPS\Db::i()->bitwiseWhere( \IPS\Member::$bitOptions['members_bitoptions'], 'bw_is_spammer' ));
break;
case 'notspammer':
return array( \IPS\Db::i()->bitwiseWhere( \IPS\Member::$bitOptions['members_bitoptions'], 'bw_is_spammer', FALSE ) );
break;
}
}
return NULL;
}
}
@@ -126,7 +126,7 @@ class _Staff
$not = TRUE;
}
return array( "(" . \IPS\Db::i()->in( 'member_id', $members, $not ) . " OR " . \IPS\Db::i()->in( 'member_group_id', $groups, $not ) . " OR " . \IPS\Db::i()->findInSet( 'mgroup_others', $groups, $not ) . ")" );
return array( "(" . \IPS\Db::i()->in( 'core_members.member_id', $members, $not ) . " OR " . \IPS\Db::i()->in( 'member_group_id', $groups, $not ) . " OR " . \IPS\Db::i()->findInSet( 'mgroup_others', $groups, $not ) . ")" );
}
return NULL;
}
@@ -0,0 +1,105 @@
<?php
/**
* @brief Member Filter Extension
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 22 Sep 2021
*/
namespace IPS\core\extensions\core\MemberFilter;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Member Filter Extension
*/
class _Validating
{
/**
* Determine if the filter is available in a given area
*
* @param string $area Area to check
* @return bool
*/
public function availableIn( $area )
{
return \in_array( $area, array( 'bulkmail' ) );
}
/**
* Get Setting Field
*
* @param mixed $criteria Value returned from the save() method
* @return array Array of form elements
*/
public function getSettingField( $criteria )
{
$options = array( 'any' => 'any', 'validating' => 'mf_validating_validating', 'notvalidating' => 'mf_validating_not_validating' );
return array(
new \IPS\Helpers\Form\Radio( 'mf_validating', isset( $criteria['validating'] ) ? $criteria['validating'] : 'any', FALSE, array( 'options' => $options ) ),
);
}
/**
* Save the filter data
*
* @param array $post Form values
* @return mixed False, or an array of data to use later when filtering the members
* @throws \LogicException
*/
public function save( $post )
{
return ( isset( $post['mf_validating'] ) and \in_array( $post['mf_validating'], array( 'validating', 'notvalidating' ) ) ) ? array( 'validating' => $post['mf_validating'] ) : FALSE;
}
/**
* Get where clause to add to the member retrieval database query
*
* @param mixed $data The array returned from the save() method
* @return array|NULL Where clause - must be a single array( "clause" )
*/
public function getQueryWhereClause( $data )
{
if ( isset( $data['validating'] ) )
{
switch ( $data['validating'] )
{
case 'validating':
return array( "( v.lost_pass=0 AND v.forgot_security=0 AND v.vid IS NOT NULL )" );
break;
case 'notvalidating':
return array( "( v.vid IS NULL )" );
break;
}
}
return NULL;
}
/**
* Callback for member retrieval database query
* Can be used to set joins
*
* @param mixed $data The array returned from the save() method
* @param \IPS\Db\Query $query The query
* @return void
*/
public function queryCallback( $data, &$query )
{
if( isset( $data['validating'] ) )
{
$query->join( [ 'core_validating', 'v' ], "core_members.member_id=v.member_id" );
}
return NULL;
}
}
@@ -45,7 +45,8 @@ class _Core
'admin_mails',
'terms_acceptance',
'points',
'badges'
'badges',
'club_membership'
);
}
@@ -548,7 +549,7 @@ class _Core
foreach ( \IPS\Application::allExtensions( 'core', 'MemberRestrictions', TRUE, 'core', 'Content', FALSE ) as $class )
{
foreach ( $class::changesForHistory( $jsonValue['restrictions'] ) as $v )
foreach ( $class::changesForHistory( $jsonValue['restrictions'], $row ) as $v )
{
$changes[] = $v;
}
@@ -745,8 +746,24 @@ class _Core
}
break;
case 'club_membership':
if( isset( $jsonValue['club_id'] ))
{
try
{
$club = \IPS\Member\Club::load( $jsonValue['club_id'] );
switch( $jsonValue['type'] )
{
case \IPS\Member\Club::STATUS_BANNED:
return \IPS\Member::loggedIn()->language()->addToStack( 'history_removed_from_club', FALSE, array('htmlsprintf' => array( $club->name, $byStaff ) ) );
case \IPS\Member\Club::STATUS_MEMBER:
return \IPS\Member::loggedIn()->language()->addToStack( 'history_added_to_club', FALSE, array('htmlsprintf' => array( $club->name, $byStaff ) ) );
}
}
catch ( \Exception $e ) { }
}
}
$member->logHistory( 'core', 'badges', [ 'action' => 'manual', 'id' => $values['acp_manual_badge']->_id ] );
return $value;
}
@@ -86,12 +86,13 @@ class _Content extends \IPS\core\MemberACPProfile\Restriction
* Get details of a change to show on history
*
* @param array $changes Changes as set in save()
* @param array $row Row of data from member history table.
* @return array
*/
public static function changesForHistory( $changes )
public static function changesForHistory( array $changes, array $row ): array
{
$return = array();
foreach ( array( 'modq' => 'mod_posts', 'nopost' => 'restrict_post', 'banned' => 'temp_ban' ) as $k => $v )
{
if ( isset( $changes[ $v ] ) )
@@ -101,7 +102,7 @@ class _Content extends \IPS\core\MemberACPProfile\Restriction
$c = \IPS\Member::loggedIn()->language()->addToStack( 'moderation_' . $k );
if ( $changes[ $v ]['new'] != -1 )
{
$interval = \IPS\DateTime::formatInterval( ( \is_numeric( $changes[ $v ]['new'] ) ) ? \IPS\DateTime::create()->diff( \IPS\DateTime::ts( $changes[ $v ]['new'] ) ) : new \DateInterval( $changes[ $v ]['new'] ), 2 );
$interval = \IPS\DateTime::formatInterval( ( \is_numeric( $changes[ $v ]['new'] ) ) ? \IPS\DateTime::ts( $row['log_date'] )->diff( \IPS\DateTime::ts( $changes[ $v ]['new'] ) ) : new \DateInterval( $changes[ $v ]['new'] ), 2 );
$c = \IPS\Member::loggedIn()->language()->addToStack( 'history_received_warning_penalty_time', FALSE, array( 'sprintf' => array( $c, $interval ) ) );
}
}
@@ -91,14 +91,15 @@ class _Statuses extends \IPS\core\MemberACPProfile\Restriction
return $return;
}
/**
* Get details of a change to show on history
*
* @param array $changes Changes as set in save()
* @param array $row Row of data from member history table.
* @return array
*/
public static function changesForHistory( $changes )
public static function changesForHistory( array $changes, array $row ): array
{
if ( isset( $changes['bw_no_status_update'] ) )
{
@@ -93,21 +93,22 @@ class _Tags extends \IPS\core\MemberACPProfile\Restriction
{
$return[] = 'restriction_no_tagging';
}
if ( !$this->member->group['bw_disable_prefixes'] and $this->member->members_bitoptions['bw_disable_prefixes'] )
if ( !$this->member->group['gbw_disable_prefixes'] and $this->member->members_bitoptions['bw_disable_prefixes'] )
{
$return[] = 'restriction_no_prefixes';
}
return $return;
}
/**
* Get details of a change to show on history
*
* @param array $changes Changes as set in save()
* @param array $row Row of data from member history table.
* @return array
*/
public static function changesForHistory( $changes )
public static function changesForHistory( array $changes, array $row ): array
{
$return = array();
@@ -110,7 +110,11 @@ class _System
array( 'core_rss_import', 'rss_import_member' ),
array( 'core_anonymous_posts', 'anonymous_member_id' ),
array( 'core_member_badges', 'member' ),
array( 'core_notifications_pwa_keys', 'member' )
array( 'core_notifications_pwa_keys', 'member' ),
array( 'core_members_logins', 'member_id' ),
array( 'core_stream_subscriptions', 'member_id' ),
array( 'core_alerts', 'alert_member_id' ),
array( 'core_alerts', 'alert_recipient_user' ),
) as $toMerge
)
{
@@ -139,7 +143,10 @@ class _System
/* Solved */
\IPS\Db::i()->update( 'core_solved_index', array( 'member_id' => $member->member_id ), array( 'member_id=?', $member2->member_id ), array(), NULL, \IPS\Db::IGNORE );
/* Achievements */
\IPS\Db::i()->update( 'core_achievements_log_milestones', array( 'milestone_member_id' => $member->member_id ), array( 'milestone_member_id=?', $member2->member_id ), array(), NULL, \IPS\Db::IGNORE );
/* Delete duplicate stuff */
\IPS\Db::i()->delete( 'core_item_markers', array( 'item_member_id=?', $member2->member_id ) );
\IPS\Db::i()->delete( 'core_members_feature_seen', array( 'member_id=?', $member2->member_id ) );
@@ -155,6 +162,7 @@ class _System
\IPS\Db::i()->delete( 'core_acp_notifcations_dismissals', array( '`member`=?', $member2->member_id ) );
\IPS\Db::i()->delete( 'core_acp_notifications_preferences', array( '`member`=?', $member2->member_id ) );
\IPS\Db::i()->delete( 'core_marketplace_tokens', array( 'id=?', $member2->member_id ) );
\IPS\Db::i()->delete( 'core_achievements_log_milestones', array( 'milestone_member_id=?', $member2->member_id ) );
/* Update PM recipient counts */
foreach( \IPS\Db::i()->select( 'map_topic_id', 'core_message_topic_user_map', array( 'map_user_id=?', $member->member_id ) ) as $topicId )
@@ -250,7 +258,10 @@ class _System
\IPS\Db::i()->delete( 'core_notifications', array( 'item_class=? AND item_id=?', 'IPS\\core\\Statuses\\Reply', $reply ) );
/* Remove item from deletion log */
\IPS\Db::i()->delete( 'core_deletion_log', array( "dellog_content_class=? AND dellog_content_id=?", "IPS\\core\\Statuses\\Reply", $reply ) );
\IPS\Db::i()->delete( 'core_deletion_log', array( "dellog_content_class=? AND dellog_content_id=?", "IPS\\core\\Statuses\\Reply", $reply ) );
/* Remove reports */
\IPS\Db::i()->delete( 'core_rc_index', array( "class=? AND content_id=?", "IPS\\core\\Statuses\\Reply", $reply ) );
}
\IPS\Content\Search\Index::i()->removeClassFromSearchIndex( 'IPS\core\Statuses\Reply', NULL, $member->member_id );
@@ -261,6 +272,9 @@ class _System
/* Remove item from deletion log */
\IPS\Db::i()->delete( 'core_deletion_log', array( "dellog_content_class=? AND dellog_content_id=?", "IPS\\core\\Statuses\\Status", $status ) );
/* Remove reports */
\IPS\Db::i()->delete( 'core_rc_index', array( "class=? AND content_id=?", "IPS\\core\\Statuses\\Reply", $status ) );
}
\IPS\Content\Search\Index::i()->removeClassFromSearchIndex( 'IPS\core\Statuses\Status', NULL, $member->member_id );
@@ -306,7 +320,11 @@ class _System
array( 'core_anonymous_posts', 'anonymous_member_id' ),
array( 'core_marketplace_tokens', 'id' ),
array( 'core_member_badges', 'member' ),
array( 'core_notifications_pwa_keys', 'member' )
array( 'core_notifications_pwa_keys', 'member' ),
array( 'core_achievements_log_milestones', 'milestone_member_id' ),
array( 'core_members_logins', 'member_id' ),
array( 'core_stream_subscriptions', 'member_id' ),
array( 'core_alerts_seen', 'seen_member_id' )
) as $toDelete )
{
\IPS\Db::i()->delete( $toDelete[0], array( '`' . $toDelete[1] . '`=?', $member->member_id ) );
@@ -349,6 +367,8 @@ class _System
$member->deletePhoto();
$member->coverPhoto()->delete();
\IPS\Api\Webhook::fire( 'member_delete', $member );
}
/**
@@ -386,5 +406,15 @@ class _System
/* Reset profile completion flag to see if there are any items to complete now permissions are elevated */
$member->members_bitoptions['profile_completed'] = 0;
}
if( \count( $changes ) )
{
$params = [
'member' => $member->apiOutput(),
'changes' => $changes
];
\IPS\Api\Webhook::fire( 'member_edited', $params );
}
}
}
@@ -1,157 +0,0 @@
<?php
/**
* @brief Mobile Navigation Extension: Custom Item
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @subpackage Core
* @since 12 Jun 2019
*/
namespace IPS\core\extensions\core\MobileNavigation;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Mobile Navigation Extension: Custom Item
*/
class _CustomItem extends \IPS\core\MobileNavigation\MobileNavigationAbstract
{
/**
* Get Type Title which will display in the AdminCP Menu Manager
*
* @return string
*/
public static function typeTitle()
{
return \IPS\Member::loggedIn()->language()->addToStack('mobilenavigation_CustomItem');
}
/**
* Allow multiple instances?
*
* @return bool
*/
public static function allowMultiple()
{
return TRUE;
}
/**
* Get configuration fields
*
* @param array $existingConfiguration The existing configuration, if editing an existing item
* @param int $id The ID number of the existing item, if editing
* @return array
*/
public static function configuration( $existingConfiguration, $id = NULL )
{
$currentUrl = NULL;
if ( isset( $existingConfiguration['menu_custom_item_url'] ) )
{
if ( isset( $existingConfiguration['internal'] ) )
{
$currentUrl = (string) \IPS\Http\Url::internal( $existingConfiguration['menu_custom_item_url'], 'front', $existingConfiguration['internal'], isset( $existingConfiguration['seoTitles'] ) ? $existingConfiguration['seoTitles'] : array() );
}
else
{
$currentUrl = $existingConfiguration['menu_custom_item_url'];
}
}
return array(
new \IPS\Helpers\Form\Translatable( 'menu_custom_item_link', NULL, NULL, array( 'app' => 'core', 'key' => $id ? "mobilemenu_item_{$id}" : NULL ), function( $val )
{
if ( !trim( $val[ \IPS\Lang::defaultLanguage() ] ) )
{
throw new \InvalidArgumentException('form_required');
}
} ),
new \IPS\Helpers\Form\Url( 'menu_custom_item_url', $currentUrl, NULL, array(), function( $val )
{
if ( isset( \IPS\Request::i()->menu_manager_extension ) and \IPS\Request::i()->menu_manager_extension === 'core_CustomItem' and empty( $val ) )
{
throw new \InvalidArgumentException('form_required');
}
} )
);
}
/**
* Parse configuration fields
*
* @param array $configuration The values received from the form
* @param int $id The ID number of the existing item, if editing
* @return array
*/
public static function parseConfiguration( $configuration, $id )
{
$baseUrl = \IPS\Http\Url::internal('', 'front');
if ( $configuration['menu_custom_item_url'] instanceof \IPS\Http\Url\Friendly )
{
$configuration['internal'] = $configuration['menu_custom_item_url']->seoTemplate;
$configuration['seoTitles'] = $configuration['menu_custom_item_url']->seoTitles;
$configuration['menu_custom_item_url'] = http_build_query( $configuration['menu_custom_item_url']->hiddenQueryString + $configuration['menu_custom_item_url']->queryString, '', '&' );
}
else
{
$configuration['menu_custom_item_url'] = (string) $configuration['menu_custom_item_url'];
}
\IPS\Lang::saveCustom( 'core', "mobilemenu_item_{$id}", $configuration['menu_custom_item_link'] );
unset( $configuration['menu_custom_item_link'] );
return $configuration;
}
/**
* Permissions can be inherited?
*
* @return bool
*/
public static function permissionsCanInherit()
{
return FALSE;
}
/**
* Get Title
*
* @return string
*/
public function title()
{
return \IPS\Member::loggedIn()->language()->addToStack( "mobilemenu_item_{$this->id}" );
}
/**
* Get Link
*
* @return \IPS\Http\Url
*/
public function link()
{
if ( isset( $this->configuration['menu_custom_item_url'] ) and ( $this->configuration['menu_custom_item_url'] or isset( $this->configuration['internal'] ) ) )
{
if ( isset( $this->configuration['internal'] ) )
{
return \IPS\Http\Url::internal( $this->configuration['menu_custom_item_url'], 'front', $this->configuration['internal'], isset( $this->configuration['seoTitles'] ) ? $this->configuration['seoTitles'] : array() );
}
else
{
return \IPS\Http\Url::external( $this->configuration['menu_custom_item_url'] );
}
}
else
{
return \IPS\Http\Url::internal('');
}
}
}
@@ -0,0 +1,217 @@
<?php
/**
* @brief Moderator Control Panel Extension: Alerts
* @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a>
* @copyright (c) Invision Power Services, Inc.
* @license https://www.invisioncommunity.com/legal/standards/
* @package Invision Community
* @since 12 May 2022
*/
namespace IPS\core\extensions\core\ModCp;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* @brief Moderator Control Panel Extension: Alerts
*/
class _Alerts
{
/**
* Returns the primary tab key for the navigation bar
*
* @return string|null
*/
public function getTab()
{
/* Check Permissions */
if ( ! \IPS\Member::loggedIn()->modPermission('can_manage_alerts') )
{
return null;
}
return 'alerts';
}
/**
* Manage
*
* @return void
*/
public function manage()
{
/* Check Permissions */
if ( ! \IPS\Member::loggedIn()->modPermission('can_manage_alerts') )
{
\IPS\Output::i()->error( 'no_module_permission', '2C427/1', 403, '' );
}
$table = new \IPS\Helpers\Table\Content( '\IPS\core\Alerts\Alert', \IPS\Http\Url::internal( 'app=core&module=modcp&controller=modcp&tab=alerts' ) );
$table->rowsTemplate = array( \IPS\Theme::i()->getTemplate( 'modcp', 'core', 'front' ), 'alertRow' );
$table->include = array( 'alert_title' );
$table->mainColumn = 'alert_title';
$table->sortBy = 'alert_id';
$table->sortDirection = 'desc';
$table->sortOptions = array( 'alert_id' );
$table->title = \IPS\Member::loggedIn()->language()->addToStack( 'modcp_alerts' );
/* Filters */
$table->filters = array(
'alert_filter_active' => [ 'alert_enabled=1' ],
'alert_filter_inactive' => [ 'alert_enabled=0' ],
'alert_filter_viewed' => [ 'alert_viewed > 0 ' ],
'alert_filter_not_viewed' => [ 'alert_viewed = 0 ' ],
'alert_filter_groups' => [ "alert_recipient_type='group'"],
'alert_filter_user' => [ "alert_recipient_type='user'"]
);
\IPS\Output::i()->sidebar['enabled'] = FALSE;
\IPS\Output::i()->breadcrumb[] = array( NULL, \IPS\Member::loggedIn()->language()->addToStack( 'modcp_alerts' ) );
\IPS\Output::i()->title = \IPS\Member::loggedIn()->language()->addToStack( 'modcp_alerts' );
return \IPS\Theme::i()->getTemplate( 'modcp' )->alerts( (string) $table );
}
/**
* Add/Edit Alert
*
* @return void
*/
public function create()
{
$current = NULL;
if ( \IPS\Request::i()->id )
{
$current = \IPS\core\Alerts\Alert::load( \IPS\Request::i()->id );
}
$form = \IPS\core\Alerts\Alert::form( $current );
$form->class = 'ipsForm_vertical';
if ( $values = $form->values() )
{
$alert = \IPS\Core\Alerts\Alert::_createFromForm( $values, $current );
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( "app=core&module=modcp&tab=alerts", 'front', 'modcp_alerts' ) );
}
if ( !\is_null( $current ) )
{
\IPS\Output::i()->title = \IPS\Member::loggedIn()->language()->addToStack( 'edit_alert' );
}
else
{
\IPS\Output::i()->title = \IPS\Member::loggedIn()->language()->addToStack( 'add_alert' );
}
\IPS\Output::i()->breadcrumb[] = array( \IPS\Http\Url::internal( 'app=core&module=modcp&controller=modcp&tab=alerts' ), \IPS\Member::loggedIn()->language()->addToStack( 'modcp_alerts' ) );
\IPS\Output::i()->breadcrumb[] = array( NULL, ( !\is_null( $current ) ) ? \IPS\Member::loggedIn()->language()->addToStack( 'edit_alert' ) : \IPS\Member::loggedIn()->language()->addToStack( 'add_alert' ) );
return $form->customTemplate( array( \IPS\Theme::i()->getTemplate( 'forms', 'core' ), 'popupTemplate' ) );
}
/**
* Delete Alert
*
* @return void
*/
public function delete()
{
if ( !\IPS\Member::loggedIn()->modPermission( 'can_manage_alerts' ) )
{
\IPS\Output::i()->error( 'no_module_permission', '2C427/2', 403, '' );
}
\IPS\Session::i()->csrfCheck();
try
{
$alert = \IPS\core\Alerts\Alert::load( \IPS\Request::i()->id );
}
catch( \OutOfRangeException $e )
{
\IPS\Output::i()->error( 'node_error', '2C427/3', 404, '' );
}
$alert->delete();
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( "app=core&module=modcp&tab=alerts", 'front', 'modcp_alerts' ) );
}
/**
* Change Author
*
* @return void
*/
public function changeAuthor()
{
if ( !\IPS\Member::loggedIn()->modPermission( 'can_manage_alerts' ) )
{
\IPS\Output::i()->error( 'no_module_permission', '2C427/4', 403, '' );
}
try
{
$alert = \IPS\core\Alerts\Alert::load( \IPS\Request::i()->id );
}
catch( \OutOfRangeException $e )
{
\IPS\Output::i()->error( 'node_error', '2C427/5', 404, '' );
}
/* Build form */
$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\Member( 'author', $alert->author(), TRUE ) );
$form->class .= 'ipsForm_vertical';
/* Handle submissions */
if ( $values = $form->values() )
{
$alert->changeAuthor( $values['author'] );
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( "app=core&module=modcp&tab=alerts", 'front', 'modcp_alerts' ) );
}
/* Display form */
\IPS\Output::i()->output = $form->customTemplate( array( \IPS\Theme::i()->getTemplate( 'forms', 'core' ), 'popupTemplate' ) );
}
/**
* Change Alert Status
*
* @return void
*/
public function status()
{
if ( !\IPS\Member::loggedIn()->modPermission( 'can_manage_alerts' ) )
{
\IPS\Output::i()->error( 'no_module_permission', '2C427/6', 403, '' );
}
\IPS\Session::i()->csrfCheck();
try
{
$alert = \IPS\core\Alerts\Alert::load( \IPS\Request::i()->id );
}
catch( \OutOfRangeException $e )
{
\IPS\Output::i()->error( 'node_error', '2C427/7', 404, '' );
}
$alert->enabled = ( $alert->enabled === 1 ? 0 : 1 );
$alert->save();
if ( \IPS\Request::i()->isAjax() )
{
\IPS\Output::i()->json( array( 'OK' ) );
}
else
{
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( "app=core&module=modcp&tab=alerts", 'front', 'modcp_alerts' ) );
}
}
}
@@ -93,6 +93,7 @@ class _Content
$table = new \IPS\Helpers\Table\Content( $currentClass, \IPS\Http\Url::internal( "app=core&module=modcp&controller=modcp&tab=hidden&type={$currentType}", 'front', 'modcp_content' ), array( $where ) );
$table->title = \IPS\Member::loggedIn()->language()->addToStack( 'modcp_hidden' );
$table->classes = array( 'ipsStream' );
return \IPS\Theme::i()->getTemplate( 'modcp' )->tableWrapper( (string) $table );
}
@@ -85,11 +85,12 @@ class _Content
$return['can_manage_announcements'] = 'YesNo';
$return['can_see_poll_voters'] = 'YesNo';
$return['can_edit_poll_votes'] = 'YesNo';
$return['can_close_polls'] = 'YesNo';
$return['can_manage_deleted_content'] = 'YesNo';
$return['can_view_anonymous_posters'] = 'YesNo';
$return['can_manage_alerts'] = 'YesNo';
return $return;
}
@@ -31,18 +31,25 @@ class _Achievements
public static function configurationOptions( \IPS\Member $member = NULL )
{
// Return an array defining each notification type, including the form elements necessary to allow its configuration
return array(
'core_Achievements' => array(
'type' => 'standard',
'notificationTypes' => array( 'new_rank', 'new_badge', 'new_recognize' ),
'title' => 'notifications__core_Achievements',
'showTitle' => FALSE,
'description' => 'notifications__core_Achievements_desc',
'default' => array( 'inline' ),
'disabled' => array()
)
);
if ( \IPS\Settings::i()->achievements_enabled )
{
return array(
'core_Achievements' => array(
'type' => 'standard',
'notificationTypes' => array( 'new_rank', 'new_badge', 'new_recognize' ),
'title' => 'notifications__core_Achievements',
'showTitle' => FALSE,
'description' => 'notifications__core_Achievements_desc',
'default' => array( 'inline' ),
'disabled' => array()
)
);
}
else
{
return [];
}
}
/**
@@ -87,13 +94,13 @@ class _Achievements
}
else
{
$title = \IPS\Member::loggedIn()->rank['title'];
$title = $notification->member->rank['title'];
}
return array(
'title' => \IPS\Member::loggedIn()->language()->addToStack( 'notification__new_rank', FALSE, array( 'sprintf' => array( $title ) ) ),
'url' => \IPS\Member::loggedIn()->url(),
'author' => \IPS\Member::loggedIn()
'title' => $notification->member->language()->addToStack( 'notification__new_rank', FALSE, array( 'sprintf' => array( $title ) ) ),
'url' => $notification->member->url(),
'author' => $notification->member
);
}
@@ -104,7 +111,7 @@ class _Achievements
* @param \IPS\Member $member The member that earned the rank
* @return array
*/
public static function parse_mobile_new_rank( \IPS\Lang $language, \IPS\Member $member )
public static function parse_mobile_new_rank( \IPS\Lang $language, \IPS\core\Achievements\Rank $rank, \IPS\Member $member )
{
return array(
'body' => $language->addToStack( 'notification__new_rank', FALSE, array( 'sprintf' => array( $member->rank['title'] ) ) ),
@@ -149,8 +156,8 @@ class _Achievements
try
{
$badge = \IPS\core\Achievements\Badge::load( $badgeId );
$content = \IPS\Member::loggedIn()->language()->addToStack( 'notification__new_badge_content', NULL, [ 'sprintf' => [ $badge->_title ] ] );
$title = \IPS\Member::loggedIn()->language()->addToStack( 'notification__new_badge', NULL, [ 'sprintf' => [ $badge->_title ] ] );
$content = \IPS\Member::loggedIn()->language()->addToStack( 'notification__new_badge_content', FALSE, [ 'sprintf' => [ $badge->_title ] ] );
$title = \IPS\Member::loggedIn()->language()->addToStack( 'notification__new_badge', FALSE, [ 'sprintf' => [ $badge->_title ] ] );
}
catch( \Exception $e )
{
@@ -165,9 +172,9 @@ class _Achievements
return array(
'title' => $title,
'url' => (string) \IPS\Http\Url::internal( "app=core&module=members&controller=profile&do=badges&id=" . \IPS\Member::loggedIn()->member_id, 'front', 'profile_badges', \IPS\Member::loggedIn()->members_seo_name ),
'url' => (string) \IPS\Http\Url::internal( "app=core&module=members&controller=profile&do=badges&id=" . $notification->member->member_id, 'front', 'profile_badges', $notification->member->members_seo_name ),
'content' => $content,
'author' => \IPS\Member::loggedIn()
'author' => $notification->member
);
}
@@ -182,7 +189,7 @@ class _Achievements
public static function parse_mobile_new_badge( \IPS\Lang $language, \IPS\Member $member, \IPS\core\Achievements\Badge $badge )
{
return array(
'body' => $language->addToStack( 'notification__new_badge', NULL, [ 'sprintf' => [ $badge->_title ] ] ),
'body' => $language->addToStack( 'notification__new_badge', FALSE, [ 'sprintf' => [ $badge->_title ] ] ),
'data' => array(
'url' => (string) \IPS\Http\Url::internal( "app=core&module=members&controller=profile&do=badges&id={$member->member_id}", 'front', 'profile_badges', $member->members_seo_name ),
'author' => $member,
@@ -42,7 +42,7 @@ class _Content
$autoFollow[] = 'comments';
}
$autoFollowField = new \IPS\Helpers\Form\CheckboxSet( 'auto_track', $autoFollow, FALSE, array( 'options' => array( 'content' => 'auto_track_content', 'comments' => 'auto_track_comments' ), 'multiple' => TRUE ) );
$autoFollowField = new \IPS\Helpers\Form\CheckboxSet( 'auto_track', $autoFollow, FALSE, array( 'options' => array( 'content' => 'auto_track_content', 'comments' => 'auto_track_comments' ), 'multiple' => TRUE, 'showAllNone' => FALSE ) );
}
else
{
@@ -55,7 +55,7 @@ class _Content
$autoFollow[] = 'comments';
}
$autoFollowField = new \IPS\Helpers\Form\CheckboxSet( 'auto_follow_defaults', $autoFollow, FALSE, array( 'options' => array( 'content' => 'auto_follow_new_content', 'comments' => 'auto_follow_replied_to' ), 'multiple' => TRUE ) );
$autoFollowField = new \IPS\Helpers\Form\CheckboxSet( 'auto_follow_defaults', $autoFollow, FALSE, array( 'options' => array( 'content' => 'auto_follow_new_content', 'comments' => 'auto_follow_replied_to' ), 'multiple' => TRUE, 'showAllNone' => FALSE ) );
}
return array(
@@ -445,12 +445,13 @@ class _Content
$names = array();
foreach ( $commenters as $member )
{
$name = ( $item->isAnonymous() ) ? \IPS\Member::loggedIn()->language()->addToStack( 'post_anonymously_placename' ) : \IPS\Member::load( $member )->name;
if ( \count( $names ) > 2 )
{
$names[] = \IPS\Member::loggedIn()->language()->addToStack( 'x_others', FALSE, array( 'pluralize' => array( \count( $commenters ) - 3 ) ) );
break;
}
$names[] = \IPS\Member::load( $member )->name;
$names[] = $name;
}
$comment = $commentClass::loadAndCheckPerms( $notification->item_sub_id );
@@ -35,7 +35,7 @@ class _Messenger
$module = \IPS\Application\Module::get( 'core', 'messaging', 'front' );
if ( $module->_enabled )
{
if ( !$member or ( $member->canAccessModule( $module ) and !$member->members_disable_pm ) )
if ( !$member or ( $member->canAccessModule( $module ) and $member->members_disable_pm != 2 ) )
{
$return['core_Messenger'] = array(
'type' => 'standard',
Loaded 100 of 1933 files, more files were not shown because too many files have changed in this diff. Show more