api.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. <?php
  2. use Illuminate\Http\Request;
  3. /*
  4. |--------------------------------------------------------------------------
  5. | API Routes
  6. |--------------------------------------------------------------------------
  7. |
  8. | Here is where you can register API routes for your application. These
  9. | routes are loaded by the RouteServiceProvider within a group which
  10. | is assigned the "api" middleware group. Enjoy building your API!
  11. |
  12. */
  13. $api = app("Dingo\Api\Routing\Router");
  14. $api->version('v1', [
  15. 'namespace' => 'App\Http\Controllers'
  16. ], function ($api) {
  17. $api->get('test', 'IndexController@index');
  18. $api->get('insert', 'IndexController@insert');
  19. $api->get('image_time', 'ImageClassController@image_time');
  20. $api->get('wechat_img', 'IndexController@wechat_img');
  21. $api->get('indexs', 'IndexController@indexs');
  22. $api->get('index', 'IndexController@index');
  23. $api->get('wechat', 'UserController@wechat');
  24. $api->get('basicinfo', 'UserController@basicinfo');
  25. $api->get('image_upload', 'IntegralController@image_upload');
  26. $api->get('token', 'IntegralController@token');
  27. $api->post('/wechat/message', 'WechatController@message');
  28. $api->get('make_sign_code','SignController@make_sign_code');
  29. /**登录相关**/
  30. $api->get('/login/send_code', 'LoginController@send_code');//发送验证码
  31. $api->get('/login/validator', 'LoginController@validator');//验证码手机验证码
  32. $api->get('/login/wechat_login', 'LoginController@wechat_login');//微信登录
  33. $api->post('/pay/message', 'PayController@message');
  34. $api->get('/pay/text', 'PayController@text');
  35. $api->get('/pay/pay_query', 'PayController@pay_query');
  36. /**发起退款**/
  37. $api->post('/pay/refund', 'PayController@sure_code');
  38. /**退款回调**/
  39. $api->post('/pay/send', 'PayController@refund');
  40. /**退款申请**/
  41. // $api->post('/pay/send', 'PayController@sure_code');
  42. $api->get('/send', 'IndexController@send');
  43. $api->group(['middleware' => 'refresh.token'], function ($api) {
  44. /**获取基本信息*/
  45. $api->get('/user/get_info', 'UserController@get_info');
  46. /**获取承诺书**/
  47. $api->get('user/promise_book', 'UserController@promise_book');
  48. /**提交承诺书**/
  49. $api->get('user/submit_promise', 'UserController@submit_promise');
  50. /**报名**/
  51. $api->get('pay/pay', 'PayController@pay');
  52. /**支付结果查询**/
  53. $api->get('pay/get_pay', 'PayController@get_pay');
  54. /**上传图片*/
  55. $api->post('integral/image_upload', 'IntegralController@image_upload');
  56. /**获取排行榜**/
  57. $api->get('rank/rank', 'RankController@rank');
  58. /**上传记录**/
  59. $api->get('user/upload_log', 'UserController@upload_log');
  60. /**报名历史*/
  61. $api->get('user/sign_list', 'PayController@pay_log');
  62. $api->get('user/get_season_log', 'PayController@get_season_log');
  63. /********
  64. * 新 增 *
  65. *******/
  66. //报名凭证
  67. $api->get('sign/look_sign', 'SignController@look_sign');
  68. $api->get('sign/get_sign_info', 'SignController@get_sign_info');
  69. /**确认签到**/
  70. $api->get('sign/sure_sign_user', 'SignController@sure_sign');
  71. /**生成另一种签到码**/
  72. $api->get('sign/make_sign_code', 'SignController@make_sign_code');
  73. /**填写的表单**/
  74. $api->get('pay/get_form', 'PayController@get_form');
  75. /**获取是否得到了相关信息**/
  76. $api->get('pay/get_basic_info', 'PayController@get_basic_info');
  77. /**提交表单**/
  78. $api->post('pay/submit_form', 'PayController@submit_form');
  79. /**查看已经填写的表单**/
  80. $api->post('pay/look_form', 'PayController@look_form');
  81. /**已报名的名单**/
  82. $api->get('enroll/get_enroll_user', 'UserController@get_enroll_user');
  83. /**相册内容**/
  84. $api->get('image/image_time', 'ImageClassController@image_time');
  85. /**查看某一个相册的详情**/
  86. $api->get('image/get_detail', 'ImageClassController@get_detail');
  87. /**收藏某一张图片**/
  88. $api->get('image/like', 'ImageClassController@like');
  89. /**我的收藏**/
  90. $api->get('image/get_like', 'ImageClassController@get_like');
  91. /**获取四种四种情况的人数**/
  92. $api->get('sign/sign_info','SignUpController@sign_info');
  93. /**获取每一种情况的人员列表**/
  94. $api->get('sign/get_sign_detail','SignUpController@get_sign_detail');
  95. /**获取个人的信息**/
  96. $api->get('sign/get_user_detail','SignUpController@get_user_detail');
  97. /**数据统计**/
  98. $api->get('data/data','IndexController@data');
  99. $api->get('data/count_data','IndexController@count_data');
  100. /**查看身份**/
  101. $api->get('/look/look_auth', 'UserController@look_auth');
  102. /*货物排名**/
  103. $api->get('/look/get_rank', 'UserController@get_rank');
  104. /***********/
  105. /**便 签***/
  106. /************/
  107. /**我的便签*/
  108. $api->get('/note/my_note_list','NoteController@my_note_list');
  109. /**展示便签**/
  110. $api->get('/note/show_note','NoteController@show_note');
  111. /**增加修改便签**/
  112. $api->post('/note/add_update_note','NoteController@add_update_note');
  113. $api->post('/note/upload_img','NoteController@upload_img');
  114. /**便签广场**/
  115. $api->get('/note/note_lists','NoteController@note_lists');
  116. /**查看评论**/
  117. $api->get('/note/look_comment','NoteController@look_comment');
  118. /**发表评论**/
  119. $api->post('/note/send_comment','NoteController@send_comment');
  120. /**回复评论**/
  121. $api->post('/note/reply','NoteController@reply');
  122. /**点赞**/
  123. $api->get('/note/click_heart','NoteController@click_heart');
  124. /**分享**/
  125. $api->get('/note/note_share','NoteController@note_share');
  126. $api->get('/note/note_share_img','NoteController@note_share_img');
  127. $api->group(['prefix'=>'message'],function ($api){
  128. //查看留言
  129. $api->get('look_message','MessageController@look_message');
  130. //管理查看留言
  131. $api->get('look_messages','MessageController@look_messages');
  132. /**删除**/
  133. $api->get('delete_message','MessageController@delete_message');
  134. /**精选留言***/
  135. $api->get('look_message_top','MessageController@look_message_top');
  136. /*这位精选**/
  137. $api->get('is_wonderful','MessageController@is_wonderful');
  138. /**这位置顶**/
  139. $api->get('is_top','MessageController@is_top');
  140. /*取消精选**/
  141. $api->get('cancel_wonderful','MessageController@cancel_wonderful');
  142. /**取消置顶**/
  143. $api->get('cancel_top','MessageController@cancel_top');
  144. //留言(☞动作)
  145. $api->post('message','MessageController@message');
  146. //回复留言
  147. $api->post('reply_message','MessageController@reply_message');
  148. $api->post('reply_message','MessageController@reply_message');
  149. });
  150. $api->group(['middleware' => 'checkauth'], function ($api) {
  151. /**显示核销信息**/
  152. $api->get('sign/get_user', 'SignController@get_user');
  153. /**确认核销**/
  154. $api->get('sign/sure_sign', 'SignController@sure_sign');
  155. });
  156. });
  157. $api->get('/index/note_share','NoteController@note_share');
  158. $api->get('/index/note_share_img','NoteController@note_share_img');
  159. $api->get('/index/look_message','MessageController@look_message');
  160. });