diff --git a/database/migrations/2024_12_10_030946_create_temp_customers_table.php b/database/migrations/2024_12_10_030946_create_temp_customers_table.php new file mode 100644 index 0000000..b2ea52c --- /dev/null +++ b/database/migrations/2024_12_10_030946_create_temp_customers_table.php @@ -0,0 +1,37 @@ +id(); + foreach ($fieldArray as $field) { + $field = trim($field); + if ($field !== '@id') { // Skip @id as we already have $table->id() + $table->text($field)->nullable(); + } + } + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::dropIfExists('temp_customers'); + } +};