feat: 彩票业务迁移并补全后台权限与代理结算体系

This commit is contained in:
2026-06-10 10:29:43 +08:00
parent bbdb69dabb
commit 1948b10fe6
108 changed files with 7083 additions and 5033 deletions

View File

@@ -0,0 +1,35 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
return new class extends Migration
{
public function up(): void
{
Schema::create('draws', function (Blueprint $table) {
$table->id();
$table->string('draw_no', 32)->unique();
$table->date('business_date');
$table->unsignedInteger('sequence_no');
$table->string('status', 32);
$table->timestamp('start_time')->nullable();
$table->timestamp('close_time')->nullable();
$table->timestamp('draw_time')->nullable();
$table->timestamp('cooling_end_time')->nullable();
$table->string('result_source', 16)->nullable()->comment('rng|manual');
$table->unsignedInteger('current_result_version')->default(0);
$table->unsignedInteger('settle_version')->default(0);
$table->boolean('is_reopened')->default(false);
$table->timestamps();
$table->index(['status', 'draw_time'], 'idx_draws_status_draw_time');
});
}
public function down(): void
{
Schema::dropIfExists('draws');
}
};