On javascript side, how its possible to trigger ir.action.client outside of the widget? Is it possible to use do_action function which is defined in AbstractWebClient outside of this class definition?
Consider this ... I am rendering static template - where I am rendering top menu (which will be shared across multiple widgets). I would like to bind actions in that menu and to be able to trigger ir.action.client function to switch left and right with something like:
$(document).on("click", ".o_dashboard", function(e) {
var action = {
type: "ir.actions.client",
tag: "mymodule.tag_name"
};
// TRIGGER ACTION SOMEHOW HERE!
});
where, declaration above is outside of widget definition in separate module. Is this possible. Is there alternative way to do something like this?
Additionally, is it possible to define the button in static xml, which is going to behave as a trigger for ir.action.client when we provide properties like type="object", or static xmls do not have any kind of this behaviour (they are just static as word says) ?