reclamar premio
This commit is contained in:
@@ -6,11 +6,6 @@ use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('notificaciones', function (Blueprint $table) {
|
||||
@@ -20,7 +15,7 @@ return new class extends Migration
|
||||
$table->string('titulo')->nullable();
|
||||
$table->text('descripcion')->nullable();
|
||||
$table->boolean('estado')->default(true);
|
||||
$table->boolean('todos')->default(false);
|
||||
$table->boolean('todos')->default(false);
|
||||
|
||||
$table->foreign('remitente_id')
|
||||
->references('id')
|
||||
@@ -33,16 +28,11 @@ return new class extends Migration
|
||||
->on('users')
|
||||
->onDelete('cascade')
|
||||
->onUpdate('cascade');
|
||||
|
||||
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('notificaciones');
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('notificaciones', function (Blueprint $table) {
|
||||
$table->integer('premio')->nullable()->default(0)->after('todos');
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('notificaciones', function (Blueprint $table) {
|
||||
$table->dropColumn('premio');
|
||||
});
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user