Context:
The Service Agreement Balance Check is only checking the Service Delivery Record (SDR) and not the Job Service Item so it is only look at the remaining budget after the actual amount spent is removed and not the amount allocated to scheduled jobs. This means that the service agreement amount is often exceeded.
Solution:
We will run the Balance Check in 2 parts
1. The normal balance check which checks the SDR and respects the over claim settings on the Service Agreement. If this check shows that there will be an overclaim if they proceed then the user should either schedule non or only the covered jobs
2. Run a daily batch to check for the Balance for all the future jobs/services created against the Service Agreements and send email to a public group for the balance check result (just like balance check when replicating jobs from Resource Roster Console).
The balance check batch was set up to run with the Healthcare Daily Scheduler job. You can enable/disable the batch via the custom setting Enable_Balance_Check_Batch in Skedulo Configs.
The scheduled job "Healthcare Daily Scheduler" will run healthcare daily tasks. The custom setting SCHEDULED_JOB_CRON_EXPRESSION determines the time the "Healthcare Daily Scheduler" job is triggered. When the job is triggered, all its tasks will be run. Currently, we have 3 tasks that have been added to the Healthcare Daily Scheduler and they can be enabled/disabled via custom settings:
-
auto timesheet creation:
skedConfigs.AUTO_TIMESHEET_CREATION
-
current hours calculation:
skedSCConstants.ENABLE_CURRENT_HOURS_CALCULATION
-
balance check:
skedConfigs.ENABLE_BALANCE_CHECK_BATCH
You can check the scheduler job run time in Setup → Scheduled Jobs:
You can setup the recipients and the schedule job’s start time in custom setting Skedulo Configs:
recipients: skedConfigs.ROSTER_REPLICATION_NOTIFICATION_GROUP_NAME
We don't create this setting by default. You can create it and put the group name that will receive the notification.
start time: skedConfigs.SCHEDULED_JOB_CRON_EXPRESSION
For testing purpose, you can execute the batch manually with these steps:
1. Give the custom setting Enable_Balance_Check_Batch value is set to true.
2. Execute the apex code below to run the balance check batch in Developer Console:
skedHCJobManager.instance.register(skedHCJobManager.CHECK_BALANCE, '');
3. Check the result email
How to access the setting:
1. Go to "Setup"
2. In the search box, input "Custom Settings"
3. Find the "Skedulo Configs" setting
4. Find the "Enable_Balance_Check_Batch" setting
Description:
Enable daily balance check batch
Value:
- true: enable and check balance on client available budget
- false: disable and check balance on client available budget
Comments
0 comments
Please sign in to leave a comment.