Home
last modified time | relevance | path

Searched refs:upvotes (Results 1 – 5 of 5) sorted by relevance

/web-php/src/UserNotes/
H A DSorter.php52 return ($note->upvotes - $note->downvotes - $this->minVote) * $this->voteFactor + .3;
56 return $note->upvotes + $note->downvotes <= 2 ? 0.5 : $this->calcRating($note);
60 $totalVotes = $note->upvotes + $note->downvotes;
61 return $totalVotes > 0 ? $note->upvotes / $totalVotes : .5;
87 $this->minVote = $this->maxVote = ($first->upvotes - $first->downvotes);
91 $this->maxVote = max($this->maxVote, ($note->upvotes - $note->downvotes));
92 $this->minVote = min($this->minVote, ($note->upvotes - $note->downvotes));
H A DUserNote.php14 public int $upvotes = 0, argument
/web-php/tests/Unit/UserNotes/
H A DSorterTest.php406 'upvotes' => $note->upvotes,
/web-php/manual/
H A Dvote-note.php61 $N[$_REQUEST['id']]->upvotes++;
/web-php/include/
H A Dshared-manual.inc137 $vote = $note->upvotes - $note->downvotes;
138 $p = floor(($note->upvotes / (($note->upvotes + $note->downvotes) ?: 1)) * 100);
139 $rate = !$p && !($note->upvotes + $note->downvotes) ? "no votes..." : "$p% like this...";

Completed in 8 milliseconds