Verified Commit 751c660c authored by Prosper De Laure's avatar Prosper De Laure
Browse files

FIX : #7061 The sub archive adding button is hidden if the archive is a file

parent f87da968
......@@ -198,9 +198,11 @@ class welcome
}
$acceptArchiveWithoutProfile = $archivalProfile->acceptArchiveWithoutProfile;
$fileplanLevel = $archivalProfile->fileplanLevel;
$acceptUserIndex = $archivalProfile->acceptUserIndex;
} else {
$acceptArchiveWithoutProfile = true;
$fileplanLevel = true;
}
}
......@@ -216,6 +218,7 @@ class welcome
$this->view->setSource("archive", $archive);
$this->view->setSource("depositPrivilege", $depositPrivilege);
$this->view->setSource("archivalProfileList", $archivalProfileList);
$this->view->setSource("fileplanLevel", $fileplanLevel);
$this->view->setSource("acceptArchiveWithoutProfile", $acceptArchiveWithoutProfile);
$this->view->setSource("acceptUserIndex", $acceptUserIndex);
$this->view->setSource('managementPrivilege', \laabs::callService('auth/userAccount/readHasprivilege', "archiveManagement/modify"));
......
......@@ -5,8 +5,8 @@
<input class="originatingDate hide" value="[?merge archive.originatingDate ?]">
<div class="col-xs-12">
<?merge acceptArchiveWithoutProfile.bool().add(archivalProfileList.count()).bool() ?>
<div id="archiveToolbarBtn" class="dropdown pull-right btn-group">
<?merge acceptArchiveWithoutProfile.bool().add(archivalProfileList.count()).bool()?>
<div id="archiveToolbarBtn" class="dropdown pull-right btn-group [?merge fileplanLevel.ifeq('file').then('hide','') ?]">
<button type="button" class="btn btn-sm btn-default dropdown-toggle [?merge depositPrivilege.not().then('disabled', '') ?]" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true" title="New archive"><span class="fa fa-plus"></span></button>
<ul class="dropdown-menu" aria-labelledby="dropdownMenu1">
<?merge acceptArchiveWithoutProfile.bool() ?>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment