Salesforce Admin Tutorial: How to create Confetti Celebrations and use the Trailshread Audio Player

Why would we create Celebrations or use the Trailshred Audio Player at all?

To be honest idk dawg, maybe just to spice up your life a little bit and have some fun? You could make a super sweet easter egg for your Salesforce org. Maybe you wanna boost your Sales teams morale with something interesting and unexpected? No matter how you slice this banana bread chocolate chip pancake it all boils down to choosing to do something that’s a little fun for the people around you and sometimes that’s the best thing you could build. Everybody gets tired of being a serious fanci boi all day. Take a stroll down having a little fun lane for once my guy.


How to setup Confetti Celebrations using Paths

To be honest, this is super easy. If you’ve never heard of paths, you can check out some sweet info here. Basically you just do the following:

1) Go to Setup -> Path Settings and click the “New Path” button

Path Settings

2) After clicking the “New Path” button follow the steps and fill out the fields as requested, until you get to Step 3.

3) On step 3 of the Path setup there will be an area called “Enable Celebrations”. Enable them. Then pick what triggers the confetti celebrations and how often the celebrations happen.

4) Congrats, you did it!


How to use the Trailshred Audio Player to play some ultra lit audio for your Sales Broz

And now we get to the guuuuuuddddddddddddd stuff. Salesforce has created a relatively simple and lightweight unmanaged package called the Trailshred Audio Player to allow you to play audio you upload to static resources by playing an LWC on lightning record pages. Let’s check out how to use this thing.

1) Install the unmanaged package here: https://login.salesforce.com/packagingSetupUI/ipLanding.app?apvId=04t1U000007sa55QAA

2) After the Trailshred Audio Player has been installed in your org, create and upload any audio file as a static resource (the audio must be less than 5mb and be an mp3 or wav file).

3) Copy the name of the static resource you just created.


4) Go to Setup -> Custom Metadata Types -> Trailshred Settings -> Manage Records

5) Create a new Trailshred Settings record and place the name of your static resource audio file in the “Audio Static Resource Path” field, then pick the Object you want the audio to run on, pick the field you want the audio to trigger on and the value for that field it should trigger on.

6) That’s it playur, you did it! On to the next section!


Setting up the Lightning App Record Page to Play the Celebration

Alright alright alright, we’re almost there, this is the last step and it’s super easy. You gotta create a lightning record page app. Let’s check out how to get it done son.

1) Go to Setup -> Lightning App Builder and click the “New” button to create a new lightning app record page (or choose to update an existing one).

2) Search for the “Path” component on the lightning app builder page and place it on the page. This will add your confetti celebration.

3) Search for the “Trailshred Audio Player” in the component search in the lightning app builder and place it at the bottom of the page. This component is invisible (because it just plays audio) so after placing it you should just see it represented by an empty space.

4) Save and Activate your lightning app record page.

5) That’s it! You did it homie! You finally had some fun!

That’s it guys, hopefully you had a little fun building it and someone gets a good laugh out of whatever you built!

Get Coding With The Force Merch!!

We now have a redbubble store setup so you can buy cool Coding With The Force merchandise! Please check it out! Every purchase goes to supporting the blog and YouTube channel.

Get Shirts Here!
Get Cups, Artwork, Coffee Cups, Bags, Masks and more here!

Check Out More Coding With The Force Stuff!

If you liked this post make sure to follow us on all our social media outlets to stay as up to date as possible with everything!

Youtube
Patreon
Github
Facebook
Twitter
Instagram


Salesforce Development Books I Recommend

Advanced Apex Programming
Salesforce Lightning Platform Enterprise Architecture
Mastering Salesforce DevOps

Good Non-SF Specific Development Books:

Clean Code
Clean Architecture

Salesforce Admin Tutorial: How to Create Unique Person Account Search Layouts using formula fields

https://youtu.be/bISt9GpFzH4

Why would you want to make unique person account search layouts?

If you’re reading this, chances are you already know the answer to this, but just in case, let’s go over why you would want/need to do this.

If you didn’t know, person account search layouts are determined by the account object and that’s because person accounts are just a mash up of a contact and an account record. Every time you create a person account you are creating 1 contact record and 1 account record.

Due to the fact that the search layout is controlled by the account object, you will likely run into the following problem eventually: A group of users needs to see both person accounts and business accounts. That group of users will also get very frustrated that when searching for accounts it’s not always clear which one is a person account and which is a business account. They will also get frustrated that there are a bunch of useless fields for either the business or person accounts in their search layouts.

So how do we fix this issue?? Formula fields!! Woot!


Formula Fields to the Rescue

Thankfully, in the background, Salesforce has a field called IsPersonAccount on the Account object that is a checkbox. This checkbox allows us to know whether an account is a person account or not a person account. It also comes in great handy in search layouts and formula fields (as well as code, but we’re not gonna cover that today).

So basically what we need to do is create formula fields for our search layouts that render one field for business accounts and another field for person accounts and then put those formula fields in the search layout that the users are assigned who have access to both person and business accounts.

Let me show you an example formula for a search layout field:

IF(IsPersonAccount, PersonContact.MailingStreet, BillingStreet)

What the formula above is doing is doing is the following. If the account is a person account, show the person account mailing street. If the account is not a person account, show the billing street.

If you just follow that example above you can make the search layout fields render whatever you need them too. It’s not perfect, but it’s as close as we can get today. You then just add these formula fields to the search layout for your users and they dynamically render the correct information for the different account types.

I would also suggest adding the IsPersonAccount field to the search layout as well. It allows users to easily Id if an account is a person account or a business account.


Get Coding With The Force Merch!!

We now have a redbubble store setup so you can buy cool Coding With The Force merchandise! Please check it out! Every purchase goes to supporting the blog and YouTube channel.

Get Shirts Here!
Get Cups, Artwork, Coffee Cups, Bags, Masks and more here!


Check Out More Coding With The Force Stuff!

If you liked this post make sure to follow us on all our social media outlets to stay as up to date as possible with everything!

Youtube
Patreon
Github
Facebook
Twitter
Instagram


Salesforce Development Books I Recommend

Advanced Apex Programming
Salesforce Lightning Platform Enterprise Architecture
Mastering Salesforce DevOps

Good Non-SF Specific Development Books:

Clean Code
Clean Architecture