equal
deleted
inserted
replaced
318 if self._cw.added_in_transaction(self.eidfrom): |
318 if self._cw.added_in_transaction(self.eidfrom): |
319 # new entity, not needed |
319 # new entity, not needed |
320 return |
320 return |
321 entity = self._cw.entity_from_eid(self.eidfrom) |
321 entity = self._cw.entity_from_eid(self.eidfrom) |
322 try: |
322 try: |
323 entity.cw_set(modification_date=datetime.now()) |
323 entity.cw_set(modification_date=datetime.utcnow()) |
324 except RepositoryError as ex: |
324 except RepositoryError as ex: |
325 # usually occurs if entity is coming from a read-only source |
325 # usually occurs if entity is coming from a read-only source |
326 # (eg ldap user) |
326 # (eg ldap user) |
327 self.warning('cant change modification date for %s: %s', entity, ex) |
327 self.warning('cant change modification date for %s: %s', entity, ex) |
328 |
328 |