def update_person(person, data): person.populate_from_dict(data) db.session.flush() signals.event.person_updated.send(person) logger.info('Person %s updated by %s', person, session.user) person.event_new.log(EventLogRealm.management, EventLogKind.change, 'Persons', "Person with email '{}' has been updated".format(person.email), session.user)
def update_person(person, data): person.populate_from_dict(data) db.session.flush() signals.event.person_updated.send(person) logger.info('Person %s updated by %s', person, session.user) person.event.log(EventLogRealm.management, LogKind.change, 'Persons', f"Person with email '{person.email}' has been updated", session.user)
def _process(self): if self.person.has_links: raise Forbidden( _('Only users with no ties to the event can be deleted.')) db.session.delete(self.person) logger.info('EventPerson deleted from event %r: %r', self.event, self.person) return jsonify_data()
def update_person(person, data): person.populate_from_dict(data) db.session.flush() logger.info('Person %s updated by %s', person, session.user) person.event_new.log(EventLogRealm.management, EventLogKind.change, 'Persons', "Person with email '{}' has been updated".format(person.email), session.user)