From: Jiri Tomasek <jtomasek(a)redhat.com>
---
src/app/stylesheets/custom.scss | 19 ----------
src/app/stylesheets/layout.scss | 10 +++++-
src/app/views/catalog_entries/_from_url.html.haml | 6 ++--
src/app/views/catalog_entries/_new.html.haml | 36 +++++++++++---------
.../catalog_entries/_new_from_image.html.haml | 15 ++++++++
src/app/views/catalog_entries/_upload.html.haml | 6 ++--
src/app/views/images/overview.html.haml | 20 +++++-----
src/config/locales/en.yml | 1 +
8 files changed, 61 insertions(+), 52 deletions(-)
diff --git a/src/app/stylesheets/custom.scss b/src/app/stylesheets/custom.scss
index f8f1cc8..4f72278 100644
--- a/src/app/stylesheets/custom.scss
+++ b/src/app/stylesheets/custom.scss
@@ -217,25 +217,6 @@ form.generic section.services {
}
}
-.instances_list {
- li {
- list-style-type: none;
- }
-
- .state {
- font-weight: bold;
- }
-
- li.instance {
- margin-top: 1em;
- font-weight: bold;
-
- ul {
- font-weight: normal;
- }
- }
-}
-
.catalog_deployments_and_images{
color: #606060;
position: relative;
diff --git a/src/app/stylesheets/layout.scss b/src/app/stylesheets/layout.scss
index 1dd93bc..065f570 100644
--- a/src/app/stylesheets/layout.scss
+++ b/src/app/stylesheets/layout.scss
@@ -2440,11 +2440,15 @@ ul.instances-array{
width:100%;
text-align:left;
margin: 0px !important;
- a {
+ a{
padding: 7px 10px 7px 10px;
display: block;
text-decoration: none;
}
+ div.catalog_with_checkbox{
+ padding: 7px 10px;
+ input[type="checkbox"]{margin: 0px; padding: 0px; float: right;}
+ }
&:hover{
background:#C4E0F0;
&:first-child{ -webkit-border-radius: 4px 0px 0px 0px; -moz-border-radius:
4px 0px 0px 0px; border-radius: 4px 0px 0px 0px; }
@@ -3024,6 +3028,10 @@ body.administer form.generic{
width: 100px;
}
+ span.text_instead_input{
+ display: inline-block;
+ padding: 6px;
+ }
}
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
diff --git a/src/app/views/catalog_entries/_from_url.html.haml
b/src/app/views/catalog_entries/_from_url.html.haml
index 4d9b583..69428c4 100644
--- a/src/app/views/catalog_entries/_from_url.html.haml
+++ b/src/app/views/catalog_entries/_from_url.html.haml
@@ -4,7 +4,7 @@
%fieldset
%p
= form.label :catalog_id, t('catalog_entries.form.catalog')
- = @catalog.name
+ %span.text_instead_input= @catalog.name
.clear
=form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
%fieldset
@@ -22,6 +22,6 @@
= check_box_tag(:edit_xml, true, false)
= label_tag :edit_xml, t('catalog_entries.form.edit_xml_after_save')
- %fieldset.options
+ %fieldset.align-center
= link_to t('cancel'), catalog_path(@catalog), :class => 'button
danger'
- = submit_tag t('save'), :name => 'save', :class =>
'button', :id => 'save_button'
+ = submit_tag t('save'), :name => 'save', :class => 'button
primary', :id => 'save_button'
diff --git a/src/app/views/catalog_entries/_new.html.haml
b/src/app/views/catalog_entries/_new.html.haml
index c66ca64..6b0fcf2 100644
--- a/src/app/views/catalog_entries/_new.html.haml
+++ b/src/app/views/catalog_entries/_new.html.haml
@@ -1,21 +1,25 @@
-= render :partial => 'section_header'
+%header.admin-page-header
+ %h1.catalog_entries=t'catalog_entries.new.add_catalog_entry'
+ #obj_actions
+ =t'users.return_to'
+ = link_to t('catalog_entries.new.catalog_detail', :name => @catalog.name
), catalog_path(@catalog), :class => 'rounded-link'
%section.admin-content-section
- %header
- %h2=t'catalog_entries.new.add_catalog_entry'
+ .content.buildpush
+ .centered
+ %p.description.align-center
+ %strong= t'.choose_option_to_upload'
-%section.admin-content-section.image-upload
- %p.description=t'.choose_option_to_upload'
+ %nav#image-upload-tabs.faceted
+ %ul.tabs
+ %li
+ = link_to t('catalog_entries.new.upload'),
new_catalog_catalog_entry_path(@catalog), :id => "upload", :class =>
"#{'active' if @form_option == 'upload'}"
+ %li
+ = link_to t('catalog_entries.new.from_url'),
new_catalog_catalog_entry_path(@catalog, :from_url => true), :id =>
"from_url", :class => "#{'active' if @form_option ==
'from_url'}"
+ .clear
- %nav#image-upload-tabs.faceted
- %ul.tabs
- %li
- = link_to t('catalog_entries.new.upload'),
new_catalog_catalog_entry_path(@catalog), :id => "upload", :class =>
"#{'selected' if @form_option == 'upload'}"
- %li
- = link_to t('catalog_entries.new.from_url'),
new_catalog_catalog_entry_path(@catalog, :from_url => true), :id =>
"from_url", :class => "#{'selected' if @form_option ==
'from_url'}"
-
- .form_option
- = render :partial => @form_option
+ .form_option
+ = render :partial => @form_option
:javascript
$(document).ready(function() {
@@ -48,8 +52,8 @@
});
function change_selected($add_selected, $remove_selected){
- $remove_selected.removeClass('selected');
- $add_selected.addClass('selected');
+ $remove_selected.removeClass('active');
+ $add_selected.addClass('active');
}
function read_name_field() {
diff --git a/src/app/views/catalog_entries/_new_from_image.html.haml
b/src/app/views/catalog_entries/_new_from_image.html.haml
index fd20f3c..f546698 100644
--- a/src/app/views/catalog_entries/_new_from_image.html.haml
+++ b/src/app/views/catalog_entries/_new_from_image.html.haml
@@ -18,8 +18,23 @@
%div
= form.label :catalog_id, t('catalog_entries.form.catalog')
= form.select :catalog_id, @catalogs.collect{|c| [c.name, c.id]}
+ %span.text_instead_input= "Catalog1"
+ %span.catalog_link
+  
+ %div.catalog_list
+ %ul.more
+ - @catalogs.each do |catalog|
+ %li.catalog
+ .catalog_with_checkbox
+ = check_box_tag :catalog_ids
+ = catalog.name
+ .clear
.clear
.centered
%fieldset.align-center
= link_to "#{t'catalog_entries.form.cancel'}", catalogs_path,
:class => 'button danger'
= submit_tag "#{t'catalog_entries.form.save'}", :name =>
'save', :class => 'button primary', :id => 'save_button'
+
+:javascript
+ $(document).ready(function(){
+ });
diff --git a/src/app/views/catalog_entries/_upload.html.haml
b/src/app/views/catalog_entries/_upload.html.haml
index 73c7d28..903e01f 100644
--- a/src/app/views/catalog_entries/_upload.html.haml
+++ b/src/app/views/catalog_entries/_upload.html.haml
@@ -4,7 +4,7 @@
%fieldset
%p
= form.label :catalog_id, t('catalog_entries.form.catalog')
- = @catalog.name
+ %span.text_instead_input= @catalog.name
.clear
= form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
%fieldset
@@ -22,6 +22,6 @@
= check_box_tag(:edit_xml, true, false)
= label_tag :edit_xml, t('catalog_entries.form.edit_xml_after_save')
- %fieldset.options
+ %fieldset.align-center
= link_to t('cancel'), catalog_path(@catalog), :class => 'button
danger'
- = submit_tag t('save'), :name => 'save', :class =>
'button', :id => 'save_button'
+ = submit_tag t('save'), :name => 'save', :class => 'button
primary', :id => 'save_button'
diff --git a/src/app/views/images/overview.html.haml
b/src/app/views/images/overview.html.haml
index bf920c3..4e70112 100644
--- a/src/app/views/images/overview.html.haml
+++ b/src/app/views/images/overview.html.haml
@@ -12,14 +12,14 @@
= hidden_field_tag :name, @name
%input{ :type => :hidden, :name => :image_xml, :value => @xml}
- .lefted.image-upload-overview
- %h2= t('.valid_image')
- %p.description= t('.description', :name => @name)
+ .lefted.image-upload-overview
+ %h2= t('.valid_image')
+ %p.description= t('.description', :name => @name)
- %fieldset.align-center
- = check_box_tag :make_deployable, 1, true
- = label_tag :make_deployable, t('.make_deployable', :name => @name)
- .centered
- %fieldset.align-center
- = submit_tag t('.back'), :name => 'back', :id =>
'back_button', :class => 'button'
- = submit_tag t('.save_template'), :name => 'save', :id =>
'save_button', :class => 'button primary'
+ %fieldset.align-center
+ = check_box_tag :make_deployable, 1, true
+ = label_tag :make_deployable, t('.make_deployable', :name => @name)
+ .centered
+ %fieldset.align-center
+ = submit_tag t('.back'), :name => 'back', :id =>
'back_button', :class => 'button'
+ = submit_tag t('.save_template'), :name => 'save', :id =>
'save_button', :class => 'button primary'
diff --git a/src/config/locales/en.yml b/src/config/locales/en.yml
index b6dc774..e7b596e 100644
--- a/src/config/locales/en.yml
+++ b/src/config/locales/en.yml
@@ -601,6 +601,7 @@ en:
upload: Upload
from_url: From URL
hw_profile: Default Hardware Profile
+ catalog_detail: "%{name} Catalog"
new_from_image:
catalog_entry_name: "%{name}"
title: Create Application Blueprint
--
1.7.7.3