I'm currently working on a form using lightning:RecordEditForm tag. I'm using lightning:inputField tag to display Account's BillingAddress fields (country code, state code, street, city, zip/code).
<lightning:recordEditForm objectApiName="Account" > <lightning:inputField aura:id="address" fieldName="BillingAddress"/> </lightning:recordEditForm>
I would like to prepopulate address fields, for instance the country field with the user's country code.
var address = component.find("address").get("v.value"); console.log(JSON.stringify(address));
I get the following results :
So I tried to set the component's value with a pre-constructed map, but no impact.
Does anyone know how I can achieve this ? Thanks !