mirror of https://github.com/OCA/web.git
[FIX] web_refresher: Define displayRefresher in setup instead of using a getter
Before this changes whe trying to access to a view with the refresher, in mobile view, an error was thrown. As it is not necessary to define the value in a get function, defining the value in the setup solves the problem.pull/2891/head
parent
acbeaf4575
commit
fc03b2d0b9
|
@ -24,11 +24,8 @@ patch(ControlPanel.prototype, "web_refresher.ControlPanel", {
|
|||
searchModel: this.env.searchModel,
|
||||
pagerProps: this.pagerProps,
|
||||
};
|
||||
},
|
||||
/**
|
||||
* @returns {Boolean}
|
||||
*/
|
||||
get displayRefresher() {
|
||||
return !this.forbiddenSubTypes.includes(this.env.config.viewSubType);
|
||||
this.displayRefresher = !this.forbiddenSubTypes.includes(
|
||||
this.env.config.viewSubType
|
||||
);
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue