[PATCH conductor] Redmine3153 partials cleanup and fixes part1
Jan Provaznik
jprovazn at redhat.com
Wed May 9 11:58:54 UTC 2012
On 05/09/2012 01:56 PM, jtomasek at redhat.com wrote:
> From: Jiri Tomasek<jtomasek at redhat.com>
>
> catalogs partials cleanup
>
> config_servers partials cleanup
>
> added specific form_header and filter_controls as options to filter_table helper in provider account detail page
>
> fixed filters in provider account and catalog details pages
>
> deployables partials cleanup
>
> deployments partials cleanup
>
> removed unused deployments partials
>
> hardware profiles cleanup
>
> removed unused hwp partials
>
> fixed instances index view
>
> deployments pretty view fix
>
> instances views and partials cleanup
>
> removed unused layout partials
> ---
> src/app/controllers/application_controller.rb | 2 +-
> src/app/controllers/catalogs_controller.rb | 5 +-
> src/app/controllers/deployables_controller.rb | 2 +-
> src/app/controllers/deployments_controller.rb | 12 +-
> src/app/controllers/instances_controller.rb | 5 +
> .../controllers/provider_accounts_controller.rb | 4 +-
> src/app/helpers/application_helper.rb | 3 -
> src/app/stylesheets/layout.scss | 14 ++-
> src/app/views/catalogs/_properties.html.haml | 12 ---
> src/app/views/catalogs/_section_header.html.haml | 4 -
> src/app/views/catalogs/edit.html.haml | 5 +-
> src/app/views/catalogs/new.html.haml | 4 -
> src/app/views/catalogs/show.html.haml | 14 +++-
> .../views/config_servers/_config_server_form.haml | 2 +-
> src/app/views/config_servers/_page_header.haml | 2 +
> src/app/views/config_servers/_section_header.haml | 2 -
> src/app/views/config_servers/edit.haml | 2 +-
> src/app/views/config_servers/new.haml | 2 +-
> src/app/views/deployables/_new.html.haml | 7 +-
> .../views/deployables/_section_header.html.haml | 5 -
> src/app/views/deployables/index.html.haml | 8 ++-
> src/app/views/deployables/show.html.haml | 1 -
> src/app/views/deployments/_alerts_show.html.haml | 2 +-
> src/app/views/deployments/_deployment.html.haml | 9 --
> src/app/views/deployments/_edit.html.haml | 27 +++--
> src/app/views/deployments/_header_show.html.haml | 5 -
> src/app/views/deployments/_history.html.haml | 6 -
> src/app/views/deployments/_list.html.haml | 2 +-
> src/app/views/deployments/_operation.html.haml | 5 -
> src/app/views/deployments/_permissions.html.haml | 1 -
> src/app/views/deployments/_properties.html.haml | 6 +-
> .../views/deployments/_provider_services.html.haml | 1 -
> .../views/deployments/_required_services.html.haml | 1 -
> src/app/views/deployments/index.html.haml | 5 +-
> src/app/views/deployments/show.html.haml | 16 +++-
> src/app/views/hardware_profiles/_form.html.haml | 5 +-
> src/app/views/hardware_profiles/_history.html.haml | 1 -
> .../_matching_provider_hardware_profiles.html.haml | 72 +++++++-------
> .../views/hardware_profiles/_properties.html.haml | 14 ---
> .../hardware_profiles/_section_header.html.haml | 4 -
> src/app/views/hardware_profiles/create.html.haml | 6 -
> src/app/views/hardware_profiles/edit.html.haml | 4 +-
> src/app/views/hardware_profiles/new.html.haml | 6 +-
> src/app/views/hardware_profiles/show.html.haml | 21 +++-
> .../instances/_can_perform_state_change.xml.haml | 7 --
> src/app/views/instances/_edit.html.haml | 26 +++--
> src/app/views/instances/_permissions.html.haml | 3 -
> src/app/views/instances/_properties.html.haml | 103 ++++++++++----------
> src/app/views/instances/index.html.haml | 5 +-
> src/app/views/instances/new.html.haml | 2 -
> src/app/views/instances/show.html.haml | 4 +
> .../views/layouts/_admin_content_tabs.html.haml | 3 +-
> src/app/views/layouts/_footer.html.haml | 5 -
> src/app/views/layouts/_header.html.haml | 20 ----
> src/app/views/layouts/_masthead.html.haml | 17 ---
> src/app/views/layouts/_notification.rhtml | 34 -------
> src/app/views/layouts/old_application.html.haml | 64 ------------
> src/app/views/permissions/_permissions.html.haml | 7 +-
> src/config/locales/en.yml | 34 +++---
> src/features/catalogs.feature | 2 +-
> src/features/deployment.feature | 1 -
> 61 files changed, 256 insertions(+), 417 deletions(-)
> delete mode 100644 src/app/views/catalogs/_properties.html.haml
> delete mode 100644 src/app/views/catalogs/_section_header.html.haml
> create mode 100644 src/app/views/config_servers/_page_header.haml
> delete mode 100644 src/app/views/config_servers/_section_header.haml
> delete mode 100644 src/app/views/deployables/_section_header.html.haml
> delete mode 100644 src/app/views/deployments/_deployment.html.haml
> delete mode 100644 src/app/views/deployments/_header_show.html.haml
> delete mode 100644 src/app/views/deployments/_history.html.haml
> delete mode 100644 src/app/views/deployments/_operation.html.haml
> delete mode 100644 src/app/views/deployments/_permissions.html.haml
> delete mode 100644 src/app/views/deployments/_provider_services.html.haml
> delete mode 100644 src/app/views/deployments/_required_services.html.haml
> delete mode 100644 src/app/views/hardware_profiles/_history.html.haml
> delete mode 100644 src/app/views/hardware_profiles/_properties.html.haml
> delete mode 100644 src/app/views/hardware_profiles/_section_header.html.haml
> delete mode 100644 src/app/views/hardware_profiles/create.html.haml
> delete mode 100644 src/app/views/instances/_can_perform_state_change.xml.haml
> delete mode 100644 src/app/views/instances/_permissions.html.haml
> delete mode 100644 src/app/views/instances/new.html.haml
> delete mode 100644 src/app/views/layouts/_footer.html.haml
> delete mode 100644 src/app/views/layouts/_header.html.haml
> delete mode 100644 src/app/views/layouts/_masthead.html.haml
> delete mode 100644 src/app/views/layouts/_notification.rhtml
> delete mode 100644 src/app/views/layouts/old_application.html.haml
>
> diff --git a/src/app/controllers/application_controller.rb b/src/app/controllers/application_controller.rb
> index 1a68b94..a277262 100644
> --- a/src/app/controllers/application_controller.rb
> +++ b/src/app/controllers/application_controller.rb
> @@ -314,7 +314,7 @@ class ApplicationController< ActionController::Base
> @roles = Role.find_all_by_scope(@permission_object.class.name)
> if @tabs
> @tabs<< {:name => t('role_assignments'),
> - :view => 'permissions',
> + :view => 'permissions/permissions',
> :id => 'permissions',
> :count => perm_obj.permissions.count,
> :pretty_view_toggle => 'disabled'}
> diff --git a/src/app/controllers/catalogs_controller.rb b/src/app/controllers/catalogs_controller.rb
> index 1a7167d..270546d 100644
> --- a/src/app/controllers/catalogs_controller.rb
> +++ b/src/app/controllers/catalogs_controller.rb
> @@ -41,7 +41,10 @@ class CatalogsController< ApplicationController
> def show
> @catalog = Catalog.find(params[:id])
> @title = @catalog.name
> - @deployables = @catalog.deployables.list_for_user(current_user, Privilege::VIEW).apply_filters(:preset_filter_id => params[:catalog_entries_preset_filter], :search_filter => params[:catalog_entries_search])
> + @deployables = @catalog.deployables.
> + list_for_user(current_user, Privilege::VIEW).
> + apply_filters(:preset_filter_id => params[:deployables_preset_filter],
> + :search_filter => params[:deployables_search])
> require_privilege(Privilege::VIEW, @catalog)
> save_breadcrumb(catalog_path(@catalog), @catalog.name)
> @header = [
> diff --git a/src/app/controllers/deployables_controller.rb b/src/app/controllers/deployables_controller.rb
> index 911e337..890847f 100644
> --- a/src/app/controllers/deployables_controller.rb
> +++ b/src/app/controllers/deployables_controller.rb
> @@ -251,7 +251,7 @@ class DeployablesController< ApplicationController
> end
>
> def filter
> - redirect_to_original({"catalog_entries_preset_filter" => params[:catalog_entries_preset_filter], "catalog_entries_search" => params[:catalog_entries_search]})
> + redirect_to_original({"deployables_preset_filter" => params[:deployables_preset_filter], "deployables_search" => params[:deployables_search]})
> end
>
> private
> diff --git a/src/app/controllers/deployments_controller.rb b/src/app/controllers/deployments_controller.rb
> index 3cdc9c6..4d34501 100644
> --- a/src/app/controllers/deployments_controller.rb
> +++ b/src/app/controllers/deployments_controller.rb
> @@ -29,6 +29,7 @@ class DeploymentsController< ApplicationController
>
> def index
> save_breadcrumb(deployments_path(:viewstate => viewstate_id))
> + @title = t 'deployments.deployments'
> respond_to do |format|
> format.html
> format.js { render :partial => 'list' }
> @@ -187,20 +188,19 @@ class DeploymentsController< ApplicationController
> if filter_view?
> @view = 'instances/list'
> params[:instances_preset_filter] = "" unless params[:instances_preset_filter]
> - @instances = paginate_collection(Instance.apply_filters(:preset_filter_id => params[:instances_preset_filter], :search_filter => params[:instances_search]).
> - list(sort_column(Instance), sort_direction).where("instances.deployment_id" => @deployment.id),
> + @instances = paginate_collection(Instance.apply_filters(:preset_filter_id => params[:instances_preset_filter],
> + :search_filter => params[:instances_search]).
> + list(sort_column(Instance), sort_direction).
> + where("instances.deployment_id" => @deployment.id),
> params[:page], PER_PAGE)
> else
> @view = 'pretty_view_show'
> @instances = paginate_collection(Instance.list(sort_column(Instance), sort_direction).where("instances.deployment_id" => @deployment.id),
> params[:page], PER_PAGE)
> end
> - #TODO add links to real data for history, permissions, services
> + #TODO add links to real data for history, services
> @tabs = [{:name => t('instances.instances.other'), :view => @view, :id => 'instances', :count => @deployment.instances.count, :pretty_view_toggle => 'enabled'},
> - #{:name => 'Services', :view => @view, :id => 'services'},
> - #{:name => 'History', :view => 'history', :id => 'history'},
> {:name => t('properties'), :view => 'properties', :id => 'properties', :pretty_view_toggle => 'disabled'}
> - #{:name => 'Permissions', :view => 'permissions', :id => 'permissions'}
> ]
> add_permissions_tab(@deployment)
> details_tab_name = params[:details_tab].blank? ? 'instances' : params[:details_tab]
> diff --git a/src/app/controllers/instances_controller.rb b/src/app/controllers/instances_controller.rb
> index ba9fa5b..85a5235 100644
> --- a/src/app/controllers/instances_controller.rb
> +++ b/src/app/controllers/instances_controller.rb
> @@ -22,6 +22,7 @@ class InstancesController< ApplicationController
>
> def index
> @params = params
> + @title = t("instances.instances.other")
> save_breadcrumb(instances_path(:viewstate => viewstate_id))
> load_instances
>
> @@ -33,6 +34,10 @@ class InstancesController< ApplicationController
> end
>
> def new
> + respond_to do |format|
> + format.js
> + format.json
> + end
> end
>
> def create
> diff --git a/src/app/controllers/provider_accounts_controller.rb b/src/app/controllers/provider_accounts_controller.rb
> index 9b09647..bf48af3 100644
> --- a/src/app/controllers/provider_accounts_controller.rb
> +++ b/src/app/controllers/provider_accounts_controller.rb
> @@ -35,7 +35,9 @@ class ProviderAccountsController< ApplicationController
> @provider_account = ProviderAccount.find(params[:id])
> @title = t('provider_accounts.show.account', :name => @provider_account.name)
> @provider = Provider.find(params[:provider_id])
> - @realms = @provider_account.realms
> + @realms = @provider_account.realms.
> + apply_filters(:preset_filter_id => params[:provider_realms_preset_filter],
> + :search_filter => params[:provider_realms_search])
> @account_id = @provider_account.credentials_hash['account_id']
> require_privilege(Privilege::VIEW, @provider_account)
> @details_tab = params[:details_tab].blank? ? 'properties' : params[:details_tab]
> diff --git a/src/app/helpers/application_helper.rb b/src/app/helpers/application_helper.rb
> index b74a341..8480508 100644
> --- a/src/app/helpers/application_helper.rb
> +++ b/src/app/helpers/application_helper.rb
> @@ -74,9 +74,6 @@ module ApplicationHelper
> :filter_controls => options[:filter_controls] || :filter_controls,
> :form_footer => options[:form_footer] || :form_footer,
> :object_count => rows.count,
> - # TODO - We need to support searches and filters below
> - :search_term => nil,
> - :filters => {},
> :columns => columns,
> :lower_class => _class.to_s.tableize,
> :block => block,
> diff --git a/src/app/stylesheets/layout.scss b/src/app/stylesheets/layout.scss
> index f469b9b..89e78ab 100644
> --- a/src/app/stylesheets/layout.scss
> +++ b/src/app/stylesheets/layout.scss
> @@ -1194,7 +1194,7 @@ ul.deployment-array.large{
> }
>
> li.deployment + li.deployment{
> - margin-left: 23px;
> + margin-left: 22px;
> }
>
> li.deployment.pending, li.deployment.alert, li.deployment.failure{
> @@ -1319,7 +1319,7 @@ ul.deployment-array.small{
> }
>
> li.deployment + li.deployment{
> - margin-left: 14px;
> + margin-left: 12px;
> }
>
> li.deployment.pending, li.deployment.alert, li.deployment.failure{
> @@ -1540,15 +1540,17 @@ table.light_table{
> }
> }
>
> +
> +/* Properties table
> + ========================================================================== */
> table.properties_table {
> - margin-top: 2em;
> th {
> border-bottom: .1em solid #ccc;
> padding-bottom: .5em;
> color: #aaa;
> &:first-child {
> text-align: right;
> - padding-right: 2em;
> + padding-right: 1em;
> width: 18.15em;
> }
> &:last-child {
> @@ -1559,9 +1561,9 @@ table.properties_table {
> &:first-child {
> font-weight: bold;
> text-align: right;
> - padding-right: 2em;
> + padding-right: 1em;
> &:after {
> - content: " :";
> + content: ":";
> }
> }
> padding-top: .5em;
> diff --git a/src/app/views/catalogs/_properties.html.haml b/src/app/views/catalogs/_properties.html.haml
> deleted file mode 100644
> index d748285..0000000
> --- a/src/app/views/catalogs/_properties.html.haml
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -%table
> - %tbody
> - %tr
> - %td
> - %label{:name => 'name'}=t('catalogs.index.name') + ":"
> - %td
> - = @catalog.name
> - %tr
> - %td
> - %label{:name => 'pool'}=t('pools.pool') + ":"
> - %td
> - = @catalog.pool.name
> diff --git a/src/app/views/catalogs/_section_header.html.haml b/src/app/views/catalogs/_section_header.html.haml
> deleted file mode 100644
> index 1460606..0000000
> --- a/src/app/views/catalogs/_section_header.html.haml
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -%header.page-header
> - .obj_actions
> - = link_to t('catalogs.new_catalog'), new_catalog_url, :class => 'button primary', :id => 'new_catalog_button'
> - %h1.no-icon=t('catalogs.catalogs')
> diff --git a/src/app/views/catalogs/edit.html.haml b/src/app/views/catalogs/edit.html.haml
> index a490f70..c6d9a2e 100644
> --- a/src/app/views/catalogs/edit.html.haml
> +++ b/src/app/views/catalogs/edit.html.haml
> @@ -2,12 +2,9 @@
> %header.page-header
> .obj_actions
> = link_to t('catalogs.new_catalog'), new_catalog_url, :class => 'button primary', :id => 'new_catalog_button'
> - %h1.no-icon= @catalog.name
> + %h1.no-icon= @title
>
> %section.content-section.user
> - %header
> - %h2= @title
> -
> .content
> = form_for @catalog, :url => catalog_path(@catalog), :html => { :method => :put, :class => 'generic horizontal' } do |f|
> = render :partial => "form", :locals => { :form => f }
> diff --git a/src/app/views/catalogs/new.html.haml b/src/app/views/catalogs/new.html.haml
> index b6417ac..93fa612 100644
> --- a/src/app/views/catalogs/new.html.haml
> +++ b/src/app/views/catalogs/new.html.haml
> @@ -1,10 +1,6 @@
> = render :partial => 'layouts/admin_nav'
>
> %header.page-header
> - .obj_actions
> - .return_to
> - = t'return_to'
> - = link_to t("catalogs.catalogs"), catalogs_path
> %h1.no-icon= @title
>
> %section.content-section
> diff --git a/src/app/views/catalogs/show.html.haml b/src/app/views/catalogs/show.html.haml
> index b0d37e6..9956fe3 100644
> --- a/src/app/views/catalogs/show.html.haml
> +++ b/src/app/views/catalogs/show.html.haml
> @@ -1,6 +1,9 @@
> = render :partial => 'layouts/admin_nav'
> %header.page-header
> .obj_actions
> + .return_to
> + = t'return_to'
> + = link_to t("catalogs.catalogs"), catalogs_path
> - if check_privilege(Privilege::CREATE, Catalog)
> = link_to t('catalogs.new_catalog'), new_catalog_url, :class => 'button primary', :id => 'new_catalog_button'
> .button-group
> @@ -14,9 +17,16 @@
> %h2=t'properties'
>
> .content
> - = render :partial => 'properties'
> + %table.properties_table
> + %tbody
> + %tr
> + %td= t('catalogs.index.name')
> + %td= @catalog.name
> + %tr
> + %td= t('pools.pool')
> + %td= @catalog.pool.name
>
> -%section.content-section.catalog_entries
> +%section.content-section
> %header
> %h2=t('catalog_entries.index.catalog_entries')
>
> diff --git a/src/app/views/config_servers/_config_server_form.haml b/src/app/views/config_servers/_config_server_form.haml
> index bdcc312..3479e88 100644
> --- a/src/app/views/config_servers/_config_server_form.haml
> +++ b/src/app/views/config_servers/_config_server_form.haml
> @@ -3,7 +3,7 @@
> %fieldset
> .field
> = hidden_field_tag "provider_account_id", @provider_account.id
> - = form.label :endpoint
> + = form.label :endpoint, :class => 'em'
> .input
> = form.text_field :endpoint, :class => 'em long'
> .field
> diff --git a/src/app/views/config_servers/_page_header.haml b/src/app/views/config_servers/_page_header.haml
> new file mode 100644
> index 0000000..f1d2562
> --- /dev/null
> +++ b/src/app/views/config_servers/_page_header.haml
> @@ -0,0 +1,2 @@
> +%header.page-header
> + %h1.provider_accounts= t('provider_accounts.show.account', :name => @provider_account.name)
> diff --git a/src/app/views/config_servers/_section_header.haml b/src/app/views/config_servers/_section_header.haml
> deleted file mode 100644
> index 50b7dcd..0000000
> --- a/src/app/views/config_servers/_section_header.haml
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -%header.page-header
> - %h1.no-icon= t('.config_server')
> diff --git a/src/app/views/config_servers/edit.haml b/src/app/views/config_servers/edit.haml
> index ae88662..de2e9f6 100644
> --- a/src/app/views/config_servers/edit.haml
> +++ b/src/app/views/config_servers/edit.haml
> @@ -1,5 +1,5 @@
> = render :partial => 'layouts/admin_nav'
> -= render :partial => 'section_header'
> += render :partial => 'page_header'
>
> %section.content-section.config_server
> %header
> diff --git a/src/app/views/config_servers/new.haml b/src/app/views/config_servers/new.haml
> index 6f9b9a4..0ef2bb9 100644
> --- a/src/app/views/config_servers/new.haml
> +++ b/src/app/views/config_servers/new.haml
> @@ -1,5 +1,5 @@
> = render :partial => 'layouts/admin_nav'
> -= render :partial => 'section_header'
> += render :partial => 'page_header'
>
> %section.content-section.config_server
> %header
> diff --git a/src/app/views/deployables/_new.html.haml b/src/app/views/deployables/_new.html.haml
> index 1ef6973..aeacc67 100644
> --- a/src/app/views/deployables/_new.html.haml
> +++ b/src/app/views/deployables/_new.html.haml
> @@ -1,10 +1,8 @@
> -= render :partial => 'section_header'
> +%header.page-header
> + %h1.catalog_entries=t'catalog_entries.new.add_catalog_entry'
>
> %section.content-section
> %header
> - %h2=t'catalog_entries.new.add_catalog_entry'
> -
> - .content
> %nav#image-upload-tabs.faceted
> %ul.tabs
> %li
> @@ -12,6 +10,7 @@
> %li
> = link_to t('catalog_entries.new.from_url'), new_polymorphic_path([@catalog, Deployable], :from_url => true), :id => "from_url", :class => "#{'active' if @form_option == 'from_url'}"
>
> + .content
> .form_option
> = render :partial => @form_option
>
> diff --git a/src/app/views/deployables/_section_header.html.haml b/src/app/views/deployables/_section_header.html.haml
> deleted file mode 100644
> index 35cc064..0000000
> --- a/src/app/views/deployables/_section_header.html.haml
> +++ /dev/null
> @@ -1,5 +0,0 @@
> -%header.page-header
> - .obj_actions
> - - if check_privilege(Privilege::CREATE, Deployable)
> - = link_to "#{t'catalog_entries.new_catalog_entry'}", new_polymorphic_path([@catalog, Deployable]), :class => 'button primary', :id => 'new_catalog_entry_button'
> - %h1.catalog_entries=t'catalog_entries.index.catalog_entries'
> diff --git a/src/app/views/deployables/index.html.haml b/src/app/views/deployables/index.html.haml
> index 3fae6b6..c1dbafd 100644
> --- a/src/app/views/deployables/index.html.haml
> +++ b/src/app/views/deployables/index.html.haml
> @@ -1,3 +1,9 @@
> = render :partial => 'layouts/admin_nav'
> -= render :partial => 'section_header'
> +
> +%header.page-header
> + .obj_actions
> + - if check_privilege(Privilege::CREATE, Deployable)
> + = link_to "#{t'catalog_entries.new_catalog_entry'}", new_polymorphic_path([@catalog, Deployable]), :class => 'button primary', :id => 'new_catalog_entry_button'
> + %h1.catalog_entries=t'catalog_entries.index.catalog_entries'
> +
> = render :partial => 'list'
> diff --git a/src/app/views/deployables/show.html.haml b/src/app/views/deployables/show.html.haml
> index 7ddb800..a79573a 100644
> --- a/src/app/views/deployables/show.html.haml
> +++ b/src/app/views/deployables/show.html.haml
> @@ -14,7 +14,6 @@
> %a{:id => :launch_deployment_button, :class => 'disabled', :'data-path' => launch_deployment_button_path}= t('.launch')
> %h1.catalog_entries= @deployable.name
>
> -
> %section.content-section
> %header
> %h2.images= t('.images')
> diff --git a/src/app/views/deployments/_alerts_show.html.haml b/src/app/views/deployments/_alerts_show.html.haml
> index e208287..6742e45 100644
> --- a/src/app/views/deployments/_alerts_show.html.haml
> +++ b/src/app/views/deployments/_alerts_show.html.haml
> @@ -2,7 +2,7 @@
> %section.content-section.alerts.collapse_entity
> %header
> .section-controls
> - = link_to t("providers.edit.toggle_alerts"), "#", :class => 'collapse alerts' unless @statistics[:instances_failed].blank?
> + = link_to t("providers.edit.toggle_alerts"), "#", :class => 'collapse alerts'
> %h2.alerts
> =t 'alerts_label'
> %span.label.badge.alert.count= @failed_instances.count
> diff --git a/src/app/views/deployments/_deployment.html.haml b/src/app/views/deployments/_deployment.html.haml
> deleted file mode 100644
> index 03cfbdc..0000000
> --- a/src/app/views/deployments/_deployment.html.haml
> +++ /dev/null
> @@ -1,9 +0,0 @@
> -%div.deployment_pretty
> - %h3
> - = link_to(deployment.name, deployment)
> - %ul
> - %li
> - = deployment.instances.count
> - Instances
> - %p
> - = deployment.provider.provider_type.name if deployment.provider
> \ No newline at end of file
> diff --git a/src/app/views/deployments/_edit.html.haml b/src/app/views/deployments/_edit.html.haml
> index eb55f6b..3c7eae4 100644
> --- a/src/app/views/deployments/_edit.html.haml
> +++ b/src/app/views/deployments/_edit.html.haml
> @@ -1,11 +1,18 @@
> -- if @deployment.errors.any?
> - = render 'layouts/error_messages', :object => @deployment
> -%h2=t 'deployments.edit.edit_deployment'
> -= form_for @deployment do
> - %ul
> - %li
> - = label :deployment
> - = text_field :deployment, :name
> +%header.page-header
> + %h1.deployments= @deployment.name.blank? ? t("deployments.deployment") : @deployment.name
>
> - = submit_tag t('cancel'), :name => 'cancel'
> - = submit_tag t('save'), :name => 'save', :id => 'save_button'
> +%section.content-section
> + %header
> + %h2= t('deployments.edit.edit_deployment')
> + .content
> + = form_for @deployment, :html => {:class => 'generic'} do |form|
> + - if @deployment.errors.any?
> + = render 'layouts/error_messages', :object => @deployment
> + %fieldset
> + .field
> + = form.label :name, :class => 'em'
> + .input
> + = form.text_field :name, :class => 'em long'
> + %fieldset.options
> + = form.submit t('save'), :class => 'button primary', :id => 'save_button'
> + = link_to t('cancel'), @deployment, :class => 'button danger'
> diff --git a/src/app/views/deployments/_header_show.html.haml b/src/app/views/deployments/_header_show.html.haml
> deleted file mode 100644
> index 46dc99f..0000000
> --- a/src/app/views/deployments/_header_show.html.haml
> +++ /dev/null
> @@ -1,5 +0,0 @@
> -%header.page-header
> - .obj_actions
> - - if check_privilege(Privilege::MODIFY, @deployment)
> - = button_to t('delete'), deployment_path(@deployment), :method => :delete, :confirm => t("deployments.confirm_delete"), :class => "button danger", :id => 'delete'
> - %h1.deployments= @title
> diff --git a/src/app/views/deployments/_history.html.haml b/src/app/views/deployments/_history.html.haml
> deleted file mode 100644
> index 03e5b35..0000000
> --- a/src/app/views/deployments/_history.html.haml
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -%h3=t 'deployments.list_of_events'
> -
> -:javascript
> - Conductor.setupPrettyFilterURL(
> - '#{url_for(:action => :show, :details_tab => 'history', :view => 'filter' )}',
> - '#{url_for(:action => :show, :details_tab => 'history', :view => 'pretty' )}');
> \ No newline at end of file
> diff --git a/src/app/views/deployments/_list.html.haml b/src/app/views/deployments/_list.html.haml
> index c1ee53b..0164e24 100644
> --- a/src/app/views/deployments/_list.html.haml
> +++ b/src/app/views/deployments/_list.html.haml
> @@ -1,5 +1,5 @@
> - if request.xhr?
> - = render :partial => '/layouts/notification'
> + = render :partial => '/layouts/new_notification'
>
> - content_for :form_header do
> %li= restful_submit_tag "#{t'deployments.list.stop_selected'}", 'stop', multi_stop_deployments_path, 'POST', :class => 'button', :id => "stop_button", 'data-none_selected' => t('deployments.flash.error.none_selected')
> diff --git a/src/app/views/deployments/_operation.html.haml b/src/app/views/deployments/_operation.html.haml
> deleted file mode 100644
> index 93910db..0000000
> --- a/src/app/views/deployments/_operation.html.haml
> +++ /dev/null
> @@ -1,5 +0,0 @@
> -%h3= t('deployments.operation.operational_status')+ " #{@deployment.name}"
> -
> -%br
> -=t 'deployments.operation.count_of_instances'
> -= @deployment.instances.count
> diff --git a/src/app/views/deployments/_permissions.html.haml b/src/app/views/deployments/_permissions.html.haml
> deleted file mode 100644
> index e73ced3..0000000
> --- a/src/app/views/deployments/_permissions.html.haml
> +++ /dev/null
> @@ -1 +0,0 @@
> -= render :partial => 'permissions/permissions'
> diff --git a/src/app/views/deployments/_properties.html.haml b/src/app/views/deployments/_properties.html.haml
> index 3ae36d3..cccc4fa 100644
> --- a/src/app/views/deployments/_properties.html.haml
> +++ b/src/app/views/deployments/_properties.html.haml
> @@ -1,8 +1,4 @@
> %table.properties_table
> - %thead
> - %tr
> - %th=t 'deployments.properties.property_name'
> - %th=t 'deployments.properties.value'
> %tbody
> - at deployment_properties.each do |key, value|
> %tr
> @@ -18,4 +14,4 @@
> :javascript
> Conductor.setupPrettyFilterURL(
> '#{url_for(:action => :show, :details_tab => 'properties', :view => 'filter' )}',
> - '#{url_for(:action => :show, :details_tab => 'properties', :view => 'pretty' )}');
> \ No newline at end of file
> + '#{url_for(:action => :show, :details_tab => 'properties', :view => 'pretty' )}');
> diff --git a/src/app/views/deployments/_provider_services.html.haml b/src/app/views/deployments/_provider_services.html.haml
> deleted file mode 100644
> index 27f50d7..0000000
> --- a/src/app/views/deployments/_provider_services.html.haml
> +++ /dev/null
> @@ -1 +0,0 @@
> -%h3= t'deployments.provider_services.list_of_services'
> diff --git a/src/app/views/deployments/_required_services.html.haml b/src/app/views/deployments/_required_services.html.haml
> deleted file mode 100644
> index ec8ad58..0000000
> --- a/src/app/views/deployments/_required_services.html.haml
> +++ /dev/null
> @@ -1 +0,0 @@
> -%h3= t 'deployments.required_services.list_of_required_services'
> diff --git a/src/app/views/deployments/index.html.haml b/src/app/views/deployments/index.html.haml
> index ce74167..7a00204 100644
> --- a/src/app/views/deployments/index.html.haml
> +++ b/src/app/views/deployments/index.html.haml
> @@ -1,2 +1,5 @@
> = render :partial => 'layouts/nav_history'
> -= render :partial => 'list'
> +%header.page-header
> + %h1.deployments= @title
> +%section.content-section
> + = render :partial => 'list'
> diff --git a/src/app/views/deployments/show.html.haml b/src/app/views/deployments/show.html.haml
> index 6006a55..da6d3b0 100644
> --- a/src/app/views/deployments/show.html.haml
> +++ b/src/app/views/deployments/show.html.haml
> @@ -1,7 +1,19 @@
> = render :partial => 'layouts/nav_history'
> -= render :partial => 'header_show'
> -= render :partial => 'pools/scoreboard_show', :locals => {:@statistics => @deployment.pool.statistics, :@pool => @deployment.pool}
> +
> +%header.page-header
> + .obj_actions
> + - if check_privilege(Privilege::MODIFY, @deployment)
> + .button-group
> + = link_to t('edit'), edit_deployment_path(@deployment), :class => 'button pill',
> + :id => 'edit_deployment_button'
> + = button_to t('delete'), deployment_path(@deployment), :method => :delete,
> + :confirm => t("deployments.confirm_delete"),
> + :class => "button pill danger",
> + :id => 'delete'
> + %h1.deployments= @title
> +
> = render :partial => 'alerts_show'
> +
> %section.content-section
> %header#tab-container-1
> .section-controls
> diff --git a/src/app/views/hardware_profiles/_form.html.haml b/src/app/views/hardware_profiles/_form.html.haml
> index 972cb69..a33ccaa 100644
> --- a/src/app/views/hardware_profiles/_form.html.haml
> +++ b/src/app/views/hardware_profiles/_form.html.haml
> @@ -1,8 +1,9 @@
> - if @hardware_profile.errors.any?
> = render 'layouts/error_messages', :object => @hardware_profile
> %fieldset
> - = hwp_form.label :name, :class => 'em'
> - = hwp_form.text_field :name, :class => 'em'
> + .field
> + = hwp_form.label :name, :class => 'em'
> + = hwp_form.text_field :name, :class => 'em long'
> %fieldset
> %table
> %thead
> diff --git a/src/app/views/hardware_profiles/_history.html.haml b/src/app/views/hardware_profiles/_history.html.haml
> deleted file mode 100644
> index f11b9bc..0000000
> --- a/src/app/views/hardware_profiles/_history.html.haml
> +++ /dev/null
> @@ -1 +0,0 @@
> -%h3= t 'hardware_profiles.history.history'
> diff --git a/src/app/views/hardware_profiles/_matching_provider_hardware_profiles.html.haml b/src/app/views/hardware_profiles/_matching_provider_hardware_profiles.html.haml
> index 60ddb0d..451287d 100644
> --- a/src/app/views/hardware_profiles/_matching_provider_hardware_profiles.html.haml
> +++ b/src/app/views/hardware_profiles/_matching_provider_hardware_profiles.html.haml
> @@ -1,34 +1,38 @@
> -- if @matching_hwps.size> 0
> - %table.flat
> - %thead
> - %tr
> - - @provider_hwps_header.each do |header|
> - %th
> - = header[:name]
> - - @matching_hwps.each do |hwp|
> - %tr{:class => cycle('nostripe','stripe')}
> - %td
> - - if hwp.provider
> - -# FIXME: what do we show for end users without provider 'view' access?
> - -# currently showing mapping but not linking to (permission-lacking)
> - -# provider view, or should we hide the mapping completely if the user
> - -# doesn't have provider 'view' privileges -- probably depends on whether
> - -# end users are expected to have permission to get to the provider
> - -# show page (read-only). If not, then the below is probably correct.
> - - if check_privilege(Privilege::VIEW, hwp.provider)
> - = link_to hwp.provider.name, provider_path(hwp.provider)
> - - else
> - = hwp.provider.name
> - %td
> - = link_to hwp.name, hardware_profile_path(hwp)
> - %td
> - =hwp.architecture.to_s
> - %td
> - =hwp.memory.to_s
> - %td
> - =hwp.storage.to_s
> - %td
> - =hwp.cpu.to_s
> -- else
> - %h3
> - = t'hardware_profiles.matching_provider_hwp.no_matching_provider_hwp'
> +%section.content-section
> + %header
> + %h2=t'hardware_profiles.show.matching_hwp'
> + .content
> + - if @matching_hwps.size> 0
> + %table.flat
> + %thead
> + %tr
> + - @provider_hwps_header.each do |header|
> + %th
> + = header[:name]
> + - @matching_hwps.each do |hwp|
> + %tr{:class => cycle('nostripe','stripe')}
> + %td
> + - if hwp.provider
> + -# FIXME: what do we show for end users without provider 'view' access?
> + -# currently showing mapping but not linking to (permission-lacking)
> + -# provider view, or should we hide the mapping completely if the user
> + -# doesn't have provider 'view' privileges -- probably depends on whether
> + -# end users are expected to have permission to get to the provider
> + -# show page (read-only). If not, then the below is probably correct.
> + - if check_privilege(Privilege::VIEW, hwp.provider)
> + = link_to hwp.provider.name, provider_path(hwp.provider)
> + - else
> + = hwp.provider.name
> + %td
> + = link_to hwp.name, hardware_profile_path(hwp)
> + %td
> + =hwp.architecture.to_s
> + %td
> + =hwp.memory.to_s
> + %td
> + =hwp.storage.to_s
> + %td
> + =hwp.cpu.to_s
> + - else
> + %h3
> + = t'hardware_profiles.matching_provider_hwp.no_matching_provider_hwp'
> diff --git a/src/app/views/hardware_profiles/_properties.html.haml b/src/app/views/hardware_profiles/_properties.html.haml
> deleted file mode 100644
> index 8fae3c1..0000000
> --- a/src/app/views/hardware_profiles/_properties.html.haml
> +++ /dev/null
> @@ -1,14 +0,0 @@
> -%table.flat
> - %thead
> - %tr
> - - @properties_header.each do |header|
> - %th
> - = header[:name]
> - - @hwp_properties.each do |hwpp|
> - %tr
> - %td
> - =hwpp.name.nil? ? "n/a" : hwpp.name
> - %td
> - =hwpp.unit.nil? ? "n/a" : hwpp.unit
> - %td
> - =hwpp.value.nil? ? "n/a" : hwpp.value
> diff --git a/src/app/views/hardware_profiles/_section_header.html.haml b/src/app/views/hardware_profiles/_section_header.html.haml
> deleted file mode 100644
> index e5f40b5..0000000
> --- a/src/app/views/hardware_profiles/_section_header.html.haml
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -%header.page-header
> - .obj_actions
> - = link_to t('hardware_profiles.list.new_hardware'), new_hardware_profile_url, :class => 'button primary', :id => 'new_hardware_profile_button'
> - %h1.hardware_profiles=t'hardware_profiles.hardware_profiles'
> diff --git a/src/app/views/hardware_profiles/create.html.haml b/src/app/views/hardware_profiles/create.html.haml
> deleted file mode 100644
> index 273a403..0000000
> --- a/src/app/views/hardware_profiles/create.html.haml
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -%h3
> - = t'hardware_profiles.create.check_matching_hwp'
> -- content_for :list do
> - = render :partial => "form"
> -- content_for :details do
> - = render :partial => 'layouts/details_pane'
> \ No newline at end of file
> diff --git a/src/app/views/hardware_profiles/edit.html.haml b/src/app/views/hardware_profiles/edit.html.haml
> index 306654f..1052524 100644
> --- a/src/app/views/hardware_profiles/edit.html.haml
> +++ b/src/app/views/hardware_profiles/edit.html.haml
> @@ -4,7 +4,7 @@
> .obj_actions
> = link_to t('hardware_profiles.list.new_hardware'), hardware_profile_url, :class => 'button primary', :id => 'new_user_button'
> = link_to t('hardware_profiles.edit.cancel_editing'), hardware_profile_path(@hardware_profile), :class => 'button pill danger', :id => 'new_user_button'
> - %h1.hardware_profiles= @title
> + %h1.hardware_profiles= @hardware_profile.name.blank? ? t("hardware_profiles.hardware_profile") : @hardware_profile.name
>
> %section.content-section
> %header
> @@ -14,4 +14,4 @@
> = form_for @hardware_profile, :url => hardware_profile_path(@hardware_profile), :html => { :multipart => true, :class => 'generic' } do |hwp_form|
> = render :partial => "form", :locals => { :hwp_form => hwp_form }
>
> - = render :partial => 'matching_provider_hardware_profiles' if params[:commit] == 'Check Matches'
> += render :partial => 'matching_provider_hardware_profiles' if params[:commit] == 'Check Matches'
> diff --git a/src/app/views/hardware_profiles/new.html.haml b/src/app/views/hardware_profiles/new.html.haml
> index 90d40f5..842f74d 100644
> --- a/src/app/views/hardware_profiles/new.html.haml
> +++ b/src/app/views/hardware_profiles/new.html.haml
> @@ -5,10 +5,10 @@
> .return_to
> = t'return_to'
> = link_to t('hardware_profiles.hardware_profiles'), hardware_profiles_path
> - %h1.hardware_profiles= @title
> + %h1.hardware_profiles= @hardware_profile.name.blank? ? t("hardware_profiles.new.new_hwp") : @hardware_profile.name
>
> %section.content-section
> - = form_for @hardware_profile, :url => hardware_profiles_path, :html => { :multipart => true } do |hwp_form|
> + = form_for @hardware_profile, :url => hardware_profiles_path, :html => { :multipart => true, :class => 'generic' } do |hwp_form|
> = render :partial => "form", :locals => { :hwp_form => hwp_form }
>
> - = render :partial => 'matching_provider_hardware_profiles' if @matching_hwps.present?&& @matching_hwps.any?
> += render :partial => 'matching_provider_hardware_profiles' if @matching_hwps.present?&& @matching_hwps.any?
> diff --git a/src/app/views/hardware_profiles/show.html.haml b/src/app/views/hardware_profiles/show.html.haml
> index b2bbb83..04f1899 100644
> --- a/src/app/views/hardware_profiles/show.html.haml
> +++ b/src/app/views/hardware_profiles/show.html.haml
> @@ -12,10 +12,19 @@
> %header
> %h2=t 'properties'
> .content
> - = render :partial => 'properties'
> + %table.flat
> + %thead
> + %tr
> + - @properties_header.each do |header|
> + %th
> + = header[:name]
> + - @hwp_properties.each do |hwpp|
> + %tr
> + %td
> + =hwpp.name.nil? ? "n/a" : hwpp.name
> + %td
> + =hwpp.unit.nil? ? "n/a" : hwpp.unit
> + %td
> + =hwpp.value.nil? ? "n/a" : hwpp.value
> - unless @hardware_profile.provider_hardware_profile?
> - %section.content-section.hardware_profile
> - %header
> - %h2=t'hardware_profiles.show.matching_hwp'
> - .content
> - = render :partial => 'matching_provider_hardware_profiles'
> + = render :partial => 'matching_provider_hardware_profiles'
> diff --git a/src/app/views/instances/_can_perform_state_change.xml.haml b/src/app/views/instances/_can_perform_state_change.xml.haml
> deleted file mode 100644
> index e20a232..0000000
> --- a/src/app/views/instances/_can_perform_state_change.xml.haml
> +++ /dev/null
> @@ -1,7 +0,0 @@
> -%result<
> - %action_request<
> - =@action_request
> - %instance_id<
> - =@instance.id
> - %value<
> - =@value
> \ No newline at end of file
> diff --git a/src/app/views/instances/_edit.html.haml b/src/app/views/instances/_edit.html.haml
> index 0ea4240..5e7a0c7 100644
> --- a/src/app/views/instances/_edit.html.haml
> +++ b/src/app/views/instances/_edit.html.haml
> @@ -1,11 +1,17 @@
> -- if @instance.errors.any?
> - = render 'layouts/error_messages', :object => @instance
> -%h2= t'instances.edit.edit_instance'
> -= form_for @instance do
> - %ul
> - %li
> - = label :instance, :name
> - = text_field :instance, :name
> +%header.page-header
> + %h1.no-icon= @instance.name.blank? ? t("instances.edit.edit_instance") : @instance.name
>
> - = submit_tag t('cancel'), :name => 'cancel'
> - = submit_tag t('save'), :name => 'save', :id => 'save'
> +%section.content-section
> + %header
> + %h2= t'instances.edit.edit_instance'
> + .content
> + = form_for @instance, :html => {:class => 'generic'} do |form|
> + - if @instance.errors.any?
> + = render 'layouts/error_messages', :object => @instance
> + %fieldset
> + .field
> + = label :instance, :name, :class => 'em'
> + = text_field :instance, :name, :class => 'em long'
> + %fieldset.options
> + = submit_tag t('save'), :name => 'save', :id => 'save', :class => 'button'
> + = link_to t('cancel'), @instance, :class => 'button danger'
> diff --git a/src/app/views/instances/_permissions.html.haml b/src/app/views/instances/_permissions.html.haml
> deleted file mode 100644
> index bbaaded..0000000
> --- a/src/app/views/instances/_permissions.html.haml
> +++ /dev/null
> @@ -1,3 +0,0 @@
> -%h3
> - = t 'instances.permissions.permissions_for'
> - = @instance.name
> diff --git a/src/app/views/instances/_properties.html.haml b/src/app/views/instances/_properties.html.haml
> index ee5ffb7..08c61e5 100644
> --- a/src/app/views/instances/_properties.html.haml
> +++ b/src/app/views/instances/_properties.html.haml
> @@ -1,53 +1,54 @@
> -%ul
> - %li
> - = label_tag :name, t('instances.properties.name')
> - %span= @instance.name
> - %li
> - = label_tag :status, t('instances.properties.status')
> - %span= t("instances.states.#{@instance.state}")
> - %li
> - = label_tag :public_addresses, t('instances.properties.public_addresses')
> - %span= @instance.public_addresses
> - %li
> - = label_tag :private_addresses, t('instances.properties.private_adresses')
> - %span= @instance.private_addresses
> - = label_tag :assembly, t('instances.properties.assembly')
> - %span= @instance.assembly_xml.name
> - %li
> - = label_tag :provider, t('instances.properties.provider')
> - %span= @instance.provider_account.provider.name if @instance.provider_account
> - %li
> - = label_tag :architecture, t('instances.properties.architecture')
> - %span= @instance.hardware_profile.architecture.value
> - %li
> - = label_tag :memory, t('instances.properties.memory')
> - %span= @instance.hardware_profile.memory.value
> - %li
> - = label_tag :storage, t('instances.properties.storage')
> - %span= @instance.hardware_profile.storage.value
> - %li
> - = label_tag :instantiation_time, t('instances.properties.instantiation_time')
> - %span= @instance.created_at.strftime("%d-%b-%Y %H:%M:%S")
> - %li
> - = label_tag :current_alerts, t('instances.properties.current_alerts')
> - %span= 0
> - %li
> - = label_tag :console_connection, t('instances.properties.console_connection')
> - %span= t('instances.properties.via_ssh')
> +%table.properties_table
> + %tr
> + %td= t('instances.properties.name')
> + %td= @instance.name
> + %tr
> + %td= t('instances.properties.status')
> + %td= t("instances.states.#{@instance.state}")
> + %tr
> + %td= t('instances.properties.public_addresses')
> + %td= @instance.public_addresses
> + %tr
> + %td= t('instances.properties.private_adresses')
> + %td= @instance.private_addresses
> + %tr
> + %td= t('instances.properties.assembly')
> + %td= @instance.assembly_xml.name
> + %tr
> + %td= t('instances.properties.provider')
> + %td= @instance.provider_account.provider.name if @instance.provider_account
> + %tr
> + %td= t('instances.properties.architecture')
> + %td= @instance.hardware_profile.architecture.value
> + %tr
> + %td= t('instances.properties.memory')
> + %td= @instance.hardware_profile.memory.value
> + %tr
> + %td= t('instances.properties.storage')
> + %td= @instance.hardware_profile.storage.value
> + %tr
> + %td= t('instances.properties.instantiation_time')
> + %td= @instance.created_at.strftime("%d-%b-%Y %H:%M:%S")
> + %tr
> + %td= t('instances.properties.current_alerts')
> + %td= 0
> + %tr
> + %td= t('instances.properties.console_connection')
> + %td= t('instances.properties.via_ssh')
> - if @instance.instance_key
> - %li
> - = label_tag :instance_key, t('instances.properties.ssh_key')
> - %span= link_to t('instances.properties.download'), key_instance_path(@instance), :id =>'download_ssh_key'
> - %li
> - = label_tag :instance_key_name, t('instances.properties.ssh_key_name')
> - %span= @instance.instance_key.name
> - %li
> - = label_tag :owner, t('instances.properties.owner')
> - %span= "#{@instance.owner.first_name} #{@instance.owner.last_name}"
> - %li
> - = label_tag :shared_to, t('instances.properties.shared_to')
> - %span= t('instances.properties.n_a')
> + %tr
> + %td= t('instances.properties.ssh_key')
> + %td= link_to t('instances.properties.download'), key_instance_path(@instance), :id =>'download_ssh_key'
> + %tr
> + %td= t('instances.properties.ssh_key_name')
> + %td= @instance.instance_key.name
> + %tr
> + %td= t('instances.properties.owner')
> + %td= "#{@instance.owner.first_name} #{@instance.owner.last_name}"
> + %tr
> + %td= t('instances.properties.shared_to')
> + %td= t('instances.properties.n_a')
> - if @instance.state == Instance::STATE_ERROR
> - %li
> - = label_tag :error, t('instances.properties.error')
> - %span= @instance.last_error
> + %tr
> + %td= t('instances.properties.error')
> + %td= @instance.last_error
> diff --git a/src/app/views/instances/index.html.haml b/src/app/views/instances/index.html.haml
> index ce74167..785ff92 100644
> --- a/src/app/views/instances/index.html.haml
> +++ b/src/app/views/instances/index.html.haml
> @@ -1,2 +1,5 @@
> = render :partial => 'layouts/nav_history'
> -= render :partial => 'list'
> +%header.page-header
> + %h1.no-icon= @title
> +%section.content-section
> + = render :partial => 'list'
> diff --git a/src/app/views/instances/new.html.haml b/src/app/views/instances/new.html.haml
> deleted file mode 100644
> index 5d4bc23..0000000
> --- a/src/app/views/instances/new.html.haml
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -= render :partial => 'layouts/nav_history'
> -= render :partial => 'new'
> diff --git a/src/app/views/instances/show.html.haml b/src/app/views/instances/show.html.haml
> index d4b96d5..4d240c9 100644
> --- a/src/app/views/instances/show.html.haml
> +++ b/src/app/views/instances/show.html.haml
> @@ -1,5 +1,9 @@
> = render :partial => 'layouts/nav_history'
> %header.page-header
> + .obj_actions
> + - if check_privilege(Privilege::MODIFY, @instance)
> + = link_to t('edit'), edit_instance_path(@instance), :class => 'button pill',
> + :id => 'edit_instance_button'
> %h1.deployments= @instance.name
>
> %section.content-section
> diff --git a/src/app/views/layouts/_admin_content_tabs.html.haml b/src/app/views/layouts/_admin_content_tabs.html.haml
> index 5e89f29..72c8c8f 100644
> --- a/src/app/views/layouts/_admin_content_tabs.html.haml
> +++ b/src/app/views/layouts/_admin_content_tabs.html.haml
> @@ -4,7 +4,8 @@
> %ul#tab-container-1-nav
> - @tabs.each do |tab|
> %li
> - %a{ :href => tab[:url], :id => "details_#{tab[:id]}", :class => "#{'active' if @details_tab[:id] == tab[:id]} show"}
> + %a{ :href => tab[:url], :id => "details_#{tab[:id]}",
> + :class => "#{'active' if @details_tab[:id] == tab[:id]} show"}
> = tab[:name]
> -if tab[:count]
> %span.label.badge.count.dark=tab[:count]
> diff --git a/src/app/views/layouts/_footer.html.haml b/src/app/views/layouts/_footer.html.haml
> deleted file mode 100644
> index 1ddc7a7..0000000
> --- a/src/app/views/layouts/_footer.html.haml
> +++ /dev/null
> @@ -1,5 +0,0 @@
> -%ul.container_16
> - - unless current_user.nil?
> - %li
> - = link_to t(:logout), logout_url
> - %li Copyright© 2010-2011 Red Hat, Inc.
> diff --git a/src/app/views/layouts/_header.html.haml b/src/app/views/layouts/_header.html.haml
> deleted file mode 100644
> index 4d3e7bc..0000000
> --- a/src/app/views/layouts/_header.html.haml
> +++ /dev/null
> @@ -1,20 +0,0 @@
> -%h1
> - Red Hat Cloud Engine
> -- unless current_user.nil?
> - %ul
> - /
> - FIXME: commented out because these links don't do anything yet
> - %li.about
> - %a{:href => ""}
> - = t(:about)
> - %li.configure
> - %a{:href => ""}
> - = t(:configure)
> -
> - %li.hello
> - - link_to edit_user_path(current_user) do
> - = t(:hello) + " "
> - %b
> - = "#{current_user.first_name} #{current_user.last_name}"
> - %li.logout
> - = link_to t(:logout), logout_url
> diff --git a/src/app/views/layouts/_masthead.html.haml b/src/app/views/layouts/_masthead.html.haml
> deleted file mode 100644
> index 312f20b..0000000
> --- a/src/app/views/layouts/_masthead.html.haml
> +++ /dev/null
> @@ -1,17 +0,0 @@
> -.container
> - = image_tag('upstream-logo.png', :id => 'logo')
> - %nav#system
> - %ul
> - %li.account
> - %span.name.label.strong.small-caps
> - = "#{current_user.first_name} #{current_user.last_name}" if current_user.present?
> - %li#view-user-menu
> -
> - %ul#user-menu
> - %li= link_to t('masthead.my_account'), account_path
> - %li= link_to t('masthead.logout'), logout_path
> - /%li.separator
> - /%li
> - / %div.query-input
> - / -# Using verbatim HTML because CSS inline-block requires it.
> - / != "<input type='text' placeholder='Search...' /><input type='submit' value='search' />"
> diff --git a/src/app/views/layouts/_notification.rhtml b/src/app/views/layouts/_notification.rhtml
> deleted file mode 100644
> index 6c204fd..0000000
> --- a/src/app/views/layouts/_notification.rhtml
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -<div id="notification"<%if flash[:error]%>class="error-align"<%end%>>
> -<%#= link_to "", params, :id => "close-notify" %>
> -<% if flash[:error] %>
> -<% if !flash[:error][:successes].nil?&& !flash[:error][:successes].empty? %>
> -<div class="success">
> -<h4>The following items were successful:</h4>
> -<ul>
> -<% flash[:error][:successes].each {|item| %>
> -<li><%= item %></li>
> -<% } %>
> -</ul>
> -</div>
> -<% end %>
> -<% if !flash[:error][:failures].nil?&& !flash[:error][:failures].empty? %>
> -<div class="warning"><h4><%= flash[:error][:summary]%></h4></div>
> -<div class="error">
> -<ul>
> -<% flash[:error][:failures].each {|key, value| %>
> -<li><%= key %>:<%= value %></li>
> -<% } %>
> -</ul>
> -</div>
> -<% end %>
> -<% end %>
> -<% if flash[:error]&& flash[:error].kind_of?(String) %>
> -<div class="error"><ul><li><%= flash[:error] %></li></ul></div>
> -<% end %>
> -<% if flash[:warning] %>
> -<div class="warning"><ul><li><%= flash[:warning] %></li></ul></div>
> -<% end %>
> -<% if flash[:notice] %>
> -<div class="success"><ul><li><%= flash[:notice] %></li></ul></div>
> -<% end %>
> -</div>
> diff --git a/src/app/views/layouts/old_application.html.haml b/src/app/views/layouts/old_application.html.haml
> deleted file mode 100644
> index 757adde..0000000
> --- a/src/app/views/layouts/old_application.html.haml
> +++ /dev/null
> @@ -1,64 +0,0 @@
> -!!! 5
> -%html{"xml:lang" => "en", :lang => "en"}
> - %head
> - %meta{:charset => 'utf-8'}/
> - %title= @title
> - %link{:rel => 'shortcut icon', :href => '/favicon.ico'}
> - = stylesheet_link_tag '/stylesheets/reset.css'
> - = stylesheet_link_tag '/stylesheets/960.css'
> - = stylesheet_link_tag '/stylesheets/buttons.css'
> - = stylesheet_link_tag '/stylesheets/compiled/layout.css'
> - = stylesheet_link_tag 'jquery.ui-1.8.1/jquery-ui-1.8.1.custom.css'
> - = stylesheet_link_tag '/stylesheets/compiled/header.css'
> - /[if lt IE 9]
> - = javascript_include_tag 'http://html5shiv.googlecode.com/svn/trunk/html5.js'
> - /[if lt IE 8]
> - = stylesheet_link_tag '/stylesheets/layout_ie7.css'
> - = stylesheet_link_tag '/stylesheets/compiled/custom.css'
> -
> - :javascript
> - window.Conductor = {}
> - window.Conductor.PATH_PREFIX = "#{root_path}"
> - // This hack prevents Backbone from switching to the #/pools/1 type URLs
> - // when the browser doesn't support the HTML5 History API.
> - window.history || (window.history = {});
> - window.history.pushState || (window.history.pushState = function(){});
> - window.history.replaceState || (window.history.replaceState = function(){});
> -
> - = javascript_include_tag "jquery-1.6.1.min.js"
> - = javascript_include_tag "jquery.ui-1.8.1/jquery-ui-1.8.1.custom.min.js"
> - = javascript_include_tag "jquery.tmpl.min.js"
> - = javascript_include_tag "underscore-min.js"
> - = javascript_include_tag "backbone-min.js"
> -
> - = javascript_include_tag "application.js"
> - = javascript_include_tag "yetii-min.js"
> -
> - = javascript_include_tag "backbone/models.js"
> - = javascript_include_tag "backbone/views.js"
> - = javascript_include_tag "backbone/routers.js"
> - = javascript_include_tag "rails.js"
> - # = javascript_include_tag 'modernizr.js'
> - = csrf_meta_tag
> - = yield :scripts
> - %body{:class => "#{(["pools" ,"deployments", "instances"].include? controller_name) ? 'monitor' : 'administer'}" }
> - #primary-container
> -
> - %header#masthead
> - = render :partial => 'layouts/masthead'
> -
> - = render :partial => '/layouts/new_notification' if flash.present? or content_for?(:error_messages)
> -
> - %nav#primary
> - =render_navigation :level => 1
> -
> - #content
> - -# works with any 960 container (.container_16 or .container_24)
> - = yield
> - .clear
> - .clearfooter
> - %footer.standard
> - .container
> - #legal
> - %nav.footer
> - %span.copyright!= t('layout.copyright')
> diff --git a/src/app/views/permissions/_permissions.html.haml b/src/app/views/permissions/_permissions.html.haml
> index ec1b421..1ace6c8 100644
> --- a/src/app/views/permissions/_permissions.html.haml
> +++ b/src/app/views/permissions/_permissions.html.haml
> @@ -1,4 +1,4 @@
> -- content_for :form_header do
> +- content_for :permissions_form_header do
> - if not(@show_inherited or @show_global)&& check_privilege(Privilege::PERM_SET)
> %li= link_to t('permissions.form.grant_access'), new_permission_path(:permission_object_type => @permission_object.class.name, :permission_object_id => @permission_object.id, :path_prefix => @path_prefix, :use_tabs => @use_tabs ? @use_tabs : (@tabs ? 'yes' : 'no')), { :class => 'button primary', :id => 'new_permission_button'}
> %li= restful_submit_tag t('permissions.revoke_access'), "destroy", multi_destroy_permissions_path, 'DELETE', :id => 'revoke_button', :class => 'button danger'
> @@ -24,7 +24,10 @@
> %li= link_to t('permissions.inherited_access'), params.merge(:show_inherited => true, :show_global => false, :page => 1), { :class => 'button primary', :id => 'inherited_permission_button'}
> %li= link_to t('permissions.global_access'), params.merge(:show_inherited => false, :show_global => true, :page => 1), { :class => 'button primary', :id => 'global_permission_button'}
>
> -= filter_table(@permission_list_header, @permissions) do |permission|
> += filter_table(@permission_list_header,
> + @permissions,
> + :form_header => :permissions_form_header,
> + :filter_controls => :permissions_filter_controls) do |permission|
> %tr{:class => cycle('nostripe','stripe')}
> - if not(@show_inherited or @show_global)
> %td{:class => 'checkbox'}
> diff --git a/src/config/locales/en.yml b/src/config/locales/en.yml
> index c65eaea..41dfd6a 100644
> --- a/src/config/locales/en.yml
> +++ b/src/config/locales/en.yml
> @@ -348,25 +348,25 @@ en:
> permissions_for: Permissions for
> properties:
> properties_for: Properties for
> - name: "Name:"
> - status: "Status: "
> - public_addresses: "Public Addresses: "
> - private_adresses: "Private Addresses: "
> - assembly: "Assembly: "
> - provider: "Provider: "
> - architecture: "Architecture: "
> - memory: "Memory: "
> - storage: "Storage: "
> - instantiation_time: "Instantiation Time: "
> - current_alerts: "Current Alerts: "
> - console_connection: "Console Connection: "
> + name: "Name"
> + status: "Status"
> + public_addresses: "Public Addresses"
> + private_adresses: "Private Addresses"
> + assembly: "Assembly"
> + provider: "Provider"
> + architecture: "Architecture"
> + memory: "Memory"
> + storage: "Storage"
> + instantiation_time: "Instantiation Time"
> + current_alerts: "Current Alerts"
> + console_connection: "Console Connection"
> via_ssh: via SSH
> - ssh_key: "SSH key: "
> - ssh_key_name: "SSH key name: "
> + ssh_key: "SSH key"
> + ssh_key_name: "SSH key name"
> download: Download
> - owner: "Owner: "
> - shared_to: "Shared to: "
> - error: "Error: "
> + owner: "Owner"
> + shared_to: "Shared to"
> + error: "Error"
> n_a: "N/A"
> states:
> new: New
> diff --git a/src/features/catalogs.feature b/src/features/catalogs.feature
> index 4a57c0e..7baa763 100644
> --- a/src/features/catalogs.feature
> +++ b/src/features/catalogs.feature
> @@ -22,7 +22,7 @@ Feature: Manage Catalogs
> Given there is a "Marketing" catalog
> And I am on the catalogs page
> When I follow "Marketing"
> - Then I should see "Name: Marketing"
> + Then I should see "Marketing"
>
> Scenario: Edit a catalog
> Given there is a "Development" catalog
> diff --git a/src/features/deployment.feature b/src/features/deployment.feature
> index ef27b73..a058d78 100644
> --- a/src/features/deployment.feature
> +++ b/src/features/deployment.feature
> @@ -149,7 +149,6 @@ Feature: Manage Deployments
> And I should see "testdeployment"
> And I follow "Properties"
> Then I should see the following:
> - | Property Name | Value |
> | Pool | Default |
> | Owner | John testuser |
> | Name | testdeployment |
ACK
More information about the aeolus-devel
mailing list