Implementing the Model-Based Controller Routes

In addition to implementing the standard route handling, you also need to implement route handling to interact with the database. You break these route handlers out of the standard comments_route.js file and into their own files for each model, to keep the code clean and ensure a good division of responsibilities.

The following sections cover the implementation of the model-specific controllers for the Page, Photo, and CommentThread models.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.58.3.72