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

[DARGA] ops_rbac - group detail - don't render trees that are not visible #13471

Merged
merged 14 commits into from
Jan 16, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
ops_rbac - make miq_bot happy
a long line, and a trailing _ in array assignment

(cherry picked from commit a7b219c)
himdel committed Jan 12, 2017
commit 0b4ba08d9b2d576023fadeb4546a4ed726deefc4
2 changes: 1 addition & 1 deletion app/controllers/ops_controller.rb
Original file line number Diff line number Diff line change
@@ -203,7 +203,7 @@ def change_tab(new_tab_id = nil)

def rbac_group_load_tab
tab_id = params[:tab_id]
_, group_id, _ = TreeBuilder.extract_node_model_and_id(x_node)
_, group_id = TreeBuilder.extract_node_model_and_id(x_node)
@sb[:active_rbac_group_tab] = tab_id

rbac_group_get_details(group_id)
8 changes: 7 additions & 1 deletion app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
@@ -1338,7 +1338,13 @@ def miq_tab_header(id, active = nil, options = {}, &_block)

def miq_tab_content(id, active = nil, options = {}, &_block)
lazy = options[:lazy] && active != id
content_tag(:div, :id => id, :class => "tab-pane #{options[:class]} #{active == id ? 'active' : ''} #{lazy ? 'lazy' : ''}") do

classname = %w(tab-pane)
classname << options[:class] if options[:class]
classname << 'active' if active == id
classname << 'lazy' if lazy

content_tag(:div, :id => id, :class => classname.join(' ')) do
yield unless lazy
end
end