diff --git a/views/bootstrap/class.Bootstrap.php b/views/bootstrap/class.Bootstrap.php index dbdd09324..d61a74ee3 100644 --- a/views/bootstrap/class.Bootstrap.php +++ b/views/bootstrap/class.Bootstrap.php @@ -1942,6 +1942,7 @@ $(document).ready( function() { $workflowmode = $this->params['workflowmode']; $previewwidth = $this->params['previewWidthList']; $enableClipboard = $this->params['enableclipboard']; + $accessop = $this->params['accessobject']; $content = ''; @@ -1979,13 +1980,15 @@ $(document).ready( function() { $content .= ""; if (file_exists($dms->contentDir . $latestContent->getPath())) { - $content .= ""; + if($accessop->check_controller_access('Download', array('action'=>'run'))) + $content .= ""; if($previewer->hasPreview($latestContent)) { $content .= "getID()."&version=".$latestContent->getVersion()."&width=".$previewwidth."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; } else { $content .= "getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; } - $content .= ""; + if($accessop->check_controller_access('Download', array('action'=>'run'))) + $content .= ""; } else $content .= "getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; $content .= "";