• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/compatible/internals/entitycompatibility.php
  • Класс: BitrixSaleCompatibleInternalsEntityCompatibility
  • Вызов: EntityCompatibility::addQueryAlias
protected function addQueryAlias($name, $value = null)
{
	$list = array();

	if ($name == $value)
	{
		$value = null;
	}

	if (!empty($value) && is_array($value))
	{
		$list = $value;
	}
	else
	{
		$list[$name] = $value;
	}

	foreach ($list as $fieldName => $fieldValue)
	{
		if (in_array($fieldName, $this->queryAliasList))
		{
			return false;
		}

		$this->queryAliasList[] = $fieldName;
		$this->query->addAlias($fieldName, $fieldValue);

	}

	return true;
}