Record page LWC - can be used in the Lead Record Page in the Lightning Record Page editor. In theory, you can use it in other places as well, but it will fail -- trust me.
The purpose of this project was to get familiar with LWC in LRP, leveraging wire services, and getting familiar with event handlers such as handlechange and handleSuccess
Note, this is a flat component, meaning, the only way to add or remove fields is to modify the code. I am working on a dynamic version
Functionality:
-
Displays the following fields from the Lead Object on a Lightning Card (leveraging: Lightning-record-edit-form): a. Lead First Name b. Lead Last Name c. Lead Title d. Lead Email e. Lead Source f. Lead Industry g. Lead Company h. Lead Phone
-
Admin user can drag and drop component anywhere on the Lead Lightning Record Page. a. In the configuration menu the admin can enter the text they would like for the toast message to be displayed on success: i. Toast Title - The front messsage part of the toast message (IE: the header) ii. Toast Body - The remainder of the toast message iii. Component Title - title displayed on LWC between Lightning Bolts.
-
User can update lead from component and have record saved.
Configuration (Toast and Title of LWC)
Completion Percentage
The completion percentage component uses the progress ring from the LWC library found here: https://developer.salesforce.com/docs/component-library/bundle/lightning-progress-ring/example
Using both OnLoad and OnUpdate methods we are able to dynamically show users while they are filling out the form their percentage towards completion with a full progress ring when all fields have a value.