Silent 6 years ago
parent
commit
b003733357
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/Http/Controllers/WeChat/ApiController.php

+ 2 - 2
app/Http/Controllers/WeChat/ApiController.php

@@ -306,7 +306,7 @@ class ApiController extends Controller
             }
             }
             $article_list = Content::where('type', 4)->orderBy('sort')->offset($article_offset)->limit(15)->get();
             $article_list = Content::where('type', 4)->orderBy('sort')->offset($article_offset)->limit(15)->get();
             foreach($article_list as $item) {
             foreach($article_list as $item) {
-                $item->pulish_date = substr($item->updated_at, 0, 10);
+                $item->publish_date = substr($item->updated_at, 0, 10);
             }
             }
             return response()->json(['status' => 'success', 'video_list' => $video_list, 'article_list' => $article_list, 'type' => $request->input('type')]);
             return response()->json(['status' => 'success', 'video_list' => $video_list, 'article_list' => $article_list, 'type' => $request->input('type')]);
         } else if($request->input('type') == 'video') {
         } else if($request->input('type') == 'video') {
@@ -322,7 +322,7 @@ class ApiController extends Controller
         } else {
         } else {
             $list = Content::where('type', 4)->orderBy('sort')->offset($article_offset)->limit(15)->get();
             $list = Content::where('type', 4)->orderBy('sort')->offset($article_offset)->limit(15)->get();
             foreach($list as $item) {
             foreach($list as $item) {
-                $item->pulish_date = substr($item->updated_at, 0, 10);
+                $item->publish_date = substr($item->updated_at, 0, 10);
             }
             }
         }
         }