MontageReview should only be visisble to people who can view events. Fix running state
parent
ea27e07276
commit
f153e9b8fb
|
@ -137,7 +137,10 @@ if ( ZM_OPT_USE_AUTH ) {
|
|||
|
||||
require_once( 'includes/lang.php' );
|
||||
require_once( 'includes/functions.php' );
|
||||
#$running = daemonCheck();
|
||||
|
||||
# Running is global but only do the daemonCheck if it is actually needed
|
||||
$running = null;
|
||||
#= daemonCheck();
|
||||
#$states = dbFetchAll( 'SELECT * FROM States' );
|
||||
#foreach ( $states as $state ) {
|
||||
#if ( $state['IsActive'] == 1 ) {
|
||||
|
|
|
@ -185,8 +185,10 @@ function getNavBarHTML() {
|
|||
global $VLANG;
|
||||
global $CLANG;
|
||||
global $VLANG;
|
||||
global $status;
|
||||
global $running;
|
||||
if ( $running == null )
|
||||
$running = daemonCheck();
|
||||
$status = $running?translate('Running'):translate('Stopped');
|
||||
global $user;
|
||||
global $bwArray;
|
||||
?>
|
||||
|
@ -220,7 +222,9 @@ function getNavBarHTML() {
|
|||
?>
|
||||
<li><?php echo makePopupLink( '?view=cycle&group='.$cycleGroup, 'zmCycle'.$cycleGroup, array( 'cycle', $cycleWidth, $cycleHeight ), translate('Cycle'), $running ) ?></li>
|
||||
<li><?php echo makePopupLink( '?view=montage&group='.$cycleGroup, 'zmMontage'.$cycleGroup, 'montage', translate('Montage'), $running ) ?></li>
|
||||
<li><?php echo makePopupLink( '?view=montagereview&group='.$cycleGroup, 'zmMontageReview'.$cycleGroup, 'montagereview', translate('MontageReview'), $running ) ?></li>
|
||||
<?php } ?>
|
||||
<?php if ( canView('Events') ) { ?>
|
||||
<li><?php echo makePopupLink( '?view=montagereview&group='.$cycleGroup, 'zmMontageReview'.$cycleGroup, 'montagereview', translate('MontageReview') ) ?></li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -22,6 +22,8 @@ $servers = Server::find_all();
|
|||
require_once('includes/Storage.php');
|
||||
$storage_areas = Storage::find_all();
|
||||
$show_storage_areas = count($storage_areas) > 1 and canEdit( 'System' ) ? 1 : 0;
|
||||
if ( $running == null )
|
||||
$running = daemonCheck();
|
||||
|
||||
$eventCounts = array(
|
||||
array(
|
||||
|
|
Loading…
Reference in New Issue