You need to sign in to do that
Don't have an account?
Jon Foy
Need to automate adding a user to Case Team - Help!
We have a custom object "Case Resource" that allows us to build a table of resources with applicable bill rates on any given case. We also use the Case Team object to control access to community users on a case by case basis. I'd like to create either a workflow or trigger (not sure which is applicable), to automatically add a user to the case team, when they are manually added to the custom object as a case resource. I need help writing the code on either the workflow or trigger if either could get the job done.
NOTE: This code has not been tested and may contain typographical or logical errors.
The full trigger would look like:
The trigger will only fire after insert and does not take into account if the user is already on the CaseTeamMember list. You will probably want to modify it to do a check for that if there is a chance that the user is already part of the CaseTeamMembers list
[1] http://blog.deadlypenguin.com/blog/2014/07/23/intro-to-apex-auto-converting-leads-in-a-trigger/
[2] http://blog.deadlypenguin.com/blog/2012/02/13/classifying-triggers-in-salesforce/