Skip to content

Commit 33a4287

Browse files
author
qiang.sun
committed
修改文章列表API返回日期格式
1 parent 6478bbc commit 33a4287

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/Http/Controllers/API/PostController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public function index(Request $request)
1919
$item['title'] = $post->title;
2020
$item['summary'] = $post->subtitle;
2121
$item['thumb'] = url(config('blog.uploads.webpath') . '/' . $post->page_image);
22-
$item['posted_at'] = $post->published_date;
22+
$item['posted_at'] = $post->publish_date;
2323
$item['views'] = mt_rand(1, 10000); // 暂时没有实现文章浏览数逻辑,返回随机数
2424
$items[] = $item;
2525
}

0 commit comments

Comments
 (0)