api code global jain

This commit is contained in:
Abhishek Mali
2025-11-05 10:37:10 +05:30
commit 52fe7e2bec
2834 changed files with 1784903 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateRequestsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('requests', function (Blueprint $table) {
$table->id()->index();
$table->bigInteger('sender_id')->unsigned();
$table->bigInteger('receiver_id')->unsigned();
$table->unsignedTinyInteger('status')->default(0)->comment('0 : Sent 1 : Accepted 2 : Declined');
$table->timestamps();
$table->softDeletes();
$table->foreign('sender_id')->references('id')->on('users');
$table->foreign('receiver_id')->references('id')->on('users');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('requests');
}
}