Displaying 3 results from an estimated 3 matches for "shirkav".
Did you mean:
sharka
2009 May 18
1
Rails + AJAX + mootools
...m with ajax an error occur that said something like
"authentication token error". I have read that i need to include
inside the form a hidden with the authentication token, this approach
fix the problem and everything worked, but i am not sure if this is
secure or not? any idea
Regards,
Shirkavand
2009 Feb 12
4
routes
I''m trying to figure this.
in my schools controller i want to do this....
# implement a create action to create just the review for the
School...
def create_review_for_a_school
@review = Review.new
@school = School.find(params[:school_id])
@review = @school.reviews.build(params[:review])
if @review.save # The creation worked....do this
flash[:notice] =
2009 May 24
6
belongs_to not saving foreign key
Under Rails 2.3.2 using a completely brand new project, I have 2
models:
class Author < ActiveRecord::Base
# name:string
end
class Book < ActiveRecord::Base
# title:string
belongs_to :author # author_id
end
And a simple test where i create a Book with an Author using the
belongs_to and then update the foreign key directly:
require ''test_helper''
class BookTest