id(); $table->string('name'); $table->string('type'); $table->string('brand'); $table->string('model'); $table->string('serial_number')->unique(); $table->string('status')->default('en_stock'); // en_stock, en_service, en_panne, au_rebut $table->date('purchase_date')->nullable(); $table->date('commissioning_date')->nullable(); $table->date('warranty_expiration_date')->nullable(); $table->string('location'); $table->string('ip_address')->nullable(); $table->foreignId('order_id')->nullable()->constrained('orders')->nullOnDelete(); $table->text('notes')->nullable(); $table->timestamps(); }); } /** * Reverse the migrations. */ public function down(): void { Schema::dropIfExists('hardwares'); } };