2021_03_30_104348_change_discharge_auth_name.php 814 B

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. use App\Authority;
  3. use Illuminate\Support\Facades\Schema;
  4. use Illuminate\Database\Schema\Blueprint;
  5. use Illuminate\Database\Migrations\Migration;
  6. class ChangeDischargeAuthName extends Migration
  7. {
  8. /**
  9. * Run the migrations.
  10. *
  11. * @return void
  12. */
  13. public function up()
  14. {
  15. Schema::table('discharge_tasks',function (Blueprint $table){
  16. $table->integer('warehouse_id')->comment('仓库')->default(null);
  17. $table->bigInteger('facilitator_id')->comment('装卸队')->default(null)->change();
  18. });
  19. }
  20. /**
  21. * Reverse the migrations.
  22. *
  23. * @return void
  24. */
  25. public function down()
  26. {
  27. Schema::table('discharge_tasks',function (Blueprint $table){
  28. $table->dropColumn('warehouse_id');
  29. });
  30. }
  31. }