feat(14.2.1-06): persist nested ML maps on relation-child create

RelationService looks up TranslationWriter like CRUDService so CreateChild can lift locale maps before fillChild, write Polish after the child PK, and return a hydrated title map.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jakub Zych
2026-10-06 15:51:38 +02:00
parent f4bea33faf
commit 88a3a88876
5 changed files with 225 additions and 6 deletions

View File

@@ -656,7 +656,13 @@ func (s *service) relations() (RelationService, error) {
if err != nil {
return RelationService{}, err
}
return RelationService{DB: db, bucket: s.bucket(), tr: s.translator()}, nil
svc := RelationService{DB: db, bucket: s.bucket(), tr: s.translator()}
if s.app != nil {
if w, ok := s.app.Lookup[TranslationWriter](); ok {
svc.writer = w
}
}
return svc, nil
}
// relationsFor is the relation service of one request, carrying its