Skip to content

Commit

Permalink
Check if DCA is closed or notCreatable
Browse files Browse the repository at this point in the history
  • Loading branch information
ausi committed Jun 9, 2018
1 parent e858a56 commit cc2b4b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Resources/contao/dca/tl_files.php
Expand Up @@ -586,7 +586,7 @@ public function dragHandle($row, $href, $label, $title, $icon, $attributes)
*/
public function uploadButton($row, $href, $label, $title, $icon, $attributes)
{
if (\Input::get('act') != 'select' && isset($row['type']) && $row['type'] == 'folder')
if (!$GLOBALS['TL_DCA']['tl_files']['config']['closed'] && !$GLOBALS['TL_DCA']['tl_files']['config']['notCreatable'] && \Input::get('act') != 'select' && isset($row['type']) && $row['type'] == 'folder')
{
return '<a href="'.$this->addToUrl('&amp;act=move&amp;mode=2&amp;pid='.$row['id']).'" title="'.\StringUtil::specialchars(sprintf($GLOBALS['TL_LANG']['tl_files']['uploadFF'], $row['id'])).'">'.\Image::getHtml('new.svg', $GLOBALS['TL_LANG']['tl_files']['move'][0]).'</a> ';
}
Expand Down

0 comments on commit cc2b4b3

Please sign in to comment.