'Override of the base.stage method
Parameter of the stage search taken from the lead:
- section_id: if set, stages must belong to this section or
be a default stage; if not set, stages must be default
stages'

def stage_find(self, section_id, domain=[], order='sequence'):

    section_ids = []
    if section_id:
        section_ids.append(section_id)
    section_ids.extend(self.mapped('project_id').ids)
    search_domain = []
    if section_ids:
        search_domain = (['|'] * (len(section_ids) - 1))
        for section_id in section_ids:
            search_domain.append(('project_ids', '=', section_id))
    search_domain += list(domain)
    return self.env['project.task.type'].search(search_domain, order=order, limit=1).id
