Update Company and Item models to have image as nullable field.

main
KKlochko 2 years ago
parent 70f2173976
commit 07a5ec44cc

@ -15,7 +15,7 @@ return new class extends Migration
$table->id(); $table->id();
$table->string('uuid'); $table->string('uuid');
$table->string('name'); $table->string('name');
$table->string('image'); $table->string('image')->nullable();
$table->string('description'); $table->string('description');
$table->timestamps(); $table->timestamps();
}); });

@ -19,7 +19,7 @@ return new class extends Migration
$table->string('url'); $table->string('url');
$table->string('description'); $table->string('description');
$table->decimal('price', 8, 2); $table->decimal('price', 8, 2);
$table->string('image'); $table->string('image')->nullable();
$table->foreign('category_id')->references('id') $table->foreign('category_id')->references('id')
->on('categories')->onDelete('cascade'); ->on('categories')->onDelete('cascade');

Loading…
Cancel
Save