Make sure BaseIDs from the DbTemplate propagate not only to Template.BaseIDs but also to the TemplateItem as a value of __Base template field