[Rails] Doubt in Routes

2014-06-04 Thread Daynthan Kabilan
Hi, I have one doubt in routes, Scenarios: Format -1: http://localhost:3000/city/category/sub-category/user-name/product-name I have written the routes for the above format-1 match '/:city-ca/:categ/:sub

[Rails] doubt on image_tag

2012-04-22 Thread Mr Hello Derp
Hello, I am very new to ruby on rails and I am facing little problem with image_tag. I have two controller product and items. In product view, I have a partial called _show.html.erb. And in items view, i call index of item to display all products. The problem is, when user clicks on the image_tag

[Rails] Doubt about checkboxes and actions

2012-03-18 Thread Andre Luiz
I am developing and app that adds tasks to the DB and show them on the screen. Now I have to list all those tasks with check-boxes, and two buttons, one will delete the selected and another will add update the task (add the string DONE). Don't have any idea how to proceed, thanks. -- You received

Re: [Rails] DOUBT

2011-10-01 Thread Dave Aronson
On Wed, Sep 28, 2011 at 08:18, sithara suresh wrote: > I NEED TO CREATE A CONSTANT SUCH THAT IT CAN NEVER BE ALTERED..IN RUBY > > Is it possible?? Yes, but shouting isn't going to do it. Meanwhile, see http://lmgtfy.com?q=ruby+constant . -Dave -- LOOKING FOR WORK, preferably Ruby on Rails, i

Re: [Rails] DOUBT

2011-10-01 Thread Max Schubert
Please be more specific about what you mean by 'never be altered' - what use case / situation are you resolving? On 9/28/11, sithara suresh wrote: > I NEED TO CREATE A CONSTANT SUCH THAT IT CAN NEVER BE ALTERED..IN RUBY > > Is it possible?? > > -- > You received this message because you are subsc

[Rails] DOUBT

2011-10-01 Thread sithara suresh
I NEED TO CREATE A CONSTANT SUCH THAT IT CAN NEVER BE ALTERED..IN RUBY Is it possible?? -- 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 grou

[Rails] Doubt with symbols in Rails

2010-10-16 Thread Arun Srini
I was trying to write a wrapper for number_to_currency to return currency in pounds. I used a helper class to do this. def number_to_pounds(amt) number_to_currency(amt, :unit => "£") end This works fine, but I am trying to understand why I can't use a symbol to pass the values. I thought symbol

[Rails] doubt in attachment

2009-11-11 Thread karthik k
Hi I have some four items in the page one among that is attachment when i leave one mandatory field blank and attach one file and hit submit it will say as one field is mandatory but the path is not available Please guide me -- Karthik.k Mobile - +91-9894991640 --~--~-~--~~

[Rails] doubt with helper

2009-08-21 Thread alexander
Hi all I need help I have in my application helper this function: def example content_for(:meta) do 'okis dokis' end end And in my main layout view: .. - yield(:meta) ... And in other view layer this: ... - example ... In development mode all this works, but in production in a serv

[Rails] Doubt in joins condition?

2009-08-10 Thread karthik k
hi I have two tables agencies contracts i have one statement like below @getdata=Agency.all(:joins=>:contracts, :select=>"agencies.*",:conditions=>["agencies.status =?",1 ]) i am able to access all data in agency but not able to access contracts data from above query please guide me how

[Rails] Doubt in retrieving data to html?

2009-08-10 Thread karthik k
hi I have a controller def showagencies @getdata=Agency.all(:joins=>:contracts, :select=>"agencies.*",:conditions=>["contract_id in (?) and agencies.status =?",contracts.id,1 ]) end @getdata is not visible in html its lenght is o but has some contents plz let me know how to access this

[Rails] Doubt in submit_to_remote?

2009-08-09 Thread karthik k
hi i have one page where i have check boxes , when i select one check box and click the below <%= submit_to_remote 'activate', 'Activate', :url => {:action => 'search_activate'} %> below is my check box <%= check_box_tag "agency[agencys_id][]" , agency.id%> it is not even going to controller

[Rails] Doubt retrieving data?

2009-08-08 Thread karthik k
hi my controller has def searchwithstatus @agency=params[:agency][:agency_id] @contract=params[:agency][:contracts_id] @agencies=Agency.find(:all,:conditions=>{:deleted=>1,:contract_id=>@contract,:state_id=>@state}) end when i am executing the code in line 3 it is saying as *"Mysql::Error: Un

[Rails] Doubt in retrievind data from habtm?

2009-08-05 Thread karthik k
hi I have one table called agencies_contract i need to get data from this table agency_idcontract_id 11 so i need to display agency_id equivalent to 1 and contract_id equivalent to 1 this table has habtm relation how do i need to write query for this any idea Plz

[Rails] Doubt in nil object with ajax

2009-07-28 Thread karthik k
hi this is my htnl <%= javascript_include_tag :defaults %> <%= form_tag nil, { :id => 'search_form' } %> <%= text_field 'recipe', 'name' %> <%= end_form_tag %> <%= observe_form :search_form, :frequency => 0.5, :update => 'recipe', :url => { :action => 'search_ajax' } %> be

[Rails] doubt

2009-05-09 Thread venky
Hi all, I have a doubt. sorry if it sounds silly. Is ruby a programming language or scripting language?. Thanks, Venkat http://www.prog2impress.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: T

[Rails] Doubt in web space Allocation

2008-10-22 Thread dark2imperial
Suppose there is a social networking site for uploading and sharing videos developed in rails. It has subscription packages like Free - 1 gb, Pro - 5 gb and Plus - 10 gb. How do they allocate the space for a particular user for a particular subscription package automatically? Thank you --~--~---

[Rails] Doubt in disk quota

2008-10-20 Thread Rock Roll
Hi. I have a small doubt. 37signals, a company where the creator of Rails works has a project management application called basecamp. It is subscription based and its plans are based on the number of users and disk space allotted for each plan. My doubt is how they allocate the disk space instantl