Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2688 Widoki

Hey There

Good Day!

 

I have a button named as action_list and it is placed in XML file and works ok. What I want is that I want to fetch data from my table like vlaues on button click and this should be displayed in a new wizard where target =new. What should I get? I should have a table displayed in front end of Odoo showing all values... Below code is showing me list view of my current entered values. Am trying the below code. please guide me in all cases

 

def action_list(self,cr,uid,ids,context=None):

        cr.execute("SELECT * FROM activity_track WHERE id =%s",ids)

        result= map(lambda x: x[0], cr.fetchall())

        context.update({'myresult':result})

        return {

          'type':'ir.actions.act_window',

          'view_mode':'tree,form',

          'view_type':'tree',

          'domain':'[]',

          'nodestroy': True,

         # **'context':context,**

          'target': 'new',

          'res_model':'activity.track',


                 }
     

 

Thanks

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
2
sty 20
15381
16
sie 19
10338
1
sty 19
5572
5
cze 18
10976
0
wrz 17
2612