倍率问题和图片问题调整

This commit is contained in:
andy committed 2026-09-23 13:33:47 +08:00
1 parent f1993eb388
commit 3f29ba716a
20 files changed
+1210 -24

No files matched your search

+3
View File
@@ -136,6 +136,9 @@ func cloneRule(r billing.PriceRule) billing.PriceRule {
r.Conditions = billing.Conditions(cloneMap(map[string]any(r.Conditions)))
r.Source = cloneMap(r.Source)
raw, _ := json.Marshal(r.Dimensions)
// Unmarshal otherwise reuses the original slice and shares tier storage
// with callers, allowing an admin edit to mutate the default catalog too.
r.Dimensions = nil
_ = json.Unmarshal(raw, &r.Dimensions)
return r
}