Последняя версия с сервера прошлого разработчика
This commit is contained in:
41
database/migrations/2022_01_19_092213_create_withdrawals_table.php
Executable file
41
database/migrations/2022_01_19_092213_create_withdrawals_table.php
Executable file
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class CreateWithdrawalsTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('withdrawals', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('user_id');
|
||||
$table->unsignedBigInteger('requisites_id');
|
||||
$table->unsignedBigInteger('point_id')->nullable();
|
||||
$table->decimal('amount', 15, 2);
|
||||
$table->string('status')->default('pending');
|
||||
$table->text('description')->nullable();
|
||||
$table->text('history_payment_details')->nullable();
|
||||
|
||||
$table->timestamps();
|
||||
|
||||
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('withdrawals');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user