Add real Gamegenre support
[cs356-p2-videostore.git] / app / models / game.rb
index 6c6b59b..15bf8e0 100644 (file)
@@ -2,6 +2,10 @@ class Game < Rentable
   validates_presence_of :game_genre
   validates_presence_of :platform
 
+  def genre
+    return Gamegenre.find(game_genre).name
+  end
+
   def calculated_price
     # FIXME: generate this based on day of week, newrelease
     day_of_week = Time.now.to_date.wday