Skip to content

Commit

Permalink
Merge pull request #5384 from skateman/notify-child-services
Browse files Browse the repository at this point in the history
Fix the access to child services from parents under My Services

(cherry picked from commit 643b1da)

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1693749
  • Loading branch information
himdel authored and simaishi committed Mar 29, 2019
1 parent 6fce3b0 commit b0f0e2b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions app/assets/javascripts/miq_tree.js
Expand Up @@ -83,6 +83,11 @@ function miqOnClickSelectTreeNode(id) {
miqJqueryRequest(url, {beforeSend: true});
}

function miqTreeSelect(key) {
var url = '/' + ManageIQ.controller + '/tree_select/?id=' + encodeURIComponent(key.split('__')[0]);
miqJqueryRequest(url, {beforeSend: true});
}

// Activate and focus on a node within a tree given the node's key
function miqTreeActivateNode(tree, key) {
miqSparkle(true);
Expand Down
2 changes: 1 addition & 1 deletion app/views/service/_svcs_show.html.haml
Expand Up @@ -27,7 +27,7 @@
%table.table.table-striped.table-bordered.table-hover
%tbody
- child_services.sort_by { |o| o.name.downcase }.each do |s|
%tr{:onclick => "miqTreeActivateNode('svcs_tree', 's-#{s.id}');", :title => _("View this Service")}
%tr{:onclick => "miqTreeSelect('s-#{s.id}');", :title => _("View this Service")}
%td.table-view-pf-select
%i.pficon.pficon-service
%td
Expand Down

0 comments on commit b0f0e2b

Please sign in to comment.