Thursday, 17 January 2019

SFDC Solution Lead Exp


1.Omni-Channel Case assignment to Agent not triggering Case WF/PB update condition?


Omni-channel does not support Escalation Rules or the firing of field updates when a record is routed from an Omni Queue and accepted by an Agent. 

Solution
AgentWork (Object): It represents a work assignment that has been routed to an agent.

1. Write trigger on this object "AgentWork"
2. Get the Agent User & WorkItem (Case Details)
3. Once got the Case Id perform the required logic which wanted to do through WF/PB.


2.One of the Custom Object not able to find from Object Manager / Profile page but from Query Window able to see?How to figure out ?


1.Enter the ID in the URL after Salesforce.com/ --> This will take you to the record directly from there can figure out easily
2.Verify is that Custom Object / Custom Setting and search accordingly 
3.Verify the Custom Object API name and Label name are same or not.If not find the label name and search accordingly
system.debug(SObjectType.MyApiName__c.getLabel());


3.What are the ways to export the data model of a Salesforce instance ?

  1. Lucidchart - Licensed [Salesforce schema connector is been added to it ],It gives the relation ship details [Master-Detail / Lookup]

  1. Schema Builder - Salesforce
  2. Field Dumper - App Exchange
  3. ERD - Tool - App Exchange


4.External Http Callout Limits,

Requirement : On object every record create /update send details to external system,External System Exposed REST API,What is your design approach and how you take care of Governor Limits?


Design / Solution :

1. Confirm again the requirement on every record create / update needs to trigger call out to external system or Can be consolidate and send a bulk request ? Why this is important is
   --> The Target application may have an API restriction,So sending one request on each create and update may hit their limit
   --> Handling bulk data is the technically the clean way of approaching it when working on clouds
  --> If it has multiple external system need to listen to the changes ,See the design of Publish-Subscribe model

2.If the external system application has SOAP API also,Then Outbound Message is suitable.Confirm with the client on this SOAP API availability.

3.If the requirement is exactly as mentioned in question and there is no possibility to send bulk request & There is no SOAP API then write the Apex Call out.

4.External Http Callout Limits : Any action that sends a call to the API counts toward usage limits, except the following:
-->  Outbound messages
-->  Apex callouts

Apex callouts are exempted from limits for total API requests and concurrent requests. but has transaction or cumulative time-based limits (Check Salesforce Documentation for limits)

Note :You can make as many callouts to Google API etc or any of your Enterprise Application web services APIs in a day, only thing is you have to take care of how many callouts to these services are allowed on an hourly, daily or monthly basis depending on the limits in these systems as mentioned in their documentations mostly.

5.Inbound call API usage limit Every inbound call into the API counts against your 24 hour limit - note: the limit is per 24 hours, not per day - the difference is that if you make 10,000 API calls at 11:01 GMT today, those calls are removed from your count at 11:01 GMT the next day, not at 00:00 GMT.

6.System Overview : Use this option to see the current API usage

Reference

5.How to share Activity record [Task/Event] ?

  • In Sharing Setting OWD of Activity object can be defined as Private or Controlled by Parent 
  • Activity object cannot be shared by Sharing rule and this object doesn't have Sharing table at all.
To share the calendar with other users


1.Personal Setup-->My Personal Information-->Calendar Sharing  


2.The "Related To" and/or "Name" field must be completed,Or the
  Activity will be deemed Private regardless of other sharing settings(Such as Calendar Sharing)
Reference

6.Case Document Attachment Notification to owner when attached by other user?

          There is no standard OOB / Can't be achieved through configuration feature.

Customization  Approach:
When attachment added to a record it will be saved into Content Document object in Lightning.

Note : Content Document is not supported in WorkFlow / Process builder
So required customization

Steps :
1.Write trigger on Content Document.
2.Get the sObject record id from ContentDocumentLink by LinkedEntityId
Note : It creates 2 records 1 for sObject link & Other User link who created
3.Find the record owner
4.Send and email alert with the below details
    Document Attached By
    Document Attached Date & Time
    Case Number #

    Title Of the Document 

7.The Src value is hardcoded in the javascript ,It will cause issue every time u migrate the code to different environment?


</script>
Instead  of that try like below --> Configure into static resource and try to access.

<script src="{!$Resource.MyJSFile}" type="text/javascript"  ></script>

Note<apex:includeScript value="{!$Resource.JSName}"/>

Has some performance issue so better is to use like above.

No comments:

Post a Comment