creazione della separazzione delle categorie

This commit is contained in:
2023-07-06 17:39:23 +02:00
parent 75761353ca
commit 8d0576099c
6 changed files with 84 additions and 6 deletions

View File

@@ -0,0 +1,37 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class UpdateCategoriesAddingSpesaEntrata extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
//
Schema::table('categories', function (Blueprint $table) {
$table->smallInteger('cat_entrata')->after('cat_name')->default(0);
$table->smallInteger('cat_uscita')->after('cat_entrata')->default(0);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
Schema::table('categories', function (Blueprint $table) {
$table->dropColumn('cat_entrata');
$table->dropColumn('cat_uscita');
});
}
}