I’d like to trigger the fields_view_get
function dynamically after doing some functions. I override the function fields_view_get
and return my results. This gets affected on XML view only at first time the actual function called. So I need to refresh the view to get affect new values on arch.
Is there any way to make the odoo view get changed with fields_view_get
function even after the function was called for the first time?
My attempt:
# here fields view get changes the button string from getting arch
# I overrided the fields_view_get on event model and its get affected and works
# perfectly when I click on main menu Event.but not after the records loaded.
@api.multi
def send_mail_event(self):
x = self.event_id.fields_view_get(view_id=None, view_type='form', toolbar=False, submenu=False)
self.send_mail_event_reg_link(test=True)
return x