Files
mini_tp/app/api/model/DyVideoUserTitk.php
T
nepiedg c909ebdf88 feat(platform): add endpoint to retrieve platform accounts for a user
- Introduced `getPlatformAccountsByUserId` method in `DyVideoUser` model to fetch active platform accounts for a specified user.
- Added new API route for accessing platform accounts under `v1/platform/accounts`, requiring user authentication.
2026-04-02 07:39:37 +00:00

34 lines
706 B
PHP

<?php
declare(strict_types=1);
namespace app\api\model;
use think\Model;
/**
* TikTok 账号附表模型(对应 dy_video_user_titk 表)
*
* 该表在 acgpmw 平台账号管理页用于补充 TikTok 账号的国家信息。
*/
class DyVideoUserTitk extends Model
{
protected $connection = 'dbmember';
protected $name = 'dy_video_user_titk';
protected $pk = 'id';
protected $autoWriteTimestamp = false;
/**
* 根据授权账号 ID 获取 TikTok 附加信息。
*
* @param int $vuid 授权账号主表 ID
* @return self|null
*/
public static function findByVuid(int $vuid): ?self
{
return self::where('vuid', $vuid)->find();
}
}