From 380fb732d73558feb040f4b3d9a2c107292b20c7 Mon Sep 17 00:00:00 2001 From: kevin_fourie Date: Mon, 19 Feb 2007 08:45:14 +0000 Subject: [PATCH] KTS-1671 "Validation breaks: Unable to move file into folder after copied file has been deleted." Fixed. --- lib/documentmanagement/Document.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/documentmanagement/Document.inc b/lib/documentmanagement/Document.inc index 387504c..2209186 100644 --- a/lib/documentmanagement/Document.inc +++ b/lib/documentmanagement/Document.inc @@ -296,7 +296,7 @@ class Document { $sQuery = "SELECT D.id AS id FROM $sD AS D LEFT JOIN $sDM AS DM ON D.metadata_version_id = DM.id LEFT JOIN $sDC AS DC ON DM.content_version_id = DC.id - WHERE DC.filename = ? AND D.folder_id = ?"; + WHERE DC.filename = ? AND D.folder_id = ? AND D.status_id=1"; $aParams = array($sFileName, $iFolderID); $id = DBUtil::getOneResultKey(array($sQuery, $aParams), 'id'); if (empty($id)) { @@ -336,7 +336,7 @@ class Document { $sQuery = "SELECT D.id AS id FROM $sD AS D LEFT JOIN $sDM AS DM ON D.metadata_version_id = DM.id LEFT JOIN $sDC AS DC ON DM.content_version_id = DC.id - WHERE DM.name = ? AND D.folder_id = ?"; + WHERE DM.name = ? AND D.folder_id = ? AND D.status_id=1"; $aParams = array($sName, $iFolderID); $id = DBUtil::getOneResultKey(array($sQuery, $aParams), 'id'); if (empty($id)) { -- libgit2 0.21.4