<?php

use Illuminate\Routing\Router;

Admin::routes();

Route::group([
    'prefix'        => config('admin.route.prefix'),
    'namespace'     => config('admin.route.namespace'),
    'middleware'    => config('admin.route.middleware'),
    'as'            => config('admin.route.prefix') . '.',
], function (Router $router) {
    $router->get('/', 'HomeController@index')->name('home');
    $router->get('/home', 'HomeController@index')->name('home');
    $router->get('/api/getCity', 'ApiController@getCity');
    $router->get('/api/getArea', 'ApiController@getArea');
    $router->post('/img_upload', 'Api\ApiController@upload');
    $router->resource('/cdms_user', CdmsController::class);
    $router->resource('/organizations', OrganizationController::class);
    $router->resource('/docters', DocterController::class);


    //文章管理
    $router->resource('articles', ArticleManagement\ArticleController::class);
    //疫苗管理
    $router->resource('vaccines', VaccinesManagement\VaccinesController::class);
    //电话咨询认证
    $router->resource('phone_service_cc',PhoneServiceCCController::class);
    $router->resource('phone_service',PhoneServiceController::class);
    //图文咨询认证
    $router->resource('reply_service',ReplyServiceController::class);
    $router->resource('reply_service_cc',ReplyServiceCCController::class);
    //门诊咨询认证
    $router->resource('outpatient_service_cc',OutpatientServiceCCController::class);
    $router->resource('outpatient_service',OutpatientServiceController::class);

    /*
     * 小程序管理
     */
    //--->用户端
    //公告管理
    $router->resource('notices_user', WeChatProgram\UserManagement\NoticeUserController::class);
    //图标DIV
    $router->resource('icons_user', WeChatProgram\UserManagement\IconsUserController::class);
    //轮播图
    $router->resource('banners', WeChatProgram\UserManagement\BannerController::class);
    //底部菜单
    $router->resource('menubars', WeChatProgram\UserManagement\MenubarController::class);
    //--->医生端
    //图标DIV
    $router->resource('icons_doctor', WeChatProgram\DoctorManagement\IconsDoctorController::class);
    //公告管理
    $router->resource('notices_doctor', WeChatProgram\DoctorManagement\NoticeDoctorController::class);


    /*
     * 服务包管理
     */
    //服务包列表
    $router->resource('service_packs', ServicePacksManagment\ServicePacksController::class);
    //服务包海报
    $router->resource('servebanners', ServicePacksManagment\ServebannerController::class);
    //团队医生
    $router->resource('teams',ServicePacksManagment\TeamController::class);
    $router->resource('team_docter',TeamDocterController::class);
    //开通记录
    $router->resource('open_pack', ServicePacksManagment\OpenPackController::class);

    $router->resource('/setting', 'Config\ConfigController');
    $router->get('/setting_form', 'Config\FormController@form');
    $router->post('/setting_form_save', 'Config\FormController@setting_form_save');

    /*
     * 用户管理->医生管理
     * */
    //认证管理
    $router->resource('/docters_approve', UserManagement\DocterManagement\ApproveController::class);
    //医生管理
    $router->resource('docters_management', UserManagement\DocterManagement\DoctorManagementController::class);
    //医生管理->签约管理
    $router->resource('sign_up', UserManagement\DocterManagement\SignUpController::class);
    //医生管理->团队管理
    $router->resource('docter_team', UserManagement\DocterManagement\DocterTeamController::class);
    //评价管理
    $router->resource('evaluates', UserManagement\DocterManagement\UserEvaluatesController::class);
    //职称类别
    $router->resource('qualifications', UserManagement\DocterManagement\QualificationsController::class);
    //标签管理
    $router->resource('docter_labels', UserManagement\DocterManagement\DocterLabelController::class);
    //服务管理
    $router->resource('docters_service', UserManagement\DocterManagement\ServiceManagementController::class);
        //处理数据
//        $router->put('put', '');
    $router->any('putdata', 'UserManagement\DocterManagement\PutdataController@putdata');
    //服务管理->图文服务配置
    $router->resource('docter_chat', UserManagement\DocterManagement\ChatController::class);
    //服务管理->电话服务配置
    $router->resource('docter_phone', UserManagement\DocterManagement\PhoneController::class);
    //服务管理->门诊预约配置
    $router->resource('docter_appoint', UserManagement\DocterManagement\AppointController::class);
    /*
     * 用户管理->宝妈用户
     * */
    //用户列表
    $router->resource('users', UserManagement\BmUser\UserListController::class);
    //用户列表->查看患者档案
    $router->resource('user_patients', UserManagement\BmUser\UserPatientsController::class);
    //用户列表->服务包管理
    $router->resource('user_order', UserManagement\BmUser\UserServiceController::class);
    //用户列表->余额明细
    $router->resource('user_balance_logs', UserManagement\BmUser\UserBalanceLogController::class);
    //用户管理->优惠券管理
    $router->resource('user_coupons', UserManagement\BmUser\UserCouponsController::class);
    //用户管理->订单数据总览
    $router->resource('user_orders', UserManagement\BmUser\UserOrdersController::class);
    //反馈列表
    $router->resource('feedback', UserManagement\BmUser\FeedBacksController::class);

    /*
     * 订单管理
     * */
    //咨询订单
    $router->resource('consulting_orders', OrdersManagement\ConsultingOrdersController::class);
    //预约订单
    $router->resource('booking_order', OrdersManagement\BookingOrderController::class);
    //服务包管理
    $router->resource('service_pack_order', OrdersManagement\ServicePackOrderController::class);
    //充值订单
    $router->resource('recharge_order', OrdersManagement\RechargeOrderController::class);
    //咨询/预约/服务包订单->订单详情
    $router->resource('orders_details', OrdersManagement\OrdersDetailsController::class);
    //订单记录中->病例意见单
    $router->resource('user_suggests', OrdersManagement\UserSuggestsController::class);
    //评价管理
    $router->resource('orders_evaluates', OrdersManagement\OrdersEvaluate::class);
    //服务包订单中的服务包详情
    $router->resource('service_packs_datails', OrdersManagement\ServicePackDetailsController::class);
    //服务包订单中的服务包订单列表
    $router->resource('service_packs_order_list', OrdersManagement\ServicePackOrderListController::class);
    //保险信息列表
    $router->resource('insurance_list', OrdersManagement\InsuranceListController::class);

    /*
     * 优惠券管理
     * */
    //优惠券列表
    $router->resource('coupons', CouponManagement\CouponManagementController::class);
    //优惠券详情
    $router->resource('coupons_details', CouponManagement\CouponDetailsController::class);
    //优惠券发放->用户列表
    $router->resource('coupon_distribution_user_list', CouponManagement\CouponDistributionUserList::class);
    /*
     * 社区端通告
     * */

    //社区端通告
    $router->resource('community_notices', CommunityNotice\CommunityNotices::class);

    /*
     * 服务审核
     * */

    //服务审核
    $router->resource('service_applys', ServiceManagement\ServiceController::class);

    /*
     * 权限管理
     * */
    $router->resource('cdms_roles', PermissionController::class);

    /*
     * 常见问题
     * */
    $router->resource('helpinfos', HelpInfoController::class);
});

