search for: productcategori

Displaying 6 results from an estimated 6 matches for "productcategori".

2012 Feb 02
3
MVC questions with rails
2008 May 08
1
Eager loading of association extensions
Hello all, Is it possible to do eager loading of association extensions? That is, the following code produces one SQL query: cat = ProductCategory.find(:first, :include => :pricing_rules) cat.pricing_rules But if in ProductCategory I have an association extension like this: has_many :pricing_rules do def applicable() find(:all).select(&:applicable?) end end the
2006 Apr 01
0
Newbie question: How to reference models in subdirectories
Hi, new to RoR I am probably going to embarrass myself now: I have models organised in subdirectories, i.e. models |--material |--product.rb |--cross-applications |--currency.rb When I try to reference another model within the same subdirectory, everything works fine, i.e. belongs_to :product_categories, :class_name => ''Material::ProductCategory"
2007 Nov 05
6
Strange wildcard problem
...there''s a non-indexed model called ProductTuple that''s got a supplier_id as well as a product_category_id and product_material_id as well as some other id fields that aren''t really important here. Thus, a ProductTuple has foreign key relationships to Suppliers and ProductCategories and ProductMaterials, but for ferret purposes just think of those foreign keys as what they are - ids (e.g. integers). The first model, Supplier, is ferret-indexed on several fields, such as the supplier name and supplier country, as well as the ''ferret_product_tuples'' n...
2005 Nov 01
5
Strange error(s) on windows only
I have some strange behaviour on Windows XP boxes (the same code on Linux doesn''t have the same behaviour). Ruby 1.8.2 and Rails 0.14.2. I have a single inheritance table nodes with a base class Node (acts_as_tree) and some subclasses such as PageNode and FolderNode. If I render the tree in an iframe in a set of iframes it doesn''t work, if I render it stand alone it works
2006 Nov 17
6
RESTful routes and resulting urls
if I have the following in my routes.rb: map.resources :product_categories it provides urls such as: /product_categories /product_categories/1 /product_categories/1;edit etc. and uses the ProductCategories controller. how can I keep the same controller (and model) but set up the resources so that I can have any abitrary url point to the existing controller, much like specifying the controller with the old style routes? -felix --~--~---------~--~----~------------~-------~--~----~ You received t...