<?php

use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Route;

Route::group([
    'prefix' => 'users',
    'as'     => 'user.',
], function (Router $router) {
    $router->get('ajax', 'IndexController@ajax')->name('users.ajax');

    $router->get('accounts', 'AccountController@index');
    $router->get('accounts/{account}', 'AccountController@show')->name('account.logs');
    $router->resource('rules', 'RuleController');
    $router->resource('identities', 'IdentitiesController');
    $router->resource('identity_logs', 'IdentityLogController');
    $router->resource('services', 'ServiceController');
    $router->get('sms', 'SmsController@index');
    $router->resource('sms/configs', 'SmsConfigController');
    $router->resource('sms/gateways', 'GatewayController');
    $router->resource('orders', 'OrderController');
    $router->resource('certifications/configs', 'CertificationConfigController');
    $router->resource('certifications', 'CertificationController');

    $router->resource('signs', 'SignConfigController');
    $router->resource('sign_texts', 'SignTextController');
    $router->resource('sign_banners', 'SignBannerController');
    $router->get('stocks', 'StockController@index');
    $router->get('stocks/{stock}/logs', 'StockLogController@index');

});

Route::resource('users', 'IndexController');
