PHP code example of chujc / v-admin
1. Go to this page and download the library: Download chujc/v-admin library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
chujc / v-admin example snippets
// 打开下面的注释
$app->withFacades();
$app->withEloquent();
// 添加内容
$app->configure('filesystems');
$app->register(Tymon\JWTAuth\Providers\LumenServiceProvider::class); // jwt
$app->register(ChuJC\Admin\AdminServiceProvider::class);
$app->register(Maatwebsite\Excel\ExcelServiceProvider::class); // 因需要导出excel 所以需要添加laravel-excel依赖包,如果不需要导出功能可以不需要
$app->factory('Admin');
$app->factory('Captcha');
if ($exception instanceof ValidationException) {
return Result::failedData($exception->response->original, $exception->getMessage(), 422);
}