发布界面优化

This commit is contained in:
yml2213
2026-05-23 13:47:26 +08:00
parent d90f31360f
commit e6cc9f1255
12 changed files with 607 additions and 65 deletions
@@ -187,4 +187,31 @@ func normalizePublishOptions(options *PublishOptionsDTO) {
if len(options.ScreenshotSlots) == 0 {
options.ScreenshotSlots = defaults.ScreenshotSlots
}
if len(options.BanRecordOptions) == 0 {
options.BanRecordOptions = defaults.BanRecordOptions
}
if len(options.BanEvidenceOptions) == 0 {
options.BanEvidenceOptions = defaults.BanEvidenceOptions
}
if options.PriceConfig.DepositPlaceholder == "" {
options.PriceConfig.DepositPlaceholder = defaults.PriceConfig.DepositPlaceholder
}
if options.PriceConfig.PricePlaceholder == "" {
options.PriceConfig.PricePlaceholder = defaults.PriceConfig.PricePlaceholder
}
if options.PriceConfig.RatioDescription == "" {
options.PriceConfig.RatioDescription = defaults.PriceConfig.RatioDescription
}
if len(options.RatioConfig.InsuranceBaseRatios) == 0 {
options.RatioConfig.InsuranceBaseRatios = defaults.RatioConfig.InsuranceBaseRatios
}
if len(options.RatioConfig.ConfigItems) == 0 {
options.RatioConfig.ConfigItems = defaults.RatioConfig.ConfigItems
}
if len(options.RatioConfig.CoinCorrections) == 0 {
options.RatioConfig.CoinCorrections = defaults.RatioConfig.CoinCorrections
}
if len(options.RatioConfig.RentRules) == 0 {
options.RatioConfig.RentRules = defaults.RatioConfig.RentRules
}
}