Odoo Help


how to auto refresh Kanban view

on 11/7/14, 11:06 AM 2,735 views

currently the auto refresh in action window definition does not work for kanban view (per study further, auto refresh even does not work for web, only works for GUI), is there any other way around? Kanban view to be auto refreshed such as new task and task status change is more important.

there is web notification module by anybox which is of great help, https://bitbucket.org/anybox/web_notification/src, now I know that I can use the existing bus mechanism to trigger and update the webpage based on changed captured, I can now broadcast the chagne message (to certain channel) from server side by the following lines

    def create(vals, context=None):
        bus = self.env['bus.bus']
        message = {
            'subject': 'xx',
            'body': 'xx',
"""         'user_ids': [(4, x.id) for x in self],  """
            'mode': 'notify',

but I have no idea on javascript side, how to access the current action manager or kanban view, then calling the re_load or something simliar to trigger the actual refresh!

I tried the following on javascript side:

(function() {
        declare_bus_channel: function() {
            var self = this,
                channel = 'xx';
            this.bus_on(channel, function(message) {

but unfortunately failed. anyone can help to guide me by sample code or sample reference module?

Many thanks.

P.S Actually it will be very help to know in customized module how to manipulate the existing web component! in essence this is about the webclient object hierarchy.

On 11/12/14, 4:03 AM

there is new module released


angel lacret
On 6/15/15, 8:29 PM

DISCALIMER: Not the best FIX, but it's a FIX.

NOTE: In teory odoo 8 web client engine must execute the Action that the Wizards returns in the python code function. This works in all views, except in Kanban views. So this is the workaround:

In the server, create a message in the odoo bus, every time you want to notify something happends:

            bus = self.env['bus.bus']
            message = {
                'subject': '',
                'body': 'Appointment Set',
                'mode': 'notify',
            bus.sendone('<CHANNEL-NAME>', message)

Then, in the frontend you must listen for a message on this channel:

First, register the channel (With out this, it wouldn't work)

    openerp.bmwe_crm = function(instance, local) {
        var bus = instance.bus.bus;

Second, reload the kanban when something happend in the channel:

    openerp.bmwe_crm = function(instance, local) {
        var bus = instance.bus.bus;
        instance.bus.bus.on("notification", instance, function(notification){

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

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.


Odoo Training Center

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

Test it now

Question tools

2 follower(s)


Asked: 11/7/14, 11:06 AM
Seen: 2735 times
Last updated: 7/13/15, 11:28 PM