I am following this idea since I needed this feature in one of my projects. Since Salesforce already has this in their future roadmap, I realized that It could be an addition to my #GivingBackToCommunity list. I managed to create a lightning component which can be used with lightning action on Opportunity records. This will allow users to clone an opportunity with the products.
IdeaExchange Idea
Here is the idea on the IdeaExchange
Lightning Component for Clone with Products
Here is the link to the Lightning Component GitHub repository
Steps to Install/Configure this component in your Org
For Sandbox/Dev Environment
First, you need to identify whether you want to install a managed or unmanaged package. This can be determined based on your purpose. If you want to amend existing functionality then the unmanaged package is what you are looking for. If that’s not the case and you just want to test it before installing it to the production then managed package is your best bet.
- Install the package in your Org. Following are the links to the package installation URL.
Link to unmanaged package
Link to managed package - After installing package successfully, you need to configure it and you will have to switch to Salesforce classic view as you need to update the fieldsets ( fieldsets are not available in lightning experience till Winter ‘2018 release).
- You have 2 fieldsets first one on Opportunity object and the second one on the OpportunityProduct object. These fieldsets let you decide which field values you want to copy to new opportunity ( cloned opportunity ). By default, it will copy those fields only which are required to save the record.
- To modify the fieldset fields navigate to Setup | Customize | Opportunity | FieldSets and you will find the Clone Opportunity Field Set.
- You can add fields which you want to be copied in the new opportunity. See the below screenshot.
- After adding the fields in the fieldset, you need to add action to the page layout. So navigate to the page layout section and drag the “Clone with Products” action on the pane.
- Save everything and switch back to lightning experience view to use this feature.
For Production Environment
- Install the package in your Org. Following are the links to the package installation URL.
Link to managed package
Rest steps are same as explained for the sandbox environment.
Please let me know if you have any feedback on this.
By Naveen Sharma
June 19, 2018Hi Naval,
I have tried this and the record will not save. Also we have zero amounts on some products but it will not allow zeros when copying over.
By Naveen Sharma
June 20, 2018Can you shoot me an email to naval.sfdc@gmail.com with the screenshots?
Thanks
By Naveen Sharma
June 20, 2018Can you tell me more about the package you installed? Are you using the managed or unmanaged package in your org. Also, did you add the fields to fieldset for opportunity and opportunity line item?
Thanks,
By Naveen Sharma
November 9, 2018I think the issue is that there is no success message upon clicking save. The oppty is cloned, but upon clicking save nothing happens.
By Naveen Sharma
November 27, 2018I will update the package once I get some time. I am super busy due to professional commitments. I am really sorry for the inconvenience.
By Naveen Sharma
August 20, 2018Thank you for your work on this, we have it working in lightning using the managed package, am I right in thinking that it won’t work if the Op is closed won? we are finding that we have to reset the stage before the clone will save.
By Naveen Sharma
August 24, 2018Hi Melinda,
Thanks for using it.
t should work if you don’t have any validation rule which doesn’t allow you to create an opportunity with closed won stage. Since the cloned opp will have the same stage name as the original opp. I am working on an enhancement so you can update the cloned opportunity before it gets created.
By Naveen Sharma
July 18, 2019Hi Everyone,
You can achieve this functionality by installing our application from AppExchange.
We have developed an application which will help you to Clone Opportunities with their Products easily just by a click of a button. This application is live on AppExchange and you can install it by clicking the link below:
If you like the application, please feel free to give us a positive review.
It would encourage us to build future applications.
AppExchange link: https://appexchange.salesforce.com/appxListingDetail?listingId=a0N3A00000FMYhaUAH
Thank-you,
Ashi Saxena
CloudVandana Solutions
info@cloudvandana.com