Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
3429 Visualizações

Hi,

I need to show the count of records in a menuitem in 'crm.lead' model.
I have tried the  'needaction_domain_get()' and '_needaction_count()' methods to do it, i.e,

1)  @api.model

     def _needaction_domain_get(self):

         return [('stage_type', '=', 'approval')]

2)  @api.model

     def _needaction_count(self, domain=None):

        domain = [('stage_type', '=', 'approval')]

        return self.search_count(domain)


The first method is not showing any count at all.
But when I use the second method, it shows the count correctly but it is showing the count on another menuitem.
Any help appreciated.
Thank you

Avatar
Cancelar
Publicações relacionadas Respostas Visualizações Atividade
1
abr. 17
4700
0
mai. 16
3
2
ago. 25
452
2
mai. 25
1452
1
abr. 25
1359