diff --git a/scipost/forms.py b/scipost/forms.py index b575736f8712dbcbc19282af42d79931a17c5aa8..388ab3878f8ee3b8cb36b5c4ed7207bba4b02009 100644 --- a/scipost/forms.py +++ b/scipost/forms.py @@ -98,7 +98,7 @@ class AuthorshipClaimForm(forms.Form): # opinion = forms.ChoiceField(choices=OPINION_CHOICES, label='Your opinion on this Comment: ') -class AssessmentForm(forms.ModelForm): - class Meta: - model = Assessment - fields = ['relevance', 'importance', 'clarity', 'validity', 'rigour', 'originality', 'significance'] +#class AssessmentForm(forms.ModelForm): +# class Meta: +# model = Assessment +# fields = ['relevance', 'importance', 'clarity', 'validity', 'rigour', 'originality', 'significance'] diff --git a/scipost/models.py b/scipost/models.py index 7144644b068d1e17d7ca9149e71193158270c253..144c6032d9211d76c7b7afbcbb01f94d74981e43 100644 --- a/scipost/models.py +++ b/scipost/models.py @@ -147,25 +147,25 @@ class AuthorshipClaim(models.Model): ### Assessments -ASSESSMENT_CHOICES = ( - (101, '-'), # Only values between 0 and 100 are kept, anything outside those limits is discarded. - (100, 'top'), (80, 'high'), (60, 'good'), (40, 'ok'), (20, 'low'), (0, 'poor') - ) - -class Assessment(models.Model): - """ - Base class for all assessments. - """ - rater = models.ForeignKey(Contributor) - submission = models.ForeignKey('submissions.Submission', blank=True, null=True) - comment = models.ForeignKey('comments.Comment', blank=True, null=True) - relevance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - importance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - clarity = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - validity = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - rigour = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - originality = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) - significance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +#ASSESSMENT_CHOICES = ( +# (101, '-'), # Only values between 0 and 100 are kept, anything outside those limits is discarded. +# (100, 'top'), (80, 'high'), (60, 'good'), (40, 'ok'), (20, 'low'), (0, 'poor') +# ) + +#class Assessment(models.Model): +# """ +# Base class for all assessments. +# """ +# rater = models.ForeignKey(Contributor) +# submission = models.ForeignKey('submissions.Submission', blank=True, null=True) +# comment = models.ForeignKey('comments.Comment', blank=True, null=True) +# relevance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# importance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# clarity = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# validity = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# rigour = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# originality = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) +# significance = models.PositiveSmallIntegerField(choices=ASSESSMENT_CHOICES, default=101) ### Opinions @@ -186,23 +186,23 @@ class Assessment(models.Model): ### AssessmentAggregates -class AssessmentAggregate(models.Model): - """ - Aggregated assessments for an object. - """ - nr = models.PositiveSmallIntegerField(default=0) - nr_relevance_ratings = models.IntegerField(default=0) - relevance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_importance_ratings = models.IntegerField(default=0) - importance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_clarity_ratings = models.IntegerField(default=0) - clarity_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_validity_ratings = models.IntegerField(default=0) - validity_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_rigour_ratings = models.IntegerField(default=0) - rigour_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_originality_ratings = models.IntegerField(default=0) - originality_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) - nr_significance_ratings = models.IntegerField(default=0) - significance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +#class AssessmentAggregate(models.Model): +# """ +# Aggregated assessments for an object. +# """ +# nr = models.PositiveSmallIntegerField(default=0) +# nr_relevance_ratings = models.IntegerField(default=0) +# relevance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_importance_ratings = models.IntegerField(default=0) +# importance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_clarity_ratings = models.IntegerField(default=0) +# clarity_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_validity_ratings = models.IntegerField(default=0) +# validity_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_rigour_ratings = models.IntegerField(default=0) +# rigour_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_originality_ratings = models.IntegerField(default=0) +# originality_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0) +# nr_significance_ratings = models.IntegerField(default=0) +# significance_rating = models.DecimalField(default=0, max_digits=3, decimal_places=0)