Surge,Surfboard 配置面板流量显示优化去掉内部没用的引号

This commit is contained in:
coldice945 2022-12-16 20:08:33 +08:00
parent 3e0abe93ab
commit 858e68399a
2 changed files with 2 additions and 2 deletions

View File

@ -69,7 +69,7 @@ class Surfboard
$download = round($user['d'] / (1024*1024*1024), 2); $download = round($user['d'] / (1024*1024*1024), 2);
$totalTraffic = round($user['transfer_enable'] / (1024*1024*1024), 2); $totalTraffic = round($user['transfer_enable'] / (1024*1024*1024), 2);
$expireDate = $user['expired_at'] === NULL ? '长期有效' : date('Y-m-d H:i:s', $user['expired_at']); $expireDate = $user['expired_at'] === NULL ? '长期有效' : date('Y-m-d H:i:s', $user['expired_at']);
$subscribeInfo = "title=\"{$appName}订阅信息\", content=\"上传流量:{$upload}GB\\n下载流量{$download}GB\\n已用总流量{$totalTraffic}GB\\n到期时间{$expireDate}\""; $subscribeInfo = "title={$appName}订阅信息, content=上传流量:{$upload}GB\\n下载流量{$download}GB\\n已用总流量{$totalTraffic}GB\\n到期时间{$expireDate}";
$config = str_replace('$subscribe_info', $subscribeInfo, $config); $config = str_replace('$subscribe_info', $subscribeInfo, $config);
return $config; return $config;

View File

@ -69,7 +69,7 @@ class Surge
$download = round($user['d'] / (1024*1024*1024), 2); $download = round($user['d'] / (1024*1024*1024), 2);
$totalTraffic = round($user['transfer_enable'] / (1024*1024*1024), 2); $totalTraffic = round($user['transfer_enable'] / (1024*1024*1024), 2);
$expireDate = $user['expired_at'] === NULL ? '长期有效' : date('Y-m-d H:i:s', $user['expired_at']); $expireDate = $user['expired_at'] === NULL ? '长期有效' : date('Y-m-d H:i:s', $user['expired_at']);
$subscribeInfo = "title=\"{$appName}订阅信息\", content=\"上传流量:{$upload}GB\\n下载流量{$download}GB\\n已用总流量{$totalTraffic}GB\\n到期时间{$expireDate}\""; $subscribeInfo = "title={$appName}订阅信息, content=上传流量:{$upload}GB\\n下载流量{$download}GB\\n已用总流量{$totalTraffic}GB\\n到期时间{$expireDate}";
$config = str_replace('$subscribe_info', $subscribeInfo, $config); $config = str_replace('$subscribe_info', $subscribeInfo, $config);
return $config; return $config;