show container around add attachment button only if button is visible

This commit is contained in:
Uwe Steinmann 2020-07-21 16:07:51 +02:00
parent 508e1b74d3
commit 9f49460ee9

View File

@ -1654,14 +1654,13 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
} }
else $this->infoMsg(getMLText("no_attached_files")); else $this->infoMsg(getMLText("no_attached_files"));
$this->contentContainerStart();
if($accessobject->check_controller_access('AddFile')) { if($accessobject->check_controller_access('AddFile')) {
$this->contentContainerStart();
if ($document->getAccessMode($user) >= M_READWRITE){ if ($document->getAccessMode($user) >= M_READWRITE){
print $this->html_link('AddFile', array('documentid'=>$documentid), array('class'=>'btn btn-primary'), getMLText("add"), false, true)."\n"; print $this->html_link('AddFile', array('documentid'=>$documentid), array('class'=>'btn btn-primary'), getMLText("add"), false, true)."\n";
} }
$this->contentContainerEnd();
} }
$this->contentContainerEnd();
?> ?>
</div> </div>
<div class="tab-pane <?php if($currenttab == 'links') echo 'active'; ?>" id="links"> <div class="tab-pane <?php if($currenttab == 'links') echo 'active'; ?>" id="links">