Skip to content

Commit

Permalink
declare Url repositoryAdmin liz global lizUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
nworr committed Sep 30, 2024
1 parent 3ef5a19 commit e662941
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lizmap/modules/view/controllers/lizMap.classic.php
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ public function index()
// Add bottom dock js
$rep->addJSLink($bp.'assets/js/bottom-dock.js', array('defer' => ''));

// TODO : refacto, quite the same URLs are declared in lizAjax.classic.php
// Pass some configuration options to the web page through javascript var
$lizUrls = array(
'params' => array('repository' => $repository, 'project' => $project),
Expand Down Expand Up @@ -224,6 +225,9 @@ function f($x)
$lizUrls['removeCache'] = jUrl::get('admin~maps:removeLayerCache');
}

if (jAcl2::check('lizmap.admin.access') || jAcl2::check('lizmap.admin.server.information.view')) {
$lizUrls['repositoryAdmin'] = jUrl::getFull('admin~maps:index');
}
$webDavProfile = RemoteStorageRequest::getProfile('webdav');
if ($webDavProfile) {
$lizUrls['webDavUrl'] = $webDavProfile['baseUri'];
Expand Down

0 comments on commit e662941

Please sign in to comment.