Hello, I am using the "conditions for collection" method in the controller to add sql for security trimming. This works fine for a straight list, but when a user runs a search, it appears that the search form, which has some of the same params used for security trimming, will override the security settings in the conditions for collection method.
A few specific questions: 1. How can I *log* the sql statement used to get results for a search? Is there some method in the controller that is run last that I could put a Logger.Info statement to get an FinderMethods.to_sql ? 2. Is there any way to set a priority on the "conditions for collections" to override search params? 3. Does it matter if the "conditions for collection" is a sql string, vs an array or hash? I could use logic to better generate a search form that is essentially security trimmed, but will be tough, and would like to better understand how the "where" clauses in the conditions for collection are merged with the search where clauses. Thanks! Dennis -- You received this message because you are subscribed to the Google Groups "ActiveScaffold : Ruby on Rails Gem" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/activescaffold/9faac77a-77ef-4c71-8c3f-f5cec8f72f34n%40googlegroups.com.
