diff --git a/database/migrations/2020_12_21_214128_create_foods_table.php b/database/migrations/2020_12_21_214128_create_foods_table.php index ee17ae1..8eb55e6 100644 --- a/database/migrations/2020_12_21_214128_create_foods_table.php +++ b/database/migrations/2020_12_21_214128_create_foods_table.php @@ -19,7 +19,7 @@ class CreateFoodsTable extends Migration $table->string('brand')->nullable(); $table->string('source')->nullable(); $table->string('notes')->nullable(); - $table->unsignedFloat('serving_size'); + $table->decimal('serving_size', 10, 8)->unsigned(); $table->enum('serving_unit', ['tsp', 'tbsp', 'cup', 'oz'])->nullable(); $table->string('serving_unit_name')->nullable(); $table->unsignedFloat('serving_weight'); diff --git a/database/migrations/2020_12_21_215932_create_recipes_table.php b/database/migrations/2020_12_21_215932_create_recipes_table.php index 43b827c..5068f56 100644 --- a/database/migrations/2020_12_21_215932_create_recipes_table.php +++ b/database/migrations/2020_12_21_215932_create_recipes_table.php @@ -24,7 +24,7 @@ class CreateRecipesTable extends Migration $table->string('source')->nullable(); $table->unsignedInteger('servings'); $table->unsignedFloat('weight')->nullable(); - //$table->decimal('volume', 10, 8)->unsigned()->nullable(); + $table->decimal('volume', 10, 8)->unsigned()->nullable(); $table->timestamps(); }); } diff --git a/database/migrations/2021_04_17_200123_add_volume_to_recipes.php b/database/migrations/2021_04_17_200123_add_volume_to_recipes.php deleted file mode 100644 index 8bbeb32..0000000 --- a/database/migrations/2021_04_17_200123_add_volume_to_recipes.php +++ /dev/null @@ -1,32 +0,0 @@ -decimal('volume', 10, 8)->unsigned()->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('recipes', function (Blueprint $table) { - $table->dropColumn('volume'); - }); - } -}