mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 12:24:04 +00:00
improve sample RootUrlBootstrapper config
This commit is contained in:
parent
dc90e60a2f
commit
27685ffe5a
1 changed files with 11 additions and 8 deletions
|
|
@ -149,14 +149,17 @@ class TenancyServiceProvider extends ServiceProvider
|
||||||
// $tenantDomain = $tenant instanceof \Stancl\Tenancy\Contracts\SingleDomainTenant
|
// $tenantDomain = $tenant instanceof \Stancl\Tenancy\Contracts\SingleDomainTenant
|
||||||
// ? $tenant->domain
|
// ? $tenant->domain
|
||||||
// : $tenant->domains->first()->domain;
|
// : $tenant->domains->first()->domain;
|
||||||
|
//
|
||||||
// $scheme = str($originalRootUrl)->before('://');
|
// $scheme = str($originalRootUrl)->before('://');
|
||||||
//
|
//
|
||||||
// // If you're using domain identification:
|
// if (str_contains($tenantDomain, '.')) {
|
||||||
|
// // Domain identification
|
||||||
// return $scheme . '://' . $tenantDomain . '/';
|
// return $scheme . '://' . $tenantDomain . '/';
|
||||||
//
|
// } else {
|
||||||
// // If you're using subdomain identification:
|
// // Subdomain identification
|
||||||
// $originalDomain = str($originalRootUrl)->after($scheme . '://');
|
// $originalDomain = str($originalRootUrl)->after($scheme . '://')->before('/');
|
||||||
// return $scheme . '://' . $tenantDomain . '.' . $originalDomain . '/';
|
// return $scheme . '://' . $tenantDomain . '.' . $originalDomain . '/';
|
||||||
|
// }
|
||||||
// };
|
// };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue