123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- <?php
- use Illuminate\Http\Request;
- /*
- |--------------------------------------------------------------------------
- | Application Routes
- |--------------------------------------------------------------------------
- |
- | Here is where you can register all of the routes for an application.
- | It is a breeze. Simply tell Lumen the URIs it should respond to
- | and give it the Closure to call when that URI is requested.
- |
- */
- /** @var TYPE_NAME $api */
- $api = app('Dingo\Api\Routing\Router');
- $api->version('v1',[
- 'namespace'=>'App\Http\Controllers'
- ],function ($api){
- $api->group([
- 'middleware' => 'api.throttle',
- 'limit' => 1000,
- 'expires' => 1,
- ],function ($api){
- $api->post('/pay/return','PayController@message');
- $api->post('/pay/refound','PayController@refound');
- $api->get('/user/login','WechatController@login');//获取openid,判断是否有此用户 xin----
- $api->post('/user/SaveUserAvatar','UserController@SaveUserAvatar');//获取openid,判断是否有此用户
- $api->group(['middleware' => 'jwt.auth'], function($api) {
- $api->get('user/messageroll','UserController@get_roll');
- $api->get('user/SaveUserInfo','UserController@SaveUserInfo');
- $api->post('/user/update_phone','UserController@update_phone');//修改手机号
- $api->get('/user/return_userinfo','UserController@return_userinfo');//修改手机号
- $api->get('/course/course_list','CourseController@course_list');
- $api->get('/course/GetSeason','CourseController@GetSeason');
- $api->get('/user/account_status','UserController@account_status');//xin---
- $api->get('basic/GetRule','UserController@GetRule');
- });
- });
- $api->group([
- 'middleware' => 'api.throttle',
- 'limit' => 5000,
- 'expires' => 1,
- ], function($api) {
- $api->get('/user/send_verify','VerificationCodesController@store'); //发送验证码(先判断卖帮帮中是否有此用户)
- $api->post('/pay/refunds','PayController@sure_code');//验证验证码,同时创建用户,返回信息
- });
- $api->post('/user/verify_code','UserController@store');//验证验证码,同时创建用户,返回信息
- $api->get('/user/GetUpgradeInfo','UserController@GetUpgradeInfo');//
- $api->get('/version','IndexController@index');
- $api->get('/weixinUrl','WechatController@weixinUrl');
- });
|