Update timestamp of the associated element.

For example the lastModified timestamp of a part is now updated, when the user changes a price information. This should represent more what a user expects under a last Modified field and should improve also sorting...
This commit is contained in:
Jan Böhmer 2020-05-20 23:36:44 +02:00
parent 2b21d4039a
commit dbf770f784
7 changed files with 68 additions and 4 deletions

View file

@ -116,6 +116,14 @@ abstract class Attachment extends AbstractNamedDBElement
}
}
public function updateTimestamps(): void
{
parent::updateTimestamps();
if ($this->element instanceof AttachmentContainingDBElement) {
$this->element->updateTimestamps();
}
}
/***********************************************************
* Various function
***********************************************************/