Merge branch 'storageareas' of github.com:connortechnology/ZoneMinder into storageareas

pull/2077/head
Isaac Connor 2018-03-27 13:24:57 -07:00
commit 4d68f9a757
18 changed files with 241 additions and 114 deletions

View File

@ -122,7 +122,7 @@ MYSQL_RES *zmDbRow::fetch(const char *query) {
result_set = zmDbFetch(query);
if ( ! result_set ) return result_set;
int n_rows = mysql_num_rows( result_set );
int n_rows = mysql_num_rows(result_set);
if ( n_rows != 1 ) {
Error("Bogus number of lines return from query, %d returned for query %s.", n_rows, query);
mysql_free_result(result_set);
@ -140,6 +140,7 @@ MYSQL_RES *zmDbRow::fetch(const char *query) {
}
return result_set;
}
zmDbRow::~zmDbRow() {
if ( result_set ) {
mysql_free_result(result_set);

View File

@ -268,8 +268,8 @@ Event::~Event() {
snprintf( sql, sizeof(sql), "UPDATE Events SET Name='%s%d', EndTime = from_unixtime( %ld ), Length = %s%ld.%02ld, Frames = %d, AlarmFrames = %d, TotScore = %d, AvgScore = %d, MaxScore = %d, DefaultVideo = '%s' where Id = %d", monitor->EventPrefix(), id, end_time.tv_sec, delta_time.positive?"":"-", delta_time.sec, delta_time.fsec, frames, alarm_frames, tot_score, (int)(alarm_frames?(tot_score/alarm_frames):0), max_score, video_name, id );
db_mutex.lock();
if ( mysql_query( &dbconn, sql ) ) {
Error( "Can't update event: %s", mysql_error( &dbconn ) );
if ( mysql_query(&dbconn, sql) ) {
Error("Can't update event: %s", mysql_error(&dbconn));
} else {
Debug(1,"Success updating event");
}

View File

@ -1186,14 +1186,14 @@ bool Monitor::CheckSignal( const Image *image ) {
break;
}
if(colours == ZM_COLOUR_GRAY8) {
if ( colours == ZM_COLOUR_GRAY8 ) {
if ( *(buffer+index) != grayscale_val )
return true;
} else if(colours == ZM_COLOUR_RGB24) {
} else if ( colours == ZM_COLOUR_RGB24 ) {
const uint8_t *ptr = buffer+(index*colours);
if ( usedsubpixorder == ZM_SUBPIX_ORDER_BGR) {
if ( usedsubpixorder == ZM_SUBPIX_ORDER_BGR ) {
if ( (RED_PTR_BGRA(ptr) != red_val) || (GREEN_PTR_BGRA(ptr) != green_val) || (BLUE_PTR_BGRA(ptr) != blue_val) )
return true;
} else {
@ -1202,8 +1202,8 @@ bool Monitor::CheckSignal( const Image *image ) {
return true;
}
} else if(colours == ZM_COLOUR_RGB32) {
if ( usedsubpixorder == ZM_SUBPIX_ORDER_ARGB || usedsubpixorder == ZM_SUBPIX_ORDER_ABGR) {
} else if ( colours == ZM_COLOUR_RGB32 ) {
if ( usedsubpixorder == ZM_SUBPIX_ORDER_ARGB || usedsubpixorder == ZM_SUBPIX_ORDER_ABGR ) {
if ( ARGB_ABGR_ZEROALPHA(*(((const Rgb*)buffer)+index)) != ARGB_ABGR_ZEROALPHA(colour_val) )
return true;
} else {
@ -1212,10 +1212,10 @@ bool Monitor::CheckSignal( const Image *image ) {
return true;
}
}
}
return( false );
}
return( true );
} // end for < signal_check_points
return false;
} // end if signal_check_points
return true;
}
bool Monitor::Analyse() {
@ -1744,32 +1744,19 @@ bool Monitor::Analyse() {
void Monitor::Reload() {
Debug( 1, "Reloading monitor %s", name );
if ( event )
if ( event ) {
Info( "%s: %03d - Closing event %d, reloading", name, image_count, event->Id() );
closeEvent();
closeEvent();
}
static char sql[ZM_SQL_MED_BUFSIZ];
// This seems to have fallen out of date.
snprintf( sql, sizeof(sql), "select Function+0, Enabled, LinkedMonitors, EventPrefix, LabelFormat, LabelX, LabelY, LabelSize, WarmupCount, PreEventCount, PostEventCount, AlarmFrameCount, SectionLength, FrameSkip, MotionFrameSkip, AnalysisFPSLimit, AnalysisUpdateDelay, MaxFPS, AlarmMaxFPS, FPSReportInterval, RefBlendPerc, AlarmRefBlendPerc, TrackMotion, SignalCheckColour from Monitors where Id = '%d'", id );
if ( mysql_query( &dbconn, sql ) ) {
Error( "Can't run query: %s", mysql_error( &dbconn ) );
exit( mysql_errno( &dbconn ) );
}
MYSQL_RES *result = mysql_store_result( &dbconn );
if ( !result ) {
Error( "Can't use query result: %s", mysql_error( &dbconn ) );
exit( mysql_errno( &dbconn ) );
}
int n_monitors = mysql_num_rows( result );
if ( n_monitors != 1 ) {
Error( "Bogus number of monitors, %d, returned. Can't reload", n_monitors );
return;
}
if ( MYSQL_ROW dbrow = mysql_fetch_row( result ) ) {
zmDbRow *row = zmDbFetchOne(sql);
if ( !row ) {
Error("Can't run query: %s", mysql_error(&dbconn));
} else if ( MYSQL_ROW dbrow = row->mysql_row() ) {
int index = 0;
function = (Function)atoi(dbrow[index++]);
enabled = atoi(dbrow[index++]);
@ -1820,12 +1807,7 @@ void Monitor::Reload() {
ready_count = image_count+warmup_count;
ReloadLinkedMonitors( p_linked_monitors );
}
if ( mysql_errno( &dbconn ) ) {
Error( "Can't fetch row: %s", mysql_error( &dbconn ) );
exit( mysql_errno( &dbconn ) );
}
mysql_free_result( result );
} // end if row
ReloadZones();
}

View File

@ -39,7 +39,7 @@ class Group extends AppModel {
public $validate = array(
'Name' => array(
'notEmpty' => array(
'rule' => array('notEmpty'),
'rule' => array('notEmpty'))),
'Id' => array(
'numeric' => array(
'rule' => array('numeric'),

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -86,7 +86,7 @@ $SLANG = array(
'Action' => 'Action',
'Actual' => 'Actual',
'AddNewControl' => 'Add New Control',
'AddNewMonitor' => 'Add New Monitor',
'AddNewMonitor' => 'Add',
'AddNewServer' => 'Add New Server',
'AddNewStorage' => 'Add New Storage',
'AddNewUser' => 'Add New User',
@ -237,7 +237,7 @@ $SLANG = array(
'ChooseLogFormat' => 'Choose a log format',
'ChooseLogSelection' => 'Choose a log selection',
'ChoosePreset' => 'Choose Preset',
'CloneMonitor' => 'Clone Monitor',
'CloneMonitor' => 'Clone',
'Close' => 'Close',
'Colour' => 'Colour',
'Command' => 'Command',

View File

@ -21,10 +21,50 @@
* Primary look and feel styles
*/
@font-face {
font-family: 'Material Icons';
font-style: normal;
font-weight: 400;
src: url(../fonts/MaterialIcons-Regular.eot); /* For IE6-8 */
src: local('Material Icons'),
local('MaterialIcons-Regular'),
url(../fonts/MaterialIcons-Regular.woff2) format('woff2'),
url(../fonts/MaterialIcons-Regular.woff) format('woff'),
url(../fonts/MaterialIcons-Regular.ttf) format('truetype');
}
.material-icons {
vertical-align:middle;
font-family: 'Material Icons';
font-weight: normal;
font-style: normal;
font-size: 24px; /* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;
/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;
/* Support for IE. */
font-feature-settings: 'liga';
}
.material-icons.md-18 { font-size: 18px; }
.material-icons.md-36 { font-size: 36px; }
body {
font-family: "Open Sans", Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
color: #333333;
font-weight: 300;
text-align: center;
}
@ -68,6 +108,20 @@ th {
*/
}
.thead-highlight {
background-color:#dfe4ea;
}
/* rounded table head top corners */
table th:first-child{
border-radius:5px 0 0 0 ;
}
table th:last-child{
border-radius:0 5px 0 0 ;
}
a:link {
color: #3498db;
text-decoration: none;
@ -79,8 +133,9 @@ a:visited {
}
a:hover {
color: #2488cb;
text-decoration: underline;
text-decoration: none;
background-color:rgba(72, 84, 96,0.2);
border-radius:4px;
}
label {
@ -90,12 +145,13 @@ label {
input,textarea,select,button,.btn-primary {
border: 1px #ccc solid;
padding: 5px;
border-radius: 2px;
border-radius: 1px;
font-family: inherit;
font-weight: 400;
font-size: 100%;
color: #333333;
text-align: left;
text-align: left;
border-radius:4px;
}
/*
input[type=text], input[type=password], input[type="url"], textarea, select {
@ -286,15 +342,15 @@ fieldset > legend {
* Behavior classes
*/
.alarm, .errorText {
color: #dc143c;
color: #ff3f34;
}
.alert, .warnText {
color: #ff8c00;
color: #ffa801;
}
.ok, .infoText {
color: #688e23;
color: #0fb9b1;
}
.fakelink {
@ -369,12 +425,11 @@ th.table-th-sort-rev span.table-th-sort-span {
#header {
width: 100%;
line-height: 1;
text-align: left;
background-color: #383836;
background-color: #34495e;
padding: 5px 20px;
margin: 0 auto 4px auto;
color: #f2f2f2;
color: white;
font-weight: 300;
}
@ -512,13 +567,28 @@ input[type=submit]:disabled,
.navbar{
margin-bottom: 0 !important;
border-radius: 0;
color: #03A9F4 !important;
background-color:#485460 !important;
color: #0fbcf9 !important;
border:none;
}
.navbar-brand {
font-weight: bold;
font-weight: normal;
font-size: 20px;
}
.navbar-brand a {
color:#ffa801;
}
.navbar-btn {
background-color:#95afc0;
color:white;
padding:4px;
margin-right:8px;
border:none;
}
.container-fluid {
position: relative;
@ -549,3 +619,39 @@ margin-left: 0;
.chosen-container {
text-align: left;
}
.chosen-single,
.chosen-container,
.chosen-container-multi,
.chosen-results,
.chosen-search,
.chosen-drop,
.chosen-choices,
li.search-choice {
font-size: inherit !important;
border-radius:4px;
border-color:rgb(200,200,200) !important ;
}
.reduced-text {
font-size:0.9em;
}
.glyphicon.glyphicon-dot:before {
content: "\25cf";
font-size: 1.5em;
padding-right:5px;
}
.gi-1p5x{font-size: 1.5em;}
.gi-2x{font-size: 2em;}
.gi-3x{font-size: 3em;}
.gi-4x{font-size: 4em;}
.gi-5x{font-size: 5em;}
.filterBar {
margin-top:5px;
margin-bottom:5px;
}

View File

@ -1,6 +1,5 @@
#logSummary {
margin: 4px auto 0;
border-collapse: collapse;
font-size:10px;
}
#logSummary tr {
@ -11,7 +10,6 @@
#logSummary td {
border: 1px solid #7f7fb2;
padding: 0 6px;
text-align: center;
font-size: 10px;
line-height: 15px;
}

View File

@ -41,7 +41,7 @@ form .alarm {
}
h1 {
font-size: 250%;
font-size: 150%;
margin-top: 0;
margin-bottom: 15px;
}

View File

@ -74,6 +74,7 @@ if ( file_exists( "skins/$skin/css/$css/graphics/favicon.ico" ) ) {
<link rel="stylesheet" href="css/reset.css" type="text/css"/>
<link rel="stylesheet" href="css/overlay.css" type="text/css"/>
<link rel="stylesheet" href="css/bootstrap.min.css" type="text/css"/>
<?php
echo output_link_if_exists( array(
'css/base/skin.css',
@ -293,7 +294,7 @@ if (isset($_REQUEST['filter']['Query']['terms']['attr'])) {
<div class="navbar-right">
<?php if ( ZM_OPT_USE_AUTH and $user ) { ?>
<p class="navbar-text"><?php echo translate('LoggedInAs') ?> <?php echo makePopupLink( '?view=logout', 'zmLogout', 'logout', $user['Username'], (ZM_AUTH_TYPE == "builtin") ) ?> </p>
<p class="navbar-text"><i class="material-icons">account_circle</i> <?php echo makePopupLink( '?view=logout', 'zmLogout', 'logout', $user['Username'], (ZM_AUTH_TYPE == "builtin") ) ?> </p>
<?php } ?>
<?php if ( canEdit( 'System' ) ) { ?>
@ -311,9 +312,9 @@ if (isset($_REQUEST['filter']['Query']['terms']['attr'])) {
if ( (!ZM_OPT_USE_AUTH) or $user ) {
if ($reload == 'reload') ob_start();
?>
<div id="reload" class="container-fluid">
<div id="reload" class="container-fluid reduced-text">
<div id="Bandwidth" class="pull-left">
<?php echo makePopupLink( '?view=bandwidth', 'zmBandwidth', 'bandwidth', $bandwidth_options[$_COOKIE['zmBandwidth']] . ' ' . translate('BandwidthHead'), ($user && $user['MaxBandwidth'] != 'low' ) ) ?>
<?php echo makePopupLink( '?view=bandwidth', 'zmBandwidth', 'bandwidth', "<i class='material-icons md-18'>network_check</i>&nbsp;".$bandwidth_options[$_COOKIE['zmBandwidth']] . ' ', ($user && $user['MaxBandwidth'] != 'low' ) ) ?>
</div>
<div id="Version" class="pull-right">
<?php echo makePopupLink( '?view=version', 'zmVersion', 'version', '<span class="version '.$versionClass.'">v'.ZM_VERSION.'</span>', canEdit( 'System' ) ) ?>
@ -322,7 +323,8 @@ if ($reload == 'reload') ob_start();
<?php } ?>
</div>
<ul class="list-inline">
<li class="Load"><?php echo translate('Load') ?>: <?php echo getLoad() ?></li>
<li class="Load"><i class="material-icons md-18">trending_up</i>&nbsp;<?php echo translate('Load') ?>: <?php echo getLoad() ?></li>
<i class="material-icons md-18">storage</i>
<?php
$connections = dbFetchOne( "SHOW status WHERE variable_name='threads_connected'", 'Value' );
$max_connections = dbFetchOne( "SHOW variables WHERE variable_name='max_connections'", 'Value' );

View File

@ -146,26 +146,28 @@ if ( $show_storage_areas ) $left_columns += 1;
xhtmlHeaders( __FILE__, translate('Console') );
?>
<body>
<form name="monitorForm" method="get" action="<?php echo $_SERVER['PHP_SELF'] ?>">
<input type="hidden" name="view" value="<?php echo $view ?>"/>
<input type="hidden" name="action" value=""/>
<?php echo $navbar ?>
<?php echo $filterbar ?>
<div class="filterBar"><?php echo $filterbar ?></div>
<div class="container-fluid">
<table class="table table-striped table-hover table-condensed" id="consoleTable">
<thead>
<thead class="thead-highlight">
<tr>
<?php if ( ZM_WEB_ID_ON_CONSOLE ) { ?>
<th class="colId"><?php echo translate('Id') ?></th>
<?php } ?>
<th class="colName"><?php echo translate('Name') ?></th>
<th class="colName"><i class="material-icons md-18">videocam</i>&nbsp;<?php echo translate('Name') ?></th>
<th class="colFunction"><?php echo translate('Function') ?></th>
<?php if ( count($servers) ) { ?>
<th class="colServer"><?php echo translate('Server') ?></th>
<?php } ?>
<th class="colSource"><?php echo translate('Source') ?></th>
<th class="colSource"><i class="material-icons md-18">settings</i>&nbsp;<?php echo translate('Source') ?></th>
<?php if ( $show_storage_areas ) { ?>
<th class="colStorage"><?php echo translate('Storage') ?></th>
<?php }
@ -206,6 +208,8 @@ for( $monitor_i = 0; $monitor_i < count($displayMonitors); $monitor_i += 1 ) {
$fclass .= ' disabledText';
$scale = max( reScale( SCALE_BASE, $monitor['DefaultScale'], ZM_WEB_DEFAULT_SCALE ), SCALE_BASE );
$stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Function'] != 'None';
$dot_class=$source_class;
if ( $fclass != 'infoText' ) $dot_class=$fclass;
if ( ZM_WEB_ID_ON_CONSOLE ) {
?>
@ -214,7 +218,7 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
}
?>
<td class="colName">
<a <?php echo ($stream_available ? 'href="?view=watch&amp;mid='.$monitor['Id'].'">' : '>') . $monitor['Name'] ?></a><br/>
<span class="glyphicon glyphicon-dot <?php echo $dot_class ?>" aria-hidden="true"></span><a <?php echo ($stream_available ? 'href="?view=watch&amp;mid='.$monitor['Id'].'">' : '>') . $monitor['Name'] ?></a><br/><div class="small text-nowrap text-muted">
<?php echo $monitor['Status'] ?><br/>
<?php echo implode('<br/>',
array_map(function($group_id){
@ -224,9 +228,9 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
return implode(' &gt; ', array_map(function($Group){ return $Group->Name(); }, $Groups ));
}, $Monitor->GroupIds() ) );
?>
</td>
</div></td>
<td class="colFunction">
<?php echo makePopupLink( '?view=function&amp;mid='.$monitor['Id'], 'zmFunction', 'function', '<span class="'.$fclass.'">'.translate('Fn'.$monitor['Function']).( empty($monitor['Enabled']) ? ', disabled' : '' ) .'</span>', canEdit( 'Monitors' ) ) ?><br/>
<?php echo makePopupLink( '?view=function&amp;mid='.$monitor['Id'], 'zmFunction', 'function', '<span class="'.$fclass.'">'.translate('Fn'.$monitor['Function']).( empty($monitor['Enabled']) ? ', disabled' : '' ) .'</span>', canEdit( 'Monitors' ) ) ?><br/><div class="small text-nowrap text-muted">
<?php
$fps_string = '';
if ( isset($monitor['CaptureFPS']) ) {
@ -234,12 +238,12 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
}
if ( isset($monitor['AnalysisFPS']) and ( $monitor['Function'] == 'Mocord' or $monitor['Function'] == 'Modect' ) ) {
$fps_string .= ' / ' . $monitor['AnalysisFPS'];
$fps_string .= '/' . $monitor['AnalysisFPS'];
}
if ($fps_string) $fps_string .= ' FPS';
if ($fps_string) $fps_string .= ' fps';
echo $fps_string;
?>
</td>
</div></td>
<?php
if ( count($servers) ) { ?>
<td class="colServer"><?php $Server = isset($ServersById[$monitor['ServerId']]) ? $ServersById[$monitor['ServerId']] : new Server( $monitor['ServerId'] ); echo $Server->Name(); ?></td>
@ -279,7 +283,7 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
foreach ( array_keys( $eventCounts ) as $i ) {
?>
<td class="colEvents"><a <?php echo (canView('Events') ? 'href="?view='.ZM_WEB_EVENTS_VIEW.'&amp;page=1'.$monitor['eventCounts'][$i]['filter']['query'].'">' : '') .
$monitor[$i.'Events'] . '<br/>' . human_filesize($monitor[$i.'EventDiskSpace']) ?></a></td>
$monitor[$i.'Events'] . '<br/></a><div class="small text-nowrap text-muted">' . human_filesize($monitor[$i.'EventDiskSpace']) ?></div></td>
<?php
}
?>
@ -301,23 +305,23 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
</tbody>
<tfoot>
<tr>
<td class="colId"><?php echo count($displayMonitors) ?></td>
<td class="colId"><?php echo translate('Total').":".count($displayMonitors) ?></td>
<td class="colLeftButtons" colspan="<?php echo $left_columns -1?>">
<button type="button" name="addBtn" onclick="addMonitor(this);"
<?php echo (canEdit('Monitors') && !$user['MonitorIds']) ? '' : ' disabled="disabled"' ?>
>
<?php echo translate('AddNewMonitor') ?>
<span class="glyphicon glyphicon-plus-sign" aria-hidden="true"></span>&nbsp;<?php echo translate('AddNewMonitor') ?>
</button>
<button type="button" name="cloneBtn" onclick="cloneMonitor(this);"
<?php echo (canEdit('Monitors') && !$user['MonitorIds']) ? '' : ' disabled="disabled"' ?>
style="display:none;">
<?php echo translate('CloneMonitor') ?>
<span class="glyphicon glyphicon-copy"></span>&nbsp;<?php echo translate('CloneMonitor') ?>
</button>
<button type="button" name="editBtn" onclick="editMonitor(this);" disabled="disabled">
<?php echo translate('Edit') ?>
<span class="glyphicon glyphicon-edit" aria-hidden="true"></span>&nbsp;<?php echo translate('Edit') ?>
</button>
<button type="button" name="deleteBtn" onclick="deleteMonitor(this);" disabled="disabled">
<?php echo translate('Delete') ?>
<span class="glyphicon glyphicon-trash" aria-hidden="true"></span>&nbsp;<?php echo translate('Delete') ?>
</button>
</td>
<?php
@ -326,7 +330,7 @@ $stream_available = canView('Stream') && $monitor['CaptureFPS'] && $monitor['Fun
?>
<td class="colEvents">
<a <?php echo (canView('Events') ? 'href="?view='.ZM_WEB_EVENTS_VIEW.'&amp;page=1'.$eventCounts[$i]['filter']['query'].'">' : '') .
$eventCounts[$i]['totalevents'].'<br/>'.human_filesize($eventCounts[$i]['totaldiskspace']) ?></a></td>
$eventCounts[$i]['totalevents'].'<br/></a>'.'<div class="small text-nowrap text-muted">'.human_filesize($eventCounts[$i]['totaldiskspace']) ?></td>
<?php
}
?>

View File

@ -51,7 +51,7 @@ xhtmlHeaders(__FILE__, translate('Groups') );
<input type="hidden" name="view" value="none"/>
<input type="hidden" name="action" value="setgroup"/>
<table id="contentTable" class="major">
<thead>
<thead class="thead-highlight">
<tr>
<th class="colName" colspan="<?php echo $max_depth ?>"><?php echo translate('Name') ?></th>
<th class="colIds"><?php echo translate('Monitors') ?></th>

View File

@ -31,40 +31,73 @@ xhtmlHeaders(__FILE__, translate('SystemLog') );
<body>
<div id="page">
<div id="header">
<div id="headerButtons">
<input type="button" value="<?php echo translate('More') ?>" onclick="expandLog()"/>
<input type="button" value="<?php echo translate('Clear') ?>" onclick="clearLog()"/>
<input type="button" value="<?php echo translate('Refresh') ?>" onclick="refreshLog()"/>
<input type="button" value="<?php echo translate('Export') ?>" onclick="exportLog()"/>
<input type="button" value="<?php echo translate('Close') ?>" onclick="closeWindow()"/>
</div>
<h2 class="floating"><?php echo translate('SystemLog') ?></h2>
<div id="headerControl">
<table id="logSummary" cellspacing="0">
<tr>
<td><?php echo translate('Updated') ?>: <span id="lastUpdate"></span></td>
<td><?php echo translate('State') ?>: <span id="logState"></span></td>
<td><?php echo translate('Total') ?>: <span id="totalLogs"></span></td>
<td><?php echo translate('Available') ?>: <span id="availLogs"></span></td>
<td><?php echo translate('Displaying') ?>: <span id="displayLogs"></span></td>
</tr>
</table>
</div>
</div>
<table class="table">
<tr class="row">
<td class="col text-center">
<div id="logSummary">
<?php echo translate('State') ?>: <span id="logState"></span>/
<?php echo translate('Total') ?>: <span id="totalLogs"></span>/
<?php echo translate('Available') ?>: <span id="availLogs"></span>/
<?php echo translate('Displaying') ?>: <span id="displayLogs"></span>/
<?php echo translate('Updated') ?>: <span id="lastUpdate"></span>
</div>
</td>
</tr>
<tr class="row">
<td class="col text-center">
<div class="btn-group">
<button type="button" class="btn btn-sm" onclick="expandLog()"> <?php echo translate('More') ?></button>
<button type="button" class="btn btn-sm" onclick="clearLog()"> <?php echo translate('Clear') ?></button>
<button type="button" class="btn btn-sm" onclick="refreshLog()"> <?php echo translate('Refresh') ?></button>
<button type="button" class="btn btn-sm" onclick="exportLog()"> <?php echo translate('Export') ?></button>
<button type="button" class="btn btn-sm" onclick="closeWindow()"> <?php echo translate('Close') ?></button>
</div> <!--btn-->
</td>
</tr>
</table>
</div> <!--header-->
<div id="content">
<div id="filters"><?php echo translate('FilterLog') ?> -
<?php echo translate('Component') ?> <select id="filter[Component]" onchange="filterLog(this)"><option value="">-----</option></select>
<?php echo translate('Server') ?> <select id="filter[ServerId]" onchange="filterLog(this)"><option value="">-----</option></select>
<?php echo translate('Pid') ?> <select id="filter[Pid]" onchange="filterLog(this)"><option value="">-----</option></select>
<?php echo translate('Level') ?> <select id="filter[Level]" onchange="filterLog(this)"><option value="">---</option></select>
<?php echo translate('File') ?> <select id="filter[File]" onchange="filterLog(this)"><option value="">------</option></select>
<?php echo translate('Line') ?> <select id="filter[Line]" onchange="filterLog(this)"><option value="">----</option></select>
<div id="filters">
<table cellpadding="5" class="table-condensed">
<tr class="row">
<td class="col">
<?php echo translate('Component') ?>
<select class="form-control chosen" id="filter[Component]" onchange="filterLog(this)"><option value="">-----</option></select>
</td>
<td class="col">
<?php echo translate('Server') ?>
<select class="form-control chosen" id="filter[ServerId]" onchange="filterLog(this)"><option value="">-----</option></select>
</td>
<td class="col">
<?php echo translate('Pid') ?>
<select class="form-control chosen" id="filter[Pid]" onchange="filterLog(this)"><option value="">-----</option></select>
</td>
</tr>
<tr class="row">
<td class="col">
<?php echo translate('Level') ?>
<select class="form-control chosen" id="filter[Level]" onchange="filterLog(this)"><option value="">---</option></select>
</td>
<td class="col">
<?php echo translate('File') ?>
<select class="form-control chosen" id="filter[File]" onchange="filterLog(this)"><option value="">------</option></select>
</td>
<td class="col">
<?php echo translate('Line') ?>
<select class="form-control chosen" id="filter[Line]" onchange="filterLog(this)"><option value="">----</option></select>
</td>
</tr>
</table>
<input type="reset" value="<?php echo translate('Reset') ?>" onclick="resetLog()"/>
</div>
<form name="logForm" method="post" action="<?php echo $_SERVER['PHP_SELF'] ?>">
<input type="hidden" name="view" value="<?php echo $view ?>"/>
<table id="logTable" class="major" cellspacing="0">
<thead>
<thead class="thead-highlight">
<tr>
<th><?php echo translate('DateTime') ?></th>
<th class="table-th-nosort"><?php echo translate('Component') ?></th>

View File

@ -16,7 +16,7 @@ xhtmlHeaders(__FILE__, translate('Login') );
<div id="loginform">
<h1><?php echo ZM_WEB_TITLE . ' ' . translate('Login') ?></h1>
<h1><i class="material-icons md-36">account_circle</i> <?php echo ZM_WEB_TITLE . ' ' . translate('Login') ?></h1>
<label for="inputUsername" class="sr-only"><?php echo translate('Username') ?></label>
<input type="text" id="inputUsername" name="username" class="form-control" placeholder="Username" required autofocus />

View File

@ -90,6 +90,7 @@ foreach ( $tabs as $name=>$value ) {
</ul>
</div>
<div class="col-sm-10 col-sm-offset-2">
<br/>
<div id="options">
<?php
if ( $tab == 'skins' ) {
@ -100,7 +101,7 @@ if ( $tab == 'skins' ) {
<div class="form-group">
<label for="skin-choice" class="col-sm-3 control-label">SKIN</label>
<div class="col-sm-6">
<select name="skin-choice" class="form-control">
<select name="skin-choice" class="form-control chosen">
<?php
foreach($skin_options as $dir) {
echo '<option value="'.$dir.'" '.($current_skin==$dir ? 'SELECTED="SELECTED"' : '').'>'.$dir.'</option>';
@ -113,7 +114,7 @@ foreach($skin_options as $dir) {
<div class="form-group">
<label for="css-choice" class="col-sm-3 control-label">CSS</label>
<div class="col-sm-6">
<select name="css-choice" class="form-control">
<select name="css-choice" class="form-control chosen">
<?php
foreach( array_map( 'basename', glob('skins/'.$current_skin.'/css/*',GLOB_ONLYDIR) ) as $dir) {
echo '<option value="'.$dir.'" '.($current_css==$dir ? 'SELECTED="SELECTED"' : '').'>'.$dir.'</option>';
@ -136,7 +137,7 @@ foreach( array_map( 'basename', glob('skins/'.$current_skin.'/css/*',GLOB_ONLYDI
<input type="hidden" name="tab" value="<?php echo $tab ?>"/>
<input type="hidden" name="action" value="delete"/>
<table id="contentTable" class="table table-striped" cellspacing="0">
<thead>
<thead class="thead-highlight">
<tr>
<th class="colUsername"><?php echo translate('Username') ?></th>
<th class="colLanguage"><?php echo translate('Language') ?></th>
@ -201,7 +202,7 @@ foreach( array_map( 'basename', glob('skins/'.$current_skin.'/css/*',GLOB_ONLYDI
<input type="hidden" name="action" value="delete"/>
<input type="hidden" name="object" value="server"/>
<table id="contentTable" class="table table-striped">
<thead>
<thead class="thead-highlight">
<tr>
<th class="colName"><?php echo translate('Name') ?></th>
<th class="colHostname"><?php echo translate('Hostname') ?></th>
@ -256,7 +257,7 @@ foreach( array_map( 'basename', glob('skins/'.$current_skin.'/css/*',GLOB_ONLYDI
<input type="hidden" name="action" value="delete"/>
<input type="hidden" name="object" value="storage"/>
<table id="contentTable" class="table table-striped" cellspacing="0">
<thead>
<thead class="thead-highlight">
<tr>
<th class="colId"><?php echo translate('Id') ?></th>
<th class="colName"><?php echo translate('name') ?></th>