2019_08_05_174302_create_refund_logs_table.php 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <?php
  2. use Illuminate\Support\Facades\Schema;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Database\Migrations\Migration;
  5. class CreateRefundLogsTable extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. *
  10. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::create('refund_logs', function (Blueprint $table) {
  15. $table->bigIncrements('id');
  16. $table->bigInteger('user_id')->default(0)->comment('用户id');
  17. $table->bigInteger('deposit_id')->default(0)->comment('押金记录id');
  18. $table->decimal('money', 15, 2)->default(0.00)->comment('押金');
  19. $table->string('type', 20)->comment('申请退款类型');
  20. $table->string('apply_reason')->nullable()->comment('申请原因');
  21. $table->string('refuse_reason')->nullable()->comment('决绝理由');
  22. $table->string('remark')->nullable()->comment('备注');
  23. $table->tinyInteger('is_check_status')->default(0)->comment('审核状态');
  24. $table->bigInteger('admin_id')->default(0)->comment('管理员id');
  25. $table->bigInteger('area_id')->default(0)->comment('区域id');
  26. $table->tinyInteger('pay_status')->default(0)->comment('支付状态');
  27. $table->decimal('pay_money', 15, 2)->default(0.00)->comment('支付金额');
  28. $table->tinyInteger('pay_type')->default(0)->comment('支付方式(0:未支付;1:已支付)');
  29. $table->timestamps();
  30. });
  31. }
  32. /**
  33. * Reverse the migrations.
  34. *
  35. * @return void
  36. */
  37. public function down()
  38. {
  39. Schema::dropIfExists('refund_logs');
  40. }
  41. }