show-exam

This commit is contained in:
xiaomlove
2021-04-25 21:28:58 +08:00
parent 512af7511d
commit 7cfde3f95b
13 changed files with 206 additions and 17 deletions

15
include/eloquent.php Normal file
View File

@@ -0,0 +1,15 @@
<?php
use \Illuminate\Database\Capsule\Manager as Capsule;
$config = require ROOT_PATH . 'config/nexus.php';
$connectionMysql = $config['mysql'];
$connectionMysql['driver'] = 'mysql';
$connectionMysql['charset'] = 'utf8mb4';
$connectionMysql['collation'] = 'utf8mb4_unicode_ci';
$capsule = new Capsule;
$capsule->addConnection($connectionMysql, 'default');
$capsule->setAsGlobal();
$capsule->bootEloquent();