12345678910111213141516171819202122232425262728293031323334353637 |
- <?php
- use Illuminate\Support\Facades\Schema;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Database\Migrations\Migration;
- class CreateEmailLogsTable extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('email_logs', function (Blueprint $table) {
- $table->increments('id');
- $table->string('send_from')->comment('发送账号');
- $table->string('send_to')->comment('发送地址');
- $table->string('subject')->comment('邮件主题');
- $table->longText('body')->comment('邮件内容')->nullable();
- $table->tinyInteger('status')->index()->comment('邮件状态(2:失败 1:成功 0:待发送)');
- $table->timestamps();
- $table->softDeletes();
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('email_logs');
- }
- }
|