You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
672 B
26 lines
672 B
<?php
|
|
|
|
use Illuminate\Database\Migrations\Migration;
|
|
use Illuminate\Database\Schema\Blueprint;
|
|
use Illuminate\Support\Facades\Schema;
|
|
|
|
return new class extends Migration
|
|
{
|
|
public function up(): void
|
|
{
|
|
Schema::table('teachers', function (Blueprint $table) {
|
|
$table->string('department', 128)
|
|
->nullable()
|
|
->after('university_text')
|
|
->comment('院系/单位,爬虫入库等场景留存,前台不展示');
|
|
});
|
|
}
|
|
|
|
public function down(): void
|
|
{
|
|
Schema::table('teachers', function (Blueprint $table) {
|
|
$table->dropColumn('department');
|
|
});
|
|
}
|
|
};
|