优化了一些问题
This commit is contained in:
@@ -35,7 +35,6 @@ class Settings {
|
||||
*/
|
||||
public const STANDALONE_OPTION_KEYS = [
|
||||
'aksrt_mail_smtp',
|
||||
'aksrt_oauth',
|
||||
'aksrt_captcha_config',
|
||||
'aksrt_moderation_config',
|
||||
'aksrt_download_config',
|
||||
@@ -53,7 +52,6 @@ class Settings {
|
||||
*/
|
||||
public const SECRET_OPTION_KEYS = [
|
||||
'aksrt_mail_smtp',
|
||||
'aksrt_oauth',
|
||||
'aksrt_identity_secrets',
|
||||
];
|
||||
|
||||
@@ -730,78 +728,10 @@ class Settings {
|
||||
DisplayRuntime::save_friend_links($links);
|
||||
}
|
||||
|
||||
/** 获取OAuth配置 */
|
||||
public static function get_oauth(): array {
|
||||
return Integration::get_oauth();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** 检查OAuth平台是否已配置 */
|
||||
public static function oauth_configured(string $provider): bool {
|
||||
return Integration::oauth_configured($provider);
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ============================================
|
||||
// OAuth 代理登录 & 自动创建用户
|
||||
// ============================================
|
||||
|
||||
/** OAuth 代理登录模式: 'off' | 'server' | 'client' (schema 存 'close'→映射为 'off') */
|
||||
public static function oauth_proxy_mode(): string {
|
||||
return Integration::oauth_proxy_mode();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** OAuth 代理登录 HMAC 密钥 */
|
||||
public static function oauth_proxy_secret(): string {
|
||||
return Integration::oauth_proxy_secret();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** OAuth 代理登录服务端地址(客户端模式使用) */
|
||||
public static function oauth_proxy_server_url(): string {
|
||||
return Integration::oauth_proxy_server_url();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** OAuth 代理登录允许的平台列表(服务端模式使用) */
|
||||
public static function oauth_proxy_allowed_providers(): array {
|
||||
return Integration::oauth_proxy_allowed_providers();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** OAuth 代理登录启用的平台列表(客户端模式使用) */
|
||||
public static function oauth_proxy_client_providers(): array {
|
||||
return Integration::oauth_proxy_client_providers();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 获取微信公众号登录完整配置
|
||||
*
|
||||
* @return array{gzh_type:string,token:string,token_nocheck:bool,encoding_aes_key:string,appid:string,appsecret:string,code_qrcode:string,code_keyword:string,code_reply:string,code_subscribe_reply:string,subscribe_msg:string,new_subscribe_msg:string,scan_msg:string,auto_reply_text:string,auto_reply_search:string,auto_reply_image:string,auto_reply_voice:string,auto_reply_default:string,gzh_menu:string,priority:bool,auto:bool,auto_expires:int}
|
||||
*/
|
||||
public static function get_weixingzh_settings(): array {
|
||||
return Integration::get_weixingzh_settings();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 获取 OAuth 代理登录完整配置(aksrt_settings 优先,BC fallback aksrt_oauth)
|
||||
*
|
||||
* @return array{mode:string,secret:string,server_url:string,server_providers:array,client_providers:array,gzh_type:string}
|
||||
*/
|
||||
public static function get_oauth_proxy_settings(): array {
|
||||
return Integration::get_oauth_proxy_settings();
|
||||
}
|
||||
/** 获取微信公众号登录完整配置。 */
|
||||
public static function get_weixingzh_settings(): array {
|
||||
return Integration::get_weixingzh_settings();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user