plugin management + user tables and torrents table text column migrate

This commit is contained in:
xiaomlove
2025-01-19 14:37:00 +08:00
parent 0f88ab8d82
commit 403a9447a9
66 changed files with 1432 additions and 786 deletions

View File

@@ -26,6 +26,8 @@ use App\Repositories\TorrentRepository;
use Carbon\Carbon;
use GuzzleHttp\Client;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Str;
use Nexus\Database\NexusDB;
@@ -332,6 +334,18 @@ class Update extends Install
["value" => User::query()->where("class", User::CLASS_STAFF_LEADER)->first(["id"])->id]
);
}
/**
* @since 1.9.0
*/
if (!Schema::hasTable("torrent_extras")) {
$this->runMigrate("database/migrations/2025_01_08_133552_create_torrent_extra_table.php");
$this->runMigrate("database/migrations/2025_01_08_133847_create_user_modify_logs_table.php");
$this->runMigrate("database/migrations/2025_01_18_235747_drop_users_table_text_column.php");
$this->runMigrate("database/migrations/2025_01_18_235757_drop_torrents_table_text_column.php");
Artisan::call("upgrade:upgrade:migrate_torrents_table_text_column");
Artisan::call("upgrade:migrate_users_table_comment_related_column");
}
}
public function runExtraMigrate()