Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change the paste image with a fonticon in custom button forms #4172

Merged
merged 1 commit into from Jun 20, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 10 additions & 13 deletions app/views/shared/buttons/_ab_form.html.haml
@@ -1,20 +1,17 @@
#ab_form
#policy_bar
- if @resolve[:uri] && Hash[*@resolve[:target_classes].flatten].invert[@resolve[:new][:target_class]] == @edit[:new][:target_class]

%li
- t = _("Paste object details for use in a Button.")
= link_to(image_tag(image_path('toolbars/paste.png'), :border => "0", :class => "", :alt => t),
{:action => "resolve", :button => "paste"},
"data-miq_sparkle_on" => true,
"data-miq_sparkle_off" => true,
:remote => true,
"data-method" => :post,
:title => t)
= link_to({:action => "resolve", :button => "paste"},
"data-miq_sparkle_on" => true,
"data-miq_sparkle_off" => true,
:remote => true,
"data-method" => :post,
:class => 'btn btn-default',
:title => _("Paste object details for use in a Button.")) do
%i.fa.fa-clipboard
- else
= image_tag(image_path('toolbars/paste.png'),
:class => "dimmed",
:title => _("Paste is not available, no object information has been copied from the Simulation screen"))
%button.btn.btn-default.disabled{:title => _("Paste is not available, no object information has been copied from the Simulation screen")}
%i.fa.fa-clipboard
= render :partial => "layouts/flash_msg"

#custom_button_tabs
Expand Down