Class: Troo::Remote::List

Inherits:
Object
  • Object
show all
Includes:
Troo::RemoteModelHelpers
Defined in:
lib/troo/remote/list.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Troo::RemoteModelHelpers

included

Class Method Details

.by_board_idHash

Returns:

  • (Hash)


20
21
22
23
24
25
# File 'lib/troo/remote/list.rb', line 20

def by_board_id
  {
    endpoint: :lists_by_board_id,
    query:    { filter: :open }
  }
end

.by_list_idHash

Returns:

  • (Hash)


28
29
30
# File 'lib/troo/remote/list.rb', line 28

def by_list_id
  { endpoint: :list_by_id }
end

.remote_optionsHash

Returns:

  • (Hash)


15
16
17
# File 'lib/troo/remote/list.rb', line 15

def remote_options
  { mode: :list }
end

Instance Method Details

#adaptedHash

Returns:

  • (Hash)


44
45
46
47
48
49
50
51
52
# File 'lib/troo/remote/list.rb', line 44

def adapted
  {
    external_board_id: idBoard,
    external_id:       id,
    name:              name,
    position:          pos,
    closed:            closed
  }
end

#associationsArray

Returns:

  • (Array)


34
35
36
# File 'lib/troo/remote/list.rb', line 34

def associations
  []
end

#local_modelTroo::List

Returns:



39
40
41
# File 'lib/troo/remote/list.rb', line 39

def local_model
  Troo::List
end