Skip to content

Commit

Permalink
Enable copy of condition
Browse files Browse the repository at this point in the history
  • Loading branch information
PanSpagetka committed Oct 18, 2017
1 parent 96b74b9 commit b6965a5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
class ApplicationHelper::Button::ConditionPolicyCopy < ApplicationHelper::Button::Basic
needs :@sb

def role_allows_feature?
@view_context.x_active_tree != :condition_tree && role_allows?(:feature => self[:child_id])
end
end
2 changes: 1 addition & 1 deletion app/helpers/application_helper/toolbar/condition_center.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class ApplicationHelper::Toolbar::ConditionCenter < ApplicationHelper::Toolbar::
end,
t,
:url_parms => "?copy=true",
:klass => ApplicationHelper::Button::ConditionPolicy),
:klass => ApplicationHelper::Button::ConditionPolicyCopy),
button(
:condition_delete,
'pficon pficon-delete fa-lg',
Expand Down

0 comments on commit b6965a5

Please sign in to comment.