feat: 接入旧站管理端并完整迁移后台能力
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"hfb_jysh/backend/internal/modules/qualityowner"
|
||||
"hfb_jysh/backend/internal/modules/rentergrowth"
|
||||
smsnode "hfb_jysh/backend/internal/modules/sms"
|
||||
)
|
||||
@@ -55,6 +56,17 @@ func (s *Service) Update(ctx context.Context, actorID uint64, key string, req Up
|
||||
}
|
||||
req.Value = value
|
||||
}
|
||||
if key == qualityowner.ConfigKey {
|
||||
cfg, err := qualityowner.ParseConfigValue(req.Value)
|
||||
if err != nil {
|
||||
return nil, ErrInvalidConfig
|
||||
}
|
||||
value, err := qualityowner.MarshalConfig(cfg)
|
||||
if err != nil {
|
||||
return nil, ErrInvalidConfig
|
||||
}
|
||||
req.Value = value
|
||||
}
|
||||
return s.repo.Update(ctx, actorID, key, req, meta)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user