Check date time occurs within Business Hours Salesforce Apex
In Salesforce Apex, we can make use of BusinessHours.isWithin() method to check whether the date time is within the business hours or not. Please check the following apex code for reference. Sample Apex Code:
Copy and paste this URL into your WordPress site to embed
Copy and paste this code into your site to embed