Skip to content

Salesforce Summer ’22 Release Top New Features

Salesforce Summer ’22 Release Top New Features.

1. Analytics – Summary Functions Now Include Median

Report on the statistics that matter to your business. The median function is now available for all summary measures in reports and dashboards.

To show the available summary functions, select a summary action. Median is available in addition to sum, average, max, and min.

Salesforce Summer '22 Release Features - Report excerpt showing median summary function

2. Analytics – Manage Your Reports and Dashboards in Analytics Home (Beta)

Analytics Home is the new home base for your Lightning reports and dashboards. The Analytics Home is where all your Salesforce analytics content is organized in a cohesive and seamless experience. You get the benefit of a powerful search experience, better organization, sharing, and more.

From Setup, in the Quick Find box, enter Reports, and then select Reports and Dashboards Settings. Select Enable the Unified Experience for Analytics Home. From the App Launcher, select Analytics.

Salesforce Summer '22 Release Features - Analytics Home page.

As you get started, you see that some areas of Home are familiar, such as the search bar (1) and left navigation (2). Analytics Home provides a personalized and intelligent experience (3) for each Analytics user that makes smart recommendations for discovering new assets.

3. Customization – Bulk Manage Picklist Values (Beta)

Save more time managing your picklists. You can now delete, activate, deactivate, or replace multiple custom picklist field values at once. Previously, you modified them one at a time.

Opt in to Advanced Picklist Values Management (beta) from the Picklist Settings page. Then navigate to the custom field definition page. In the Values and Inactive Values sections, you see a checkbox next to each picklist value. You can select multiple values and use one of the new buttons: Delete SelectedDeactivate SelectedReplace Selected, or Activate Selected. This feature is available only for custom picklists with predefined values.

Salesforce Summer '22 Release  Features - The advanced picklist values management buttons in the Values and Inactive Values panes

4. Customization – Customize and Filter Related Lists in the Lightning App Builder

Customize related lists directly from the Lightning App Builder instead of the page layout editor with the new Dynamic Related List – Single component. Choose the list’s fields and sort order, apply filters, and give the list a descriptive name. To see the most relevant records, set up two related lists with different filters on the same object. For example, on the Contact record page, create one related list to see only the opportunities created in the last 30 days. Then, create a second related list to see all opportunities with an amount over $500,000.

5. Development – Create Notifications with New Alert, Confirm, and Prompt Modules

Use the new modules LightningAlertLightningConfirm, and LightningPrompt instead of native APIs to create notifications from your Lightning web components. Chrome and Safari plan to end support for cross-origin use of the window.alert()window.confirm(), and window.prompt() native APIs. Each new module creates a modal that functions like its API counterpart and works in cross-origin iframes.

Unlike the window.*() APIs, these modules’ .open() functions don’t halt execution on the page, and they each return a promise. Use async/await or .then() for any code that you want to execute after the modal closes.

These examples show how to use LightningAlertLightningConfirm, and LightningPrompt in Lightning web components. See New and Changed Aura Components for examples using Aura syntax with the lightning:alertlightning:confirm, and lightning:prompt components.

This example creates an alert modal with an error message and “OK” button. The .open() function returns a promise that resolves when the user clicks “OK.”


<!-- c/myApp.html --> <template> <lightning-button onclick={handleAlertClick} label="Open Alert Modal"> </lightning-button> </template>
// c/myApp.js
import { LightningElement } from 'lwc';
import LightningAlert from 'lightning/alert';

export default class MyApp extends LightningElement {
    async handleAlertClick() {
        await LightningAlert.open({
            message: 'this is the alert message',
            theme: 'error', // a red theme intended for error states
            label: 'Error!', // this is the header text
        });
        //Alert has been closed
    }
}

This example creates a headerless confirm modal with two buttons, “OK” and “Cancel”. The .open() function returns a promise that resolves to true when the user clicks “OK” and false when they click “Cancel.”

<!-- c/myApp.html -->
<template>
    <lightning-button onclick={handleConfirmClick} label="Open Confirm Modal">
    </lightning-button>
</template>
// c/myApp.js
import { LightningElement } from 'lwc';
import LightningConfirm from 'lightning/confirm';

export default class MyApp extends LightningElement {
    async handleConfirmClick() {
        const result = await LightningConfirm.open({
            message: 'this is the prompt message',
            variant: 'headerless',
            label: 'this is the aria-label value',
            // setting theme would have no effect
        });
        //Confirm has been closed
        //result is true if OK was clicked
        //and false if cancel was clicked
    }
}

This example creates a prompt modal with a header, message, and two buttons. If the user inputs text and clicks “OK” in the prompt, the .open() function returns a promise that resolves to the input value, but if the user clicks “Cancel” it resolves to null.

<!-- c/myApp.html -->
<template>
    <lightning-button onclick={handlePromptClick} label="Open Prompt Modal">
    </lightning-button>
</template>
// c/myApp.js
import { LightningElement } from 'lwc';
import LightningPrompt from 'lightning/prompt';

export default class MyApp extends LightningElement {
    handlePromptClick() {
        LightningPrompt.open({
            message: 'this is the prompt message',
            //theme defaults to "default"
            label: 'Please Respond', // this is the header text
            defaultValue: 'initial input value', //this is optional
        }).then((result) => {
            //Prompt has been closed
            //result is input text if OK clicked
            //and null if cancel was clicked
        });
    }
}

Salesforce Summer ’22 Release Top New Features


6. Development – Load Large Datatables Faster with Virtual Rendering

Display datatables with more than 200 rows more quickly and make them scroll more smoothly with virtual rendering. Use the render-mode and render-config attributes with the lightning-datatable component to enable virtualization for your datatable. Instead of rendering all the table rows on load, the datable renders the rows that are visible and a few rows above and below them to ensure smooth scrolling.

This example shows how to enable virtualization for lightning-datatable in Lightning web components. See New and Changed Aura Components for an example using Aura syntax with the lightning:datatable component.

In the JavaScript file of your component, create a renderConfig object with the attribute virtualize set to vertical.

import { LightningElement } from 'lwc';

export default class DataTable extends LightningElement {
    // set data
    // set columns
    renderConfig = {
        virtualize: 'vertical',
        // additional customization
    };
}

In the lightning-datatable component, set the render-config attribute to your renderConfig object. Set the component’s render-mode attribute to role-based and set the lightning-datatable component’s parent container to an explicit height.

<template>
    <div style="height: 300px;">
        <lightning-datatable
            key-field="id"
            data={data}
            columns={columns}
            render-mode="role-based"
            render-config={renderConfig}>
        </lightning-datatable>
    </div>
</template>

7. Development – Secure Apex Code with User Mode Database Operations (Beta)

Declare if Apex runs database operations in user mode or system mode. The new Database methods support an AccessLevel parameter that lets you run database operations in user mode instead of in the default system mode.

You can indicate the mode of the operation by using WITH USER_MODE or WITH SYSTEM_MODE in your SOQL query. This example specifies user mode.

List<Account> acc = [SELECT Id FROM Account WITH USER_MODE];

Database operations can specify user or system mode. This example inserts a new account in user mode.

Account acc = new Account(Name='test');
insert as user acc;

The new AccessLevel class represents the two modes in which Apex runs database operations. Use this new class to define the execution mode as user mode or system mode. Use these new overloaded methods to perform DML and query operations.

  • Database.query methods
  • Search.query methods
  • Database DML methods (insertupdateupsertmergedeleteundelete, and convertLead)

8. Development – Call Invocable Actions from Apex (Developer Preview)

Invocable.Action is a new Apex class that allows you to call invocable actions from Apex code. For the developer preview, this feature is available only in scratch orgs.

To enable this feature in your scratch org, add a reference to CallIAFromApex in the project-scratch-def.json file in your SFDX project.

{
 "orgName": "my company", "edition": "Developer",
 "features": [ "CallIAFromApex" ],
 "settings": {
   ...
 }
}

After you modify the file, reference Invocable.Action in your Apex code. This example uses the standard invocable action “chatterPost” to post a message to the current user’s feed.


Invocable.Action action = Invocable.Action.createStandardAction('chatterPost');
action.setInvocationParameter('text', 'This is a test.');
action.setInvocationParameter('type', 'User');
action.setInvocationParameter('subjectNameOrId', UserInfo.getUserId());
List<Invocable.Action.Result> results = action.invoke();
if (results.size() > 0 && results[0].isSuccess()) {
    System.debug('Created feed item with ID: ' + 
results[0].getOutputParameters().get('feedItemId'));
}

This example calls a custom invocable action named Doubler that returns a number that’s twice the input value.


Invocable.Action action = Invocable.Action.createCustomAction('apex', 'Doubler');
action.setInvocationParameter('input', 1);
List<Invocable.Action.Result> results = action.invoke();                                          
if (results.size() > 0 && results[0].isSuccess()) {
    System.debug('Result is: ' + results[0].getOutputParameters().get('output'));
}

9. Customize Cumulative Rollup Names

To tailor your forecast grid to your business, change the labels that represent cumulative rollups of forecast categories. For example, show cumulative rollups for Closed Only, Best Case, Commit, Most Likely, and Open Pipeline forecasts to reflect the way your company forecasts. Previously, label changes showed only for single-category rollups. Also, in Forecast Settings, we renamed the buttons to save and cancel your changes to Save and Cancel, respectively.

In Forecasts Settings, under Manage Forecast Rollups, click the name that you want to change (1). Edit the forecast category name, and save your changes (2). If you use multiple languages, translate cumulative rollup labels in Translation Workbench.

Salesforce Summer '22 Release Features - Manage Forecast Rollups section of Forecasts Settings showing two renamed rollups.

To change labels for single-category rollups, continue to use the object management settings for opportunities.

Metadata API supports forecast rollup setup.

10. Enable Salesforce for Slack (Beta)

Integrate Slack and Salesforce to unlock access to Slack apps, tools, and services.

To enable Salesforce for Slack, complete these steps.

  1. Confirm that each Slack user has a Salesforce permission set with the Connect Salesforce with Slack system permission.
  2. Confirm that the Slack app, tool, or service you want to use with Salesforce has been approved by a workspace admin and installed in Slack.
  3. From Setup, in the Quick Find box, enter Slack, and then select Enable Slack for Salesforce.Enable Slack for Salesforce setup screen
  4. Review the terms and conditions, and click to accept.
  5. Under Record Detail Settings, select Show object type only or Show record name.Record Detail Settings box in the Enable Slack for Saleforce window in SetupIf you’re enabling Salesforce for a tool or service, you’re done! If you’re enabling Salesforce for an app, continue with step 6.
  6. In the Slack section of Setup, select the Slack app that you want to enable.
  7. Review the terms and conditions, and click to accept.
  8. Instruct end users to open Slack, add the Slack app, and connect their Salesforce accounts.

You can find Salesforce Summer ’22 Release Notes here!


Recommend Articles

Share this article...

Please Leave a Comment

error: Content is protected !!

Discover more from DYDC

Subscribe now to keep reading and get access to the full archive.

Continue reading