Browse files

updated model to work if search is installed

  • Loading branch information...
1 parent b2a43f9 commit 58d7f3f72d33681f55ce399fb3ff126a095a10b9 @byropig committed Feb 8, 2012
Showing with 5 additions and 1 deletion.
  1. +5 −1 app/models/product.rb
View
6 app/models/product.rb
@@ -28,7 +28,11 @@ class Product < ActiveRecord::Base
has_and_belongs_to_many :categories
has_many :line_items
has_many :variants
-
+
+ def title
+ name
+ end
+
def validate_category
categories.each do |category|
if category.children.present?

0 comments on commit 58d7f3f

Please sign in to comment.