database/migrations/yandex_checkouts_table.php.stub
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\Schema;
class CreateYandexCheckoutsTable extends Migration
{
/**
* Run the migrations.
*/
public function up()
{
Schema::create(config('yandex-checkout.table_name'), function (Blueprint $table) {
$table->bigIncrements('id');
$table->string('payable_type');
$table->unsignedBigInteger('payable_id');
$table->index(['payable_type', 'payable_id']);
$table->string('payment_id')->index()->unique();
$table->string('status')->index();
$table->json('response');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down()
{
Schema::dropIfExists(config('yandex-checkout.table_name'));
}
}