I'm trying to disable massAction on all entity record/list views by Views setup handler but unfortunately that it could not work.
This is my custom code, please help me to correct if it has any incorrect line:
This is my custom code, please help me to correct if it has any incorrect line:
PHP Code:
define('custom:views/record/list', [], () => {
class Handler {
/**
* @param {import('view').default} view
*/
constructor(view) {
this.view = view;
}
process() {
this.listenTo(this.view, 'after:render', () => {
this.view.rowActionsDisabled = true;
this.view.massActionsDisabled = true;
});
}
}
// Establish event support.
Object.assign(Handler.prototype, Backbone.Events);
return Handler;
});
Comment