Search Results

Search found 1 results on 1 pages for 'r yanchuleff'.

Page 1/1 | 1 

  • Rails 3 Abstract Class vs Inherited Class

    - by R. Yanchuleff
    In my rails 3 model, I have two classes: Product, Service. I want both to be of type InventoryItem because I have another model called Store and Store has_many :InventoryItems This is what I'm trying to get to, but I'm not sure how to model this in my InventoryItem model and my Product and Service models. Should InventoryItem just be a parent class that Product and Service inherit from, or should InventoryItem be modeled as a class abstract of which Product and Service extend from. Thanks in advance for the advice!

    Read the article

1