[Rails] [JOBS] - Two Exciting RoR Full-Time Jobs in Medellin, Colombia - 8M - 12M Pesos

2019-04-11 Thread Michael C. Bertoni
Ruby on Rails Community - My name is Michael C. Bertoni and I'm the Founder & CTO of PhillyTech and the SVP of Business Development with Source Meridian. We are currently experiencing hyper-growth and need to add 20 engineers to our teams in Philadelphia, Medellin, Cali, Reonegro,

[Rails] [JOBS] Exciting HealthTech Software Company | Sr Ruby on Rails Engineer | Great Comp & Relo Pa

2019-03-09 Thread Michael C. Bertoni
t.meetup.com/wf/click?upn=DtKvkirJMjJK-2FpI8UHiQTiC5JfxR1Z32GjJpnq4cweY-3D_HDu-2BON2WuckNVJ2U1s3AlBnI-2FJCjyhJgFtzRt-2BQYXtt6dL12SZUGBMnUTNA-2FpTmntaAIHC-2FrZ5hnAr4ZObUrMC4wReHnzD3CkaEhvNCW1eTUEj-2BTZcM3w5K7bGEpSK0t0F123e-2F4jaUp3nXuF2hiaCS7oPczM09iS3A1HJoqo5IXo81VoTNOsK-2FeR7G7mJLZmx3PbNZVC3p4IePKpqWtxF6B-2BxnQDE5AgCuA

Re: [Rails] Polymorphism and brittle class names

