parameters: (self, work_days=1)
return_statement: return teams_data, members_data
docstring: Private method for lead assignment. This method both
  
            * assigns leads to teams given by self;
            * assigns leads to salespersons belonging to self;
  
          See sub methods for more details about assign process.
  
          :param float work_days: see ``CrmTeam.action_assign_leads()``;
  
          :return teams_data, members_data: structure-based result of assignment
            process. For more details about data see ``CrmTeam._allocate_leads()``
            and ``CrmTeamMember._assign_and_convert_leads``;
docstring_summary: Private method for lead assignment. This method both
docstring_tokens: Private method for lead assignment . This method both
function: def _action_assign_leads(self, work_days=1):
          """ Private method for lead assignment. This method both
  
            * assigns leads to teams given by self;
            * assigns leads to salespersons belonging to self;
  
          See sub methods for more details about assign process.
  
          :param float work_days: see ``CrmTeam.action_assign_leads()``;
  
          :return teams_data, members_data: structure-based result of assignment
            process. For more details about data see ``CrmTeam._allocate_leads()``
            and ``CrmTeamMember._assign_and_convert_leads``;
          """
          if not self.env.user.has_group('sales_team.group_sale_manager') and not self.env.user.has_group('base.group_system'):
              raise exceptions.UserError(_('Lead/Opportunities automatic assignment is limited to managers or administrators'))
  
          _logger.info('### START Lead Assignment (%d teams, %d sales persons, %.2f work_days)', len(self), len(self.crm_team_member_ids), work_days)
          teams_data = self._allocate_leads(work_days=work_days)
          _logger.info('### Team repartition done. Starting salesmen assignment.')
          members_data = self.crm_team_member_ids._assign_and_convert_leads(work_days=work_days)
          _logger.info('### END Lead Assignment')
          return teams_data, members_data
function_tokens: def _action_assign_leads ( self , work_days = 1 ) : if not self . env . user . has_group ( 'sales_team.group_sale_manager' ) and not self . env . user . has_group ( 'base.group_system' ) : raise exceptions . UserError ( _ ( 'Lead/Opportunities automatic assignment is limited to managers or administrators' ) ) _logger . info ( '### START Lead Assignment (%d teams, %d sales persons, %.2f work_days)' , len ( self ) , len ( self . crm_team_member_ids ) , work_days ) teams_data = self . _allocate_leads ( work_days = work_days ) _logger . info ( '### Team repartition done. Starting salesmen assignment.' ) members_data = self . crm_team_member_ids . _assign_and_convert_leads ( work_days = work_days ) _logger . info ( '### END Lead Assignment' ) return teams_data , members_data