I've extended the project module with a many2many field for subtypes. The field will be used to set the tasks users following sub types. When I create a new project it sets the correct default values, but not on existing. Is there a way to set default values for existing projects.
def _get_user_default_subtypes(self):
return self.env['mail.message.subtype'].sudo().search([('res_model', '=', False)]).ids
user_subtype_ids = fields.Many2many('mail.message.subtype', 'project_user_subtype_rel', 'project_id', 'subtype_id', string='Users Subtypes', default=_get_user_default_subtypes)
I don't want to do this on hand for 140+ projects :/