Displaying 5 results from an estimated 5 matches for "notescontroller".
Did you mean:
notes_controller
2006 Dec 11
1
Index help on Polymorphic Associations
...ype => {}}
belongs_to :notable, :polymorphic => true
..........
But when i searched for a project with the note ''test'':
@results = Project.find_by_contents(''test'')
it returns 0 results. I checked in the logs and it created the index:
Processing NotesController#create (for 127.0.0.1 at 2006-12-11 13:53:53)
[POST]
.......
creating doc for class: Note, id: 17
Adding field notable_id with value ''9'' to index
Adding field details with value ''test project 9'' to index
Adding field notable_type with value ''Project'...
2006 Mar 04
10
Help setting up relationships needed
...ooks chronologically like this.
Book One: This is the note.
Book Four: This is the note.
Book One: A different note, entered later.
Right now my models are:
User
has_many :books
Book
has_many :notes
belongs_to :user
Note (has column book_id)
belongs_to :book
has_one :book
The NotesController has:
@books = current_user.books.find(:all)
@notes = @books.notes
In my views/notes/list.rhtml I can get all the notes fine, but what I
can''t get is what book they belong to.
<% for note in @notes %>
Doesn''t work: <%= note.book.title %>
Works: <%= note.descri...
2007 Sep 14
2
Testing a nested controller
Hey everyone.
I really stuck on testing a nested controller. I''m trying to make a
request using get and afterwards checking the response by
response.should ...
My routes.rb looks like this:
map.resources :writers do |writers|
writers.resources :notes
end
In my notes_controller_spec.rb
def do_get
writer_id = 1
note_id = 1
get note_path(writer_id, note_id)
end
it "should show
2007 Jul 18
16
Edge Rails namespaced routing
Hi,
I was wondering if anyone came across a similar scenario when working
with namespaced routes with edge rails.
Consider an application with controllers customers and products that
also have other resources.
map.resources :customers do |customer|
customer.resources :notes
customer.resources :tags
end
map.resources :products do |product|
customer.resources :notes
customer.resources
2009 Jul 29
9
partials...
I am getting a blank page, no errors, just a blank page.
I have 2 files...
reports/city_taxes_print.erb
reports/_city_taxes_print.erb
and my method is city_taxes_print and after getting variables from the
controller, my erb file which is fairly basic...
<% # City of Scottsdale
@taxauthids = [ "32", "40" ]
@report_title = "Scottsdale Sales Tax Detail Report for