feat(front): 官网套餐页提交开通意向线索(PlatformLead)

This commit is contained in:
萝卜
2026-03-14 02:31:28 +00:00
parent e1822e4389
commit 249ffb3aba
7 changed files with 201 additions and 12 deletions

View File

@@ -0,0 +1,45 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::create('platform_leads', function (Blueprint $table) {
$table->id();
// 对外平台线索/开通意向(前期先承接 A站点开通型
$table->string('name', 100)->default('');
$table->string('mobile', 30)->default('');
$table->string('email', 100)->default('');
$table->string('company', 100)->default('');
$table->string('source', 50)->default('platform');
$table->string('status', 30)->default('new');
$table->text('note')->nullable();
// 预期套餐(可选)
$table->unsignedBigInteger('plan_id')->nullable()->index();
// 扩展字段:便于后续接入 Blicense或更复杂的开通信息
$table->json('meta')->nullable();
$table->timestamps();
$table->index(['status', 'created_at']);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('platform_leads');
}
};