---
src/app/views/images/show.html.haml | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/src/app/views/images/show.html.haml b/src/app/views/images/show.html.haml
index 802a994..82bb693 100644
--- a/src/app/views/images/show.html.haml
+++ b/src/app/views/images/show.html.haml
@@ -6,7 +6,8 @@
= link_to t('images.index.images'), images_path
.button-group
= button_to t("delete"), image_path((a)image.id), :method =>
'delete', :confirm => "Are you sure you want to delete?", :class
=> 'button danger', :id => 'delete'
- = link_to t('.new_deployable_from_image'),
new_deployable_path(:create_from_image => @image.id)
+ - unless @image.imported?
+ = link_to t('.new_deployable_from_image'),
new_deployable_path(:create_from_image => @image.id)
%section.admin-content-section
%header
@@ -16,7 +17,8 @@
= form_tag image_path((a)image.id), :method => :get do
= select_tag :build, options_for_build_select(@builds, @build, @latest_build)
= submit_tag t('.select_build'), :id =>
'seletect_build_button'
- = button_to t('.rebuild_all'), rebuild_all_image_path((a)image.id)
+ - unless @image.imported?
+ = button_to t('.rebuild_all'), rebuild_all_image_path((a)image.id)
.content
%dl.image_builds
- @account_groups.each do |driver, group|
@@ -28,7 +30,7 @@
= label_tag b.status
- elsif timg
= button_to t('.delete'), image_target_image_path((a)image.id,
timg.id), :method => :delete
- - elsif @build and @build.id == @latest_build
+ - elsif @build and @build.id == @latest_build && !(a)image.imported?
= button_to t('.build'), image_target_images_path((a)image.id, :target
=> driver, :build_id => @build ? @build.id : nil), :method => :post
- else
@@ -57,7 +59,7 @@
%td
- if timg and b = @builder.find_active_push(timg.id,
account.provider.name, account.warehouse_id)
= label_tag b.status
- - elsif timg and not pimg and @build and @build.id ==
@latest_build
+ - elsif timg and not pimg and @build and @build.id == @latest_build
&& !(a)image.imported?
= button_to t('.upload'),
image_provider_images_path((a)image.id, :build_id => @build.id, :target_image_id =>
timg.id, :account_id => account.id), :method => :post
- elsif pimg
= button_to t('delete'),
image_provider_image_path((a)image.id, pimg.id), :method => :delete
--
1.7.6.4