ConfigSeeder

This commit is contained in:
邓皓元 2019-01-16 10:40:31 +08:00
parent 147d5e760e
commit 5da1b4cb52
2 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,31 @@
<?php
use Illuminate\Database\Seeder;
use App\Domains\Config\Services\ConfigService;
class ConfigSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
if (ConfigService::get('logistics')) {
return ;
}
ConfigService::set('logistics', [
'sf' => '顺丰速运',
'sto' => '申通快递',
'yto' => '圆通速递',
'zto' => '中通快递',
'best' => '百世快递',
'yunda' => '韵达快递',
'ttkd' => '天天快递',
'ems' => 'EMS邮政特快专递'
]);
}
}

View File

@ -16,5 +16,6 @@ class DatabaseSeeder extends Seeder
$this->call(AccountSeeder::class);
$this->call(PermissionSeeder::class);
$this->call(CompanyAccountSeeder::class);
$this->call(ConfigSeeder::class);
}
}