opt: mail config

This commit is contained in:
Tokumeikoi 2020-08-19 15:41:31 +08:00
parent 7c54939970
commit 727c4c8f9f
3 changed files with 20 additions and 8 deletions

View File

@ -116,7 +116,13 @@ class ConfigController extends Controller
'apple_id' => config('v2board.apple_id') 'apple_id' => config('v2board.apple_id')
], ],
'email' => [ 'email' => [
'email_template' => config('v2board.email_template', 'default') 'email_template' => config('v2board.email_template', 'default'),
'email_host' => config('v2board.email_host'),
'email_port' => config('v2board.email_port'),
'email_username' => config('v2board.email_username'),
'email_password' => config('v2board.email_password'),
'email_encryption' => config('v2board.email_encryption'),
'email_from_address' => config('v2board.email_from_address')
], ],
'telegram' => [ 'telegram' => [
'telegram_bot_enable' => config('v2board.telegram_bot_enable', 0), 'telegram_bot_enable' => config('v2board.telegram_bot_enable', 0),

View File

@ -85,6 +85,12 @@ class ConfigSave extends FormRequest
'apple_id_password' => '', 'apple_id_password' => '',
// email // email
'email_template' => '', 'email_template' => '',
'email_host' => '',
'email_port' => '',
'email_username' => '',
'email_password' => '',
'email_encryption' => '',
'email_from_address' => '',
// telegram // telegram
'telegram_bot_enable' => 'in:0,1', 'telegram_bot_enable' => 'in:0,1',
'telegram_bot_token' => '', 'telegram_bot_token' => '',

View File

@ -29,7 +29,7 @@ return [
| |
*/ */
'host' => env('MAIL_HOST', config('v2board.mail_host')), 'host' => env('MAIL_HOST', config('v2board.email_host')),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -42,7 +42,7 @@ return [
| |
*/ */
'port' => env('MAIL_PORT', config('v2board.mail_port', 587)), 'port' => env('MAIL_PORT', config('v2board.email_port', 587)),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -56,8 +56,8 @@ return [
*/ */
'from' => [ 'from' => [
'address' => env('MAIL_FROM_ADDRESS', config('v2board.mail_from_address')), 'address' => env('MAIL_FROM_ADDRESS', config('v2board.email_from_address')),
'name' => env('MAIL_FROM_NAME', config('v2board.mail_from_address')), 'name' => env('MAIL_FROM_NAME', config('v2board.email_from_address')),
], ],
/* /*
@ -71,7 +71,7 @@ return [
| |
*/ */
'encryption' => env('MAIL_ENCRYPTION', config('v2board.mail_encryption')), 'encryption' => env('MAIL_ENCRYPTION', config('v2board.email_encryption')),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -84,9 +84,9 @@ return [
| |
*/ */
'username' => env('MAIL_USERNAME', config('v2board.mail_username')), 'username' => env('MAIL_USERNAME', config('v2board.email_username')),
'password' => env('MAIL_PASSWORD', config('v2board.mail_password')), 'password' => env('MAIL_PASSWORD', config('v2board.email_password')),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------