菜谱项目

api.php 2.3KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?php
  2. /*
  3. |--------------------------------------------------------------------------
  4. | API Routes
  5. |--------------------------------------------------------------------------
  6. |
  7. | Here is where you can register API routes for your application. These
  8. | routes are loaded by the RouteServiceProvider within a group which
  9. | is assigned the "api" middleware group. Enjoy building your API!
  10. |
  11. */
  12. $api = app('Dingo\Api\Routing\Router');
  13. $api->version('v1', ['namespace' => 'App\Api\V1\Controllers'], function ($api) {
  14. // $api->group(['middleware' => 'sign.token'], function($api) {
  15. //功能列表
  16. $api->post('features/getCategoryList', 'FeaturesController@getCategoryList');
  17. $api->post('features/getTagList', 'FeaturesController@getTagList');
  18. $api->post('features/getMenuList', 'FeaturesController@getMenuList');
  19. $api->post('features/getMenu', 'FeaturesController@getMenu');
  20. $api->post('features/getRecommend', 'FeaturesController@getRecommend');
  21. $api->post('features/getBannerRecommend', 'FeaturesController@getBannerRecommend');
  22. $api->post('features/getRecommendTag', 'FeaturesController@getRecommendTag');
  23. $api->post('features/selectIngredients', 'FeaturesController@selectIngredients');
  24. $api->post('features/selectTag', 'FeaturesController@selectTag');
  25. $api->post('features/selectAll', 'FeaturesController@selectAll');
  26. $api->post('features/getHotSearch', 'FeaturesController@getHotSearch');
  27. $api->post('features/feedBack', 'FeaturesController@feedBack');
  28. //收藏
  29. $api->post('features/addCollection', 'FeaturesController@addCollection');
  30. //2.0菜谱
  31. //早中晚专题
  32. $api->post('features/earlyMiddleAndLateTheme', 'FeaturesController@earlyMiddleAndLateTheme');
  33. //其他专题
  34. $api->post('features/otherTheme', 'FeaturesController@otherTheme');
  35. //最近50条菜谱
  36. $api->post('features/theLastRecipes', 'FeaturesController@theLastRecipes');
  37. //菜谱列表详情
  38. $api->post('features/menuList', 'FeaturesController@menuList');
  39. //菜谱详情
  40. $api->post('features/menuDetail', 'FeaturesController@menuDetail');
  41. //文章列表
  42. $api->post('features/articleList', 'FeaturesController@articleList');
  43. //文章详情
  44. $api->post('features/articleDetail', 'FeaturesController@articleDetail');
  45. //发现页面
  46. $api->post('finds/getFinds', 'FindsController@getFinds');
  47. });