Class: TrelloCli::Formatters::CardMove

Inherits:
Base
  • Object
show all
Defined in:
lib/trello_cli/formatters/card_move.rb

Instance Method Summary collapse

Methods inherited from Base

#initialize, #output, #to_json

Constructor Details

This class inherits a constructor from TrelloCli::Formatters::Base

Instance Method Details

#to_legacyObject



4
5
6
7
8
9
10
# File 'lib/trello_cli/formatters/card_move.rb', line 4

def to_legacy
  if data[:success]
    "Card #{data[:card_id]} was succesfully moved to #{data[:list_id]}.\n"
  else
    "Error moving card."
  end
end

#to_tsvObject



12
13
14
# File 'lib/trello_cli/formatters/card_move.rb', line 12

def to_tsv
  [data[:success], data[:card_id], data[:list_id]].join("\t") + "\n"
end