typo
This commit is contained in:
parent
20e1f44605
commit
f91171441e
|
|
@ -7,12 +7,13 @@ use App\Jobs\Auth\CreateUser;
|
||||||
use App\Jobs\Common\CreateCompany;
|
use App\Jobs\Common\CreateCompany;
|
||||||
use App\Jobs\Common\CreateContact;
|
use App\Jobs\Common\CreateContact;
|
||||||
use App\Traits\Jobs;
|
use App\Traits\Jobs;
|
||||||
|
use App\Traits\Modules;
|
||||||
use Artisan;
|
use Artisan;
|
||||||
use Illuminate\Database\Seeder;
|
use Illuminate\Database\Seeder;
|
||||||
|
|
||||||
class TestCompany extends Seeder
|
class TestCompany extends Seeder
|
||||||
{
|
{
|
||||||
use Jobs;
|
use Jobs, Modules;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Run the database seeds.
|
* Run the database seeds.
|
||||||
|
|
@ -40,20 +41,14 @@ class TestCompany extends Seeder
|
||||||
|
|
||||||
private function migrateRoles()
|
private function migrateRoles()
|
||||||
{
|
{
|
||||||
$modules = module()->all();
|
if (! $this->moduleExists('roles')) {
|
||||||
|
return;
|
||||||
foreach ($modules as $module) {
|
|
||||||
$alias = $module->getAlias();
|
|
||||||
|
|
||||||
if ($alias !== 'roles') {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
Artisan::call('module:migrate', [
|
|
||||||
'alias' => 'roles',
|
|
||||||
'--force' => true
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Artisan::call('module:migrate', [
|
||||||
|
'alias' => 'roles',
|
||||||
|
'--force' => true
|
||||||
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
private function createCompany()
|
private function createCompany()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue