Odoo Help

3

11
3 Answers
15
Turkesh Patel (tpa) India
4/8/13, 9:54 AM

Use this:

return {
    'type': 'ir.actions.client',
    'tag': 'reload',
}
7 Comments
Hannes Smit Netherlands
4/8/13, 10:26 AM

Yes, that works, thanks! Do you perhaps know why this is needed?

Turkesh Patel (tpa) India
4/8/13, 10:36 AM

when you will return nothing then it will it simply close that wizard and to reload you will need to pass this values.

Hannes Smit Netherlands
4/10/13, 5:17 AM

@Turky: but it seems strange to me that it (the source form view) does refresh after the first 'click' (in the darker background). What triggers that then?

Cpueyo Spain
4/12/13, 6:42 AM

Thanks!! It's work!

Apertoso, Jos De Graeve Belgium
4/24/13, 8:36 AM

It's a pity that this reload the complete web application. Is there a way to trigger a refresh like 'button_dummy' that triggers the view to be refreshed from the DB ?

bruno bottacini Italy
10/8/13, 6:36 AM

i think there is only one moment the original view refresh and is when the wizard is saved that is when an ID is assigned, this happen when click on a button.

Ronald Portier Netherlands
11/18/13, 1:30 PM

Does not work here (on 6.1). With new style wizard (TransientModel).

What version are you using? Old style wizards or osv_memory/TransientModel?

6
Petar Najman Serbia
12/22/13, 5:56 AM

Hi Hannes,

As far as I know there is no such functionality in the framework at the moment. However, you can try with the following ActionManager extension which should be defined in the JS file within your module

Here for example: 'static/src/js/your_module_name.js'

openerp.your_module_name = function (instance) {
    instance.web.ActionManager = instance.web.ActionManager.extend({

        ir_actions_act_close_wizard_and_reload_view: function (action, options) {
            if (!this.dialog) {
                options.on_close();
            }
            this.dialog_stop();
            this.inner_widget.views[this.inner_widget.active_view].controller.reload();
            return $.when();
        },
    });
}

To use this action just return following when closing a wizard:

return { 'type' :  'ir.actions.act_close_wizard_and_reload_view' }

I hope this helps :-)

Cheers, Petar

4 Comments
Subhin P V India
1/20/14, 5:27 AM

Thanks man. that helped.. :)

Pedro M. Baeza Spain
4/4/14, 11:23 PM

Great trick! Thanks

Atchuthan - Technical Consultant, Sodexis Inc India
6/12/14, 2:09 AM

@Hannes, Is it possible to create for ir.actions.clients_close that works for client window?

Andre Germany
8/13/15, 5:19 AM

Awesome! Thanks.

0
Ronald Portier Netherlands
11/18/13, 1:30 PM

Does not work here (on 6.1). With new style wizard (TransientModel).

What version are you using? Old style wizards or osv_memory/TransientModel?

1 Comment
Hannes Smit Netherlands
6/17/14, 3:22 AM

I think this was in the context of v 7

Ask a Question
Writer
Keep Informed
4 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