D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
forge
/
almahero.online
/
database
/
migrations
/
Filename :
2022_11_05_171546_add_lat_long_to_users_table.php
back
Copy
<?php use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; return new class extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::table('users', function (Blueprint $table) { $table->decimal('lat', 12, 8)->nullable()->after('address'); $table->decimal('long', 12, 8)->nullable()->after('lat'); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::table('users', function (Blueprint $table) { $table->dropColumn('lat'); $table->dropColumn('long'); }); } };