\ No newline at end of file
--
cgit v1.2.3-2-g168b
From dc417a48ec2abc83a3ffad742c3c4a4207054300 Mon Sep 17 00:00:00 2001
From: guntasgrewal
Date: Sun, 6 Apr 2014 20:03:32 -0400
Subject: Dragging to Rank
---
app/views/matches/show.html.erb | 36 ++++++++++++------------------------
1 file changed, 12 insertions(+), 24 deletions(-)
(limited to 'app/views/matches')
diff --git a/app/views/matches/show.html.erb b/app/views/matches/show.html.erb
index 6fb4042..ffa7682 100644
--- a/app/views/matches/show.html.erb
+++ b/app/views/matches/show.html.erb
@@ -2,7 +2,6 @@
Status:
<%= @match.status %>
-
Tournament:
<%= @match.tournament.id %>
@@ -27,49 +26,38 @@
Note:- The change of status from 1 to 2 is coming from League Data Pull (RIOT API)
-->
-
-<% if (@tournament.hosts.include?(current_user) and @match.winner.nil?) %>
- <%= form_for([@tournament, @match], method: "put") do |f| %>
-
- <% @match.teams.each do |team| %>
-
- <% end %>
-
- <%= f.submit("Select Winner") %>
- <% end %>
-<% end %>
-<% if (@match.status==0) %>
+<% if (@match.status==1) %>
<% if (@tournament.players.include?(current_user) || @tournament.hosts.include?(current_user)) %>
<% @match.teams.each do |team| %>
-
+
<% team.users.collect{|u| u.user_name}.each do |k| %>
-
+
<%= k %>
<% end %>
-
+
<% end %>
<% end %>
<% end %>
<% if (@match.status==0) %>
- <% if (@tournament.players.include?(current_user) %>
+ <% if (@tournament.players.include?(current_user)) %>
<% @match.teams.each do |team| %>
-
+
<% team.users.collect{|u| u.user_name}.each do |k| %>
-
+
<%= k %>
<% end %>
-
- <% end %>
+
+ <% end %>
+ <% elsif (@tournament.hosts.include?(current_user)) %>
+
<% end %>
<% end %>
--
cgit v1.2.3-2-g168b
From 0f982ba511d4f38322f69a6aaed768181b4e2852 Mon Sep 17 00:00:00 2001
From: tkimia
Date: Sun, 6 Apr 2014 21:10:46 -0400
Subject: some more graphics
---
app/views/matches/index.html.erb | 80 +++++++++++++++++++++++-----------------
1 file changed, 46 insertions(+), 34 deletions(-)
(limited to 'app/views/matches')
diff --git a/app/views/matches/index.html.erb b/app/views/matches/index.html.erb
index 031b2a9..6fd831f 100644
--- a/app/views/matches/index.html.erb
+++ b/app/views/matches/index.html.erb
@@ -27,38 +27,50 @@
-
\ No newline at end of file
+
--
cgit v1.2.3-2-g168b
From dd46c4b23640b0719e16e874b8f593e159b54a3c Mon Sep 17 00:00:00 2001
From: guntasgrewal
Date: Sun, 6 Apr 2014 22:04:51 -0400
Subject: small changes
---
app/views/matches/show.html.erb | 1 +
1 file changed, 1 insertion(+)
(limited to 'app/views/matches')
diff --git a/app/views/matches/show.html.erb b/app/views/matches/show.html.erb
index ffa7682..25be7b8 100644
--- a/app/views/matches/show.html.erb
+++ b/app/views/matches/show.html.erb
@@ -55,6 +55,7 @@
<%# If user is the host, let them start the tournment %>
+ <% if @tournament.hosts.include?(current_user) %>
+
+ <%= form_tag(tournament_match_path(@tournament, match), method: "put") do %>
+
+ <%= submit_tag("Start Match") %>
+ <% end %>
+ <% end %>
+