Skip to content

Commit

Permalink
Fix for displaying the advanced search for list nodes only
Browse files Browse the repository at this point in the history
  • Loading branch information
lgalis committed May 1, 2017
1 parent db88a5b commit ae513eb
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/controllers/automation_manager_controller.rb
Expand Up @@ -262,6 +262,7 @@ def provider_node(id, model)
elsif x_active_tree == :configuration_scripts_tree
cs_provider_node(provider)
else
@show_adv_search = true
@no_checkboxes = true
options = {:model => "ManageIQ::Providers::AutomationManager::InventoryRootGroup",
:match_via_descendants => ConfiguredSystem,
Expand All @@ -279,6 +280,7 @@ def cs_provider_node(provider)
:match_via_descendants => ConfigurationScript,
:where_clause => ["manager_id IN (?)", provider.id],
:gtl_dbname => "automation_manager_configuration_scripts"}
@show_adv_search = true
process_show_list(options)
@right_cell_text = _("%{model} \"%{name}\"") % {:name => provider.name,
:model => "#{ui_lookup(:tables => "job_templates")} under "}
Expand All @@ -291,6 +293,7 @@ def inventory_group_node(id, model)
self.x_node = "root"
get_node_info("root")
else
@show_adv_search = true
options = {:model => "ConfiguredSystem",
:match_via_descendants => ConfiguredSystem,
:where_clause => ["inventory_root_group_id IN (?)", from_cid(@inventory_group_record.id)],
Expand All @@ -308,6 +311,7 @@ def inventory_group_node(id, model)

def configuration_scripts_list(id, model)
return configuration_script_node(id) if id
@show_adv_search = true
@listicon = "configuration_script"
if x_active_tree == :configuration_scripts_tree
options = {:model => model.to_s,
Expand All @@ -319,11 +323,13 @@ def configuration_scripts_list(id, model)

def configuration_script_node(id)
@record = @configuration_script_record = find_record(ManageIQ::Providers::AnsibleTower::AutomationManager::ConfigurationScript, id)
@show_adv_search = false
display_node(id, nil)
end

def default_node
return unless x_node == "root"
@show_adv_search = true
if x_active_tree == :automation_manager_providers_tree
options = {:model => "ManageIQ::Providers::AnsibleTower::AutomationManager",
:gtl_dbname => "automation_manager_providers"}
Expand Down

0 comments on commit ae513eb

Please sign in to comment.