Hola que tal, es posible en rails hacer un consulta por medio del AR y usar en el include scopes o funciones del modelo, en vez de las relaciones has_many?? Ejemplo :controller objetoSupremo = Supremo.find(:all, :include => [objeto_no_tan_supremo(nombre)] ) donde objeto_no_tan_supremo, sea la funcion del modelo objetoSupremo o un alcance y a este se le puedan enviar parametros??
on 2012-03-08 19:46
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.