Error using store layout for admin
Kyle Murphy
3 posts
|
I’m on page 174, right where we add the store layout to the application controller. Then, when I navigate to http://localhost:3000/admin, I get this Exception: ActionView::ActionViewError in Admin#login Showing layouts/store.html.erb where line #25 raised: Couldn’t find template file for admin/_cart in [“C:/Documents and Settings/bah/My Documents/NetBeansProjects/Depot/app/views”] Extracted source (around line #25): 22: 23: <!- START_HIGHLIGHT -> 25: <%= render(:partial => “cart”, :object => @cart) %> 27: This is obviously due to not having _cart.html.erb in the admin view folder, but I would think the book would account for that, so I must be doing something wrong. Help? |
Sam Ruby
196 posts
|
The next printing of the book will have little arrows next to all of the lines that you need to insert. This printing neglected to highlight the insertion of <% if @cart > and < end %> around that line. The full version of that file should look like this: http://media.pragprog.com/titles/rails3/code/depot_q/app/views/layouts/store.html.erb |
2 posts, 2 voices
