feat: 更新 .env.example 文件,新增彩票业务配置与 Redis、邮件、队列等环境变量,优化开发环境设置

This commit is contained in:
2026-05-08 17:26:01 +08:00
parent 8cce1778b9
commit 85e57782cc
12 changed files with 663 additions and 54 deletions

View File

@@ -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');
}
};