2023-07-13 13:07:42 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
use Illuminate\Database\Migrations\Migration;
|
|
|
|
use Illuminate\Database\Schema\Blueprint;
|
|
|
|
use Illuminate\Support\Facades\Schema;
|
|
|
|
|
2023-08-11 18:48:52 +00:00
|
|
|
return new class extends Migration
|
|
|
|
{
|
2023-07-13 13:07:42 +00:00
|
|
|
/**
|
|
|
|
* Run the migrations.
|
|
|
|
*/
|
|
|
|
public function up(): void
|
|
|
|
{
|
|
|
|
Schema::create('subscriptions', function (Blueprint $table) {
|
|
|
|
$table->id();
|
2023-07-13 20:03:27 +00:00
|
|
|
$table->string('lemon_subscription_id');
|
2023-07-13 13:07:42 +00:00
|
|
|
$table->string('lemon_order_id');
|
|
|
|
$table->string('lemon_product_id');
|
|
|
|
$table->string('lemon_variant_id');
|
2023-07-13 20:03:27 +00:00
|
|
|
$table->string('lemon_variant_name');
|
2023-07-13 13:07:42 +00:00
|
|
|
$table->string('lemon_customer_id');
|
|
|
|
$table->string('lemon_status');
|
2023-07-13 20:03:27 +00:00
|
|
|
$table->string('lemon_trial_ends_at')->nullable();
|
2023-07-13 13:07:42 +00:00
|
|
|
$table->string('lemon_renews_at');
|
2023-07-13 20:03:27 +00:00
|
|
|
$table->string('lemon_ends_at')->nullable();
|
2023-07-13 13:07:42 +00:00
|
|
|
$table->string('lemon_update_payment_menthod_url');
|
|
|
|
$table->foreignId('team_id');
|
|
|
|
$table->timestamps();
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Reverse the migrations.
|
|
|
|
*/
|
|
|
|
public function down(): void
|
|
|
|
{
|
|
|
|
Schema::dropIfExists('subscriptions');
|
|
|
|
}
|
2023-08-08 09:51:36 +00:00
|
|
|
};
|