aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2018-07-04 13:33:09 +0100
committerChristopher Baines <mail@cbaines.net>2018-07-04 13:33:09 +0100
commit399c87bcad5016882b2918fe2d46f4edee6250a0 (patch)
treec66d7dd4a25aef32c9997b3145ca43f3a26d87da
parent004b035f0c2fbde3285eea46b61603d96ecacd9c (diff)
downloadgovuk-mini-environment-admin-399c87bcad5016882b2918fe2d46f4edee6250a0.tar
govuk-mini-environment-admin-399c87bcad5016882b2918fe2d46f4edee6250a0.tar.gz
Disable the Refresh button if there is no state to refresh
-rw-r--r--app/views/mini_environments/show.html.erb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/views/mini_environments/show.html.erb b/app/views/mini_environments/show.html.erb
index 0184749..203fb62 100644
--- a/app/views/mini_environments/show.html.erb
+++ b/app/views/mini_environments/show.html.erb
@@ -95,6 +95,7 @@ License along with the GOV.UK Mini Environment Admin. If not, see
<% end %>
<li class="list-group-item">
<%= submit_tag('Refresh',
+ disabled: @mini_environment.terraform_states.empty?,
role: 'button',
class: 'btn btn-lg btn-info btn-block')
%>