#1 fix syntax error

This commit is contained in:
2015-08-16 22:57:00 +08:00
parent 9378f88c2a
commit 8d6727fae6
+40 -36
View File
@@ -119,6 +119,7 @@
7 喜欢 post POST: http://localhost:3000/api/v1/posts/3/like
- 返回结果
``` json
{
"msg": "done",
@@ -133,48 +134,51 @@
- 参数
* content
- 返回结果
``` json
{
"msg": "done",
"comments_count": 3
}
```
``` json
{
"msg": "done",
"comments_count": 3
}
```
10 评论列表 GET http://localhost:3000/api/v1/posts/1/comments
- 返回结果:
``` json
[
{
"content": "这篇文章写得很深入,很好",
"likes_count": 0,
"user": "test",
"time": "2015-08-12T22:00:27.556+08:00"
},
{
"content": "太长了,不太好读",
"likes_count": 1,
"user": "test",
"time": "2015-08-12T22:00:42.356+08:00"
},
{
"content": "太长了,不太好读",
"likes_count": 0,
"user": "test",
"time": "2015-08-16T22:48:39.099+08:00"
}
]
```
- 返回结果:
``` json
[
{
"content": "这篇文章写得很深入,很好",
"likes_count": 0,
"user": "test",
"time": "2015-08-12T22:00:27.556+08:00"
},
{
"content": "太长了,不太好读",
"likes_count": 1,
"user": "test",
"time": "2015-08-12T22:00:42.356+08:00"
},
{
"content": "太长了,不太好读",
"likes_count": 0,
"user": "test",
"time": "2015-08-16T22:48:39.099+08:00"
}
]
```
11 喜欢评论 comment: POST http://localhost:3000/api/v1/posts/1/comments/1/like
- 返回结果:
```json
{
"msg": "done",
"likes_count": 1
}
```
- 返回结果:
```json
{
"msg": "done",
"likes_count": 1
}
```
12 取消喜欢评论 comment: POST http://localhost:3000/api/v1/posts/1/comments/1/unlike