module PIM::Services::TaskService

Public Instance Methods

__task_service() click to toggle source
# File services.rb, line 4115
def __task_service
  __service(:taskService)
end
add_comment_to_task(task_id, comment) click to toggle source
# File services.rb, line 4103
def add_comment_to_task task_id, comment
  __task_service.addComment(task_id.to_i, comment)
end
create_task(task_hash) click to toggle source
# File services.rb, line 4067
def create_task task_hash

  transition_hash = {}
  if task_hash[:transitions]
    task_hash[:transitions].each do |key, val|
      transition_hash[key.to_s] = val
    end
  end

  tags = task_hash[:tags] || []
  if task_hash[:tag]
    tags << task_hash[:tag]
  end

  items = task_hash[:items] ||= []
  custom_values = task_hash[:custom_values] || {}

  __task_service.createTodo(
    task_hash[:title],
    task_hash[:assignee],
    task_hash[:due_date],
    task_hash[:gathering],
    task_hash[:tasklist_title],
    task_hash[:notes],
    task_hash[:selection_id],
    java.util.HashMap.new(custom_values),
    java.util.LinkedHashMap.new(transition_hash),
    java.util.ArrayList.new(items),
    java.util.ArrayList.new(tags))

end
get_open_tasks_for_item(item_primary_key, tag) click to toggle source
# File services.rb, line 4107
def get_open_tasks_for_item item_primary_key, tag
  __task_service.findByItemPrimaryKey(item_primary_key, tag, com.lansa.lax.pim.TodoStatus::OPEN)
end
get_tasks_for_task_list(task_list_name, keywords: nil, author: nil, assignee: nil, status: :open, offset: nil, limit: 20, cursor: nil) click to toggle source
# File services.rb, line 4111
def get_tasks_for_task_list task_list_name, keywords: nil, author: nil, assignee: nil, status: :open, offset: nil, limit: 20, cursor: nil
  __task_service.findTasksForTaskList(task_list_name, keywords, author, assignee, status.to_s, offset, limit, cursor)
end
update_task(task) click to toggle source
# File services.rb, line 4099
def update_task task
  __task_service.save(task)
end