Fix a bug where ratings were allowed to be set with less than 10 votes. Fixes bug #11294
This helps fix people trying to game the system.
This commit is contained in:
parent
5153d82327
commit
d1e6f30493
5 changed files with 253 additions and 94 deletions
|
|
@ -3,6 +3,7 @@
|
|||
- fixed #11292: Search function limited to onje search?
|
||||
- fixed #11286: Workflow Instance deleted when reaching an Activity that fails to load
|
||||
- fixed #11296: listLDAPLinks op permissions problems
|
||||
- fixed #11294: Matrix - Best/Worse Rated Calculations
|
||||
|
||||
7.8.7
|
||||
- fixed #11278: Wrong test for Template::Toolkit in testEnvironment.pl
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ my $session = start(); # this line required
|
|||
|
||||
# upgrade functions go here
|
||||
deleteFieldFromEMSSubmission($session);
|
||||
tenVoteMinimumForMatrixRatings($session);
|
||||
|
||||
finish($session); # this line required
|
||||
|
||||
|
|
@ -60,6 +61,15 @@ ENDSQL
|
|||
print "DONE!\n" unless $quiet;
|
||||
}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
# Describe what our function does
|
||||
sub tenVoteMinimumForMatrixRatings {
|
||||
my $session = shift;
|
||||
print "\tRestrict Matrix Listing Statistics to those with more than 10 ratings..." unless $quiet;
|
||||
$session->db->write('update MatrixListing_ratingSummary set meanValue=0, medianValue=0 where countValue < 10');
|
||||
print "\tDONE!\n" unless $quiet;
|
||||
}
|
||||
|
||||
# -------------- DO NOT EDIT BELOW THIS LINE --------------------------------
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue