@@ -60,4 +60,15 @@ class BeanDetailController extends Controller
return $this->jsonSuccess();
}
+
+ //不登录单独返回每日新闻、小贴士
+ public function lists(Request $request)
+ {
+ $star_lists = $this->beanRepository->lists($request->all());
+ if ($star_lists){
+ return $this->jsonSuccess($star_lists);
+ }else{
+ return $this->jsonSuccess();
+ }
@@ -304,4 +304,14 @@ class BeanRepository
+ public function lists($request)
+ $star_lists = [];
+ $star_lists['daily_news'] = $this->getNews($request);
+ $star_lists['tips'] = $this->getPlatformContent($id = 1);
+ return $star_lists;
@@ -105,5 +105,6 @@ $api->version('v1', [
//分享/邀请首页
$api->get('starDetail', 'BeanDetailController@starDetail');
-
+ $api->get('/starHome/lists', 'BeanDetailController@lists');
});