parameters: (self, record)
return_statement: return any(differ(field.name) for field in self_sudo.trigger_field_ids)
docstring: Return whether any of the trigger fields has been modified on ``record``.
docstring_summary: Return whether any of the trigger fields has been modified on ``record``.
docstring_tokens: Return whether any of the trigger fields has been modified on record .
function: def _check_trigger_fields(self, record):
          """ Return whether any of the trigger fields has been modified on ``record``. """
          self_sudo = self.sudo()
          if not self_sudo.trigger_field_ids:
              # all fields are implicit triggers
              return True
  
          if not self._context.get('old_values'):
              # this is a create: all fields are considered modified
              return True
  
          # Note: old_vals are in the format of read()
          old_vals = self._context['old_values'].get(record.id, {})
  
          def differ(name):
              field = record._fields[name]
              return (
                  name in old_vals and
                  field.convert_to_cache(record[name], record, validate=False) !=
                  field.convert_to_cache(old_vals[name], record, validate=False)
              )
          return any(differ(field.name) for field in self_sudo.trigger_field_ids)
function_tokens: def _check_trigger_fields ( self , record ) : self_sudo = self . sudo ( ) if not self_sudo . trigger_field_ids : # all fields are implicit triggers return True if not self . _context . get ( 'old_values' ) : # this is a create: all fields are considered modified return True # Note: old_vals are in the format of read() old_vals = self . _context [ 'old_values' ] . get ( record . id , { } ) def differ ( name ) : field = record . _fields [ name ] return ( name in old_vals and field . convert_to_cache ( record [ name ] , record , validate = False ) != field . convert_to_cache ( old_vals [ name ] , record , validate = False ) ) return any ( differ ( field . name ) for field in self_sudo . trigger_field_ids )