Displaying 3 results from an estimated 3 matches for "contacts_path".
2012 Oct 10
8
link_to with additional data
...a contacts
page - here is the code:
routes.rb
root :to => ''home#index'', :as => ''home''
resource ''contacts''
Haml Home Page View
# I want to be able to display ''bar'' on the contacts page
= link_to "Contacts", contacts_path, :data => {:foo => ''bar''}
The generated html link:
<a href="/contacts <http://localhost:3000/contacts>" data-foo="bar">contacts
</a>
But I don''t receive the foo attribute in the params object in the show
action of ContactsCo...
2009 Aug 27
8
Adding New Column
I added a new column using a migration. Once I updated the
new.html.erb, edit.html.erb, show.html.erb, and the index.html.erb I
brought up my web pages. There was a field to update show. I tried the
update and the it was successful but the update did not show up in any
of the other pages. What did I miss? I am using 2.3.3 of ror.
2012 Jan 15
2
DEPRECATION WARNING: Passing a template handler in the template name is deprecated. (rspec + haml)
...9 end
10
11 it "renders new contact form" do
12 render ####### this render seems to trigger it
13
14 # Run the generator again with the --webrat flag if you want
to use webrat matchers
15 assert_select "form", :action => contacts_path, :method =>
"post" do
16 assert_select "input#contact_email", :name =>
"contact[email]"
17 assert_select "input#contact_person_id", :name =>
"contact[person_id]"
18 end
19 end
20 end
The...