selects

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
% block my_js %}
<script type="text/javascript">
$(document).ready(function(){
var $director = $("#director-select");
var $people = $("#people-select");
var $is_stageur = $("#is-stageur-select");
$director.click(function(){
var e = document.getElementById("director-select");
var strUser = e.options[e.selectedIndex].value;
});
$director.change(function(){
var val = $(this).val();
window.location.href = "" + val;
});
$people.click(function(){
var e2 = document.getElementById("people-select");
var strUser2 = e2.options[e2.selectedIndex].value;
});
$people.change(function(){
var val2 = $(this).val();
window.location.href = "" + val2;
});
$is_stageur.click(function(){
var e3 = document.getElementById("is-stageur-select");
var strUser3 = e3.options[e3.selectedIndex].value;
});
$is_stageur.change(function(){
var val3 = $(this).val();
window.location.href = val3;
});
});
</script>
{% endblock my_js %}