From 01d867a8ab1a9e116556ae5d9303d8f2d3579723 Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Tue, 13 Nov 2012 16:02:51 +0100 Subject: [PATCH] Implement domain filter in attribution interface --- templates/attribution.html | 38 ++++++++++++++++++++++++++++++++------ 1 file changed, 32 insertions(+), 6 deletions(-) diff --git a/templates/attribution.html b/templates/attribution.html index 0072161..aee253a 100644 --- a/templates/attribution.html +++ b/templates/attribution.html @@ -12,7 +12,7 @@ select#student_select, select#student_filter { width: 100%; } div#corp_choice { float: right; width: 18%; } - select#corp_select { width: 100%; } + select#corp_select, select#corp_filter { width: 100%; } div#student_detail { float:left; width: 40%; margin: 1em; padding: 0.5em; border: 3px solid red; min-height: 4em; border-radius: 8px; } div#corp_detail { float:right; width: 40%; margin: 1em; padding: 0.5em; border: 3px solid red; min-height: 4em; border-radius: 8px; } @@ -42,6 +42,7 @@ function update_periods(section_id) { } update_students(''); update_corporations(''); + update_trainings(''); }); } @@ -62,7 +63,7 @@ function update_students(period_id) { $('#student_select').empty(); $('#student_detail').html('').removeClass("filled"); current_student = null; - $('input#valid_training').hide() + $('input#valid_training').hide(); if (period_id == '') return; $.getJSON('/period/' + period_id + '/students/', function(data) { var sel = $('#student_select'); @@ -70,7 +71,7 @@ function update_students(period_id) { $.each(data, function() { if (this.training_id == null) { options.push(this); - sel.append($("