Commit 4fee20ec authored by 陈曦's avatar 陈曦
Browse files

去除版本在页面的上的展示

parent 2b4c7986
......@@ -64,7 +64,7 @@ func main() {
flag.Parse()
if *showVersion {
log.Printf("Sub2API %s (commit: %s, built: %s)\n", Version, Commit, Date)
log.Printf("TrafficAPI %s (commit: %s, built: %s)\n", Version, Commit, Date)
return
}
......@@ -114,7 +114,7 @@ func runSetupServer() {
// This allows users to run setup on a different address if needed
addr := config.GetServerAddress()
log.Printf("Setup wizard available at http://%s", addr)
log.Println("Complete the setup wizard to configure Sub2API")
log.Println("Complete the setup wizard to configure TrafficAPI")
server := &http.Server{
Addr: addr,
......
......@@ -271,7 +271,7 @@ func (s *AuthService) SendVerifyCode(ctx context.Context, email string) error {
}
// 获取网站名称
siteName := "Sub2API"
siteName := "TrafficAPI"
if s.settingService != nil {
siteName = s.settingService.GetSiteName(ctx)
}
......@@ -314,7 +314,7 @@ func (s *AuthService) SendVerifyCodeAsync(ctx context.Context, email string) (*S
}
// 获取网站名称
siteName := "Sub2API"
siteName := "TrafficAPI"
if s.settingService != nil {
siteName = s.settingService.GetSiteName(ctx)
}
......@@ -962,7 +962,7 @@ func (s *AuthService) preparePasswordReset(ctx context.Context, email, frontendB
}
// Get site name
siteName := "Sub2API"
siteName := "TrafficAPI"
if s.settingService != nil {
siteName = s.settingService.GetSiteName(ctx)
}
......
......@@ -194,7 +194,7 @@ func (s *SettingService) GetPublicSettings(ctx context.Context) (*PublicSettings
TotpEnabled: settings[SettingKeyTotpEnabled] == "true",
TurnstileEnabled: settings[SettingKeyTurnstileEnabled] == "true",
TurnstileSiteKey: settings[SettingKeyTurnstileSiteKey],
SiteName: s.getStringOrDefault(settings, SettingKeySiteName, "Sub2API"),
SiteName: s.getStringOrDefault(settings, SettingKeySiteName, "TrafficAPI"),
SiteLogo: settings[SettingKeySiteLogo],
SiteSubtitle: s.getStringOrDefault(settings, SettingKeySiteSubtitle, "Subscription to API Conversion Platform"),
APIBaseURL: settings[SettingKeyAPIBaseURL],
......@@ -757,7 +757,7 @@ func (s *SettingService) IsTotpEncryptionKeyConfigured() bool {
func (s *SettingService) GetSiteName(ctx context.Context) string {
value, err := s.settingRepo.GetValue(ctx, SettingKeySiteName)
if err != nil || value == "" {
return "Sub2API"
return "TrafficAPI"
}
return value
}
......@@ -813,7 +813,7 @@ func (s *SettingService) InitializeDefaultSettings(ctx context.Context) error {
SettingKeyEmailVerifyEnabled: "false",
SettingKeyRegistrationEmailSuffixWhitelist: "[]",
SettingKeyPromoCodeEnabled: "true", // 默认启用优惠码功能
SettingKeySiteName: "Sub2API",
SettingKeySiteName: "TrafficAPI",
SettingKeySiteLogo: "",
SettingKeyPurchaseSubscriptionEnabled: "false",
SettingKeyPurchaseSubscriptionURL: "",
......@@ -872,7 +872,7 @@ func (s *SettingService) parseSettings(settings map[string]string) *SystemSettin
TurnstileEnabled: settings[SettingKeyTurnstileEnabled] == "true",
TurnstileSiteKey: settings[SettingKeyTurnstileSiteKey],
TurnstileSecretKeyConfigured: settings[SettingKeyTurnstileSecretKey] != "",
SiteName: s.getStringOrDefault(settings, SettingKeySiteName, "Sub2API"),
SiteName: s.getStringOrDefault(settings, SettingKeySiteName, "TrafficAPI"),
SiteLogo: settings[SettingKeySiteLogo],
SiteSubtitle: s.getStringOrDefault(settings, SettingKeySiteSubtitle, "Subscription to API Conversion Platform"),
APIBaseURL: settings[SettingKeyAPIBaseURL],
......
......@@ -83,7 +83,7 @@ const (
totpLoginTTL = 5 * time.Minute
totpAttemptsTTL = 15 * time.Minute
maxTotpAttempts = 5
totpIssuer = "Sub2API"
totpIssuer = "TrafficAPI"
)
// TotpService handles TOTP operations
......
......@@ -51,7 +51,7 @@ func RunCLI() error {
fmt.Println()
fmt.Println("╔═══════════════════════════════════════════╗")
fmt.Println("║ Sub2API Installation Wizard ║")
fmt.Println("║ TrafficAPI Installation Wizard ║")
fmt.Println("╚═══════════════════════════════════════════╝")
fmt.Println()
......
-- 将默认站点名称从 "Sub2API" 更新为 "TrafficAPI"
-- 仅更新仍为旧默认值的记录,不覆盖管理员自定义的站点名称
UPDATE settings
SET value = 'TrafficAPI', updated_at = NOW()
WHERE key = 'site_name' AND value = 'Sub2API';
......@@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<link rel="icon" type="image/png" href="/logo.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Sub2API - AI API Gateway</title>
<title>TrafficAPI - AI API Gateway</title>
</head>
<body>
<div id="app"></div>
......
/**
* API Client for Sub2API Backend
* API Client for TrafficAPI Backend
* Central export point for all API modules
*/
......
......@@ -18,7 +18,7 @@
{{ siteName }}
</span>
<!-- Version Badge -->
<VersionBadge :version="siteVersion" />
<!-- <VersionBadge :version="siteVersion" /> -->
</div>
</transition>
</div>
......@@ -151,7 +151,6 @@ import { computed, h, onMounted, ref, watch } from 'vue'
import { useRoute } from 'vue-router'
import { useI18n } from 'vue-i18n'
import { useAdminSettingsStore, useAppStore, useAuthStore, useOnboardingStore } from '@/stores'
import VersionBadge from '@/components/common/VersionBadge.vue'
import { sanitizeSvg } from '@/utils/sanitize'
interface NavItem {
......@@ -178,7 +177,6 @@ const isDark = ref(document.documentElement.classList.contains('dark'))
// Site settings from appStore (cached, no flicker)
const siteName = computed(() => appStore.siteName)
const siteLogo = computed(() => appStore.siteLogo)
const siteVersion = computed(() => appStore.siteVersion)
const settingsLoaded = computed(() => appStore.publicSettingsLoaded)
// SVG Icon Components
......
/**
* Vue Router configuration for Sub2API frontend
* Vue Router configuration for TrafficAPI frontend
* Defines all application routes with lazy loading and navigation guards
*/
......
/* Sub2API Interactive Tour Styles - DOM Restructured Version */
/* TrafficAPI Interactive Tour Styles - DOM Restructured Version */
/* 1. Overlay & Highlight */
.driver-overlay {
......
/**
* Core Type Definitions for Sub2API Frontend
* Core Type Definitions for TrafficAPI Frontend
*/
// ==================== Common Types ====================
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment