mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 18:34:04 +00:00
custom path
This commit is contained in:
parent
6e513c49f4
commit
9c9a3d09fc
1 changed files with 6 additions and 1 deletions
|
|
@ -230,7 +230,12 @@ test('path used by sqlite manager can be customized', function () {
|
||||||
})->toListener());
|
})->toListener());
|
||||||
|
|
||||||
// Set custom path for SQLite file
|
// Set custom path for SQLite file
|
||||||
SQLiteDatabaseManager::$path = $customPath = storage_path();
|
SQLiteDatabaseManager::$path = $customPath = database_path('custom');
|
||||||
|
|
||||||
|
if (! is_dir($customPath)) {
|
||||||
|
// Create custom directory
|
||||||
|
mkdir($customPath);
|
||||||
|
}
|
||||||
|
|
||||||
$name = Str::random(8). '.sqlite';
|
$name = Str::random(8). '.sqlite';
|
||||||
Tenant::create([
|
Tenant::create([
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue