.block .secondary-navigation %ul.wat-cf %li.first= link_to t("layout.platforms.list"), platforms_path %li= link_to t("layout.platforms.new"), new_platform_path if can? :create, Platform %li.active= link_to t("layout.platforms.show"), platform_path %li= link_to t("layout.platforms.private_users"), platform_private_users_path(@platform) .content .inner %p %b = t("activerecord.attributes.platform.name") \: = @platform.name %p %b = t("activerecord.attributes.platform.description") \: = @platform.description - if @platform.parent %p %b = t("activerecord.attributes.platform.parent") \: - if @platform.parent = link_to @platform.parent.description, platform_path(@platform.parent) %p %b = t('layout.platforms.location') \: = @platform.path %p %b = t('layout.platforms.owner') \: = link_to @platform.owner.try(:name), url_for(@platform.owner) %p %b = t('layout.platforms.visibility') \: = @platform.visibility %p %b = t('layout.platforms.platform_type') \: = @platform.platform_type %p %b = t('layout.platforms.distrib_type') \: = @platform.distrib_type .wat-cf -#= link_to image_tag("code.png", :alt => t("layout.edit")) + " " + t("layout.edit"), edit_platform_path(@platform), :class => "button" = link_to image_tag("x.png", :alt => t("layout.delete")) + " " + t("layout.delete"), platform_path(@platform), :method => "delete", :class => "button", :confirm => t("layout.platforms.confirm_delete") if can? :delete, @platform - if @platform.released? = link_to t("layout.platforms.unfreeze"), unfreeze_platform_path(@platform), :confirm => I18n.t("layout.platforms.confirm_unfreeze"), :method => :post, :class => "button" if can? :unfreeze, @platform - else = link_to t("layout.platforms.freeze"), freeze_platform_path(@platform), :confirm => I18n.t("layout.platforms.confirm_freeze"), :method => :post, :class => "button" if can? :freeze, @platform = link_to "Клонировать", clone_platform_path(@platform), :class => "button" if can? :clone, @platform = link_to t("layout.platforms.build_all"), build_all_platform_path(@platform), :confirm => I18n.t("layout.confirm"), :method => :post, :class => "button" if can? :build_all, @platform = link_to t("layout.platforms.edit"), edit_platform_path(@platform), :class => "button" if can? :edit, @platform %a{ :name => "repositories" } .block .secondary-navigation %ul.wat-cf %li.first.active= link_to t("layout.repositories.list"), platform_path(@platform) + "#repositories" %li= link_to t("layout.repositories.new"), new_platform_repository_path(@platform) if can? :create, Repository.build_stub(@platform) .content %h2.title = t("layout.repositories.list_header") .inner %table.table %tr %th.first= t("activerecord.attributes.repository.description") %th.last   - @platform.repositories.recent.each do |repository| %tr{:class => cycle("odd", "even")} %td = link_to repository.description, platform_repository_path(@platform, repository) %td.last = link_to t("layout.show"), platform_repository_path(@platform, repository) | = link_to t("layout.delete"), platform_repository_path(@platform, repository), :method => :delete, :confirm => t("layout.repositories.confirm_delete") if can? :destroy, @platform .actions-bar.wat-cf .actions %a{ :name => "producs" } .block .secondary-navigation %ul.wat-cf %li.first.active= link_to t("layout.products.list"), platform_path(@platform) + "#products" %li= link_to t("layout.products.new"), new_platform_product_path(@platform) if can? :create, Product.new(:platform_id => @platform.id) .content %h2.title = t("layout.products.list_header") .inner %table.table %tr %th.first= t("activerecord.attributes.product.name") %th.last   - @platform.products.recent.each do |product| %tr{:class => cycle("odd", "even")} %td = link_to product.name, [@platform, product] %td.last = link_to t("layout.edit"), edit_platform_product_path(@platform, product) if can? :update, product | = link_to t("layout.delete"), platform_product_path(@platform, product), :method => :delete, :confirm => t("layout.products.confirm_delete") if can? :destroy, product = (product.can_clone? ? "| #{link_to t("layout.products.clone"), clone_platform_product_path(@platform, product)}" : "").html_safe .actions-bar.wat-cf .actions - content_for :sidebar, render(:partial => 'sidebar')