Move status fields out of the object fields

pull/2077/head
Isaac Connor 2018-01-29 10:27:46 -05:00
parent cfb0461fcf
commit 8c4a786114
1 changed files with 17 additions and 15 deletions

View File

@ -5,20 +5,22 @@ require_once( 'Server.php' );
class Monitor {
private $defaults = array(
'Id' => null,
'Name' => '',
'StorageId' => 0,
'ServerId' => 0,
'Function' => 'None',
'Enabled' => 1,
'Width' => null,
'Height' => null,
'Orientation' => null,
'AnalysisFPSLimit' => null,
'AnalysisFPS' => null,
'CaptureFPS' => null,
'ZoneCount' => 0,
'Triggers' => null,
'Id' => null,
'Name' => '',
'StorageId' => 0,
'ServerId' => 0,
'Function' => 'None',
'Enabled' => 1,
'Width' => null,
'Height' => null,
'Orientation' => null,
'AnalysisFPSLimit' => null,
'ZoneCount' => 0,
'Triggers' => null,
);
$private $status_fields = array(
'AnalysisFPS' => null,
'CaptureFPS' => null,
);
private $control_fields = array(
'Name' => '',
@ -329,7 +331,7 @@ private $control_fields = array(
daemonControl( 'start', 'zmc', $zmcArgs );
}
}
} else {
} else if ( $this->ServerId() ) {
$Server = $this->Server();
$url = $Server->Url() . '/zm/api/monitors/'.$this->{'Id'}.'.json';