feat: 更新 .env.example 文件,新增彩票业务配置与 Redis、邮件、队列等环境变量,优化开发环境设置
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* 【任务 3 · 配置中心】键值运行时配置。
|
||||
*
|
||||
* 与 `config/*.php` / `.env` 分工:
|
||||
* - 密钥、站点 URL 等仍以 env 为准,不进库或不在此表明文扩写密钥;
|
||||
* - 可随时由运营调整的开关、限额类配置放本表,读时走 LotterySettings 带缓存。
|
||||
*/
|
||||
return new class extends Migration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('lottery_settings', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('setting_key', 160)->unique();
|
||||
$table->json('value_json');
|
||||
$table->string('group_name', 64)->default('general')->comment('控制台分组展示用');
|
||||
$table->string('description_zh')->nullable()->comment('运维说明');
|
||||
$table->timestamps();
|
||||
|
||||
$table->index('group_name', 'idx_lottery_settings_group');
|
||||
});
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('lottery_settings');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user