Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
1 Rispondi
1233 Visualizzazioni

Here this i get user id. But I want to show user name in this report. 
team_ids = fields.Many2many('crm.team', string="Segment", required=True)
data = {
'start_date': self.date_from,
'end_date': self.date_to,
'team_id': self.team_ids.ids
\\\\ \\\\ \\\\ \\\\ \\\\ \\\\ \\\\ \\\\ \\\\}
here\\\\ I\\\\ pass\\\\ the\\\\ data\\\\ In\\\\ xml:


I\\\ get\\\ id\\\ for\\\ this\\\ but\\\ how\\\ can\\\ I\\\ get\\\ name\\\ instead\\\ of\\\ i
d


Please help.

Avatar
Abbandona
Risposta migliore

Hi,

You can get the names into list as below:

 'team_id' : [team.name for team in self.team_ids]
Avatar
Abbandona