2024_05_24_212547_add_path_to_menus.php 605 B

1234567891011121314151617181920212223242526272829
  1. <?php
  2. use Illuminate\Database\Migrations\Migration;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Support\Facades\Schema;
  5. return new class extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. */
  10. public function up(): void
  11. {
  12. Schema::table('menus', function (Blueprint $table) {
  13. $table->string("path")->nullable();
  14. });
  15. }
  16. /**
  17. * Reverse the migrations.
  18. */
  19. public function down(): void
  20. {
  21. Schema::table('menus', function (Blueprint $table) {
  22. //
  23. $table->dropColumn(['path']);
  24. });
  25. }
  26. };