Total Hours:
Workload Factor:
FTE %:
function calculateFTE() {
var totalHours = parseFloat(document.getElementById(‘total-hours’).value);
var workloadFactor = parseFloat(document.getElementById(‘workload-factor’).value);
var weekDivisor = 18;
if (isNaN(totalHours) || isNaN(workloadFactor) || workloadFactor === 0) {
alert(“Please enter valid numbers. Workload Factor cannot be zero.”);
return;
}
var ftePercentage = (totalHours / workloadFactor / weekDivisor) * 100;
document.getElementById(‘fte-result’).textContent = ftePercentage.toFixed(2) + ‘%’;
}