Thank you for your post.
After reading your post, there are still a lot of unknown factors. For instance, it is easy to search for employees with a performance score of 10 or above, as well as searching for employees with a performance of less than 10. However, how do you know which shift to assign an employee. For example, if I assigned an employee to a Night shift one day, and the next day to the Morning shift, that might be 16 straight hours of working, and I assume you don't want this to occur. What other criteria is used to put employees into a shift?
Thank you for your quick reply,
other criteria would be
limiting the hours of work to 37.5 per week
Awarding two day off after each stretch of 5 Morning or afternoon shift
Awarding one day off per each night duty and not to have tretch of 4 nighs in a row
How ever, having said that, Staff will have access to a request layout where they are able to request the shifts they want and script sholud check the requests for consistancy and fill the empty slots( where no request for shifts have been made).
I am very new to FM and tried to make script for this but so far with my limited knowledge, it appears like an impossible task unless you could point me to the correct path. Any help would be gratefully appreciated.
Thank you for the additional information.
For each week, subtract the hours requested from 37.5, and if greater, then display a message.
You'll need to determine what constitutes a stretch of 5 morning or afternoon shifts. That is, would Tuesday afternoon, Wednesday morning, Thursday morning, Friday afternoon and Saturday morning constitute 5 continuous days?
If someone works 4 nights in a row, do they get four days off? Can the person then work more days to not exceed 37.5?
The best option right now is to take it one step at a time. That is, work on the 37.5 hours until you are satisfied. Then work in the next criteria until satisfied, and continue.
Let me know if you are having difficulty with any of the scripts.