Like in version 15 we can achieve it this way:
var BoardRenderer = FormRenderer.extend({
custom_events: _.extend({}, FormRenderer.prototype.custom_events, {
update_filters: '_onUpdateFilters',
switch_view: '_onSwitchView',
}),
events: _.extend({}, FormRenderer.prototype.events, {
'click .oe_dashboard_column .oe_fold': '_onFoldClick',
'click .oe_dashboard_link_change_layout': '_onChangeLayout',
'click .oe_dashboard_column .oe_close': '_onCloseAction',
}),
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
1
Reply
2802
Views
Hi,
Try this code to perform on click in odoo 16 form view.
var BasicRenderer = require('web.BasicRenderer');
var FormRenderer = BasicRenderer.extend({
className: "o_legacy_form_view",
events: _.extend({}, BasicRenderer.prototype.events, {
'click .o_notification_box .oe_field_translate': '_onTranslate',
'click .o_notification_box .btn-close': '_onTranslateNotificationClose',
'shown.bs.tab a[data-bs-toggle="tab"]': '_onNotebookTabChanged',
'click .o_form_label': '_onFieldLabelClicked',
}),
custom_events: _.extend({}, BasicRenderer.prototype.custom_events, {
'navigation_move': '_onNavigationMove',
'activate_next_widget': '_onActivateNextWidget',
'quick_edit': '_onQuickEdit',
}),
})
Regards
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign upRelated Posts | Replies | Views | Activity | |
---|---|---|---|---|
|
1
Aug 24
|
1425 | ||
|
2
Dec 24
|
2237 | ||
|
1
Oct 24
|
580 | ||
|
2
May 24
|
503 | ||
|
0
Nov 23
|
388 |