This repository has been archived on 2023-12-31. You can view files and clone it, but cannot push or open issues or pull requests.
meritkollen/html/assets/js/changeall.js
Felix Schulze 026618e581 upload from server
uploaded all websites as they are on the server
2019-09-17 21:20:48 +02:00

29 lines
718 B
JavaScript

$('.changeall').live('click', function(){
var grade;
var val;
if (document.getElementById('option-1').checked) {
grade = "A";
val = 20;
} else if (document.getElementById('option-2').checked) {
grade = "B";
val = 17.5;
} else if (document.getElementById('option-3').checked) {
grade = "C";
val = 15;
} else if (document.getElementById('option-4').checked) {
grade = "D";
val = 12.5;
} else if (document.getElementById('option-5').checked) {
grade = "E";
val = 10;
} else if (document.getElementById('option-6').checked) {
grade = "F";
val = 0;
}
$('form.kurser').find('div').each(function(){
$('.select-dropdown').val(grade);
$('.grade').val(val);
});
raknaUtMeritvarde();
});