I have a small suggestion that will be very helpful to n00bs like me regarding
http://web2py.com/book/default/chapter/13#Components
The following is the correct code snippet from the correct code snippet
@auth.requires_login()
def post():
return
dict(form=crud.create(db.comment), comments=db(db.comment.id>0).select())
However, in the context of my code, I did
@auth.requires_login()
def post():
comments=db(db.comment.id>0).select()
return dict(form=crud.create(db.comment), comments=comments)
What happens here is that the component that is acquired by LOAD upon form
submission is still the old set of rows. I spent quite some time figuring it
out
unfortunately. Perhaps this point could be highlighted in the book.