- Модуль: crm
- Путь к файлу: ~/bitrix/modules/crm/lib/controller/response/engine/content.php
- Класс: Bitrix\Crm\Controller\Response\Engine\Content
- Вызов: Content::__construct
public function __construct(ContentInterface $content, $status = self::STATUS_SUCCESS, ErrorCollection $errorCollection = null, array $additionalResponseParams = [])
{
global $APPLICATION;
$this->status = $status?: self::STATUS_SUCCESS;
$this->errorCollection = $errorCollection?: new ErrorCollection;
$APPLICATION->ShowAjaxHead();
$html = $content->getHtml();
$this->collectAssetsPathList();
$this->setData([
'status' => $this->status,
'data' => [
'html' => $html,
'assets' => [
'css' => $this->getCss(),
'js' => $this->getJsList(),
'string' => $this->getStringList()
]
],
'additionalParams' => $additionalResponseParams,
'errors' => $this->getErrorsToResponse(),
]);
}