2023_02_02_065537_assets_table.php 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  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. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::create('assets', function (Blueprint $table) {
  15. $table->id();
  16. $table->integer('vendor_id', 11)->nullable();
  17. $table->integer('category_id', 11)->nullable();
  18. $table->string('name', 100)->nullable();
  19. $table->string('model_name', 100)->nullable();
  20. $table->string('model_number', 100)->nullable();
  21. $table->string('registered_number', 100)->nullable();
  22. $table->string('brand', 20)->nullable();
  23. $table->integer('duration', 20)->nullable();
  24. $table->string('duration_type', 50)->nullable();
  25. $table->string('asset_type', 50)->nullable();
  26. $table->double('cost')->nullable();
  27. $table->text('description', 50)->nullable();
  28. $table->text('image', 50)->nullable();
  29. $table->enum('status')->unique();
  30. $table->timestamp('email_verified_at')->nullable();
  31. $table->string('password');
  32. $table->rememberToken();
  33. $table->timestamps();
  34. });
  35. }
  36. /**
  37. * Reverse the migrations.
  38. *
  39. * @return void
  40. */
  41. public function down()
  42. {
  43. //
  44. }
  45. };