--- a/OSSEval/analysis/forms.py
+++ b/OSSEval/analysis/forms.py
@@ -19,18 +19,16 @@
class AnalysisForm(ModelForm):
def __init__(self, data=None, *args, **kwargs):
super(AnalysisForm, self).__init__(data, *args, **kwargs)
- if 'instance' in kwargs.keys():
- self._meta.widgets['methodology_version'] = HiddenInput() ###NON FUNZIONA!!!
+
class Meta:
model = Analysis
# fields = '__all__' #('name', 'description', 'comment', 'weight_scenario')
- fields = ('id', 'name', 'description', 'comment', 'created', 'user_login', 'methodology_version', 'weight_scenario')
+ fields = ('id', 'name', 'description', 'comment', 'created', 'user_login', 'methodology_version')
widgets = {
'description': Textarea(attrs={'cols': 80, 'rows': 5}),
'comment': Textarea(attrs={'cols': 80, 'rows': 5}),
- 'id': HiddenInput(),
- 'weight_scenario': HiddenInput()
+ 'id': HiddenInput()
}
class UploadFileForm(forms.Form):