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 @@ -84,7 +84,8 @@ define([
84
84
quoteAddressToFormAddressData : function ( addrs ) {
85
85
var self = this ,
86
86
output = { } ,
87
- streetObject ;
87
+ streetObject ,
88
+ customAttributesObject ;
88
89
89
90
$ . each ( addrs , function ( key ) {
90
91
if ( addrs . hasOwnProperty ( key ) && ! $ . isFunction ( addrs [ key ] ) ) {
@@ -100,6 +101,16 @@ define([
100
101
output . street = streetObject ;
101
102
}
102
103
104
+ //jscs:disable requireCamelCaseOrUpperCaseIdentifiers
105
+ if ( $ . isArray ( addrs . customAttributes ) ) {
106
+ customAttributesObject = { } ;
107
+ addrs . customAttributes . forEach ( function ( value ) {
108
+ customAttributesObject [ value . attribute_code ] = value . value ;
109
+ } ) ;
110
+ output . custom_attributes = customAttributesObject ;
111
+ }
112
+ //jscs:enable requireCamelCaseOrUpperCaseIdentifiers
113
+
103
114
return output ;
104
115
} ,
105
116
You can’t perform that action at this time.
0 commit comments