Modules
Class 16: Complex Estimated Commission using Advanced Formula Builder
Transcript
Hey, team. What's going on?
So a couple of you have been asking, how do we build an estimated commission field or a similar functionality using the new, custom formula builder or advanced formula builder. How do you access the property? It's same as you create any calculated property. So on any object.
So basically, you can go on select the calculation property type. And then once you have enabled this beta, wait, you know, one or two minutes to get this, you know, reflected in your account refreshed. So you'll get this advanced mode and you can start building your, formula field. So let's go to our actual formula.
So we are using nested if functionality.
The aim here is so if, the deal amount is a hundred k or above than that, then we are going to assign, the estimated commission to that particular dealer as ten percent, which is huge, but it's just an example. So, no one is harmed, like, no business is harmed in making of this field.
But, if it's, like, between fifty k and hundred k, the commission will be five percent. And if it's, like, less than that, then it's gonna be two percent. So let's check. So my math is, like, super bad, but I'll, do my best.
So I have entered the amount sixty k. The commission is calculated at five percent. I believe I hope that is correct. If it's not, blame my math and not the, custom property.
Let's try to reduce it, to, you know, less than fifty k threshold. So let's do, four thousand and it should or let's do easier one. So it should generate a two percent of the commission. So one thousand yeah.
Twenty two. Twenty percent. So that's correct. My formula is working. My math is like not so bad.
It's bad, but fine. Let's increase it by a hundred k. And, I've used the logic greater than, so I'll have to, you know, add at least one here. So, you you should use greater than or equal to.
So one hundred k greater than hundred k's. Okay. Let's do a refresh. Yeah. Now we are talking ten percent commission.
So this is, how you build it. Feel free to use this code, like, not the exact formula, but take inspiration from this one. Build all those nested ifs and see what you can, you know, unleash with this. This is like really powerful if you are smart about