On Tue, May 22, 2007 at 04:18:05AM +0200, Aryk G. wrote:
I upgraded to the latest version. Everything works great, it even
queries the results more efficiently. Great job!
I don’t see any method for total_hits for multi_search. The
model.total_hits works fine when you are just searching on one model.
Any idea how to do only total_hits with multi_search?
That was indeed missing. I just committed a fix for this to trunk. now
you can give total_hits additional model classes with the :models
A.total_hits(query, :models => [B, C])
Also, I added a little fix to multi_search to allow users to include
associations even if it works on one model but not the other. Here is
what the code looks like. It currently works great on one-level include
and somewhat hacky on two-level associations. Maybe you can find some
use for it?
thanks, I integrated this
webit! Gesellschaft für neue Medien mbH
Schnorrstraße 76 | 01069 Dresden
Telefon +49 351 46766-0 | Telefax +49 351 46766-66
[email protected] | www.webit.de
Amtsgericht Dresden | HRB 15422
GF Sven Haubold, Hagen Malessa