No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2014_10_12_000000_create_users_table.php 901B

12345678910111213141516171819202122232425262728293031323334
  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::create('users', function (Blueprint $table) {
  13. $table->id();
  14. $table->string('name');
  15. $table->string('email')->unique();
  16. $table->timestamp('email_verified_at')->nullable();
  17. $table->string('password');
  18. $table->enum('role',['admin','user'])->default('user');
  19. $table->string('foto')->default('../../assets/img/avatars/foto.png');
  20. $table->rememberToken();
  21. $table->timestamps();
  22. });
  23. }
  24. /**
  25. * Reverse the migrations.
  26. */
  27. public function down(): void
  28. {
  29. Schema::dropIfExists('users');
  30. }
  31. };