X-Git-Url: https://projects.mako.cc/source/selectricity-live/blobdiff_plain/dc7d60a0de460c72d292b43616eb97a8b34741c8..c933ff40da110253bc4c474d9c79c3a4ed98721d:/app/views/election/_winner.rhtml diff --git a/app/views/election/_winner.rhtml b/app/views/election/_winner.rhtml new file mode 100644 index 0000000..531e0d2 --- /dev/null +++ b/app/views/election/_winner.rhtml @@ -0,0 +1,21 @@ +<% %> + +<% if @winners.length > 1 %> +

There were multiple winners for the election. The winners (tied) + were: + +

+ +<% else %> + + <% winner = @winners[0] %> +

The winner of the election was: + <%= @candidates_by_id[winner].name %> +

+ +<% end %> +