It is an app for Painless Rails project.
To develop a system where auhor can post new book chapters, and reviewer can add comments to chapters. To make it more fun, everyone can also add likes to comments. Chapters can be in these statuses: draft, on review, approved, published. Only author can change status. Status can’t be changed to “approved” if less than 50% of paticipants commented on it. Author can also update a chapter. Chapter update generates a special type of comment saying that “chapter was updated”. This comment can’t be liked, and doesn’t counts as a comment when we calculate if 50% people have left feedback.
- Registration
- Session
- Users (index, show)
- Chapter CRUD
- Comment CRUD
- Chapter::Comment::Like CRUD
- Chapter workflow with state-machine
- Nested ApplicationController O_o
- Deploy to Heroku with seeds
rails s
open localhost:3000/apipie
rails db:setup
rails s
rspec spec/
# api
open chapter-rails-jsonapi.herokuapp.com
# apipie
open 'https://chapter-rails-jsonapi.herokuapp.com/apipie'
user1email@tmail.com:super_pass
user2email@tmail.com:lololo