Created
March 27, 2019 15:23
-
-
Save devmeireles/665acabd2c4763a39f44616dc7d117ef to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Illuminate\Support\Facades\Schema; | |
use Illuminate\Database\Schema\Blueprint; | |
use Illuminate\Database\Migrations\Migration; | |
use Illuminate\Database\Eloquent\SoftDeletes; | |
class CreateProductosCategoriasTable extends Migration | |
{ | |
/** | |
* Run the migrations. | |
* | |
* @return void | |
*/ | |
public function up() | |
{ | |
Schema::create('productos_categorias', function (Blueprint $table) { | |
$table->bigIncrements('id'); | |
$table->integer('id_producto'); | |
$table->integer('id_categoria'); | |
$table->timestamps(); | |
$table->softDeletes(); | |
}); | |
} | |
/** | |
* Reverse the migrations. | |
* | |
* @return void | |
*/ | |
public function down() | |
{ | |
Schema::dropIfExists('productos_categorias'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment