In my previous GAE app, I had something like a blog (Post and related Comment)
Posts and Comments where 2 different models such as
class Post(db.Model):
headline = db.StringProperty(required = True)
content = db.TextProperty(required = True)
class Comment(db.Model):
""" Comment object with many-to-one relationship """
content = db.TextProperty(required = True)
post = db.ReferenceProperty(Post, collection_name='comment_set')
Now with db, thanks to the collection_name, I could easily find the comments referring to a post ( aka back reference) using post.comment_set
How are now back references handled in ndb?
Is there a preferred method?
Regards