Odoo Help

0

0
3 Answers
-1
wizardz
7/25/16, 8:19 AM

I found a solution:

return {

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

'res_model': 'project.task.work',

'view_type': 'form',

'view_mode': 'tree,form',

}

0
kirubanidhi
7/20/16, 6:16 AM

This is a way to switch a other view after clicking button

<button name="start_work" attrs="{'invisible':[('work_time_status','!=', True)]}" string="Stop Work" type="object" class="oe_highlight"/>

@api.multi

def start_work(self):

course_form = self.env.ref('your form view name', False)

return {

'name': 'New Course',

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

'res_model': 'your module name',

'view_type': 'form',

'view_mode': 'tree,form',

'target': 'self',

'views': [(course_form.id, 'form')],

'view_id': 'course_form.id',

'flags': {'action_buttons': True},

        }

1 Comment
wizardz
7/22/16, 4:40 AM

this is not working, I need an example on the task view

Ask a Question
Writer
Keep Informed
1 follower(s)
About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

Register
Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now