3namespace Bitrix\Socialnetwork\CommentAux;
5use Bitrix\Disk\Configuration;
6use Bitrix\Main\UserTable;
7use Bitrix\Main\Localization\Loc;
10Loc::loadMessages(__FILE__);
14 public const TYPE =
'FILEVERSION';
21 if (!empty(
$fields[
'AUTHOR_ID']))
31 static $userCache = [];
42 if (isset($userCache[(
int)
$params[
'userId']][
'PERSONAL_GENDER']))
44 $gender = $userCache[(int)
$params[
'userId']][
'PERSONAL_GENDER'];
48 $res = UserTable::getList([
50 '=ID' => (
int)
$params[
'userId'],
52 'select' => [
'ID',
'PERSONAL_GENDER' ],
58 $gender =
$user[
'PERSONAL_GENDER'];
63 $availableGenders = [
'M',
'F'];
64 if (!in_array($gender, $availableGenders,
true))
69 if (Loader::includeModule(
'disk') && !Configuration::isEnabledKeepVersion())
71 return Loc::getMessage(
72 'SONET_COMMENTAUX_HEAD_FILEVERSION_TEXT' . (!empty($gender) ?
'_' . $gender :
'')
76 return Loc::getMessage(
'SONET_COMMENTAUX_FILEVERSION_TEXT' . (!empty($gender) ?
'_' . $gender :
'')) ??
'';
81 return \CSocNetLogFollow::getExactValueByRating(
90 return 'RATING|' . ($ratingVoteParams[
'VALUE'] >= 0 ?
'' :
'DL|') .
'BLOG_COMMENT|' .
$fields[
'ID'];
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)