-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#375 Feed billing and shipping address form from graphql using with r…
…espect to field config mapping
- Loading branch information
1 parent
8b94a08
commit 34af785
Showing
5 changed files
with
57 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/** | ||
* Here it maps field config data with graphql data. | ||
* | ||
* If you have custom fields, then most probably you need to pass this data | ||
* via graphql (using custom implementation) and then if it is a part of graphql | ||
* repsonse `cart.billing_address` or `cart.shipping_address[0]`, then you can | ||
* add the corresponding mapping here. | ||
* | ||
* Key ==> Field config reference | ||
* Value ==> Graphql reference. | ||
*/ | ||
export default { | ||
city: 'city', | ||
street: 'street', | ||
company: 'company', | ||
lastname: 'lastname', | ||
postcode: 'postcode', | ||
region: 'region.code', | ||
firstname: 'firstname', | ||
telephone: 'telephone', | ||
country_id: 'country.code', | ||
// vat_id: 'vat_id', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters