diff --git a/src/app/attachment/controllers/AttachmentController.php b/src/app/attachment/controllers/AttachmentController.php index 771a33ac87d9b4181d3c097f5a8eed8f55a044cf..5975cca26df5886c24801ac29f8923463f3b9091 100755 --- a/src/app/attachment/controllers/AttachmentController.php +++ b/src/app/attachment/controllers/AttachmentController.php @@ -118,8 +118,8 @@ class AttachmentController if (!empty($attachment['originId'])) { $oldVersions = AttachmentModel::get([ 'select' => ['res_id as "resId"', 'relation'], - 'where' => ['(origin_id = ? OR res_id = ?)', 'res_id != ?', 'status not in (?)', 'attachment_type not in (?)'], - 'data' => [$attachment['originId'], $attachment['originId'], $args['id'], ['DEL'], $excludeAttachmentTypes], + 'where' => ['(origin_id = ? OR res_id = ?)', 'res_id != ?', 'status not in (?)'], + 'data' => [$attachment['originId'], $attachment['originId'], $args['id'], ['DEL']], 'orderBy' => ['relation DESC'] ]); }