Simplify budget stats in voting phase
So we only show the total number of participants, and not divided by web participants and booth participants.
This commit is contained in:
@@ -6,8 +6,7 @@ class Budget::Stats
|
||||
super +
|
||||
%i[total_participants_support_phase total_participants_vote_phase
|
||||
total_budget_investments total_votes total_selected_investments
|
||||
total_unfeasible_investments total_supports headings
|
||||
total_participants_web total_participants_booths]
|
||||
total_unfeasible_investments headings]
|
||||
end
|
||||
|
||||
def participants
|
||||
@@ -24,14 +23,6 @@ class Budget::Stats
|
||||
voters.uniq.count
|
||||
end
|
||||
|
||||
def total_participants_web
|
||||
(balloters - poll_ballot_voters).uniq.compact.count
|
||||
end
|
||||
|
||||
def total_participants_booths
|
||||
poll_ballot_voters.uniq.count
|
||||
end
|
||||
|
||||
def total_participants_vote_phase
|
||||
(balloters + poll_ballot_voters).uniq.count
|
||||
end
|
||||
@@ -52,10 +43,6 @@ class Budget::Stats
|
||||
budget.investments.unfeasible.count
|
||||
end
|
||||
|
||||
def total_supports
|
||||
supports(budget).count
|
||||
end
|
||||
|
||||
def authors
|
||||
budget.investments.pluck(:author_id)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user