env→config
このコミットが含まれているのは:
コミット
e711e1373d
|
@ -34,9 +34,12 @@ MAIL_PASSWORD=null
|
|||
MAIL_ENCRYPTION=null
|
||||
MAIL_FROM_ADDRESS=null
|
||||
MAIL_FROM_NAME="${APP_NAME}"
|
||||
MAIL_OWNER=""
|
||||
MAIL_CC_OWNER=""
|
||||
MAIL_BCC_OWNER=""
|
||||
MAIL_OWNER_ADDRESS=""
|
||||
MAIL_OWNER_NAME=""
|
||||
MAIL_CC_ADDRESS=""
|
||||
MAIL_CC_NAME=""
|
||||
MAIL_BCC_ADDRESS=""
|
||||
MAIL_BCC_NAME=""
|
||||
|
||||
AWS_ACCESS_KEY_ID=
|
||||
AWS_SECRET_ACCESS_KEY=
|
||||
|
|
|
@ -31,7 +31,7 @@ class ContactsController extends Controller {
|
|||
Contacts::create($insert);
|
||||
|
||||
// メールを送ります。
|
||||
Mail::to($r->email)->cc(env('MAIL_CC_OWNER'))->bcc(env('MAIL_BCC_OWNER'))->send(new FathersRegistrationTemporaryMail($r->message));
|
||||
Mail::to($r->email)->cc(config('mail.cc.address'))->bcc(config('mail.bcc.address'))->send(new FathersRegistrationTemporaryMail($r->message));
|
||||
} catch (\Throwable $e) {
|
||||
// 失敗
|
||||
Log::critical($e->getMessage());
|
||||
|
|
|
@ -87,6 +87,18 @@ return [
|
|||
'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'),
|
||||
'name' => env('MAIL_FROM_NAME', 'Example'),
|
||||
],
|
||||
'owner' => [
|
||||
'address' => env('MAIL_OWNER_ADDRESS', 'hello@example.com'),
|
||||
'name' => env('MAIL_OWNER_NAME', 'Example'),
|
||||
],
|
||||
'cc' => [
|
||||
'address' => env('MAIL_CC_ADDRESS', 'hello@example.com'),
|
||||
'name' => env('MAIL_CC_NAME', 'Example'),
|
||||
],
|
||||
'bcc' => [
|
||||
'address' => env('MAIL_BCC_ADDRESS', 'hello@example.com'),
|
||||
'name' => env('MAIL_BCC_NAME', 'Example'),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
|
@ -16,6 +16,6 @@ class AdminsTableSeeder extends Seeder
|
|||
public function run()
|
||||
{
|
||||
\App\Models\Admin::factory()->count(10)->create();
|
||||
\App\Models\Admin::create(['email' => env('MAIL_OWNER'), 'password' => Hash::make('password')]);
|
||||
\App\Models\Admin::create(['email' => config('mail.owner.address'), 'password' => Hash::make('password')]);
|
||||
}
|
||||
}
|
||||
|
|
新しいイシューから参照