2020_05_25_093853_change_waybills_table.php 907 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. use Illuminate\Database\Migrations\Migration;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Support\Facades\Schema;
  5. class ChangeWaybillsTable extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. *
  10. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::table('waybills',function (Blueprint $table){
  15. $table->string('mileage')->nullable()->comment('里程');
  16. $table->bigInteger('amount')->nullable()->comment('件数');
  17. $table->string('inquire_tel')->nullable()->comment('查件电话');
  18. });
  19. }
  20. /**
  21. * Reverse the migrations.
  22. *
  23. * @return void
  24. */
  25. public function down()
  26. {
  27. Schema::table('waybills',function (Blueprint $table){
  28. $table->dropColumn('mileage');
  29. $table->dropColumn('amount');
  30. $table->dropColumn('inquire_tel');
  31. });
  32. }
  33. }