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

This commit is contained in:
Isaac Connor 2019-08-23 18:17:50 -04:00
commit c4c6935c6e
3 changed files with 16 additions and 5 deletions

View File

@ -201,6 +201,8 @@ function changeReplayMode() {
}
var streamParms = "view=request&request=stream&connkey="+connKey;
if ( auth_hash )
streamCmdParms += '&auth='+auth_hash;
var streamCmdTimer = null;
var streamStatus = null;
@ -268,7 +270,7 @@ function getCmdResponse( respObj, respText ) {
}
var streamReq = new Request.JSON( {
url: thisUrl,
url: monitorUrl,
method: 'get',
timeout: AJAX_TIMEOUT,
link: 'chain',
@ -310,6 +312,7 @@ function playClicked( ) {
vjsPlay(); //handles fast forward and rewind
}
} else {
console.log("sending"+streamParms+"&command="+CMD_PLAY);
streamReq.send(streamParms+"&command="+CMD_PLAY);
streamPlay();
}
@ -597,6 +600,8 @@ var eventReq = new Request.JSON( {url: thisUrl, method: 'get', timeout: AJAX_TIM
function eventQuery( eventId ) {
var eventParms = "view=request&request=status&entity=event&id="+eventId;
if ( auth_hash )
eventParms += '&auth='+auth_hash;
eventReq.send( eventParms );
}
@ -897,6 +902,8 @@ var actReq = new Request.JSON( {url: thisUrl, method: 'get', timeout: AJAX_TIMEO
function actQuery( action, parms ) {
var actParms = "view=request&request=event&id="+eventData.Id+"&action="+action;
if ( auth_hash )
actParms += '&auth='+auth_hash;
if ( parms != null ) {
actParms += "&"+Object.toQueryString( parms );
}

View File

@ -36,6 +36,7 @@ var eventData = {
Frames: '<?php echo $Event->Frames() ?>',
MonitorName: '<?php echo $Monitor->Name() ?>'
};
var monitorUrl = '<?php echo $Monitor->UrlToIndex(); ?>';
var filterQuery = '<?php echo isset($filterQuery)?validJsStr(htmlspecialchars_decode($filterQuery)):'' ?>';
var sortQuery = '<?php echo isset($sortQuery)?validJsStr(htmlspecialchars_decode($sortQuery)):'' ?>';

View File

@ -154,9 +154,12 @@ function getImageSource(monId, time) {
var duration = Frame.NextTimeStampSecs - Frame.TimeStampSecs;
frame_id = Frame.FrameId + parseInt( (NextFrame.FrameId-Frame.FrameId) * ( time-Frame.TimeStampSecs )/duration );
//console.log("Have NextFrame: duration: " + duration + " frame_id = " + frame_id + " from " + NextFrame.FrameId + ' - ' + Frame.FrameId + " time: " + (time-Frame.TimeStampSecs) );
}
} else {
frame_id = Frame['Id'];
frame_id = Frame.FrameId;
}
} else {
frame_id = Frame.FrameId;
console.log("No NextFrame");
}
Event = events[Frame.EventId];