Commit Graph

14 Commits

Author SHA1 Message Date
Greg Price
df3e6535dc Add "following" parameter to thread creation
This allows authors to follow the thread immediately upon creation.
2015-05-27 10:58:14 -04:00
Greg Price
f891450f50 Add thread creation to discussion API
Also, fix the field-specific error format for all API endpoints.

This requires cs_comments_service commit fdf017c918.
2015-05-26 12:42:40 -04:00
Greg Price
c83f56153e Add comment list URLs to discussion api threads 2015-05-21 15:03:02 -04:00
Greg Price
c65893e9e0 Add endorsement fields to comment list API 2015-05-21 11:35:39 -04:00
Greg Price
2451e06788 Add comment list endpoint to Discussion API 2015-05-20 13:13:19 -04:00
Greg Price
7309352ef7 Refactor discussion API to use DRF serializer
This will make it easier to add the creation and update interfaces.
2015-05-18 14:03:02 -04:00
Greg Price
565cdb8edf Move Discussion API access control checks
The checks are now within the Python API instead of the DRF view. This
will be necessary for certain operations (like fetching/editing threads)
because the relevant course cannot be known until the thread is fetched
from the comments service. This commit updates the existing endpoints to
fit that pattern.
2015-05-18 14:03:02 -04:00
Greg Price
6189cf9b41 Fix type field in thread list endpoint
The API's type field should come from the CS data's thread_type field,
not its type field, which distinguishes comments from threads.
2015-05-11 16:07:07 -04:00
Greg Price
7ce579c274 Add group fields to thread list endpoint 2015-05-11 15:59:35 -04:00
Greg Price
b1a9d33472 Add authorship data to thread list endpoint 2015-05-11 15:59:34 -04:00
Greg Price
fa6e5338c2 Add fields to discussion thread list endpoint
This commit adds fields that are related to the requesting user's
interaction with the thread (e.g. following).
2015-05-11 15:59:34 -04:00
Greg Price
603eae65d8 Add params to CS query in thread list endpoint
The thread list endpoint needs to restrict the set of threads it
retrieves if the course is cohorted and the user is not privileged.
This also adds an explicit default sort (by most recent activity).
2015-05-07 15:59:23 -04:00
Greg Price
90f28dce31 Add thread list endpoint to the new discussion API
This is an initial implementation that only allows retrieval of all
threads for a course and only returns an easily computed subset of the
fields that are needed, in order to keep this change from getting too
large.

JIRA: MA-641
2015-05-05 11:45:09 -04:00
Greg Price
ebff94af3f Add discussion topic API
This is the first stage of the new Discussion API.

JIRA: MA-604
2015-04-30 14:25:05 -04:00