Class: TodoView

Inherits:
Object
  • Object
show all
Defined in:
lib/todo_view.rb

Instance Method Summary collapse

Constructor Details

#initialize(todo) ⇒ TodoView

Returns a new instance of TodoView.



4
5
6
# File 'lib/todo_view.rb', line 4

def initialize(todo)
  @todo = todo
end

Instance Method Details

#renderObject



8
9
10
11
12
# File 'lib/todo_view.rb', line 8

def render
  output = "#{formated_id} #{@todo.description}"
  output += tags
  mark_if_finished(output)
end