Skip to content

Commit

Permalink
ENGCOM-2587: [Backport] Fixed ability to set field config from layout…
Browse files Browse the repository at this point in the history
… xml #11302 #17211
  • Loading branch information
Stanislav Idolov authored Jul 31, 2018
2 parents 00a357b + 19d0412 commit ece58a4
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions app/code/Magento/Checkout/Block/Checkout/AttributeMerger.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,20 +164,19 @@ protected function getFieldConfig(

$element = [
'component' => isset($additionalConfig['component']) ? $additionalConfig['component'] : $uiComponent,
'config' => [
// customScope is used to group elements within a single form (e.g. they can be validated separately)
'customScope' => $dataScopePrefix,
'customEntry' => isset($additionalConfig['config']['customEntry'])
? $additionalConfig['config']['customEntry']
: null,
'template' => 'ui/form/field',
'elementTmpl' => isset($additionalConfig['config']['elementTmpl'])
? $additionalConfig['config']['elementTmpl']
: $elementTemplate,
'tooltip' => isset($additionalConfig['config']['tooltip'])
? $additionalConfig['config']['tooltip']
: null
],
'config' => $this->mergeConfigurationNode(
'config',
$additionalConfig,
[
'config' => [
// customScope is used to group elements within a single
// form (e.g. they can be validated separately)
'customScope' => $dataScopePrefix,
'template' => 'ui/form/field',
'elementTmpl' => $elementTemplate,
],
]
),
'dataScope' => $dataScopePrefix . '.' . $attributeCode,
'label' => $attributeConfig['label'],
'provider' => $providerName,
Expand Down

0 comments on commit ece58a4

Please sign in to comment.