Do not set Task.last_update when moving or updating (i.e. changing name, comment, tags etc.)

This commit is contained in:
allegroai 2021-01-05 18:06:04 +02:00
parent bca3a6e556
commit 618a0b9473
2 changed files with 1 additions and 9 deletions

View File

@ -127,14 +127,7 @@ class ProjectBLL:
project_name=project_name,
description="Auto-generated during move",
)
extra = (
{"set__last_update": datetime.utcnow()}
if hasattr(entity_cls, "last_update")
else {}
)
entity_cls.objects(company=company, id__in=ids).update(
set__project=project, **extra
)
entity_cls.objects(company=company, id__in=ids).update(set__project=project)
return project

View File

@ -471,7 +471,6 @@ def update(call: APICall, company_id, req_model: UpdateRequest):
company_id=company_id,
id=task_id,
partial_update_dict=partial_update_dict,
injected_update=dict(last_update=datetime.utcnow()),
)
if updated_count:
new_project = updated_fields.get("project", task.project)