Class: WorkItems::Widgets::Assignees

Inherits:
Base
  • Object
show all
Defined in:
app/models/work_items/widgets/assignees.rb

Instance Attribute Summary

Attributes inherited from Base

#widget_definition, #work_item

Class Method Summary collapse

Methods inherited from Base

api_symbol, callback_class, #initialize, process_quick_action_param, sync_data_callback_class, #sync_data_callback_class, type, #type

Constructor Details

This class inherits a constructor from WorkItems::Widgets::Base

Class Method Details

.can_invite_members?(user, resource_parent) ⇒ Boolean

Returns:

  • (Boolean)


16
17
18
# File 'app/models/work_items/widgets/assignees.rb', line 16

def self.can_invite_members?(user, resource_parent)
  Ability.allowed?(user, "admin_#{resource_parent.to_ability_name}_member".to_sym, resource_parent)
end

.quick_action_commandsObject



8
9
10
# File 'app/models/work_items/widgets/assignees.rb', line 8

def self.quick_action_commands
  [:assign, :unassign, :reassign]
end

.quick_action_paramsObject



12
13
14
# File 'app/models/work_items/widgets/assignees.rb', line 12

def self.quick_action_params
  [:assignee_ids]
end