This use case pertains to contract management. You can use process builder to create a new contract for an account based on specified activity within the system. We will be creating a new contract for an account whenever an opportunity is closed/won.
Here are the steps I followed:
- Created a new checkbox on contract: contract – opportunity
- Created a new process “when a record changes”
- On the opportunity object, whenever a record is created or edited
- Process criteria: conditions are met
- Opportunity stage equals closed won
- AccountID not null
- All of the conditions are met (both the above two)
- Scroll down to advanced and check “Do you want to execute the actions only when specified changes are made to the record?”. I’m not sure about this but I think it’s equivalent to “to subsequently meet criteria”.
For action, create a record
- Create new contract
- Fill in the fields as follows
Then there is a second process to be made, on the contract object.
- Create new process
- When a record changes
- Contract object
- Whenever a record is created
- For conditions, do whenever contract – opportunity is checked
- Immediate action: update contract record and set picklist to activated
So basically, whenever an opportunity is closed/won and it has a valid account associated with it, Salesforce will create a new contract for that account, ticking a checkbox among other things. Whenever a contract is created with that checkbox ticked, it will run another process to activate the contract by way of picklist.
What I don’t understand about this is why they wouldn’t just set that picklist field to active with the first process, which would seem to eliminate the need for two processes.