form-for
Nested attribute not saving in a form with polymorphic associations
I\'m trying to make an app where a user can save goals, milestones for those goals, tasks for the milestones, and tasks for the goal itself. I\'m using polymorphic associations, but making a form to i[详细]
2023-03-19 19:23 分类:问答nested form with polymorphic models
I\'m making an app with the following attributes, and I\'m working on a creating a single form to be able to save a goal, a goal\'s tasks, a goal\'s milestones, and a milestone\'s tasks.[详细]
2023-03-19 15:39 分类:问答Changing the text on a label in form_for
I have this code in my view (for the \"debate\" class): <%= form_for(@debate) do |f| %> ... <%= f.label :proposition, :body %>[详细]
2023-03-19 08:22 分类:问答DRYing up a helper: wrap form_for and access local form variable
I am trying to DRY up a bunch of forms code that has a repeating set of fields appearing at the end of each form. I wrote a helper that wraps around the form_for rails helper. But I\'m starting to get[详细]
2023-03-16 04:15 分类:问答Saving data from select_tag
Trying to save data from a form to the database. Using the select_tag <%= select_tag :size, options_from_collection_for_select(@plan, \'name\', \'size\') %>[详细]
2023-03-15 09:20 分类:问答Form_for Gives Wrong Outputs After render :action=>'edit'
I think this question might have been asked before, but I honestly don\'t know how to search for it. Basically, when I do a render :action => \'edit\' in the update action in controller, somehow the[详细]
2023-03-15 05:53 分类:问答Is it possible to edit different models from the same form when three of the four are nested? How?
How do you handle multiple models in a form? I know that nested models exist, but I\'m not su开发者_JAVA技巧re if this is the same situation. Sorry, a bit new to Rails.[详细]
2023-03-14 17:37 分类:问答Rails 3 rendering form partial in another controller
I have a form partial for a namespaced and nested resource (\"blog/posts/comments\") which so far has been a pain to get working properly. I managed to get it working for the \"开发者_C百科new\" and \[详细]
2023-03-10 23:38 分类:问答Rails: need help displaying a form_for one model in the view of another model
I have two models, Character and Statistic. Their relationship is Character has_one Statistic and Statistic belongs_to Character.[详细]
2023-03-03 09:34 分类:问答Rails not editable text field
I have a form_for written in the following manner: <div class=\"field\"> <%= location.label :city %>[详细]
2023-02-24 07:05 分类:问答