• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/cashbox/inputs/file.php
  • Класс: Bitrix\Sale\Cashbox\Inputs\File
  • Вызов: File::getEditHtmlSingle
static function getEditHtmlSingle($name, array $input, $value)
{
	$input['ONCHANGE'] =
		"var anchor = this.previousElementSibling.previousElementSibling;".
		"if (anchor.firstChild) anchor.removeChild(anchor.firstChild);".
		"anchor.appendChild(document.createTextNode(this.value.split(/(\\\\|\\/)/g).pop()));".
		($input['ONCHANGE'] ?? '');

	$fileAttributes = static::extractAttributes($input,
		array('DISABLED'=>'', 'AUTOFOCUS'=>'', 'REQUIRED'=>''),
		array('FORM'=>1, 'ACCEPT'=>1));

	$otherAttributes = static::extractAttributes($input, array('DISABLED'=>''), array('FORM'=>1), false);

	return static::getViewHtmlSingle($input, $value)
		.''
		.''
		.''
		.(
		$input['NO_DELETE']
			? ''
			: ''
		);
}