class ShowSessionsForProjectScreen

Public Instance Methods

handle_menu() click to toggle source
# File lib/kale/ui.rb, line 224
def handle_menu
  answer = gets.chomp

  if answer == "1"
    ShowProjectScreen.new
  end
end
info() click to toggle source
# File lib/kale/ui.rb, line 201
def info
  show_project_heading

  puts

  if @@project.sessions.length > 0
    puts "## Work Completed\n"
    @@project.sessions.each do |s|
      puts "#{s.description} \t #{seconds_to_hms(s.elapsed_time)} \t #{s.earned}"
    end

    puts "\n## Total"
    puts "#{seconds_to_hms(@@project.total_time)} \t #{@@project.total_earned}"
  else
    puts "You haven't worked on this project yet."
  end
end
menu() click to toggle source
Calls superclass method Screen#menu