search for: projects_help

Displaying 4 results from an estimated 4 matches for "projects_help".

Did you mean: projects_helper
2008 Jun 18
7
Object Task at episode 74 of railscasts
...74 <http://railscasts.com/episodes/74>, Ryan has a model "project" that can have many "tasks", and he uses link_to_function to dynamically add a field in the form for a new Task. In order to do that he created a helper called add_task_link. The code of the method is: # projects_helper.rb def add_task_link(name) link_to_function name do |page| page.insert_html :bottom, :tasks, :partial => ''task'', :object => Task.new end end The problem i have here is that i can''t figure out where does this Task object, which he instantiate with Task.ne...
2009 Dec 18
2
Undefined Method error - help request
...even means, aside from the name, and I can''t figure out an action based on having an apparently bad path. Diagnosis hints would be much appreciated. 2. In the ''proper MVC / Rails'' realm - should my method be in the controller, or somewhere else? I tried moving it to the projects_helper and application_helper files assuming that this would help Rails connect the dots to the appropriate path, but that did not work and ''felt wrong''. 3. My code is probably suboptimal - like I said, I''m just learning RoR and Ruby. Suggestions in that realm, especially if...
2011 Nov 04
1
add dynamic nested attributes without nested form gem
Hello people In my rails 3.0.9 app I''m trying to add nested attributes dynamically, but I don''t want to use "nested form gem" So I found this example https://github.com/alloy/complex-form-examples/blob/a234fde4419836f277d7e340657f1d8418911d68/app/helpers/projects_helper.rb but this code doesn''t work module ProjectsHelper def remove_link_unless_new_record(fields) unless fields.object.new_record? out = '''' out << fields.hidden_field(:_delete) out << link_to_function("remove", "$ (this)...
2007 Oct 10
2
RSpec seems to be having a hard time loading Helper classes
...or) from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/dependencies.rb:452:in `const_missing'' from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/dependencies.rb:464:in `const_missing'' from ./spec/helpers/projects_helper_spec.rb:3 from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/dependencies.rb:488:in `load'' from /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/dependencies.rb:488:in `load'' from /usr/local/lib/ruby/gems...