Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
3996 มุมมอง

Hello guys, I would like put a number in menus about this ones need an action, I inherit ir.needaction_mixin in my model and in the xml I added <field name="message_needaction" invisible="1"/> in my tree view and in the menus actions I added this (all the menus that should have the notification number):

            <field name="context">{

                'needaction_menu_ref':

                [

                    'hr_holidays_horasextras.menu_hr_holidays_horasextras',

                    'hr_holidays_horasextras.menu_hr_holidays_horasextrascreadas',

                    'hr_holidays_horasextras.menu_hr_holidays_horasextrasaprobar',

                    'hr_holidays_horasextras.menu_hr_holidays_horasextrasaprobar_director',

                ]

            }</field>


But It didn't work, could you help me? Thanks!

อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

Okay I did it ! just with  def _needaction_domain_get(self, cr, uid, context=None)  

I resolved my problem

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
0
ต.ค. 17
3267
0
เม.ย. 17
8595
3
ม.ค. 24
8772
0
ม.ค. 24
7
3
ก.พ. 20
3022