Re: [Rails] How to remove empty object from array

2012-07-02 Thread Ahmy Yulrizka
for erros you can call method errors on each model object. the other one, im not really sure. But one thing I could think of is adding a virtual attribute on the model. and display a check box to the user wether to save the record or not. then you can iterate to check on that attribute first. Ahm

Re: [Rails] Rails compatibility with Ubuntu

2012-07-02 Thread Mandeep Kaur
On Tue, Jul 3, 2012 at 11:59 AM, Ahmy Yulrizka wrote: > very compatible, > > the version of rails is depend on the version of ruby not the version of the > operating system. And I think old box still install ruby fine. You just > have to try it and ask if you found any problem. Ok then Rails 3.x

[Rails] How to remove empty object from array

2012-07-02 Thread renu mehta
Hello, I have a view on which I accept multiple objects of the same model. I create an array like @member_list=[] 5.times{ @member_list

Re: [Rails] Rails compatibility with Ubuntu

2012-07-02 Thread Ahmy Yulrizka
very compatible, the version of rails is depend on the version of ruby not the version of the operating system. And I think old box still install ruby fine. You just have to try it and ask if you found any problem. Ahmy Yulrizka On Tue, Jul 3, 2012 at 6:55 AM, Mandeep Kaur wrote: > Hi All, >

Re: [Rails] a hands-on tutoring needed

2012-07-02 Thread Gregory Bataille
Did you watch this one http://railscasts.com/episodes/111-advanced-search-form for a search without plugins, I think it covers well the basics of the subject to let you improve it. this is the "advanced search form" episode. If you were to find yourself a bit lost, there is a "simple search form

Re: [Rails] Creating a new record doesnt update the browser view

2012-07-02 Thread Colin Law
On 2 July 2012 22:15, cyber c. wrote: > Hi, > > I have a rails app. upon creating a new record from the browser(although > it is being created successfully) it doesnt show up in the browsers > view. Connecting to the DB , i confirmed that the record is created. I > should do a "Rake db:migrate" in

[Rails] How to display error in view for an instance

2012-07-02 Thread renu mehta
Hello, How can we display the errors in a view if that view contains one instance of type member and an array also of instances from the same model. In my app I have a form which accepts a member data for registration for a family on the top and at the end of the screen in the same form I accept t

[Rails] Re: variable iteration

2012-07-02 Thread Sebastian H.
oh yeah ! thank you very much! -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread hanish jadala
Thank you ive tried in other system it worked but not on my system.ill remove all the version of ruby and ill try with rvm On Mon, Jul 2, 2012 at 6:58 PM, thiagocifani wrote: > I recommend you remove all your ruby version on your system, remove rvm > and begins from scratch. It is probabily some

[Rails] Rails compatibility with Ubuntu

2012-07-02 Thread Mandeep Kaur
Hi All, I want to know the compatibility of Ubuntu with Rails. Anyone know which Ubuntu version support Rails 2.x and Rails 3.x. -- Mandeep Kaur http://mandeepsimak.wordpress.com/ -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post

[Rails] Creating a new record doesnt update the browser view

2012-07-02 Thread cyber c.
Hi, I have a rails app. upon creating a new record from the browser(although it is being created successfully) it doesnt show up in the browsers view. Connecting to the DB , i confirmed that the record is created. I should do a "Rake db:migrate" inorder to make the record appear on the browser's v

Re: [Rails] Re: slow development compiling with asset pipleine

2012-07-02 Thread Hassan Schroeder
On Mon, Jul 2, 2012 at 12:16 PM, S Ahmed wrote: > any comments? Sure. Your chances of getting a useful response are directly proportional to the amount of information you provide: platform, Ruby interpreter and version, Rails version, what your app does and what gems it's using, your definition

Re: [Rails] variable iteration

2012-07-02 Thread Aleksey V Zapparov
On Mon, 02 Jul 2012 21:21:25 +0200 "Sebastian H." wrote: > hello guys > > i have a big problem and i don't know how to solve it -.- > > i have a data base. the models name is Blafoo > > if i go to console i create a new entry with tst = Blafoo.new(:d1 => > true) > > with Blafoo.d1 i can now s

[Rails] variable iteration

2012-07-02 Thread Sebastian H.
hello guys i have a big problem and i don't know how to solve it -.- i have a data base. the models name is Blafoo if i go to console i create a new entry with tst = Blafoo.new(:d1 => true) with Blafoo.d1 i can now see the calue of d1 lets take a variable var = "d1" how can i get it working,

[Rails] Re: slow development compiling with asset pipleine

2012-07-02 Thread S Ahmed
any comments? On Sun, Jul 1, 2012 at 10:30 PM, S Ahmed wrote: > I don't have much experience with the new asset pipleine, but when > developing locally it seems things are very very slow to compile now. > > Am I missing something or is this how the new asset pipleine rails version > is? > -- Y

Re: [Rails] a hands-on tutoring needed

2012-07-02 Thread Walter Lee Davis
On Jul 2, 2012, at 1:42 PM, sehrguey o. wrote: > dear Walter, > > thank you for your kind attention and readiness to help. > > You talked about my controller and proposed an awesomely nice line: > > “ @foos = Foo.where(["bar LIKE '%?%'",params[:q]])” > > Unfortunately, it is not enough to ge

[Rails] Re: a hands-on tutoring needed

2012-07-02 Thread sehrguey o.
dear Walter, thank you for your kind attention and readiness to help. You talked about my controller and proposed an awesomely nice line: “ @foos = Foo.where(["bar LIKE '%?%'",params[:q]])” Unfortunately, it is not enough to get me started because I can't imagine where on earth to stick it in

[Rails] Re: a hands-on tutoring needed

2012-07-02 Thread sehrguey o.
Hello Bill, sometime ago I hacked the database structure from Kevin Yank's tutorial “Build Your Own Database Driven Website Using PHP & MySQL” to use it for a database at my site and it works OK storing and delivering a hundred plus of records in the database I needed. However I haven't deplo

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread Hassan Schroeder
On Mon, Jul 2, 2012 at 6:23 AM, hanish jadala wrote: > everything went fine other than installing the gems only. i get this > ERROR: While executing gem ... (Errno::EACCES) > Permission denied - /home/hanish/.gem/specs So? What *are* the perms on that directory? You've probably messed them

[Rails] £ Symbol Ruby/Rails/Mongrel

2012-07-02 Thread Peter Eaves
Hi, I have an application which had been developed and deployed with the following: *** LOCAL GEMS *** actionmailer (2.3.5) actionpack (2.3.5) activemodel (3.0.5, 3.0.4) activerecord (2.3.5, 1.15.6) activerecord-sqlserver-adapter (2.3.5) activeresource (2.3.5) activesupport (3.0.5, 3.0.4, 2.3.5,

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread thiagocifani
I recommend you remove all your ruby version on your system, remove rvm and begins from scratch. It is probabily some permission problem, because you have a ruby version installed by default in your OS. I guess you are using linux, but if not I recommend do the same approach. Remove everything and

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread hanish jadala
updates: i followed this link http://screencasts.org/episodes/how-to-use-rvmeverything went fine other than installing the gems only. i get this ERROR: While executing gem ... (Errno::EACCES) Permission denied - /home/hanish/.gem/specs when go with sudo it works but the gem is installing in ro

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread hanish jadala
ive gone through rvm site only On Mon, Jul 2, 2012 at 6:18 PM, thiagocifani wrote: > Did you follow the rvm site tutorial? Ig not please try by there! > > Sent from my iPhone > > On 02/07/2012, at 09:40, honey ruby wrote: > > Hi all ive installed rvm 1.8.7 and 1.9.2 when i select rvm 1.8.7 and w

Re: [Rails] how to create gemsets using rvm

2012-07-02 Thread thiagocifani
Did you follow the rvm site tutorial? Ig not please try by there! Sent from my iPhone On 02/07/2012, at 09:40, honey ruby wrote: > Hi all ive installed rvm 1.8.7 and 1.9.2 when i select rvm 1.8.7 and when i > try to create a gem set and install gems it is not installing it is asking > from pe

[Rails] how to create gemsets using rvm

2012-07-02 Thread honey ruby
Hi all ive installed rvm 1.8.7 and 1.9.2 when i select rvm 1.8.7 and when i try to create a gem set and install gems it is not installing it is asking from permissions. if i use sudo to install gems and then when i type gem list i can't any gem . where did i go wrong . correct me Thanks in ad

Re: [Rails] Rspec

2012-07-02 Thread thil
Hi Colin, Thanks for your reply. Thanks, Senthil On Monday, 2 July 2012 15:10:07 UTC+5:30, Colin Law wrote: > > On 2 July 2012 08:07, thil wrote: > > Hi All , > > > > I am working in rails past 1+ years but still I didn't used any Unit > testing > > in my project. > > > > Can any one h

[Rails] Re: different between these two array method.

2012-07-02 Thread phoe san
Hi Sentil and Colin, ႊThank for your reply message and solution! phoesan -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com.

Re: [Rails] Rspec

2012-07-02 Thread Colin Law
On 2 July 2012 08:07, thil wrote: > Hi All , > > I am working in rails past 1+ years but still I didn't used any Unit testing > in my project. > > Can any one help me to know where I can learn the Rspec or basic things to > start. Work through the tutorial railstutorial.org which is free to use

Re: [Rails] Re: different between these two array method.

2012-07-02 Thread Colin Law
On 2 July 2012 10:26, phoe san wrote: > <%= collection_select(:sport_name,count,Sport.find( :all, :order => 'id' > ), > :id, :sport_name, {:selected =>@sport_id})%> > > Collection_select Value. > We take data from collection_select by params[:sport_name] > > In Controller, we use this

[Rails] Re: different between these two array method.

2012-07-02 Thread thil
Hi, + operator won't works in array I think but used as concatenation in staring. Second scenario of your case works fine. Thanks, senthil On Monday, 2 July 2012 14:29:57 UTC+5:30, Ruby-Forum.com User wrote: > > Dear friends, > > What is different between these two array method. > > First

[Rails] Re: different between these two array method.

2012-07-02 Thread phoe san
<%= collection_select(:sport_name,count,Sport.find( :all, :order => 'id' ), :id, :sport_name, {:selected =>@sport_id})%> Collection_select Value. We take data from collection_select by params[:sport_name] In Controller, we use this ps_array = params[:sport_name] we get the data Firs

[Rails] Rspec

2012-07-02 Thread thil
Hi All , I am working in rails past 1+ years but still I didn't used any Unit testing in my project. Can any one help me to know where I can learn the Rspec or basic things to start. Thanks, Senthil -- You received this message because you are subscribed to the Google Groups "Ruby on Rai

Re: [Rails] different between these two array method.

2012-07-02 Thread Colin Law
On 2 July 2012 09:59, phoe san wrote: > Dear friends, > > What is different between these two array method. > > First Array Method > > arr = ps_array["1"] What is the type of ps_array["1"] Colin > arr += ps_array["2"] > arr += ps_array["3"] > > > Second Array Method > >

[Rails] different between these two array method.

2012-07-02 Thread phoe san
Dear friends, What is different between these two array method. First Array Method arr = ps_array["1"] arr += ps_array["2"] arr += ps_array["3"] Second Array Method arr = [ps_array["1"],ps_array["2"],ps_array["3"]] yours, phoesan -- Posted via http://www.ruby-f