Skip to content

Commit

Permalink
Added changes to update modified_by field
Browse files Browse the repository at this point in the history
  • Loading branch information
ihor-palii committed Nov 18, 2024
1 parent 54880b6 commit 180540c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions temba/contacts/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1057,6 +1057,11 @@ def bulk_modify(cls, user, contacts, mods: list[modifiers.Modifier]):
logger.error(f"Contact update failed: {str(e)}", exc_info=True)
raise e

# update the contacts modified_by field because it is not updated on the mailroom side
for contact in contacts:
contact.modified_by = user
Contact.objects.bulk_update(contacts, ["modified_by"])

def modified(contact):
return len(response.get(contact.id, {}).get("events", [])) > 0

Expand Down

0 comments on commit 180540c

Please sign in to comment.