function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Laxman1975Laxman1975 

Override New Button on child with Lightening Component and get parent record id

Hi All,

We have Quote as custom child object under Opportunity. On Opportunity Page layout - > Related list for Quote-> New Button is override by visualforce in classic. Using retURL, we are getting parent id i.e. opportunity id and we can do necessary business logic.

But in lightening, as we cannot use retURL , so we have override New button with Lightening Component with HasRecordId. But we are not able to get parent record id i.e. Opportunity. Does any one know solution on this? Please let us know any suggestion or comments. 

Regards
Laxman
Veena Sundara-HeraguVeena Sundara-Heragu
I don't think you can do it that way in lightning.  Instead, create a lightning object level action on Opportunity to create "New Quote"