Class: CreateProjectScreen

Inherits:
Screen
  • Object
show all
Defined in:
lib/kale/ui.rb

Instance Method Summary collapse

Methods inherited from Screen

#initialize

Constructor Details

This class inherits a constructor from Screen

Instance Method Details

#handle_menuObject



115
116
117
118
119
120
121
122
123
124
125
# File 'lib/kale/ui.rb', line 115

def handle_menu
  name = gets.chomp
  
  system "clear"

  puts "Type the rate per hour for this project (ex: 60)"
  rate = gets.chomp

  @@project = Project.create(:name => name, :rate_per_hour => rate)
  ShowProjectScreen.new
end

#infoObject



107
108
109
# File 'lib/kale/ui.rb', line 107

def info
  puts ""
end


111
112
113
# File 'lib/kale/ui.rb', line 111

def menu
  puts "Type the name of your new project"
end