Commit 59ab073d authored by Cecilia Vela Gurovic's avatar Cecilia Vela Gurovic Committed by Robert Lyon

Bug 1824767: site template should not have the edit access section

behatnotneeded

Change-Id: I40553bc4ebf69eef950f1c170d442aa7a963efe0
(cherry picked from commit 0e1d50d4)
parent 12235f11
......@@ -9,7 +9,7 @@
<span class="icon icon-lg icon-pencil" aria-hidden="true" role="presentation"></span>
<span class="btn-title">{str tag=editcontent1 section=view}</span>
</a>
{if !$accesssuspended && ($edittitle || $viewtype == 'share')}
{if !$accesssuspended && ($edittitle || $viewtype == 'share') && !$issitetemplate}
<a class="btn btn-default editviews editshare {if $selected == 'share'}active{/if}" href="{$WWWROOT}view/accessurl.php?id={$viewid}{if $collectionid}&collection={$collectionid}{/if}" title="{str tag=shareview1 section=view}">
<span class="icon icon-lg icon-unlock-alt" aria-hidden="true" role="presentation"></span>
<span class="btn-title">{str tag=shareview1 section=view}</span>
......
......@@ -53,6 +53,9 @@ if (!$USER->can_edit_view($view)) {
if ($group && !group_within_edit_window($group)) {
throw new AccessDeniedException();
}
if ($view->get('template') == View::SITE_TEMPLATE) {
throw new AccessDeniedException();
}
$form = array(
......
......@@ -59,7 +59,9 @@ if (!$USER->can_edit_view($view)) {
if ($group && !group_within_edit_window($group)) {
throw new AccessDeniedException();
}
if ($view->get('template') == View::SITE_TEMPLATE) {
throw new AccessDeniedException();
}
$form = array(
'name' => 'accessurl',
......
Markdown is supported
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