mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 12:54:05 +00:00
* Stop bypassing tenancy initialization when host is central domain in domain ID MW * Delete dataset for testing global domain ID MW + route-level prevent access MW * Provide ID MW statically in TenantAssetController * Fix code style (php-cs-fixer) --------- Co-authored-by: PHP CS Fixer <phpcsfixer@example.com>
16 lines
595 B
PHP
16 lines
595 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
use Illuminate\Support\Facades\Route;
|
|
use Stancl\Tenancy\PathIdentificationManager;
|
|
use Stancl\Tenancy\Controllers\TenantAssetController;
|
|
|
|
Route::get('/tenancy/assets/{path?}', TenantAssetController::class)
|
|
->where('path', '(.*)')
|
|
->name('stancl.tenancy.asset');
|
|
|
|
Route::prefix('/{' . PathIdentificationManager::getTenantParameterName() . '}/')->get('/tenancy/assets/{path?}', TenantAssetController::class)
|
|
->where('path', '(.*)')
|
|
->middleware('tenant')
|
|
->name(PathIdentificationManager::getTenantRouteNamePrefix() . 'stancl.tenancy.asset');
|