Skip to content
This repository has been archived by the owner on May 21, 2018. It is now read-only.

Ability to 'like' a post #20

Open
8 tasks
GautamGupta opened this issue Oct 14, 2017 · 0 comments
Open
8 tasks

Ability to 'like' a post #20

GautamGupta opened this issue Oct 14, 2017 · 0 comments

Comments

@GautamGupta
Copy link
Member

GautamGupta commented Oct 14, 2017

Backend:

  • Create a new table to store post id, user id, like timestamp (created_at)
  • Add a new column to posts table to store a cached value of the # likes
  • Add backend methods to like and unlike topics performing the 2 db operations above
  • Add backend method to know if the user currently likes the topic.
  • Add a new route and controller logic to like the topic for the current user (this will be used by frontend)
  • Add tests

Frontend:

  • Add javascript logic to show the like/unlike link and perform the XHR request
  • Handle errors
@GautamGupta GautamGupta changed the title Ability to 'like' a post/topic Ability to 'like' a post Oct 14, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant