TryTo do the comparison against the current date, you need to use the @now
. Also, you need to calculate a date 5 days back from today. So, you need to subtract 5 days worth of milliseconds, (5 * 24 * 60 * 60 * 1000 = 432000000
).
So, try using below JSON code:
{
"schema": "https://developer.microsoft.com/json-schemas/sp/view-formatting.schema.json",
"additionalRowClass": "=if([$ApprovalStatus] == 'Pending' && [$RequestDate] < @now-432000000, 'sp-field-severity--severeWarning', '')"
}
References: