first commit

This commit is contained in:
2023-09-11 09:44:39 +08:00
commit fa76d02135
9 changed files with 348 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateSmsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('sms', function (Blueprint $table) {
$table->increments('id');
$table->string('mobile', 16);
$table->string('channel', 16);
$table->string('code', 16);
$table->boolean('used')->default(0);
$table->timestamps();
$table->index(['mobile', 'channel']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('sms');
}
}