fix: defaut ui triage (#4802)
* fix: theme-aware payment paths, auto-group validation, route guards, perf group filtering - Add common.ThemeAwarePath to generate correct redirect URLs based on active theme (default vs classic), replacing hardcoded /console/* paths in 7 controllers and service/quota.go (#4765) - Validate auto-group availability against getUserGroups before defaulting form values; playground falls back to 'default' group when 'auto' is unavailable (#4796, #4799) - Enforce HeaderNavModules settings in rankings route (frontend + backend API) and SidebarModulesAdmin in playground route to block direct URL access when features are disabled (#4704, #4512) - Filter perf_metrics API response to only include currently configured groups, hiding stale data from deleted groups (#4790) - Preserve query params (pay=success/fail) in /console/topup → /wallet frontend redirect * fix: update hero section text and localization strings for clarity
This commit is contained in:
+2
-3
@@ -17,7 +17,6 @@ import (
|
||||
perfmetrics "github.com/QuantumNous/new-api/pkg/perf_metrics"
|
||||
relaycommon "github.com/QuantumNous/new-api/relay/common"
|
||||
"github.com/QuantumNous/new-api/setting/ratio_setting"
|
||||
"github.com/QuantumNous/new-api/setting/system_setting"
|
||||
"github.com/QuantumNous/new-api/types"
|
||||
|
||||
"github.com/bytedance/gopkg/util/gopool"
|
||||
@@ -467,7 +466,7 @@ func checkAndSendQuotaNotify(relayInfo *relaycommon.RelayInfo, quota int, preCon
|
||||
}
|
||||
if quotaTooLow {
|
||||
prompt := "您的额度即将用尽"
|
||||
topUpLink := fmt.Sprintf("%s/console/topup", system_setting.ServerAddress)
|
||||
topUpLink := PaymentReturnURL("/console/topup")
|
||||
|
||||
// 根据通知方式生成不同的内容格式
|
||||
var content string
|
||||
@@ -521,7 +520,7 @@ func checkAndSendSubscriptionQuotaNotify(relayInfo *relaycommon.RelayInfo) {
|
||||
}
|
||||
|
||||
prompt := "您的订阅额度即将用尽"
|
||||
topUpLink := fmt.Sprintf("%s/console/topup", system_setting.ServerAddress)
|
||||
topUpLink := PaymentReturnURL("/console/topup")
|
||||
|
||||
var content string
|
||||
var values []interface{}
|
||||
|
||||
Reference in New Issue
Block a user