petehamilton / citier

CITIER (Class Inheritance & Table Inheritance Embeddings for Rails) is a solution for simple Multiple Class Inheritance in Rails.
88 stars 24 forks source link

Weirdness. Why does loading the product effect my second identical call to Book? #17

Open morgz opened 13 years ago

morgz commented 13 years ago

ruby-1.9.2-p0 > Book.first.respond_to?(:site_id) citier -> Root Class citier -> table_name -> products citier -> Non Root Class citier -> table_name -> books citier -> tablename (view) -> view_books => false ruby-1.9.2-p0 > Product.first.respond_to?(:site_id) => true ruby-1.9.2-p0 > Book.first.respond_to?(:site_id) => true

educobuci commented 13 years ago

Same here. I'm going to take a look at the problem and eventually pull a path ;)

morgz commented 13 years ago

Cool. I think this may have been because I didn't drop and then create my views after adding site_id. WIll investigate today.

Also dropping views isn't working for me right now on mysql as it's create tables called 'view_books' instead of views... will be investigating and possibly opening issues into this too.