- Модуль: sale
- Путь к файлу: ~/bitrix/modules/sale/lib/controller/property.php
- Класс: BitrixSaleControllerProperty
- Вызов: Property::getLocationSettings
protected function getLocationSettings()
{
$orderProps = new CSaleOrderProps();
$locationOptions = ['' => Loc::getMessage('NULL_ANOTHER_LOCATION')];
$result = $orderProps->GetList([],
[
'PERSON_TYPE_ID' => $this->personTypeId,
'TYPE' => 'STRING',
'ACTIVE' => 'Y'
],
false, false, ['ID', 'NAME']
);
while ($row = $result->Fetch())
{
$locationOptions[$row['ID']] = $row['NAME'];
}
return [
'IS_LOCATION' => [
'TYPE' => 'Y/N' ,
'LABEL' => Loc::getMessage('F_IS_LOCATION'),
'DESCRIPTION' => Loc::getMessage('F_IS_LOCATION_DESCR'),
'ONCLICK' => null
],
'INPUT_FIELD_LOCATION' => [
'TYPE' => 'ENUM',
'LABEL' => Loc::getMessage('F_ANOTHER_LOCATION'),
'DESCRIPTION' => Loc::getMessage('F_INPUT_FIELD_DESCR'),
'OPTIONS' => $locationOptions,
'VALUE' => 0
],
'IS_LOCATION4TAX' => [
'TYPE' => 'Y/N',
'LABEL' => Loc::getMessage('F_IS_LOCATION4TAX'),
'DESCRIPTION' => Loc::getMessage('F_IS_LOCATION4TAX_DESCR'),
'ONCLICK' => null
],
];
}