2019-01-14 Thread Christophe C
I don't follow. The column name isn't OldClassName, so I'm not sure what that assignment is supposed to mean. The issue is that a polymorphic reference can literally be any activerecord model in your app, there's no restrictions. Really the only reliable way is to look at the DB and group by `p

[Rails] Re: Polymorphism and brittle class names

2019-01-13 Thread Christophe C
19 at 10:25:12 PM UTC-8, Christophe C wrote: > > I haven't found an exact statement of this problem yet, but if you find > one please direct me accordingly. > > My one problem with polymorphic associations is that your code is now in > the database. What happens when you ren

[Rails] Polymorphism and brittle class names

2019-01-12 Thread Christophe C
I haven't found an exact statement of this problem yet, but if you find one please direct me accordingly. My one problem with polymorphic associations is that your code is now in the database. What happens when you rename a class, or re-scope it's module? Since class name changes are much more

[Rails] Re: I'm looking for a job as Ruby, Ruby on Rails developer.

2016-04-08 Thread Geoff C
http:// webwork.io has loads of remote ruby jobs I would try there On Tuesday, February 2, 2016 at 10:03:25 PM UTC, Pavel Sh wrote: > > Hi guys, I'm looking for any job related with this technology. > > I have a 1 year of experience with RoR and 8 years as IT specialist > (

[Rails] [JOBS] Senior Ruby Backend Developer (m/f) at GetSafe

2015-09-25 Thread C. Merkler
Hey guys! I am CTO & Co-Founder at GetSafe. We are hiring a Senior Ruby Backend Developer for Heidelberg, Germany (onsite): * lead a small team of RoR developers * automate insurance processes using APIs, OCR and ML to create real business value * exciting work environment * 4 years experience wit

[Rails] [JOBS] Senior Ruby Backend Developer (m/f) at GetSafe

2015-09-24 Thread c . schneider
Hey guys! I am CTO & Co-Founder at GetSafe. We are hiring a *Senior Ruby Backend Developer for Heidelberg*, Germany (onsite): * lead a small team of RoR developers * automate insurance processes using APIs, OCR and ML to create real business value * exciting work environment * 4 years experience

[Rails] Re: Emails Not Sending

2015-04-15 Thread Ron C.
As a RoR novice myself, I can tell you that you are NOT doing your home work before asking questions ... you are NOT putting in the necessary time, patience and resolve required to find a solution for YOURSELF ... However, in about 15 secs I found on the internet a possible hint to what your pr

[Rails] Re: what can i do if super admin user id is deleted by admin only

2015-02-25 Thread ankit c
using rails console create new admin.. for instance, if you are having user model having role admin.. you can create like User.create(:email => "ad...@admin.com", :username => "admin", :password => "12345678", :password_confirmation => "12345678", :admin => true).. I hope this will help On Thu

Re: [Rails] what can i do if super admin user id is deleted by admin only

2015-02-25 Thread ankit c
using rails console create new admin.. for instance, if you are having user model having role admin.. you can create like User.create(:email => "ad...@admin.com", :username => "admin", :password => "12345678", :password_confirmation => "12345678", :admin => true).. I hope this will help On Thu, F

Re: [Rails] what can i do if super admin user id is deleted by admin only

2015-02-25 Thread ankit c
create new admin On Thu, Feb 26, 2015 at 12:11 PM, Sailatha K. wrote: > our site admin deleted his own id while deleting users ,what can i do > now to get back admin user can any one help,its urgent. > > -- > Posted via http://www.ruby-forum.com/. > > -- > You received this message because you a

[Rails] Re: Database Testing in Rails

2015-01-04 Thread D. C.
Thanks Colin. It's not practical to change the database as data arrives from a 3rd party provider with a particular structure. You're note made me realize that I'm going about this the wrong way, however. I didn't even think to use transactions on insert. I'm accustomed to an old system where tra

[Rails] Re: Marshal Data too short error with ActiveRecord sess. sto

2014-11-20 Thread Gökhan C.
Wes Gamble wrote in post #157243: > Wes Gamble wrote: >> Does anyone know how to figure out the size of a text column in SQL >> Server? > > SELECT datalength(data) FROM sessions; Hello my friend. I have the same sitiutaion at now. Do you find a solution for that? regards Coban -- Posted via htt

[Rails] Are you a rails programmer that wants to explore EXOTIC ASIA?

2014-09-08 Thread Sky C.
There is now a job opportunity in the Centre of ASIA ! Kuala Lumpur! Check out the poster here for more information. http://www.codemalaysia.com/collaborate -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails:

[Rails] Re: Quick question about AR arrays.

2014-07-01 Thread manoj c.
Samson Oak wrote in post #1151218: > Oops, I meant Foo.all.each {|foo| foo.bar } for the second one. Yes, second one should work as your method is a instance method Thanks. Manoj Menon, -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Goo

[Rails] Re: Recommendations for Hosted CI servers supporting RoR with private repos?

2014-05-14 Thread John C
I used CircleCi with my private github repo and heroku. I was impressed. Set up parallel tests and git-flow publishing to staging and production servers on success. Their support was good for this use case. --John On Thursday, May 8, 2014 9:22:33 AM UTC-4, Ganesh Ranganathan wrote: > > Any re

[Rails] How to send other params with rails3-jquery-autocomplete

2013-12-03 Thread vijay c.
I want to send other params i.e hidden field values in `get_autocomplete_items(parameters)` and I tried = rec.autocomplete_field :name, autocomplete_recruiter_name_job_applications_path, :placeholder=>"Recruiter name",:id_element=>"#phone", :param_name => 'search' But ajax request is sendi

[Rails] Re: gmaps4rails "acts_as_gmappable" error

2013-10-02 Thread Caner C.
http://stackoverflow.com/questions/17994840/gmaps4rails-map-doesnt-appear-fully-on-canvas-on-ajax-call can anyone help me on this? -- 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 unsubscribe

[Rails] Re: gmaps4rails "acts_as_gmappable" error

2013-10-02 Thread Caner C.
http://stackoverflow.com/questions/17994840/gmaps4rails-map-doesnt-appear-fully-on-canvas-on-ajax-call -- 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 unsubscribe from this group and stop rec

[Rails] Re: gmaps4rails "acts_as_gmappable" error

2013-10-02 Thread Caner C.
can anyone help me on this?? http://stackoverflow.com/questions/17994840/gmaps4rails-map-doesnt-appear-fully-on-canvas-on-ajax-call -- 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 unsubscribe

[Rails] Re: Requesting information from user

2013-09-05 Thread Jorge C.
Joel Pearson wrote in post #1120757: > I believe the standard way to do this would be to show a previously > hidden div containing a form. And that is possible using Rails or is it Javascript? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to

[Rails] Requesting information from user

2013-09-05 Thread Jorge C.
Hi, I need to "popup" a message to the user in order he can choose an option. It is not a YES-NO option but almost the same (has has to choose among two options). It has to be a message with a question and two buttons. Is that possible on Rails? Thanks! Jorge -- Posted via http://www.ruby

[Rails] Re: Error layout

2013-08-29 Thread Jorge C.
Thanks Colin! The "issue" was on HTML code: each faulty HTML tag was being wrapped inside a new , so the default behavior was to start a new line. I have added "display:inline-block" in the CSS class and everything is working perfect now. Thanks!! -- Posted via http://www.ruby-forum.com/. --

[Rails] Error layout

2013-08-29 Thread Jorge C.
Hi all, I have created a form to insert new records (see "Selección_001.png") with two mandatory fields ("name" and "surname") but if I try to insert a blank record (so it is invalid) I get the two errors (that is correct) but the page layout is modified (see "Selección_002.png"), which is not cor

[Rails] My first rails microblogging website

2013-07-17 Thread Toufique Imam C.
I've been trying to learn ruby and rails (my first attempt to learn programming) for several months. Now I have decided to build a website using whatever I learned. So I built this website ( anofeed.com ) using whatever I learned. This a microblogging site. But slight different than twitter. You ca

[Rails] Re: How to add observer to namespace model?

2013-06-17 Thread Bruno C.
with Rails 3.1 this worked for me: config.active_record.observers = [ :"Admin::BusinessObserver" ] Came up from looking at how the active_record.observer list is parsed in gems/1.8/gems/activemodel-3.1.0/lib/active_model/observing.rb line 86 Bruno Ankit Varshney wrote in post #907087: > I

[Rails] Re: APP-ID for using Bing search api through "rbing" gem!

2013-05-13 Thread Robert C.
You should be able to use your account key as the correct value, given the recent migration to Azure. If you are looking for this functionality packaged into a gem, try checking out the searchbing gem. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscr

[Rails] Re: "rm public/index.html not recognized."

2013-04-10 Thread Hutch C.
Thanks Jan - ran into same problem. 'del' for windows (vs. 'rm'), and the cd to 'public' did the trick. Very helpful. Jan V. wrote in post #1087171: > You need to "cd public" then "del index.html" windows always have > problems with path :D -- Posted via http://www.ruby-forum.com/. -- You re

[Rails] can't config profile page to update data forms and save

2013-02-27 Thread C Wilson
I am new to Rails and I am setting up the user profile and adding fields to it for users to add details to their profile such as career, about me, height, religion, etc. This information is completely different from the registration options (account settings). As of now the profile fields are b

[Rails] [JOB] Lead Rails Engineer - Boston metrowest

2013-02-21 Thread Patty C.
Hi All, I'm not a recruiter. I work for Location, Inc. (locationinc.com). We crunch Big Data into real estate and map-based information products. (See www.neighborhoodscout.com and www.securitygauge.com). We're fun and exciting, venture backed, profitable, AND growing! We're looking for a Lead E

[Rails] Re: conditional validates_associated

2013-02-13 Thread Rafael C. de Almeida
On Wednesday, February 13, 2013 12:59:11 PM UTC-2, Matt Jones wrote: > > On Tuesday, 12 February 2013 20:29:49 UTC-5, Rafael C. de Almeida wrote: >> >> Hello, >> >> Have you guys noticed that conditional validation with >> validates_associated does not work wel

[Rails] conditional validates_associated

2013-02-12 Thread Rafael C. de Almeida
Hello, Have you guys noticed that conditional validation with validates_associated does not work well when you are creating a new record? Consider this gist: https://gist.github.com/aflag/4780225 The Lawyer class has validates_associated on address conditioned on whether the Lawyer data comes

[Rails] Re: Nested attributes (unknown attribute error)-overiding default foreign key referencing

2013-02-08 Thread poornima c.
Hi Colin Sorry for the typo error. My code has belongs_to and :foreign_key=>"request_id" . Still it throws this error. Looks like I have to use alias_attribute functionality to map asin_whitelist_request_id to request_id in my table. But am not sure about how to handle the queries. -- Posted

[Rails] Nested attributes (unknown attribute error)-overiding default foreign key referencing

2013-02-08 Thread poornima c.
Am getting the following error in ruby on rails: ActiveRecord::UnknownAttributeError in AWRequestsController#new unknown attribute: a_w_request_id. I have a form that is tied to two models. a_w_request.rb: class AWRequest :destroy accepts_nested_attributes for :w_a_details, :allow_destroy

[Rails] Re: Re: Select_tag query

2013-02-07 Thread manoj c.
manoj c. wrote in post #1094553: > Colin Law wrote in post #1094550: >> On 31 January 2013 11:56, manoj c. wrote: >>> yes i meant select_tag only like below example >>> <%=select_tag "people", "David".html_safe%> >>> >>>

[Rails] Re: Re: Select_tag query

2013-01-31 Thread manoj c.
Colin Law wrote in post #1094550: > On 31 January 2013 11:56, manoj c. wrote: >> yes i meant select_tag only like below example >> <%=select_tag "people", "David".html_safe%> >> >> But here name and id of select_tag is same(people), i want to

[Rails] Re: Select_tag query

2013-01-31 Thread manoj c.
yes i meant select_tag only like below example <%=select_tag "people", "David".html_safe%> But here name and id of select_tag is same(people), i want to know how to give it seprately Thanks Manoj. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are sub

[Rails] Select_tag query

2013-01-31 Thread manoj c.
Hi anybody please give me example to write select_tag with id, name and options, :note => here id and name of my select tag are different. Regards and Thanks in advance Manoj. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google G

[Rails] Re: Nested models in a form

2013-01-13 Thread Rafael C. de Almeida
ce_ids in attr_accessible and accept_nested_attributes_for :services). On Sunday, January 13, 2013 7:00:55 PM UTC-2, Rafael C. de Almeida wrote: > > I have found out that user[lawyers_attributes][0][service_ids][] works for > the first lawyer (I update 0 to 1 for the second and so on). Howev

[Rails] Re: Nested models in a form

2013-01-13 Thread Rafael C. de Almeida
, Rafael C. de Almeida wrote: > > Hello, > > I'm trying to work with nested models in a form view and it's not going so > smoothly. A user has many lawyers and a lawyer can take many services. I > want a checkbox on which the user can select the services of each lawyer.

[Rails] Nested models in a form

2013-01-13 Thread Rafael C. de Almeida
Hello, I'm trying to work with nested models in a form view and it's not going so smoothly. A user has many lawyers and a lawyer can take many services. I want a checkbox on which the user can select the services of each lawyer. How can I do it? This is what I've got so far: <%= form_for @user

[Rails] Re: Thinking Sphinx can't find Sphinx.

2012-12-29 Thread vijay c.
Add sphinx.yml file in config folder with added following line. it will surely work fine development: version: '2.0.11' -- 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,

[Rails] Re: Thinking Sphinx can't find Sphinx.

2012-12-29 Thread vijay c.
Add sphinx.yml file in cofig folder with added following line. it will surely work fine development: version: '2.0.11' -- 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,

[Rails] JOBS IN GERMANY

2012-11-21 Thread Rocío C.
Hello, I´m looking for Ruby and Rails developer for interesting job in Germany. You can see the position in www.es.exrein.com If you are intereste, please, send me your english cv to r...@exrein.com Skills: -2-3 years of experience in Ror, -Fluent english -Work permit for Germany (Blue Card) if

[Rails] Re: An error occured while installing mysql2 (0.3.11), and Bundler cannot continue.

2012-11-08 Thread Edson Carlos C.
problem solve, type this command sudo apt-get install libmysqlclient-dev sudo apt-get install mysql then run gem install mysql2 -- 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

[Rails] How to avoid an attribute without passing it to post in formtastic

2012-10-16 Thread Ramesh C.
I am developing rails application. I have a check box in the form like: <%= b.check_box :chkbx, label: false, checked: false %> While submitting the form. I need to avoid passing checkbox name argument in the post. How to avoid checkbox attribute from passing it to post in formtastic? -- Post

[Rails] Re: Auto refresh the drop-down

2012-10-10 Thread Ramesh C.
Walter Davis wrote in post #1079286: > On Oct 10, 2012, at 2:13 PM, chandru c. wrote: > >>>>> >>>> rubyonrails-talk+unsubscr...@googlegroups.com. >> Jim, >> val2 = document.getElementById("item_id").value >> alert "Item sav

[Rails] Re: Auto refresh the drop-down

2012-10-10 Thread chandru c.
Jim ruther Nill wrote in post #1079179: > On Wed, Oct 10, 2012 at 5:01 PM, KUL KING wrote: > >>> And when user clicks on the "Add new option". A pop up dialog appears to >>> add a new value. And when I click create it hits the database and adds the >>> value to the db. >>> >>> But It never updates

[Rails] Re: Rails s - startup issue (new Rails on ubuntu installation

2012-08-21 Thread Vincent C.
http://stackoverflow.com/questions/9783573/tests-are-running-on-my-ubuntu-pc-but-not-on-my-mac-os-x-lion-10-7-3-ruby-1-9 work for me, gem incompatible with ubuntu -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Ra

[Rails] Re: Rails' inflections are messy

2012-07-27 Thread Rafael C. de Almeida
ted into a gem (which is what I did), it > would still need to be bundled by default. Inflections are used in routing, > mapping between models and controllers, and a lot of other places within > Rails. They need to be there. > > On Thursday, July 26, 2012 6:21:26 PM UTC-7, Rafae

[Rails] Re: Difference between save and create ?

2012-07-27 Thread manoj c.
thanks a lot. -- 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 to rubyonrails-t

[Rails] Difference between save and create ?

2012-07-27 Thread manoj c.
Hi, Anybody please help me showing difference between save and create in ruby on rails. expecting help. Regards, Manoj. -- 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 gro

[Rails] Re: Rails' inflections are messy

2012-07-26 Thread Rafael C. de Almeida
One thing that have always bothered me about the inflector and this pluralize business is that it only work in English. That make rails newbies from non-english speaking countries have a harder time learning the technology than they should. I know ruby's keywords are already in English, and so

[Rails] Rerendering parts of a page with ajax

2012-07-26 Thread Rafael C. de Almeida
n people controller (via ajax) with the currently selected properties b) the controller (after consulting the model) returns a list of people using json c) javascript changes the HTML already rendered using the information received from such method That solution doesn't sound good to me bec

[Rails] Re: Validation in ruby on rails

2012-07-24 Thread manoj c.
Ace S. wrote in post #1069767: > Dear sirs, > > I dont't think the addition of :message => "can't be blank" does make a > difference.\ > > Validations have their own strings already packed, in en.yml in the > active_model gem. In the console (rails c)

[Rails] Re: Validation in ruby on rails

2012-07-22 Thread manoj c.
Rafi A wrote in post #1069463: > Manoj, > > try this in the model: > > validates_presence_of :name, :message => "can't be blank" > > Regards, > Seeni Rafiyullah Khan A, > Skype id: rafiyullah.railsfactory | +91 9786832092 | rafigl...@gmail.com > *In Every moment, thank God.* Thanks a lot sir. reg

[Rails] Validation in ruby on rails

2012-07-20 Thread manoj c.
Hi, Please Help me,in a model i gave like validates_presence_of :name,now i need to display error message like "name is required" while clicking form submission button when leaving text box for name as empty,how to do this ?? -- Posted via http://www.ruby-forum.com/. -- You received this mes

[Rails] Zipping files contained in a dir (rubyzip)

2012-07-18 Thread Delvison C.
hey so I'm trying to zip all the files contained in a directory (RubyZip). heres what I have: def bundle #create the ZIPfile with the title of (:id).zip bundle_filename = "public/attachments/#{self.id}/#{self.id}.zip" #open the ZIPfile in order to add items in

[Rails] Re: ActiveRecord - return array of only ids?

2012-07-14 Thread Gregory C.
Should anyone else come across this, another way to refine this further is: Object.pluck(:id) This will produce your array of ids. More here http://guides.rubyonrails.org/active_record_querying.html#pluck -- Posted via http://www.ruby-forum.com/. -- You received this message because you are

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

2012-07-06 Thread cyber c.
Hi, I'm not using the back button , but refreshing the browser to see the updated list. I'm using Safari browser. Tried with a chrome too(from a windows machine, ofcourse my rails server is still running on my mac machine) and i see the same result. -- Posted via http://www.ruby-forum.com/.

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

2012-07-06 Thread cyber c.
>It is a bit suspicious that you have 3.2.6 of only some of these. I should have asked you to post Gemfile and Gemfile.lock too. Gemfile.lock GEM remote: https://rubygems.org/ specs: actionmailer (3.2.4) actionpack (= 3.2.4) mail (~> 2.4.4) actionpack (3.2.4) active

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

2012-07-06 Thread cyber c.
Hi Colin, >Here we /do/ see the sql fetching the records. Very odd. There must >be something going wrong with the caching. Have you changed anything >in the the config directory other than database.yml and routes.rb? >Specifically environment.rb or anything in config/environments? Are >you in

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

2012-07-05 Thread cyber c.
>Now run the app, bring up the index and note the count shown (what is >it and how many records do you see), add a record and then show the >index again. Does the count change? Post the log for that complete >cycle. The count shown is old , doesnt include the newly created one. Started GET "/

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

2012-07-05 Thread cyber c.
>>> buggy. >> >> >> >> Started POST "/trials" for 127.0.0.1 at Thu Jul 05 10:26:19 -0700 2012 >>(1.2ms) commit transaction >> Completed 200 OK in 39ms (Views: 37.9ms | ActiveRecord: 0.2ms) >> >> >> >> Started GET "/assets/trials.js?body=1" for 127.0.0.1 at Thu Jul 05 >> 10:26:45 -0700 2012 >>

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

2012-07-05 Thread cyber c.
>> Hi Colin, >Please remember to quote the previous post when replying, I have just >had to look back at the previous email to find what I suggested last >time. This is a mailing list not a forum, though you may be accessing >it via a forum style interface. >> >>Thanks for the response . I have

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

2012-07-03 Thread cyber c.
Hi Colin, Thanks for the response . I have spent enough time debugging my rails app and found that the default code generated by the rails itself is buggy. I have created a new scaffold for the resource Trial. After creating a new entry, the index page of the resource shows up stale data. (I s

[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

[Rails] Passing values between controllers

2012-06-27 Thread cyber c.
Hi, I have 2 controllers A and B. The create method in controller A is programmed to redirect to B#index method. I want to pass data between my controllers, so i have made use of the params hash. But i cannot access the params hash on the index method of B controller. what is the right way to pass

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi Walter, Thanks for the detailed explanation. I am redirecting to different pages in both the cases(valid and not valid case). Now that i am rendering a new page incase of a validate failure and i see the errors. Thank you very much :) -- Posted via http://www.ruby-forum.com/. -- You rece

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi Walter, The validate* methods works fine on the console. The function object.valid? returns false if any of the validate method fails. For that case object.valid? returns false even in the controller function, but when i redirect to the same url, it doesn't show any errors from the code <%

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi Walter, Yah the ":" came from copy pasting my earlier comment. The result is the same(no errors) with one attribute or using validates_presense_of(tried with other validate* options too). I was wondering if that problem was to do with the view? Anyother way of displaying the errors? -- Post

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi, I'm using rails 3.2.4. I had referred to the activemodel episode from the rail casts and yes i included the initialize and persisted methods as specified. Still i dont see errors when i click the submit button with empty values model class Record include ActiveModel::Validations includ

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi Walter, Thanks for your comments. > > def create -> same for def submit too > > respond_to do |format| > if PARAM matches so and so > DEPENDING on params this gets routed to different page at any point here do you instantiate a new instance of your model, assign the params to it,

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
I'm sorry, I dont know how it ended up in the post , but my code doesnt have the extra colon. Its actually this model class Record include ActiveModel::Validations validates :ipaddress, :name, :presence => true end -- Posted via http://www.ruby-forum.com/. -- You received this message bec

[Rails] Re: Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi, Thanks for the suggestions. I have now included the code to display the error messages. Here is the code for my MVC model class Record include ActiveModel::Validations validates: :ipaddress, :name, :presence => true end View <%= form_for :Record, :url => {:action => 'submit'} do |f

[Rails] Validations doesnt work with activemodel?

2012-06-26 Thread cyber c.
Hi, I have a form with 2 attributes/fields. As im not storing them in a database, i have used activemodel::validations for validations in my model class. In the views file i have 2 associated text fields (part of a form) with a submit button. I have used validates_presence_of for the 2 attribute

[Rails] Re: Problem with submit button

2012-06-22 Thread cyber c.
I can specify the controller using :url => {:action => 'XYZ'} But since I don't have ( nor need) a model file for the form , so what should i write here "?" <%= form_for (?) do |f| %> -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Googl

[Rails] Re: Problem with submit button

2012-06-22 Thread cyber c.
routes.rb have only these get "staticpages/main" get "staticpages/movie" get "staticpages/book" How do i add a route to post method? -- 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

[Rails] Problem with submit button

2012-06-22 Thread cyber c.
Hi, I wanted to create some static pages using rails and used rails g controller Staticpages main movie song book Which has created a controller file "static_pages_controller.erb" and view files under /views/static_pages/main.html.erb etc I have created a form using form_for on my main page which

[Rails] Rails command for creating static pages

2012-06-21 Thread cyber c.
Hi, How do we create static pages using rails(shud have only buttons, some text and upon clicks the appropriate controller should be called)? -- 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

[Rails] Re: Is activeresource broken in rails 3.2.4?

2012-06-20 Thread cyber c.
Found a solution to the problem , the default index methods of the controller should be modified to return records according to the params -- 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 pos

[Rails] validation method breaks cucumber scenario

2012-06-19 Thread Mauro C.
I'm trying to find an effective way to validate the following: I have 3 form fields, a select menu a checkbox and a textfield. They can all be left blank on submission, but if you select two or more it should prompt an error. If the user chooses to, only one field should be allowed to be submitt

[Rails] Re: Problem with exists? method

2012-06-19 Thread cyber c.
Hi Frederick, Activeresource exists doesnt support conditions i think . Even i got confused by activerecord and activeresource exists method. -- 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

[Rails] Re: Is activeresource broken in rails 3.2.4?

2012-06-19 Thread cyber c.
Hi Ryan, Where is not an activeresource method. Here are the list of activeresource methods http://api.rubyonrails.org/classes/ActiveResource/Base.html Also i will be using find to look for records that match multiple conditions like if name = XYZ, build = ABC etc -- Posted via http://www.ruby

[Rails] Re: Is activeresource broken in rails 3.2.4?

2012-06-18 Thread cyber c.
Seems like this has been a problem/bug from earlier versions. http://www.rornoob.com/a/active-resource-find-with-conditions-problem/ Is there a work around for this? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby o

[Rails] Re: Is activeresource broken in rails 3.2.4?

2012-06-18 Thread cyber c.
I dont have a column with "params". Person.find(:all, :conditions => [ "id = ?","9"]) generates a request Started GET "/persons.json" for 127.0.0.1 => hence returns all the records Where as Person.find(:all, {:id => '2'}) generates a request Started GET "/persons.json?id=2" for 127.0.0.1 But *re

[Rails] Is activeresource broken in rails 3.2.4?

2012-06-18 Thread cyber c.
Hi, I see that Person.find(:all) and Person.find(:all, :params => {id => '2'}) returns all records irrespective of conditions. Is activeresource broken? PS: Im using rails 3.2.4 -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Grou

[Rails] Re: Problem with exists? method

2012-06-18 Thread cyber c.
Im sorry i have looked at wrong documentation. I have to use find(:all, :params) -- 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@googlegrou

[Rails] Problem with exists? method

2012-06-18 Thread cyber c.
Hi, I have a DB with table TABLENAME, column COLUMN and an active resource client trying to connect to the DB. When i do Tablename.find(:all) => i get all the entries from the table But Tablename.exists?(:column => value) always returns false I verified that the above command works from rails con

[Rails] Problem with active resource(500 internal server error)

2012-06-15 Thread cyber c.
Hi, I have a rails server running. I wanted to connect to this using activeresource. Executing this code Class Buildclient < ActiveResource::Base self.site = "http://localhost:3000/builds"; end builds = Buildclient.find(:all) puts builds (## printed nil) On the rails server terminal i see St

[Rails] Re: Reading a file using File.read

2012-06-14 Thread cyber c.
I think i understood the problem -- 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 emai

[Rails] Re: Reading a file using File.read

2012-06-14 Thread cyber c.
Im using absolute path. Actually i mounted a directory from remote server anddo a "find" for a specific file and then try reading it. The cmd find passes and returns a valid path to the file. But only the read cmd fails. -- Posted via http://www.ruby-forum.com/. -- You received this mess

[Rails] Reading a file using File.read

2012-06-14 Thread cyber c.
Hi, File.read(VALID_PATH_TO_FILE) works on ruby console but not as a rails application. I dont understand why it fails saying "No such file or directory". Even File.exist? returns false from rails application output but returns true from rails console. It has readable permissions for the current u

[Rails] How to use a text_field for dates?

2012-06-14 Thread Marc C.
Hello, I need to accept dates in a form using a text_field and not a date_select. Why? Well, because for users it's faster to type a date. But if I enter a simple date like "13/05/2012" (dd/mm/ format), when I want to edit this register, in the text_field appears "2012-05-13". How can I chan

[Rails] Re: Cmd line interface for ruby on rails app

2012-06-13 Thread cyber c.
I dont know how it works with out rails server. But what i have now is a) browser based interface to DB to edit/view the records b) Clients can access this remotely What i want is a) cmd line interface (using a ruby script ?) , so that remote clients can use this app/script to interface with the

[Rails] Re: Cmd line interface for ruby on rails app

2012-06-13 Thread cyber c.
Hi Miguel, I think that wont serve my purpose, as i'm building a tool which will help clients to update/create entries in the DB. You mean to say every client has to use rails console and connect to the rails server? -- Posted via http://www.ruby-forum.com/. -- You received this message beca

[Rails] Cmd line interface for ruby on rails app

2012-06-13 Thread cyber c.
Hi, I have a rails app running which provides an interface to create/update data stored in a DB. How do i develop a cmd line interface to do the same i.e i should be able to retrieve/update data to a DB. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are sub

[Rails] Using activeresource for client/server model

2012-06-08 Thread cyber c.
Hi, i have a rails app running which has a DB of records. I wanted to develop a client app which can 1) view the records 2) edit them So i have created a new rails app (for this client) and edited the model file "record.rb" class Record < ActiveResource::Base self.site = "http://0.0.0.0:3000";

[Rails] Can't mass-assign protected attributes:

2012-06-07 Thread cyber c.
Hi, i added a column to my DB using rails g migration AddAttrToTablename attr:string rake db:migrate I didnt change the model file. Should i? Now when i create a new record to the table assigning values to existing attrs and newly added attribute i get this error "Can't mass-assign protected att

  1   2   3   4   >