Proposal Summary
This proposal outlines a custom solution that would automate the creation of an Opportunity record when a Supply Proposal record is generated. Additionally, the changes made to the Supply Proposal record on Probability and Subtotal would trigger updates to the Projected Total and Probability fields in the corresponding Opportunity record.
Requirement
The Flowco Ltd t/a Waterworks-New Zealand-NS needs to automatically create an Opportunity record when a Supply Proposal record is generated.
Basically, we need the system to automatically generate a new Opportunity every time a Supply Proposal is created, pulling the data from the SP, and with the option to exclude the SP from this script if needed (assuming this would be a script).
Fields to be mapped upon create:
And if possible, we would need the following fields to be updated if the supply proposal is edited:
Deliverables
Automatically creates the Opportunity record when a Supply Proposal record is generated.
There will be two different contexts:
Create Context
A custom checkbox labeled “Exclude from Opportunity” will be available in the Supply Proposal record (also known as the Estimate record) which by default will be set to “False” or unchecked.
Upon generating a Supply Proposal, an Opportunity record will be created. The criteria for creating the opportunity record will be based on the checkbox field “Exclude from Opportunity”.
In case the user wishes to exclude the Supply Proposal from creating the Opportunity record, they can mark the checkbox as “true”.
A new field named “Related Opportunity” will be available within the Supply Proposal record, specifically for storing the document number of the created Opportunity record. This field will be added under the custom tab. This field will be non-editable for the user.
Field Mapping:
Mandatory Field Mapping:
Status – Default Value “In discussion”
Expected Close – Current Date
Currency – Currency form Supply proposal accounting tab
Exchange Rate – Exchange Rate form Supply proposal accounting tab
Items – Items from the Supply Proposal record.
Edit Context
Upon editing specific fields, such as “Probability” and “Subtotal”, in the Supply Proposal record, we will update the corresponding fields, “Probability” and “Projected Total”, in the Opportunity record.
The scripts will only execute if the Supply Proposal record is linked to the Opportunity record through the custom field called “Related Opportunity”.
Assumptions
We assume the mapping for the default values will be same as mentioned.
If the user unchecks the checkbox value in the Supply proposal record after the opportunity record has been created, we will not remove the linked custom field value.
We will only update the opportunity record based on changes to the “Probability” and “Subtotal” fields in the Supply proposal record during the edit process, and not consider any additional modifications like adding line items.
The opportunity records will be created as standalone records.
Role permissions are not considered in this scope