aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2018-03-28 22:14:39 +0100
committerChristopher Baines <mail@cbaines.net>2018-04-03 21:58:55 +0100
commit42b87660df9215e81ce1c13a0cc7c1aef3f154b7 (patch)
treee9403aede63c517459d1ba7766ddf0d111201cce /app
parent94f2e9b893774ad7114316b25b868224dc1927e6 (diff)
downloadgovuk-mini-environment-admin-42b87660df9215e81ce1c13a0cc7c1aef3f154b7.tar
govuk-mini-environment-admin-42b87660df9215e81ce1c13a0cc7c1aef3f154b7.tar.gz
Improve the govuk-guix revision page
Show the store path, and the mini environments which use this revision.
Diffstat (limited to 'app')
-rw-r--r--app/views/govuk_guix/revisions/show.html.erb27
1 files changed, 27 insertions, 0 deletions
diff --git a/app/views/govuk_guix/revisions/show.html.erb b/app/views/govuk_guix/revisions/show.html.erb
index 5f2b70d..a25cd31 100644
--- a/app/views/govuk_guix/revisions/show.html.erb
+++ b/app/views/govuk_guix/revisions/show.html.erb
@@ -2,4 +2,31 @@
Back to Setup
</a>
+
<h1>Revision: <%= @revision.commit_hash %></h1>
+
+<div class="row">
+ <div class="col-md-8">
+ <h2>Store path</h2>
+ <pre><%= @revision.store_path %></pre>
+ </div>
+</div>
+
+<% if @revision.mini_environments.any? %>
+ <h2>There <%= @revision.mini_environments.count == 1 ? 'is' : 'are' %> <%= pluralize(@revision.mini_environments.count, 'mini environment') %> using this revision</h2>
+
+ <div class="row">
+ <div class="col-md-8">
+ <div class="list-group">
+ <% @revision.mini_environments.each do |mini_environment| %>
+ <a href="<%= mini_environment_path(mini_environment) %>"
+ class="list-group-item">
+ <%= mini_environment.name %>
+ </a>
+ <% end %>
+ </div>
+ </div>
+ </div>
+<% else %>
+ <h2>There are no mini environments using this revision</h2>
+<% end %>