File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
app/code/Magento/Checkout/view/frontend/web/js/model Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,8 @@ define([
135
135
quoteAddressToFormAddressData : function ( addrs ) {
136
136
var self = this ,
137
137
output = { } ,
138
- streetObject ;
138
+ streetObject ,
139
+ customAttributesObject ;
139
140
140
141
$ . each ( addrs , function ( key ) {
141
142
if ( addrs . hasOwnProperty ( key ) && ! $ . isFunction ( addrs [ key ] ) ) {
@@ -151,6 +152,16 @@ define([
151
152
output . street = streetObject ;
152
153
}
153
154
155
+ //jscs:disable requireCamelCaseOrUpperCaseIdentifiers
156
+ if ( $ . isArray ( addrs . customAttributes ) ) {
157
+ customAttributesObject = { } ;
158
+ addrs . customAttributes . forEach ( function ( value ) {
159
+ customAttributesObject [ value . attribute_code ] = value . value ;
160
+ } ) ;
161
+ output . custom_attributes = customAttributesObject ;
162
+ }
163
+ //jscs:enable requireCamelCaseOrUpperCaseIdentifiers
164
+
154
165
return output ;
155
166
} ,
156
167
You can’t perform that action at this time.
0 commit comments