ada kolom is_current ga di model Quiz nya, liat di db/schema.rb,  
soalnya klo di searchlogic ga ada kondisi current deh.

 > #<Quiz id: nil, name: "ano", created_at: nil, updated_at: nil,  
is_current: true>
 >> cq.save
NoMethodError: undefined method `is_current_equals' for #<Quiz: 
0x10339e1b8>
kalau ga ada nama kolom tersebut ada kemungkinan error gara-gara  
is_current_equals nya bentrok sama searchlogic, dia ngira itu dynamic  
method punya nya searchlogic. jadi kalau pake searclogic harus hati- 
hati dalam penamaan attribut/kolom, jangan sama/mengandung dengan  
condition di bawah  (untuk comparisson, wildcard, sama boolean) :

COMPARISON_CONDITIONS   =       { :equals => [:is, :eq], :does_not_equal =>  
[:not_equal_to, :is_not, :not, :ne], :less_than =>  
[:lt, :before], :less_than_or_equal_to => [:lte], :greater_than =>  
[:gt, :after], :greater_than_or_equal_to => [:gte], }
WILDCARD_CONDITIONS     =       { :like => [:contains, :includes], :not_like => 
 
[], :begins_with => [:bw], :not_begin_with =>  
[:does_not_begin_with], :ends_with => [:ew], :not_end_with =>  
[:does_not_end_with]
BOOLEAN_CONDITIONS      =       { :null => [:nil], :not_null =>  
[:not_nil], :empty => [], :blank => [], :not_blank => [:present]
CONDITIONS      =       {}
PRIMARY_CONDITIONS      =       CONDITIONS.keys
ALIAS_CONDITIONS        =       CONDITIONS.values.flatten


moga2 membantu

visit my blog at http://bobbyprabowo.wordpress.com

On Nov 13, 2009, at 10:22 AM, Adinda Praditya wrote:

> Ternyata pake searchlogic pun nggak menyelesaikan masalah karena  
> akarnya
> nggak di situ. Ini pastie-nya:
>
> http://pastie.org/696747
>
> Ada yang bisa kasih saran?
>
> Dida
>
> 2009/11/13 Adinda Praditya <[email protected]>
>
> > Makasih atas solusi alternatif-nya. Kalo nggak salah selain lebih  
> mudah,
> > searchlogic juga lebih efisien query-nya ya..? Sekarang pas tau  
> find-nya
> > bermasalah gini, jadi panik juga, uda ditengah jalan gini.  
> Mudah2an gem ini
> > bisa membantu. Kalo ada yang mo ngecek ada sesuatu di OSX 10.6.2 +  
> ruby
> > 1.8.7 p174, mohon dishare juga di sini.
> >
> > Thanks,
> > Dida
> >
> > 2009/11/13 Bobby Adi Prabowo <[email protected]>
> >
> >
> >>
> >> kalau untuk perintah query buat nyari, saya menyarankan pake gem
> >> searchlogic, ga ribet, ga perlu pake sequel.
> >>
> >> example nya jadi gini
> >>
> >> Nation.country_like(params[:ctr_id]).
> >>
> >> atau
> >>
> >> Product.code_number_equals(params[:ctr_id])
> >>
> >> lebih enak.
> >>
> >> bisa dilihat di railscast nya, di
> >> http://railscasts.com/episodes/176-searchlogic
> >>
> >>
>
> [Non-text portions of this message have been removed]
>
> 



[Non-text portions of this message have been removed]



------------------------------------

ID-Ruby
Berdiskusi dan belajar bersama Bahasa Pemrograman Ruby, termasuk segala varian 
Ruby (JRuby, Rubinius, IronRuby, XRuby), dan program yang dibuat dengan Ruby 
(Ruby on Rails, JRuby on Rails, Merb)

<*> Follow Ruby Indonesia on Twitter
    http://twitter.com/rubyindonesia

<*> Kunjungi Situs Resmi Ruby Indonesia
    http://www.ruby-lang.org/id/

<*> Join Ruby Indonesia on Facebook
    http://rubyurl.com/QV48

<*> Join Ruby Indonesia on LinkedIn
    http://rubyurl.com/eh0i

<*> Kunjungi *arsip milis* id-ruby di
    http://groups.yahoo.com/group/id-ruby/messages
    http://www.mail-archive.com/[email protected]/
    http://rubyurl.com/Q8DD
    http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia

<*> Baca peraturan id-ruby sebelum posting
    http://rubyurl.com/gay1
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/id-ruby/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/id-ruby/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

Kirim email ke