-
How to prepopulate EventWhoids in Salesforce lightning component?
I am trying to create a lightning component which uses e.force:recordCreate and prepopulates a list of ContactIds in the EventWhoIds field. However, the contact do not get prepopulated in the form.
console.log(component.get("v.contactIds"));
var contactRecords = component.get("v.contactIds");
console.log("contactRecords: " + contactRecords);var createEvent = $A.get("e.force:createRecord");
createEvent.setParams({
"entityApiName": "Event",
"defaultFieldValues": {
'WhatId' : component.get("v.recordId"),
'EventWhoIds' : contactRecords
}
});
createEvent.fire();-
This discussion was modified 6 years ago by
Prachi.
-
This discussion was modified 6 years ago by
Forcetalks.
-
This discussion was modified 6 years ago by
Forcetalks.
-
This discussion was modified 6 years ago by
Log In to reply.
Popular Salesforce Blogs
8 Ways CRM Software Can Help Reduce Costs
CRM systems are becoming essential tools for businesses. A recent study by Nucleus Research found that for every dollar invested in CRM, businesses see a…
Salesforce Links Einstein GPT and Data Cloud to Flow
Salesforce links Einstein GPT and Data Cloud to Flow to drive the autonomous, intelligent enterprise by integrating AI-generated content with real-time customer data to automate…
Popular Salesforce Videos
What is Workflow Rule in Salesforce | Salesforce Interview Questions and Answers
What is Workflow Rule in Salesforce | Salesforce Interview Questions and Answers
Automate Your App With and Without Code | Salesforce Developer Tutorial
In this video, you will learn how you can automate your business process with and without code. This video teaches you how to use a…
Salesforce Tutorial For Beginners | Introduction To Salesforce | Salesforce Training
This video on Salesforce training will help you understand the easy and best tool for CRM and Branding. You will learn how to customize the…