0

When an Opportunity of Record Type='Execute' is closed a) Case of Record Type ='order management' should be created, routed to OM queue and OppId need to be populated on case.

b) When OM member close queue, Email has to be send.

Can I make it like this with workflow? or trigger?

  1. Setup >> Create >> Workflows & Approvals >> Workflow Rules >> New Rule >> Opportunity
  2. Evaluate the workflow "created, and every time it’s edited"
  3. Run the rule if the following "formula evaluates to true"
  4. Formula is this: ISPICKVAL(Execute, "Closed") but how to do it with case or to write trigger and how can I send the email template with workflow or trigger.
2
  • 1
    Have you tried anything? You'll get a better response if you edit your question with actual code or process builder flows as the Community tends not to like doing your work for you.
    – cropredy
    Jun 23, 2016 at 2:45
  • Can I make it with trigger or workflow like this Setup >> Create >> Workflows & Approvals >> Workflow Rules >> New Rule >> Opportunity Evaluate the workflow "created, and every time it’s edited" Run the rule if the following "formula evaluates to true" 4. Formula is this: ISPICKVAL(Execute, "Closed") 5. Add a field update that changes the record type Jun 23, 2016 at 3:22

1 Answer 1

1

You can either use Process Builder or a Trigger as a Workflow rule is not able to create a new Case record only update a field or send an email. Process Builder or a Trigger can both create the case record and send an email if required. This can auto assign that new case to the queue or you can use an assignment rule.

I would recommend using Process Builder in the first place as it is easier to use than writing Apex Code and allows you to prototype the logic even if you decide a trigger is required.

an example

If the Case is accepted from the Queue and then closed a workflow rule can easily be setup to send an email. In this case I would advise including the Record Type in the Formula as it will prevent emails being sent on other cases when closed.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .