|
@@ -27,9 +27,9 @@ class Config extends BaseModel
|
|
|
}
|
|
}
|
|
|
// 获取系统配置信息
|
|
// 获取系统配置信息
|
|
|
public static function getSystemInfo($update=false){
|
|
public static function getSystemInfo($update=false){
|
|
|
- $name='systemInfo';
|
|
|
|
|
|
|
+ $name='systemInfo_config';
|
|
|
// $auth=request()->header('Authorization');
|
|
// $auth=request()->header('Authorization');
|
|
|
- $nameFields=['sysInfo','fileUpload','chatInfo','compass','kefu_cancel_message','user_open_comment', 'user_open_special_comment', 'user_send_gap_time', 'user_open_speech', 'user_show_kefu_read','user_cancel_message','user_cancel_message_time','platform_head_logo','platform_head_logo_night','pc_title_color','platform_logo','platform_name','platform_logo_night'];
|
|
|
|
|
|
|
+ $nameFields=['translate','sysInfo','fileUpload','chatInfo','compass','kefu_cancel_message','user_open_comment', 'user_open_special_comment', 'user_send_gap_time', 'user_open_speech', 'user_show_kefu_read','user_cancel_message','user_cancel_message_time','platform_head_logo','platform_head_logo_night','pc_title_color','platform_logo','platform_name','platform_logo_night'];
|
|
|
// 如果是登录状态才会返回chatINfo
|
|
// 如果是登录状态才会返回chatINfo
|
|
|
// if($auth){
|
|
// if($auth){
|
|
|
// $name='all'.$name;
|
|
// $name='all'.$name;
|
|
@@ -56,6 +56,9 @@ class Config extends BaseModel
|
|
|
}
|
|
}
|
|
|
Cache::set($name,$systemInfo,7*86400);
|
|
Cache::set($name,$systemInfo,7*86400);
|
|
|
}
|
|
}
|
|
|
|
|
+ if (isset($systemInfo['translate']) && empty(getEnvValue('GOOGLE_KEY') )) {
|
|
|
|
|
+ $systemInfo['translate'] = '0';
|
|
|
|
|
+ }
|
|
|
return $systemInfo;
|
|
return $systemInfo;
|
|
|
}
|
|
}
|
|
|
|
|
|