403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/im/classes/general/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/im/classes/general/im_notify_schema.php
<?

use Bitrix\Im\Configuration\Notification;

IncludeModuleLangFile(__FILE__);

class CIMNotifySchema
{
	protected static $arNotifySchema = null;

	public function __construct()
	{
	}

	public static function GetNotifySchema()
	{
		if (is_null(self::$arNotifySchema))
		{
			self::$arNotifySchema = Notification::getDefaultSettings();
		}
		return self::$arNotifySchema;
	}

	public static function CheckDisableFeature($moduleId, $notifyEvent, $feature)
	{
		return (new Notification($moduleId, $notifyEvent))->checkDisableFeature($feature);
	}

	public static function GetDefaultFeature($moduleId, $notifyEvent, $feature)
	{
		return (new Notification($moduleId, $notifyEvent))->getDefaultFeature($feature);
	}

	public static function GetLifetime($moduleId, $notifyEvent)
	{
		return (new Notification($moduleId, $notifyEvent))->getLifetime();
	}

	public static function OnGetNotifySchema()
	{
		$config = array(
			"im" => Array(
				"NAME" => GetMessage('IM_NS_IM'),
				"NOTIFY" => Array(
					"message" => Array(
						"NAME" => GetMessage('IM_NS_MESSAGE_NEW_MSGVER_1'),
						"PUSH" => 'Y',
						"DISABLED" => Array(IM_NOTIFY_FEATURE_SITE, IM_NOTIFY_FEATURE_XMPP)
					),
					"chat" => Array(
						"NAME" => GetMessage('IM_NS_CHAT_NEW'),
						"MAIL" => 'N',
						"PUSH" => 'Y',
						"DISABLED" => Array(IM_NOTIFY_FEATURE_SITE, IM_NOTIFY_FEATURE_XMPP, IM_NOTIFY_FEATURE_MAIL)
					),
					"openChat" => Array(
						"NAME" => GetMessage('IM_NS_OPEN_NEW_MSGVER_1'),
						"MAIL" => 'N',
						"PUSH" => 'Y',
						"DISABLED" => Array(IM_NOTIFY_FEATURE_SITE, IM_NOTIFY_FEATURE_XMPP, IM_NOTIFY_FEATURE_MAIL)
					),
					"like" => Array(
						"NAME" => GetMessage('IM_NS_LIKE'),
					),
					"mention" => Array(
						"NAME" => GetMessage('IM_NS_MENTION_2'),
						"PUSH" => 'Y',
					),
					"default" => Array(
						"NAME" => GetMessage('IM_NS_DEFAULT'),
						"PUSH" => 'N',
						"MAIL" => 'N',
					),
				)
			)
		);

		if (!IsModuleInstalled("b24network"))
		{
			$config["main"] = array(
				"NAME" => GetMessage('IM_NS_MAIN'),
				"NOTIFY" => Array(
					"rating_vote" => Array(
						"NAME" => GetMessage('IM_NS_MAIN_RATING_VOTE'),
						"LIFETIME" => 86400*7
					),
					"rating_vote_mentioned" => Array(
						"NAME" => GetMessage('IM_NS_MAIN_RATING_VOTE_MENTIONED'),
						"LIFETIME" => 86400*7
					),
				),
			);
		}

		return $config;
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit