Halo bry,
Sory kepencet jadi double post.
Kalau saya lihat dari error nya tuh :
linux:/home/ br # rails -v
/usr/local/lib/ ruby/site_ ruby/
1.8/rubygems. rb:827:in `report_activate_ error': Could not find RubyGem rails
(>= 0) (Gem::LoadError)
from /usr/local/lib/ ruby/site_ ruby/1.8/ rubygems. rb:261:in `activate'
from /usr/local/lib/ ruby/site_ ruby/1.8/ rubygems. rb:68:in `gem'
from /usr/local/bin/ rails:18
Kaya nya kamu belum install rails nya deh. coba install dulu aja railsnya.
"Coba Yahoo! Mail baru yang LEBIH CEPAT. Rasakan bedanya sekarang!
http://id.mail.yahoo.com"
[Non-text portions of this message have been removed]
sorry for late reply,
kemarin saya uninstall semua, dan install ulang :)
sekarang sudah ga ada error, tp ada satu dependencies yang gak ketemu waktu
mau run script/server : "openssl"
*rails/railties/lib/initializer.rb:229:in `require_frameworks': no such file
to load -- openssl (RuntimeError)
*
Padahal openssl udah ada di mesin saya (/usr/bin/openssl). agak sulit karena
saya install di secure server yg offline jd gak bisa pake apt-get.
need advise ... :)
thanks.
bry
2009/11/17 Bobby Adi Prabowo <tigaenamb@...>
>
>
> wah bener-bener unik, bisa ampe kaya gitu. baru liat ada kasus kaya gitu.
>
>
> On Nov 17, 2009, at 10:47 PM, Rafeequl Rahman wrote:
>
> > Halo bry,
> >
> > install railsnya gimana ?
> > sudo gem install rails ?
> >
> >
> > On Nov 17, 2009, at 6:10 PM, b.r.y wrote:
> >
> >> hi semua...,
> >> Sorry jd dobel post .. gak sengaja ke-reply.
> >>
> >> newbie numpang nanya .. :)
> >>
> >> Barusan saya coba install ruby, rails, rake, sama rubygems di mesin
> linux :
> >> SUSE Linux Enterprise Server 9 (i586)
> >>
> >> tapi keluar error waktu execute script/server, ternyata waktu saya cek
> >> satu-persatu aplikasi yg telah saya install ada beberapa error yg muncul
> :
> >>
> >> linux:/home/br # ruby -v
> >> ruby 1.8.7 (2008-05-31 patchlevel 0) [i686-linux]
> >>
> >> linux:/home/br # rails -v
> >> /usr/local/lib/ruby/site_ruby/
> >> 1.8/rubygems.rb:827:in `report_activate_error': Could not find RubyGem
> rails
> >> (>= 0) (Gem::LoadError)
> >> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
> >> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
> >> from /usr/local/bin/rails:18
> >>
> >> linux:/home/br # rake -v
> >> /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
> >> `report_activate_error': Could not find RubyGem rake (>= 0)
> (Gem::LoadError)
> >> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
> >> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
> >> from /usr/local/bin/rake:18
> >>
> >> linux:/home/br # gem -v
> >> 1.3.5
> >>
> >> Kira-kira apa yg harus dilakukan selanjutnya ya..?
> >>
> >> thanks.
> >> brian
> >>
> >> [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)
> >
> > http://rubyurl.com/Q8DD
> > http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
> >
> >
> >
> >
>
>
>
[Non-text portions of this message have been removed]
wah bener-bener unik, bisa ampe kaya gitu. baru liat ada kasus kaya gitu.
On Nov 17, 2009, at 10:47 PM, Rafeequl Rahman wrote:
> Halo bry,
>
> install railsnya gimana ?
> sudo gem install rails ?
>
>
> On Nov 17, 2009, at 6:10 PM, b.r.y wrote:
>
>> hi semua...,
>> Sorry jd dobel post .. gak sengaja ke-reply.
>>
>> newbie numpang nanya .. :)
>>
>> Barusan saya coba install ruby, rails, rake, sama rubygems di mesin linux :
>> SUSE Linux Enterprise Server 9 (i586)
>>
>> tapi keluar error waktu execute script/server, ternyata waktu saya cek
>> satu-persatu aplikasi yg telah saya install ada beberapa error yg muncul :
>>
>> linux:/home/br # ruby -v
>> ruby 1.8.7 (2008-05-31 patchlevel 0) [i686-linux]
>>
>> linux:/home/br # rails -v
>> /usr/local/lib/ruby/site_ruby/
>> 1.8/rubygems.rb:827:in `report_activate_error': Could not find RubyGem rails
>> (>= 0) (Gem::LoadError)
>> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
>> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
>> from /usr/local/bin/rails:18
>>
>> linux:/home/br # rake -v
>> /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
>> `report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
>> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
>> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
>> from /usr/local/bin/rake:18
>>
>> linux:/home/br # gem -v
>> 1.3.5
>>
>> Kira-kira apa yg harus dilakukan selanjutnya ya..?
>>
>> thanks.
>> brian
>>
>> [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)
>
> http://rubyurl.com/Q8DD
> http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
>
>
>
>
Halo bry,
install railsnya gimana ?
sudo gem install rails ?
On Nov 17, 2009, at 6:10 PM, b.r.y wrote:
> hi semua...,
> Sorry jd dobel post .. gak sengaja ke-reply.
>
> newbie numpang nanya .. :)
>
> Barusan saya coba install ruby, rails, rake, sama rubygems di mesin linux :
> SUSE Linux Enterprise Server 9 (i586)
>
> tapi keluar error waktu execute script/server, ternyata waktu saya cek
> satu-persatu aplikasi yg telah saya install ada beberapa error yg muncul :
>
> linux:/home/br # ruby -v
> ruby 1.8.7 (2008-05-31 patchlevel 0) [i686-linux]
>
> linux:/home/br # rails -v
> /usr/local/lib/ruby/site_ruby/
> 1.8/rubygems.rb:827:in `report_activate_error': Could not find RubyGem rails
> (>= 0) (Gem::LoadError)
> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
> from /usr/local/bin/rails:18
>
> linux:/home/br # rake -v
> /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
> `report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
> from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
> from /usr/local/bin/rake:18
>
> linux:/home/br # gem -v
> 1.3.5
>
> Kira-kira apa yg harus dilakukan selanjutnya ya..?
>
> thanks.
> brian
>
> [Non-text portions of this message have been removed]
>
>
[Non-text portions of this message have been removed]
hi semua...,
Sorry jd dobel post .. gak sengaja ke-reply.
newbie numpang nanya .. :)
Barusan saya coba install ruby, rails, rake, sama rubygems di mesin linux :
SUSE Linux Enterprise Server 9 (i586)
tapi keluar error waktu execute script/server, ternyata waktu saya cek
satu-persatu aplikasi yg telah saya install ada beberapa error yg muncul :
linux:/home/br # ruby -v
ruby 1.8.7 (2008-05-31 patchlevel 0) [i686-linux]
linux:/home/br # rails -v
/usr/local/lib/ruby/site_ruby/
1.8/rubygems.rb:827:in `report_activate_error': Could not find RubyGem rails
(>= 0) (Gem::LoadError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
from /usr/local/bin/rails:18
linux:/home/br # rake -v
/usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
`report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
from /usr/local/bin/rake:18
linux:/home/br # gem -v
1.3.5
Kira-kira apa yg harus dilakukan selanjutnya ya..?
thanks.
brian
[Non-text portions of this message have been removed]
hi semua...,
newbie numpang nanya .. :)
Barusan saya coba install ruby, rails, rake, sama rubygems di mesin linux :
SUSE Linux Enterprise Server 9 (i586)
tapi keluar error waktu execute script/server, ternyata waktu saya cek
satu-persatu aplikasi yg telah saya install ada beberapa error yg muncul :
linux:/home/br # ruby -v
ruby 1.8.7 (2008-05-31 patchlevel 0) [i686-linux]
linux:/home/br # rails -v
/usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
`report_activate_error': Could not find RubyGem rails (>= 0)
(Gem::LoadError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
from /usr/local/bin/rails:18
linux:/home/br # rake -v
/usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:827:in
`report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:261:in `activate'
from /usr/local/lib/ruby/site_ruby/1.8/rubygems.rb:68:in `gem'
from /usr/local/bin/rake:18
linux:/home/br # gem -v
1.3.5
Kira-kira apa yg harus dilakukan selanjutnya ya..?
thanks.
brian
[Non-text portions of this message have been removed]
maksud saya attribut is_current nya itu bentrok sama conditionsnya
searchlogic nya, coba diganti namanya / dihapus.
On Nov 13, 2009, at 1:11 PM, Aditya Agustyana wrote:
> oh Quiz itu hasil intercept ruby-debugger, atau hasil Ruby script/
> console ?
>
> 2009/11/13 Adinda Praditya <apraditya@...>
>
>>
>>
>> Ada, khan uda kliatan dr sini:
>>
>>
>> #<Quiz id: nil, name: "ano", created_at: nil, updated_at: nil,
>> is_current:
>> true>
>>
>> makasi informasi tambahannya
>>
>> dida
>>
>>
>> On Friday, November 13, 2009, Bobby Adi Prabowo
>> <tigaenamb@...<tigaenamb%40gmail.com>>
>> wrote:
>>> 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 <apraditya@... <apraditya
>>>> %40gmail.com>
>>>
>>>>
>>>>> 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 <tigaenamb@...<tigaenamb
>>>>> %40gmail.com>
>>>
>>>>>
>>>>>
>>>>>>
>>>>>> 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)
>>>
>>> http://rubyurl.com/Q8DD
>>> http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
>>>
>>>
>>>
>>>
>>>
>>
>>
>
>
>
> --
> blog : http://adityakircon.blogsome.com
> ym : kirconboy
> skype : adit_skype
>
> Be Nice. Treat others with the same respect you'd want them to treat
> you.
> We're all here to learn together. Be tolerant of others who may not
> know
> everything you know. BRING YOUR SENSE OF HUMOR (stackoverflow.com)
>
>
> [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)
>
> http://rubyurl.com/Q8DD
> http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
>
>
>
>
yup, sebelumnya saya pakai acts_as_tree tapi sekarang saya menggunakan STI,
rasanya bener aja :p
class Location < ActiveRecord::Base
end
class Branch < Location
has_many :regions, :foreign_key => :parent_id # parent_id sebelumnya dipakai
buat acts_as_tree
end
class Region < Location
belongs_to :branch, :foreign_key => :parent_id
has_many :streets, :foreign_key => :parent_id
end
class Street < Location
belongs_to :region, :foreign_key => :parent_id
has_many :customers
end
cheers...
(\ /)
(O.o)
(> <)
This is Bunny. Copy Bunny into your signature to help him on his way to
world domination.
________________________________
From: Reza Primardiansyah <reza.primardiansyah@...>
To: id-ruby@yahoogroups.com
Sent: Fri, November 13, 2009 3:54:12 PM
Subject: Re: [id-ruby] acts as tree atau STI ?
Pertanyaan utamanya lebih pada "apakah memang bisa dikelompokkan jadi satu
entitas besar (superclass)? Apa nama superclass itu?"
Saya sendiri membuat perjenjangan wilayah administratif (Propinsi,
Kabupaten, dst) pakai STI *dan* acts_as_tree (sedang nimbang2 pakai
ancestry).
class Location < AR::Base
acts_as_tree
end
class Propinsi < Location
has_many :kabupaten2 #mbuat aturan pluralisasi sendiri di
config/environment.rb
end
class Kabupaten < Location
belongs_to :propinsi
end
Hope this helps
2009/11/12 rahmat budiharso <r_budiharso@...>
>
>
> saya punya format data seperti ini:
>
> branch has many regions
>
> region belongs to branch
> region has many streets
>
> street belongs to region
> street has many customers
>
> atribut untuk branch, region n street sama (hanya code n name), nah
> kira-kira lebih baik pakai plugin acts_as_tree atau single table inheritance
> ?
>
> makasih...
>
> (\ /)
> (O.o)
> (> <)
>
> This is Bunny. Copy Bunny into your signature to help him on his way to
> world domination.
>
> [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)
http://rubyurl.com/Q8DDhttp://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
[Non-text portions of this message have been removed]
Pertanyaan utamanya lebih pada "apakah memang bisa dikelompokkan jadi satu
entitas besar (superclass)? Apa nama superclass itu?"
Saya sendiri membuat perjenjangan wilayah administratif (Propinsi,
Kabupaten, dst) pakai STI *dan* acts_as_tree (sedang nimbang2 pakai
ancestry).
class Location < AR::Base
acts_as_tree
end
class Propinsi < Location
has_many :kabupaten2 #mbuat aturan pluralisasi sendiri di
config/environment.rb
end
class Kabupaten < Location
belongs_to :propinsi
end
Hope this helps
2009/11/12 rahmat budiharso <r_budiharso@...>
>
>
> saya punya format data seperti ini:
>
> branch has many regions
>
> region belongs to branch
> region has many streets
>
> street belongs to region
> street has many customers
>
> atribut untuk branch, region n street sama (hanya code n name), nah
> kira-kira lebih baik pakai plugin acts_as_tree atau single table inheritance
> ?
>
> makasih...
>
> (\ /)
> (O.o)
> (> <)
>
> This is Bunny. Copy Bunny into your signature to help him on his way to
> world domination.
>
> [Non-text portions of this message have been removed]
>
>
>
[Non-text portions of this message have been removed]
Ada, khan uda kliatan dr sini:
#<Quiz id: nil, name: "ano", created_at: nil, updated_at: nil, is_current: true>
makasi informasi tambahannya
dida
On Friday, November 13, 2009, Bobby Adi Prabowo <tigaenamb@...> wrote:
> 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 <apraditya@...>
>>
>> > 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 <tigaenamb@...>
>> >
>> >
>> >>
>> >> 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)
>
> Â Â http://rubyurl.com/Q8DD
> Â Â http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
>
>
>
>
>
pastikan apakah class User adalah turunan AR, mungkin ada yg nge-override
class tsb di tengah jalan
coba aja di inspeksi pake ruby-debugger gem
nanti di codenya, taro statement debugger di atas User.find
nanti debugger akan meng-intercept kode tsb, sehingga kita bisa
menginspeksinya via console
di console tinggal ketik User.inspect
class turunan AR, kalo diinspect akan menghasilkan kira2 yg seperti ini
User(id: integer, login: string, name: string, email: string,
crypted_password: string, salt: string, created_at: datetime, updated_at:
datetime, remember_token: string, remember_token_expires_at: datetime)"
2009/11/12 Adinda Praditya <apraditya@...>
>
>
> Hi All,
>
> Saya dapet NoMethodError saat menjalankan find method dari model seperti
> ini:
>
> undefined method `find' for #<User:0x1034331a0>
>
> Padahal find adalah class method dari rails. Error ini dari web, tapi kalo
> saya jalanin dari rails console, normal tanpa error. Ada yang pernah
> ngalami
> hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas frozen
> rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
>
> Trims,
> Dida
>
> [Non-text portions of this message have been removed]
>
>
>
--
blog : http://adityakircon.blogsome.com
ym : kirconboy
skype : adit_skype
Be Nice. Treat others with the same respect you'd want them to treat you.
We're all here to learn together. Be tolerant of others who may not know
everything you know. BRING YOUR SENSE OF HUMOR (stackoverflow.com)
[Non-text portions of this message have been removed]
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 <apraditya@...>
>
> > 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 <tigaenamb@...>
> >
> >
> >>
> >> 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]
Saya coba di tempat lain pake ruby-18.7p72 (bawaan DVD Snow Leopard kayanya)
dan ruby 1.8.6p114 di OpenSuSE 11 dan errornya sama. Apa ini berarti
rails-nya? Saya pake versi frozen 2.3.4. Mohon sarannya.
Thanks,
Dida
2009/11/13 Adinda Praditya <apraditya@...>
> 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 <apraditya@...>
>
>> 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 <tigaenamb@...>
>>
>>
>>>
>>> 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]
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 <apraditya@...>
> 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 <tigaenamb@...>
>
>
>>
>> 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]
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 <tigaenamb@...>
>
>
> 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
>
>
> On Nov 13, 2009, at 9:32 AM, Widi Harsojo wrote:
>
> > coba sequel... saya pakai sequel di rails dan untuk find ex:
> > Nation.where("country like '#{params[:ctr_id]}%'").all
> > konsep nya simple DB, Data, atau Model
> > Result set ORM(bisa di convert ke array hash) atau array hash.
> >
> > 2009/11/13 Adinda Praditya <apraditya@... <apraditya%40gmail.com>>
> >
> >>
> >>
> >> Makasih atas tanggapan2nya. Code apa ya..? Cuman find biasa aja
> >> kok. Dan di
> >> model yang lain biasa2 aja. Awalnya saya jalanin
> >> find_all_by_country dan
> >> muncul jenis error yang sama. Setelah chat dan disaranin untuk coba
> >> ini itu
> >> nggak bisa, saya jalanin find biasa seperti ini
> >>
> >> self.find(:all, :conditions => {:country => self.country})
> >>
> >> Tetap nggak bisa. Googling juga dapetnya 'find_all' yang katanya udah
> >> deprecated. Apa masih ada orang yg biasa chat di #rubyonrails
> >> Freenode?
> >>
> >> Dida
> >>
>
[Non-text portions of this message have been removed]
Ralat: Saya baru nyadar ternyata semua model2 yang lain terjadi kasus aneh
yang sama. find pun nggak bisa.
2009/11/13 Adinda Praditya <apraditya@...>
> Makasih atas tanggapan2nya. Code apa ya..? Cuman find biasa aja kok. Dan di
> model yang lain biasa2 aja. Awalnya saya jalanin find_all_by_country dan
> muncul jenis error yang sama. Setelah chat dan disaranin untuk coba ini itu
> nggak bisa, saya jalanin find biasa seperti ini
>
> self.find(:all, :conditions => {:country => self.country})
>
> Tetap nggak bisa. Googling juga dapetnya 'find_all' yang katanya udah
> deprecated. Apa masih ada orang yg biasa chat di #rubyonrails Freenode?
>
> Dida
>
>
> 2009/11/13 Rafeequl Rahman <rafeequl@...>
>
> menarik juga, kebetulan saya 10.6.2 , boleh share code snippets dan/atau
>> log
>>
>> On Nov 12, 2009, at 7:31 PM, Arie Kusuma Atmaja wrote:
>>
>> > 2009/11/12 Adinda Praditya <apraditya@...>:
>> >
>> > > Saya dapet NoMethodError saat menjalankan find method dari model
>> seperti
>> > > ini:
>> > >
>> > > undefined method `find' for #<User:0x1034331a0>
>> > >
>> > > Padahal find adalah class method dari rails. Error ini dari web, tapi
>> kalo
>> > > saya jalanin dari rails console, normal tanpa error. Ada yang pernah
>> ngalami
>> > > hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas
>> frozen
>> > > rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
>> >
>> > Hmm.. aneh.. dan menarik..
>> >
>> > >> User.respond_to? 'find'
>> > => true
>> >
>> > >> User.methods.include? "find"
>> > => true
>> >
>> > saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX 10.5.8
>> > , Probably other Snow Leopard users could help / I saw Michael's
>> > MacBook Pro was using Snow Leopard but he never complained about it.
>> >
>> > D'oh!
http://en.wikipedia.org/wiki/D'oh<http://en.wikipedia.org/wiki/D%27oh>
>> !
>> >
>>
>>
[Non-text portions of this message have been removed]
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
On Nov 13, 2009, at 9:32 AM, Widi Harsojo wrote:
> coba sequel... saya pakai sequel di rails dan untuk find ex:
> Nation.where("country like '#{params[:ctr_id]}%'").all
> konsep nya simple DB, Data, atau Model
> Result set ORM(bisa di convert ke array hash) atau array hash.
>
> 2009/11/13 Adinda Praditya <apraditya@...>
>
>>
>>
>> Makasih atas tanggapan2nya. Code apa ya..? Cuman find biasa aja
>> kok. Dan di
>> model yang lain biasa2 aja. Awalnya saya jalanin
>> find_all_by_country dan
>> muncul jenis error yang sama. Setelah chat dan disaranin untuk coba
>> ini itu
>> nggak bisa, saya jalanin find biasa seperti ini
>>
>> self.find(:all, :conditions => {:country => self.country})
>>
>> Tetap nggak bisa. Googling juga dapetnya 'find_all' yang katanya udah
>> deprecated. Apa masih ada orang yg biasa chat di #rubyonrails
>> Freenode?
>>
>> Dida
>>
>> 2009/11/13 Rafeequl Rahman <rafeequl@... <rafeequl
>> %40gmail.com>>
>>
>>
>>> menarik juga, kebetulan saya 10.6.2 , boleh share code snippets
>>> dan/atau
>>> log
>>>
>>> On Nov 12, 2009, at 7:31 PM, Arie Kusuma Atmaja wrote:
>>>
>>>> 2009/11/12 Adinda Praditya <apraditya@...<apraditya
>>>> %40gmail.com>
>>> :
>>>>
>>>>> Saya dapet NoMethodError saat menjalankan find method dari model
>>> seperti
>>>>> ini:
>>>>>
>>>>> undefined method `find' for #<User:0x1034331a0>
>>>>>
>>>>> Padahal find adalah class method dari rails. Error ini dari web,
>>>>> tapi
>>> kalo
>>>>> saya jalanin dari rails console, normal tanpa error. Ada yang
>>>>> pernah
>>> ngalami
>>>>> hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas
>>> frozen
>>>>> rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
>>>>
>>>> Hmm.. aneh.. dan menarik..
>>>>
>>>>>> User.respond_to? 'find'
>>>> => true
>>>>
>>>>>> User.methods.include? "find"
>>>> => true
>>>>
>>>> saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX
>>>> 10.5.8
>>>> , Probably other Snow Leopard users could help / I saw Michael's
>>>> MacBook Pro was using Snow Leopard but he never complained about
>>>> it.
>>>>
>>>> D'oh! http://en.wikipedia.org/wiki/D'oh<
>> http://en.wikipedia.org/wiki/D%27oh>
>>
>>> !
>>>>
>>>
>>>
>>
>> [Non-text portions of this message have been removed]
>>
>>
>>
>
>
>
> --
> /wh
>
> e=mc2inhologram
>
>
> [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)
>
> http://rubyurl.com/Q8DD
> http://news.gmane.org/gmane.comp.lang.ruby.region.indonesia
>
>
>
>
coba sequel... saya pakai sequel di rails dan untuk find ex:
Nation.where("country like '#{params[:ctr_id]}%'").all
konsep nya simple DB, Data, atau Model
Result set ORM(bisa di convert ke array hash) atau array hash.
2009/11/13 Adinda Praditya <apraditya@...>
>
>
> Makasih atas tanggapan2nya. Code apa ya..? Cuman find biasa aja kok. Dan di
> model yang lain biasa2 aja. Awalnya saya jalanin find_all_by_country dan
> muncul jenis error yang sama. Setelah chat dan disaranin untuk coba ini itu
> nggak bisa, saya jalanin find biasa seperti ini
>
> self.find(:all, :conditions => {:country => self.country})
>
> Tetap nggak bisa. Googling juga dapetnya 'find_all' yang katanya udah
> deprecated. Apa masih ada orang yg biasa chat di #rubyonrails Freenode?
>
> Dida
>
> 2009/11/13 Rafeequl Rahman <rafeequl@... <rafeequl%40gmail.com>>
>
>
> > menarik juga, kebetulan saya 10.6.2 , boleh share code snippets dan/atau
> > log
> >
> > On Nov 12, 2009, at 7:31 PM, Arie Kusuma Atmaja wrote:
> >
> > > 2009/11/12 Adinda Praditya <apraditya@...<apraditya%40gmail.com>
> >:
> > >
> > > > Saya dapet NoMethodError saat menjalankan find method dari model
> > seperti
> > > > ini:
> > > >
> > > > undefined method `find' for #<User:0x1034331a0>
> > > >
> > > > Padahal find adalah class method dari rails. Error ini dari web, tapi
> > kalo
> > > > saya jalanin dari rails console, normal tanpa error. Ada yang pernah
> > ngalami
> > > > hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas
> > frozen
> > > > rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
> > >
> > > Hmm.. aneh.. dan menarik..
> > >
> > > >> User.respond_to? 'find'
> > > => true
> > >
> > > >> User.methods.include? "find"
> > > => true
> > >
> > > saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX 10.5.8
> > > , Probably other Snow Leopard users could help / I saw Michael's
> > > MacBook Pro was using Snow Leopard but he never complained about it.
> > >
> > > D'oh! http://en.wikipedia.org/wiki/D'oh<
> http://en.wikipedia.org/wiki/D%27oh>
>
> > !
> > >
> >
> >
>
> [Non-text portions of this message have been removed]
>
>
>
--
/wh
e=mc2inhologram
[Non-text portions of this message have been removed]
Makasih atas tanggapan2nya. Code apa ya..? Cuman find biasa aja kok. Dan di
model yang lain biasa2 aja. Awalnya saya jalanin find_all_by_country dan
muncul jenis error yang sama. Setelah chat dan disaranin untuk coba ini itu
nggak bisa, saya jalanin find biasa seperti ini
self.find(:all, :conditions => {:country => self.country})
Tetap nggak bisa. Googling juga dapetnya 'find_all' yang katanya udah
deprecated. Apa masih ada orang yg biasa chat di #rubyonrails Freenode?
Dida
2009/11/13 Rafeequl Rahman <rafeequl@...>
> menarik juga, kebetulan saya 10.6.2 , boleh share code snippets dan/atau
> log
>
> On Nov 12, 2009, at 7:31 PM, Arie Kusuma Atmaja wrote:
>
> > 2009/11/12 Adinda Praditya <apraditya@...>:
> >
> > > Saya dapet NoMethodError saat menjalankan find method dari model
> seperti
> > > ini:
> > >
> > > undefined method `find' for #<User:0x1034331a0>
> > >
> > > Padahal find adalah class method dari rails. Error ini dari web, tapi
> kalo
> > > saya jalanin dari rails console, normal tanpa error. Ada yang pernah
> ngalami
> > > hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas
> frozen
> > > rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
> >
> > Hmm.. aneh.. dan menarik..
> >
> > >> User.respond_to? 'find'
> > => true
> >
> > >> User.methods.include? "find"
> > => true
> >
> > saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX 10.5.8
> > , Probably other Snow Leopard users could help / I saw Michael's
> > MacBook Pro was using Snow Leopard but he never complained about it.
> >
> > D'oh! http://en.wikipedia.org/wiki/D'oh<http://en.wikipedia.org/wiki/D%27oh>
> !
> >
>
>
[Non-text portions of this message have been removed]
menarik juga, kebetulan saya 10.6.2 , boleh share code snippets dan/atau log
On Nov 12, 2009, at 7:31 PM, Arie Kusuma Atmaja wrote:
> 2009/11/12 Adinda Praditya <apraditya@...>:
>
> > Saya dapet NoMethodError saat menjalankan find method dari model seperti
> > ini:
> >
> > undefined method `find' for #<User:0x1034331a0>
> >
> > Padahal find adalah class method dari rails. Error ini dari web, tapi kalo
> > saya jalanin dari rails console, normal tanpa error. Ada yang pernah ngalami
> > hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas frozen
> > rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
>
> Hmm.. aneh.. dan menarik..
>
> >> User.respond_to? 'find'
> => true
>
> >> User.methods.include? "find"
> => true
>
> saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX 10.5.8
> , Probably other Snow Leopard users could help / I saw Michael's
> MacBook Pro was using Snow Leopard but he never complained about it.
>
> D'oh! http://en.wikipedia.org/wiki/D'oh!
>
[Non-text portions of this message have been removed]
On Thu, Nov 12, 2009 at 6:26 PM, wharsojo <wharsojo@...> wrote:
> Dear all,
>
> As of version 0.9.58, you can try it online on "http://w2tags.heroku.com"
Congrats and Kudos !
Now the documentation is much clearer.
2009/11/12 Adinda Praditya <apraditya@...>:
> Saya dapet NoMethodError saat menjalankan find method dari model seperti
> ini:
>
> undefined method `find' for #<User:0x1034331a0>
>
> Padahal find adalah class method dari rails. Error ini dari web, tapi kalo
> saya jalanin dari rails console, normal tanpa error. Ada yang pernah ngalami
> hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas frozen
> rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
Hmm.. aneh.. dan menarik..
>> User.respond_to? 'find'
=> true
>> User.methods.include? "find"
=> true
saya pribadi belum pernah pakai OSX 10.6.2 , saya pakai yg OSX 10.5.8
, Probably other Snow Leopard users could help / I saw Michael's
MacBook Pro was using Snow Leopard but he never complained about it.
D'oh! http://en.wikipedia.org/wiki/D'oh!
Silahkan dilihat,
http://rails.learnhub.com/lesson/6380-action-controller-streaming-and-file-downl\
oads. di link ini cuman diberitahu cara untuk download. untuk uploadnya kamu
tanya mr google aja ya.
________________________________
Dari: andrean_voo <andrean_voo@...>
Kepada: id-ruby@yahoogroups.com
Terkirim: Rab, 11 November, 2009 21:56:13
Judul: [id-ruby] script RoR upload & download file PDF
halo,, saya mengalami kesulitan dalam pengkodingan RoR upload & download file
PDF nih,, ada yg tau g?? mohon bantuannya..
-thanx for all-
Apakah demonstrasi & turun ke jalan itu hal yang wajar? Temukan jawabannya
di Yahoo! Answers! http://id.answers.yahoo.com
[Non-text portions of this message have been removed]
saya punya format data seperti ini:
branch has many regions
region belongs to branch
region has many streets
street belongs to region
street has many customers
atribut untuk branch, region n street sama (hanya code n name), nah kira-kira
lebih baik pakai plugin acts_as_tree atau single table inheritance ?
makasih...
(\ /)
(O.o)
(> <)
This is Bunny. Copy Bunny into your signature to help him on his way to
world domination.
[Non-text portions of this message have been removed]
Hi All,
Saya dapet NoMethodError saat menjalankan find method dari model seperti
ini:
undefined method `find' for #<User:0x1034331a0>
Padahal find adalah class method dari rails. Error ini dari web, tapi kalo
saya jalanin dari rails console, normal tanpa error. Ada yang pernah ngalami
hal ini? Apa yang harus saya periksa? Aplikasi saya berada di atas frozen
rails 2.3.4 on OSX 10.6.2, ruby 1.8.7 patchlevel 174.
Trims,
Dida
[Non-text portions of this message have been removed]
Supaya pointing ke satu server/railsapp masing2 domain harus diarahkan
keserver tsb. modify DNS masing2 domain, A Record ke IP railsapp tsb.
cookie+session bisa dihandle dgn trick booking2heaven.
Untuk beda2in datanya, bisa dgn mudah tambahkan filter
find_by_domain_name utk setiap data yg ingin dikelola. Sebelumnya kan
daftarkan dulu masing2 domain dinamis (a,b,c).
On 11/3/09, Booking Heaven <booking2heaven@...> wrote:
> Maaf mas Goz, kayanya terlalu extrim klo maen Vhost :D, Mungkin
> pertanyaanyna pak wawan tepatnya : "Bagaimana caranya melakukan Restful
> disuatu applikasi tapi jika dijalankan larinya ke domain lain bukan ke path
> atau urlnya si aplikasi", gimana kalo pake session-domain atau cookieDomain?
> dah coba?
>
> Coba deh mampir kesini (sessionDomain):
>
http://szeryf.wordpress.com/2008/01/21/cookie-handling-in-multi-domain-applicati\
ons-in-ruby-on-rails/
>
> yang ini buat CookieDomain:
> http://codetunes.com/2009/04/17/dynamic-cookie-domains-with-racks-middleware/
>
> Semoga bermafaat :) & semoga saya tidak salah tanggap. Sorry saya malas
> nulis coding jadi kasih referensi aja :D
>
> Regards,
> Jack The Chick
>
> --- On Fri, 10/30/09, Achmad Gozali <gozali@...> wrote:
>
> From: Achmad Gozali <gozali@...>
> Subject: Re: [id-ruby] tanya Routing Banyak Domain ke Satu Aplikasi Ruby on
> Rails
> To: id-ruby@yahoogroups.com
> Date: Friday, October 30, 2009, 7:23 AM
>
>
>
>
>
>
>
>
>
>
>
>
> Pak Wawan,
>
>
>
> Saya pernah bikin pake passenger, bukan routes.rb nya yg dioprek tapi
>
> konfigurasi di apache (lingkungan OSX)
>
> konfigurasi vhost nya misalnya seperti ini :
>
>
>
> <VirtualHost *:80>
>
> ServerName dev1.com
>
> DocumentRoot /User/Documents/ Projects/ dev1_public
>
> RailsEnv development
>
>
>
> <directory "/User/Documents/ Projects/ projectname/ dev1_public" >
>
> Order allow,deny
>
> Allow from all
>
> </directory>
>
>
>
> RailsAllowModRewrit e on
>
> RewriteEngine On
>
>
>
> RewriteCond %{DOCUMENT_ROOT} %{REQUEST_ FILENAME} !-f
>
> RewriteRule ^/(.*)$ /public%{REQUEST_ URI} [QSA]
>
>
>
> </VirtualHost>
>
>
>
> <VirtualHost *:80>
>
> ServerName dev2.com
>
> DocumentRoot /User/Documents/ Projects/ projectname/ dev2_public
>
> RailsEnv development
>
>
>
> <directory "/User/Documents/ Projects/ projectname/ dev2_public" >
>
> Order allow,deny
>
> Allow from all
>
> </directory>
>
>
>
> RailsAllowModRewrit e on
>
> RewriteEngine On
>
>
>
> RewriteCond %{DOCUMENT_ROOT} %{REQUEST_ FILENAME} !-f
>
> RewriteRule ^/(.*)$ /public%{REQUEST_ URI} [QSA]
>
>
>
> </VirtualHost>
>
>
>
> Good luck,
>
>
>
> Gozali
>
>
>
> On Oct 30, 2009, at 5:02 PM, Wawan Syahrani wrote:
>
>
>
>> Disini ada yang tau routing satu aplikasi ruby on rails bisa diakses
>
>> dari domain domain berbeda secara dinamis?
>
>>
>
>> Contoh
>
>>
>
>> http://a.com -> GET /foos/a
>
>> http://b.com -> GET /foos/b
>
>> http://z.com -> GET /foos/z
>
>>
>
>> Dan ini bukan ditulis manual di routes.rb satu-satu, tetapi dinamis
>
>> (karena a, b, z tadi juga dinamis, bukan hard code).
>
>>
>
>> Gimana ?
>
>>
>
>>
>
>
>
> [Non-text portions of this message have been removed]
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>
>
--
irfani
http://irfani.web.id
Y! irfani_s