1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-15 00:04:04 +00:00

Use seeder params in tenants:seed instead of just the automatic seeder (#317)

* Use seeder params in tenants:seed instead of just the automatic seeder

* Left trim - from option names

* Use no seeder params for tests
This commit is contained in:
Samuel Štancl 2020-03-17 15:59:45 +01:00 committed by GitHub
parent 776af4643c
commit 526f0826a4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 9 deletions

View file

@ -52,6 +52,10 @@ class Seed extends SeedCommand
$this->input->setOption('database', $tenant->getConnectionName());
foreach (config('tenancy.seeder_parameters') as $parameter => $value) {
$this->input->setOption(ltrim($parameter, '-'), $value);
}
$tenant->run(function () {
// Seed
parent::handle();