mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-12 00:45:34 +00:00
Merge branch 'seeddms-4.3.13' into develop
This commit is contained in:
commit
8809086014
|
@ -5,6 +5,10 @@
|
|||
- fix saving multi value attributes without a maximum number of values
|
||||
- webdav sets propper modification time
|
||||
- add button to select all log files for removal
|
||||
- deleted folders and documents on the clipboard don't crash seeddms anymore
|
||||
when moving into a different folder (Bug #186)
|
||||
- Download of documents whose content is gone will not be possible anymore
|
||||
(Bug #185)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
Changes in version 4.3.12
|
||||
|
|
|
@ -43,6 +43,7 @@ if ($targetFolder->getAccessMode($user) < M_READWRITE) {
|
|||
$clipboard = $session->getClipboard();
|
||||
foreach($clipboard['docs'] as $documentid) {
|
||||
$document = $dms->getDocument($documentid);
|
||||
if($document) {
|
||||
$oldFolder = $document->getFolder();
|
||||
|
||||
if ($document->getAccessMode($user) < M_READWRITE) {
|
||||
|
@ -80,11 +81,12 @@ foreach($clipboard['docs'] as $documentid) {
|
|||
} else {
|
||||
$session->removeFromClipboard($document);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach($clipboard['folders'] as $folderid) {
|
||||
$folder = $dms->getFolder($folderid);
|
||||
|
||||
if($folder) {
|
||||
if ($folder->getAccessMode($user) < M_READWRITE) {
|
||||
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("access_denied"));
|
||||
}
|
||||
|
@ -117,6 +119,7 @@ foreach($clipboard['folders'] as $folderid) {
|
|||
} else {
|
||||
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("error_occured"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$session->setSplashMsg(array('type'=>'success', 'msg'=>getMLText('splash_moved_clipboard')));
|
||||
|
|
|
@ -316,16 +316,21 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
|||
*/
|
||||
$previewer = new SeedDMS_Preview_Previewer($cachedir, $previewwidthdetail);
|
||||
$previewer->createPreview($latestContent);
|
||||
if ($viewonlinefiletypes && in_array(strtolower($latestContent->getFileType()), $viewonlinefiletypes))
|
||||
if ($file_exists) {
|
||||
if ($viewonlinefiletypes && in_array(strtolower($latestContent->getFileType()), $viewonlinefiletypes)) {
|
||||
print "<a target=\"_blank\" href=\"../op/op.ViewOnline.php?documentid=".$documentid."&version=". $latestContent->getVersion()."\">";
|
||||
else
|
||||
} else {
|
||||
print "<a href=\"../op/op.Download.php?documentid=".$documentid."&version=".$latestContent->getVersion()."\">";
|
||||
}
|
||||
}
|
||||
if($previewer->hasPreview($latestContent)) {
|
||||
print("<img class=\"mimeicon\" width=\"".$previewwidthdetail."\" src=\"../op/op.Preview.php?documentid=".$document->getID()."&version=".$latestContent->getVersion()."&width=".$previewwidthdetail."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">");
|
||||
} else {
|
||||
print "<img class=\"mimeicon\" src=\"".$this->getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
|
||||
}
|
||||
if ($file_exists) {
|
||||
print "</a>";
|
||||
}
|
||||
print "</td>\n";
|
||||
|
||||
print "<td><ul class=\"actions unstyled\">\n";
|
||||
|
@ -908,17 +913,22 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
|||
|
||||
print "<tr>\n";
|
||||
print "<td nowrap>";
|
||||
if ($viewonlinefiletypes && in_array(strtolower($version->getFileType()), $viewonlinefiletypes))
|
||||
if($file_exists) {
|
||||
if ($viewonlinefiletypes && in_array(strtolower($version->getFileType()), $viewonlinefiletypes)) {
|
||||
print "<a target=\"_blank\" href=\"../op/op.ViewOnline.php?documentid=".$documentid."&version=".$version->getVersion()."\">";
|
||||
else
|
||||
} else {
|
||||
print "<a href=\"../op/op.Download.php?documentid=".$documentid."&version=".$version->getVersion()."\">";
|
||||
}
|
||||
}
|
||||
$previewer->createPreview($version);
|
||||
if($previewer->hasPreview($version)) {
|
||||
print("<img class=\"mimeicon\" width=\"".$previewwidthdetail."\" src=\"../op/op.Preview.php?documentid=".$document->getID()."&version=".$version->getVersion()."&width=".$previewwidthdetail."\" title=\"".htmlspecialchars($version->getMimeType())."\">");
|
||||
} else {
|
||||
print "<img class=\"mimeicon\" src=\"".$this->getMimeIcon($version->getFileType())."\" title=\"".htmlspecialchars($version->getMimeType())."\">";
|
||||
}
|
||||
if($file_exists) {
|
||||
print "</a>\n";
|
||||
}
|
||||
print "</td>\n";
|
||||
print "<td><ul class=\"unstyled\">\n";
|
||||
print "<li>".$version->getOriginalFileName()."</li>\n";
|
||||
|
@ -996,16 +1006,20 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
|||
print "<tr>";
|
||||
print "<td>";
|
||||
$previewer->createPreview($file, $previewwidthdetail);
|
||||
if($file_exists) {
|
||||
if ($viewonlinefiletypes && in_array(strtolower($file->getFileType()), $viewonlinefiletypes))
|
||||
print "<a target=\"_blank\" href=\"../op/op.ViewOnline.php?documentid=".$documentid."&file=". $file->getID()."\">";
|
||||
else
|
||||
print "<a href=\"../op/op.Download.php?documentid=".$documentid."&file=".$file->getID()."\">";
|
||||
}
|
||||
if($previewer->hasPreview($file)) {
|
||||
print("<img class=\"mimeicon\" width=\"".$previewwidthdetail."\" src=\"../op/op.Preview.php?documentid=".$document->getID()."&file=".$file->getID()."&width=".$previewwidthdetail."\" title=\"".htmlspecialchars($file->getMimeType())."\">");
|
||||
} else {
|
||||
print "<img class=\"mimeicon\" src=\"".$this->getMimeIcon($file->getFileType())."\" title=\"".htmlspecialchars($file->getMimeType())."\">";
|
||||
}
|
||||
if($file_exists) {
|
||||
print "</a>";
|
||||
}
|
||||
print "</td>";
|
||||
|
||||
print "<td><ul class=\"unstyled\">\n";
|
||||
|
|
Loading…
Reference in New Issue
Block a user