You need to sign in to do that
Don't have an account?
Dennis Warner2
Convert a url button to a lightning component.
Hello, I've been working to convert this url button:
/apex/SDOC__SDCreate1?id={!FX5__Quote__c.Id}&Object=FX5__Quote__c
into a lightning component. I've already built the component button, but i don't know where to put the above url. In controller? How would that look? I've tried figuring it out on trailhead, but it'll take another week before it answers my question. Any answers would be appreciated.
/apex/SDOC__SDCreate1?id={!FX5__Quote__c.Id}&Object=FX5__Quote__c
into a lightning component. I've already built the component button, but i don't know where to put the above url. In controller? How would that look? I've tried figuring it out on trailhead, but it'll take another week before it answers my question. Any answers would be appreciated.
You can use isUrlAddressable interface to call lightning component and pass parameters to it.
https://developer.salesforce.com/docs/component-library/bundle/lightning:isUrlAddressable/documentation
<aura:component implements="lightning:isUrlAddressable">
add this handler in your lighting component
<aura:handler name="change" value="{!v.pageReference}" action="{!c.onPageReferenceChange}"/>
replace url in your button with this url
/lightning/cmp/c__componentName?c__id={!FX5__Quote__c.Id}&c__Object=FX5__Quote__c
Add this method in lightning component controller js---
Note:- If the link look like foreign language to you then,who created the lightning component? Ask him to follow the above steps.
Were you able to resolve this issue? I too am trying to create the SDOC link from a lightning component.