fix: 完成商务迁移复核与接口优化并清理历史资料

This commit is contained in:
Yvan
2026-11-04 14:45:02 +08:00
parent 5a96be6a79
commit 297e80827d
176 changed files with 6803 additions and 6002 deletions
+16
View File
@@ -0,0 +1,16 @@
package config
import "strings"
// SwaggerEnabled exposes API documentation only in explicitly selected local/test environments.
func SwaggerEnabled(admin *Admin) bool {
if admin == nil || admin.App == nil {
return false
}
switch strings.ToLower(strings.TrimSpace(admin.App.Env)) {
case "development", "dev", "test", "local":
return true
default:
return false
}
}