Skip to main content

Posts

Recent posts

What is Defer sharing calculation in salesforce

Defer Sharing Calculation lets an administrator suspend and resume sharing calculations. This permission affects group membership calculation and sharing rule calculation. Performing a large number of configuration changes can lead to very long sharing rule evaluations or time outs. To avoid these issues, an administrator can suspend these calculations and resume calculations during an organization’s maintenance period. The Defer Sharing Calculation permission is not enabled by default. We should contact Salesforce to enable it. Administrators should plan to suspend/resume sharing calculations during maintenance windows to have minimal impact on users. For example, you make large number of changes to criteria based sharing rules to allow access to specific groups and territories. Since sharing rule calculation is enabled by default, those sharing rule changes are evaluated immediately and can take a very long time to process and cause your organization to time out. With Defer ...

Custom Queue Management using visualforce page

Here is the pseudo code to build custom page to add/remove queue members without giving Setup and Configuration setting to any other user's profile than Sys Admin Sample Controller: public class QueueManagementController {       public SelectOption[] selectedContacts { get; set; }     public SelectOption[] allContacts { get; set; }     public SelectOption[] queuelist {get; set;}       public String queueId {get; set;}     public String message { get; set; }       public QueueManagementController(){               queuelist = new List<SelectOption>();         queuelist.add(new SelectOption('', '-None-'));         for(Group Grouprecord : [Select Id, name from Group where type = 'Queue']){             queuelist.add(new SelectOption(grouprecord.Id, grouprecord.name));       ...

Tree Structure for Self related records in salesforce

How to build a tree for the records which has self lookup? Here I am taking a custom object called Category__c and created a self-lookup to it with the field FKParentCategory__c. Controller: public without sharing class categoryTreeController {       List<Category__c> parentrecord;     Map<Id, List<Category__c>> categoryMap{get;set;}     public string treeJSON{get;set;}     public string treeJSON2{get;set;}     private string whereClause;     public integer count{get;set;}     public categoryTreeController ()     {         treeJSON='[';         count=0;         whereClause='';               string pageName=ApexPages.currentPage().getParameters().get('pageName');         if(pageName=='clientPage'){             whereCl...

Kanban view for Lightning

Tired of list views? Looking for a dynamic views to show your cases or opportunities in all new way? Here we go,  Salesforce introduced Kanban views for us to have better visibility  of our cases/opportunities and their journey from opening to closure. A case kanban allows you to visually summarize all of the cases for your agents,  by status or priority. It's not only a board, but also a  drag and drop  tool that will help agents keep their cases moving towards resolution. Similarly an opportunity Kanban display opportunities from a particular sales path Let's take a closer look at what all we can do with Kanban Track a Deal with Path Display opportunities by Sales path Move an Opportunity to the Next Stage Take Action on Your Records

How to login to another salesforce Instance from your own Instance

Need to login to other salesforce Instance from your own Instance ?        Here is a simple solution. Decide service provider and Identity provider Service Provider  :  Salesforce Instance (A's developer org). Identity Provider  :  Salesforce Instance (B's developer org). Identity provider Step 1 : Create and register a domain in Identity provider organization,  (Domain Management --> B's Domain) Step 2 : Enable Identity provider. (Security Controls --> Identity Provider)              Create a dummy certificate (self Signed) and set it as use on communication with service provider .              Save identity provider settings.              Download the certificate and saved in a drive.( Need to upload in service provi...

Salesforce Spring 16 Release - CreatedDate and Apex Unit Tests

( Note that this blog post refers to functionality that is intended to be made available in the Spring 16 release of Salesforce, but features may be removed prior to the Spring 16 go-live date, so you may never see this in the wild! ) INTRODUCTION Anyone who has written a reasonable amount of Apex unit tests is likely to have butted up against the shortcoming that the CreatedDate is set when a record is inserted into the Salesforce database. While at first glance this may not seem to be such a huge issue, consider the scenario of a custom Visualforce page, maybe for use in a dashboard, that displays the 10 most recent cases: The controller is about as straightforward as it can be - simply querying back the records from the Salesforce database: ? 1 2 3 4 5 6 7 8 9 10 11 public class RecentCasesController {      public List<Case> getRecentCases()      {     ...