Skip to content

Commit

Permalink
Update HlElement.php
Browse files Browse the repository at this point in the history
Исправлена формирование карты полей
  • Loading branch information
aak74 authored Dec 18, 2018
1 parent 7f678c7 commit abf44ce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Element/HlElement.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,6 @@ private function getMapFields(array $userFields)
$result = $this->fieldsBase;
foreach ($userFields as $field) {
$alias = \Akop\Util::camelize(substr($field["FIELD_NAME"], 3));
if (!in_array($alias, $this->fieldsIgnore) && !in_array($fieldName, $this->fieldsIgnore)) {
$result[$alias] = $fieldName;
}
switch ($field["USER_TYPE_ID"]) {
case "hlblock":
$result = array_merge(
Expand All @@ -133,6 +130,9 @@ private function getMapFields(array $userFields)
$alias .= "Id";
break;
default:
if (!in_array($alias, $this->fieldsIgnore) && !in_array($fieldName, $this->fieldsIgnore)) {
$result[$alias] = $fieldName;
}
break;
}
$result[$alias] = $field["FIELD_NAME"];
Expand Down

0 comments on commit abf44ce

Please sign in to comment.