2018_04_05_054304_create_education_levels_table.php 941 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. use Illuminate\Database\Schema\Blueprint;
  3. use Illuminate\Database\Migrations\Migration;
  4. class CreateEducationLevelsTable extends Migration
  5. {
  6. /**
  7. * Run the migrations.
  8. *
  9. * @return void
  10. */
  11. public function up()
  12. {
  13. if (!Schema::hasTable('education_levels')){
  14. Schema::create('education_levels', function (Blueprint $table) {
  15. $table->increments('id');
  16. $table->string('level_name',255);
  17. $table->tinyInteger('added_by')->nullable();
  18. $table->tinyInteger('updated_by')->nullable();
  19. $table->tinyInteger('status')->nullable();
  20. $table->tinyInteger('approved_by')->nullable();
  21. $table->softDeletes();
  22. $table->timestamps();
  23. });
  24. }
  25. }
  26. /**
  27. * Reverse the migrations.
  28. *
  29. * @return void
  30. */
  31. public function down()
  32. {
  33. Schema::drop('education_levels');
  34. }
  35. }