diff --git a/app/destinations/app_config.php b/app/destinations/app_config.php index c4c266589c..3e9b0f81f2 100644 --- a/app/destinations/app_config.php +++ b/app/destinations/app_config.php @@ -165,6 +165,8 @@ $apps[$x]['permissions'][$y]['groups'][] = "superadmin"; $apps[$x]['permissions'][$y]['groups'][] = "admin"; $y++; + $apps[$x]['permissions'][$y]['name'] = "destination_local"; + $y++; //default settings $y = 0; diff --git a/app/destinations/destination_edit.php b/app/destinations/destination_edit.php index c0ece1e8b1..d00d9ccc95 100644 --- a/app/destinations/destination_edit.php +++ b/app/destinations/destination_edit.php @@ -1570,7 +1570,9 @@ } echo " \n"; echo " \n"; - echo " \n"; + if (permission_exists('destination_local')) { + echo " \n"; + } unset($selected); echo " \n"; echo "
\n"; @@ -2098,4 +2100,4 @@ //include the footer require_once "resources/footer.php"; -?> \ No newline at end of file +?> diff --git a/app/destinations/destinations.php b/app/destinations/destinations.php index 43b19f5787..df33b03936 100644 --- a/app/destinations/destinations.php +++ b/app/destinations/destinations.php @@ -279,7 +279,9 @@ echo "
\n"; echo button::create(['type'=>'button','label'=>$text['button-inbound'],'icon'=>'location-arrow fa-rotate-90','link'=>'?type=inbound'.($show == 'all' ? '&show=all' : null).($search != '' ? "&search=".urlencode($search) : null)]); echo button::create(['type'=>'button','label'=>$text['button-outbound'],'icon'=>'location-arrow','link'=>'?type=outbound'.($show == 'all' ? '&show=all' : null).($search != '' ? "&search=".urlencode($search) : null)]); - echo button::create(['type'=>'button','label'=>$text['button-local'],'icon'=>'vector-square','link'=>'?type=local'.($show == 'all' ? '&show=all' : null).($search != '' ? "&search=".urlencode($search) : null)]); + if (permission_exists('destination_local')) { + echo button::create(['type'=>'button','label'=>$text['button-local'],'icon'=>'vector-square','link'=>'?type=local'.($show == 'all' ? '&show=all' : null).($search != '' ? "&search=".urlencode($search) : null)]); + } if (permission_exists('destination_import')) { echo button::create(['type'=>'button','label'=>$text['button-import'],'icon'=>$_SESSION['theme']['button_icon_import'],'link'=>'destination_imports.php']); }