Browse Source

Add votes per candidate to votes by party table

tags/last-sinatra-version
Adrian Short 10 years ago
parent
commit
1b9b16907a
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      views/resultsdistrict.haml

+ 4
- 0
views/resultsdistrict.haml View File

@@ -95,6 +95,7 @@
%th candidates
%th.right votes
%th.right % votes
%th.right votes per candidate
- count = 0
@@ -112,9 +113,11 @@
- if @election_held
%td.right= commify(row['total_votes'])
%td.right= format_percent(row['total_votes'].to_f / @total_votes * 100)
%td.right= commify(row['total_votes'] / row['num_candidates'])
- else
%td.right —
%td.right —
%td.right —
%tr.footer
%td  
@@ -127,6 +130,7 @@
%td.right= @total_candidates
%td.right= commify(@total_votes)
%td  
%td  

- if @poll
%p


Loading…
Cancel
Save