diff --git a/encuesta/forms.py b/encuesta/forms.py index 6e8e81f..8cb91e7 100644 --- a/encuesta/forms.py +++ b/encuesta/forms.py @@ -8,7 +8,7 @@ class InfluenciaForm(forms.Form): tipo = forms.MultipleChoiceField(choices=TIPO_CHOICE, label='Modalidad de apoyo') - organizacion = forms.ModelMultipleChoiceField(queryset=Organizacion.objects.all(), label='Organizaciones')#, widget=forms.CheckboxSelectMultiple) + organizacion = forms.ModelMultipleChoiceField(queryset=None, label='Organizaciones')#, widget=forms.CheckboxSelectMultiple) resultado = forms.ModelMultipleChoiceField(queryset=Resultado.objects.all(), label='Resultados') periodo = forms.MultipleChoiceField(choices=CHOICE_PERIODO, label='Período') anio = forms.ChoiceField(choices=CHOICE_ANIO, label='Año') diff --git a/templates/fed/indicadores.html b/templates/fed/indicadores.html index eb44cc9..43f7531 100644 --- a/templates/fed/indicadores.html +++ b/templates/fed/indicadores.html @@ -10,7 +10,7 @@ verificar(); $("#id_tipo").change(function() { verificar(); - }); + }); $('#select_organizacion').click(function(){ $('#id_organizacion option').each(function(){ @@ -64,6 +64,9 @@ $('#id_organizacion').append($('').val(item.id).html(item.nombre_corto)); }); } + {% for o in orgs_aux %} + $('#id_organizacion option[value={{o.id}}]').attr('selected', true); + {% endfor %} }); }else{ verificar();