Skip to content

Commit

Permalink
Merge pull request #7127 from skateman/noedit-features-tree-rename
Browse files Browse the repository at this point in the history
Rename the features_tree when not in edit mode under Access Control
  • Loading branch information
mzazrivec authored Jun 15, 2020
2 parents 1db1f05 + b3ca1f7 commit cd41c79
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/controllers/ops_controller/ops_rbac.rb
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,8 @@ def rbac_role_get_details(id)
def build_rbac_feature_tree
@role = @sb[:typ] == "copy" ? @record.dup : @record if @role.nil? # if on edit screen use @record
@role.miq_product_features = @record.miq_product_features if @sb[:typ] == "copy"
TreeBuilderOpsRbacFeatures.new("features_tree", @sb, true, :role => @role, :editable => @edit.present?)
# The edit/noedit tree should have a different name due to a collision between RJS and Redux
TreeBuilderOpsRbacFeatures.new(@edit.present? ? "features_tree" : "features_tree_noedit", @sb, true, :role => @role, :editable => @edit.present?)
end

# Set form variables for user edit
Expand Down

0 comments on commit cd41c79

Please sign in to comment.