From c37278788233c31e6bef6e9ab79ad4f3bfc07cd2 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Thu, 6 Jul 2017 10:50:56 -0400 Subject: [PATCH 1/9] fix typo --- web/includes/functions.php | 3 +-- web/skins/classic/views/events.php | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/web/includes/functions.php b/web/includes/functions.php index b76cb5c55..b85624335 100644 --- a/web/includes/functions.php +++ b/web/includes/functions.php @@ -2138,8 +2138,7 @@ function getSkinFile( $file ) { return( $skinFile ); } -function getSkinIncludes( $file, $includeBase=false, $asOverride=false ) -{ +function getSkinIncludes( $file, $includeBase=false, $asOverride=false ) { global $skinBase; $skinFile = false; foreach ( $skinBase as $skin ) { diff --git a/web/skins/classic/views/events.php b/web/skins/classic/views/events.php index 59df19e7f..ea1a58f2e 100644 --- a/web/skins/classic/views/events.php +++ b/web/skins/classic/views/events.php @@ -214,7 +214,7 @@ foreach ( $events as $event ) { Id().'&fid='.$thumbData['FrameId'].'&width='.$thumbData['Width'].'&height='.$thumbData['Height']; - $streamSrc = $Event->getStreamSrc( array( 'mode'=>'jpeg', 'scale'=>$scale, 'maxfps'=>ZM_WEB_VIDEO_MAXFPS, 'replay'=>'single') ); + $streamSrc = $event->getStreamSrc( array( 'mode'=>'jpeg', 'scale'=>$scale, 'maxfps'=>ZM_WEB_VIDEO_MAXFPS, 'replay'=>'single') ); $imgHtml = ''. validHtmlStr('Event '.$event->Id()) .''; From 50adec45c5445381b356f6aa55b3d5900459b9ba Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Thu, 6 Jul 2017 11:45:17 -0400 Subject: [PATCH 2/9] Strip non 7-bit ascii chars from log message --- web/ajax/log.php | 1 + 1 file changed, 1 insertion(+) diff --git a/web/ajax/log.php b/web/ajax/log.php index c38a6d5d0..81312d709 100644 --- a/web/ajax/log.php +++ b/web/ajax/log.php @@ -95,6 +95,7 @@ switch ( $_REQUEST['task'] ) foreach ( dbFetchAll( $sql, NULL, $values ) as $log ) { $log['DateTime'] = preg_replace( '/^\d+/', strftime( "%Y-%m-%d %H:%M:%S", intval($log['TimeKey']) ), $log['TimeKey'] ); $log['Server'] = ( $log['ServerId'] and isset($servers_by_Id[$log['ServerId']]) ) ? $servers_by_Id[$log['ServerId']]->Name() : ''; + $log['Message'] = preg_replace('/[\x00-\x1F\x7F-\xFF]/', '', $log['Message'] ); $logs[] = $log; } $options = array(); From 39745e49d45ce9f6fdd0597c3926fcfa2169c81a Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 7 Jul 2017 09:51:51 -0400 Subject: [PATCH 3/9] I think we switch to border-box model or something, anyways, the box that the pantilt buttons go in needs to be 100px not 96px --- web/skins/classic/css/classic/control.css | 4 ++-- web/skins/classic/css/dark/control.css | 4 ++-- web/skins/classic/css/flat/control.css | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/web/skins/classic/css/classic/control.css b/web/skins/classic/css/classic/control.css index 8e84b4705..55134cd27 100644 --- a/web/skins/classic/css/classic/control.css +++ b/web/skins/classic/css/classic/control.css @@ -79,8 +79,8 @@ border: 1px solid #006699; text-align: center; padding: 1px; - width: 96px; - height: 96px; + width: 100px; + height: 100px; } .ptzControls .controlsPanel .pantiltPanel .pantiltControls .arrowBtn { diff --git a/web/skins/classic/css/dark/control.css b/web/skins/classic/css/dark/control.css index 8e84b4705..55134cd27 100644 --- a/web/skins/classic/css/dark/control.css +++ b/web/skins/classic/css/dark/control.css @@ -79,8 +79,8 @@ border: 1px solid #006699; text-align: center; padding: 1px; - width: 96px; - height: 96px; + width: 100px; + height: 100px; } .ptzControls .controlsPanel .pantiltPanel .pantiltControls .arrowBtn { diff --git a/web/skins/classic/css/flat/control.css b/web/skins/classic/css/flat/control.css index 8e84b4705..55134cd27 100644 --- a/web/skins/classic/css/flat/control.css +++ b/web/skins/classic/css/flat/control.css @@ -79,8 +79,8 @@ border: 1px solid #006699; text-align: center; padding: 1px; - width: 96px; - height: 96px; + width: 100px; + height: 100px; } .ptzControls .controlsPanel .pantiltPanel .pantiltControls .arrowBtn { From 2dd8b5df1fbdd76da2feaa23321808934ba7b69b Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 7 Jul 2017 09:59:41 -0400 Subject: [PATCH 4/9] in dark and flat, the buttons use a larger font. The fixed size is not appropriate --- web/skins/classic/css/dark/control.css | 1 - web/skins/classic/css/flat/control.css | 1 - 2 files changed, 2 deletions(-) diff --git a/web/skins/classic/css/dark/control.css b/web/skins/classic/css/dark/control.css index 55134cd27..c36cd537b 100644 --- a/web/skins/classic/css/dark/control.css +++ b/web/skins/classic/css/dark/control.css @@ -6,7 +6,6 @@ .ptzControls input.ptzTextBtn { margin-top: 2px; - width: 40px; } .ptzControls .controlsPanel { diff --git a/web/skins/classic/css/flat/control.css b/web/skins/classic/css/flat/control.css index 55134cd27..c36cd537b 100644 --- a/web/skins/classic/css/flat/control.css +++ b/web/skins/classic/css/flat/control.css @@ -6,7 +6,6 @@ .ptzControls input.ptzTextBtn { margin-top: 2px; - width: 40px; } .ptzControls .controlsPanel { From 90882edc31b357d086eea4703d03fe83c377b3d3 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 7 Jul 2017 10:05:20 -0400 Subject: [PATCH 5/9] make montage images be display: block; This makes the layout not jump around when a camera feed dies --- web/skins/classic/css/classic/views/montage.css | 1 + web/skins/classic/css/dark/views/montage.css | 1 + web/skins/classic/css/flat/views/montage.css | 1 + 3 files changed, 3 insertions(+) diff --git a/web/skins/classic/css/classic/views/montage.css b/web/skins/classic/css/classic/views/montage.css index f37156633..c39ea7034 100644 --- a/web/skins/classic/css/classic/views/montage.css +++ b/web/skins/classic/css/classic/views/montage.css @@ -25,6 +25,7 @@ #monitors .imageFeed img { border: 2px solid #ffffff; + display: block; } #monitors .imageFeed img.idle { diff --git a/web/skins/classic/css/dark/views/montage.css b/web/skins/classic/css/dark/views/montage.css index 9553f7ad1..70e50abb1 100644 --- a/web/skins/classic/css/dark/views/montage.css +++ b/web/skins/classic/css/dark/views/montage.css @@ -21,6 +21,7 @@ #monitors .imageFeed img { border: 2px solid #999999; + display: block; } #monitors .imageFeed img.idle { diff --git a/web/skins/classic/css/flat/views/montage.css b/web/skins/classic/css/flat/views/montage.css index e315443ff..27a87069d 100644 --- a/web/skins/classic/css/flat/views/montage.css +++ b/web/skins/classic/css/flat/views/montage.css @@ -21,6 +21,7 @@ #monitors .imageFeed img { border: 2px solid #ffffff; + display: block; } #monitors .imageFeed img.idle { From 0eb7bfabf2de8a8aa012c6b14ec08b75485bafb3 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Fri, 7 Jul 2017 12:15:09 -0400 Subject: [PATCH 6/9] put the ajax query back to a post --- web/skins/classic/views/js/log.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/skins/classic/views/js/log.js b/web/skins/classic/views/js/log.js index f78912681..a7a8aa2c6 100644 --- a/web/skins/classic/views/js/log.js +++ b/web/skins/classic/views/js/log.js @@ -1,5 +1,5 @@ var logParms = "view=request&request=log&task=query"; -var logReq = new Request.JSON( { url: thisUrl, method: 'get', timeout: AJAX_TIMEOUT, link: 'cancel', onSuccess: logResponse } ); +var logReq = new Request.JSON( { url: thisUrl, method: 'post', timeout: AJAX_TIMEOUT, link: 'cancel', onSuccess: logResponse } ); var logTimer = undefined; var logTable = undefined; From 0faeef58c010207cb15942b351ee2a1766f5ac70 Mon Sep 17 00:00:00 2001 From: Joe Alamo Date: Mon, 10 Jul 2017 22:16:01 +0100 Subject: [PATCH 7/9] Update filterevents.rst (#1944) State where filters are actually saved --- docs/userguide/filterevents.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/filterevents.rst b/docs/userguide/filterevents.rst index 8477ef157..d3c4955c9 100644 --- a/docs/userguide/filterevents.rst +++ b/docs/userguide/filterevents.rst @@ -101,7 +101,7 @@ How filters actually work -------------------------- It is useful to know how filters actually work behind the scenes in ZoneMinder, in the event you find your filter not functioning as intended: -* the primary filter processing process in ZoneMinder is a perl file called ``zmfilter.pl`` +* the primary filter processing process in ZoneMinder is a perl file called ``zmfilter.pl`` which retrieves filters from the Filters database table * zmfilter.pl runs every FILTER_EXECUTE_INTERVAL seconds (default is 20s, can be changed in Options->System) * in each run, it goes through all the filters which are marked as "Run in Background" and if the conditions match performs the specified action * zmfilter.pl also reloads all the filters every FILTER_RELOAD_DELAY seconds (default is 300s/5mins, can be changed in Options->System) From dfd1c2844a6bb73adb260d80093c9535a309c5aa Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 11 Jul 2017 11:28:15 -0400 Subject: [PATCH 8/9] remove storageId --- web/skins/classic/views/montagereview.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/skins/classic/views/montagereview.php b/web/skins/classic/views/montagereview.php index 0c4342e8e..d3391387b 100644 --- a/web/skins/classic/views/montagereview.php +++ b/web/skins/classic/views/montagereview.php @@ -116,7 +116,7 @@ if ( !empty($_REQUEST['group']) ) { // Note we round up just a bit on the end time as otherwise you get gaps, like 59.78 to 00 in the next second, which can give blank frames when moved through slowly. $eventsSql = ' - SELECT E.Id,E.Name,E.StorageId,UNIX_TIMESTAMP(E.StartTime) AS StartTimeSecs, + SELECT E.Id,E.Name,UNIX_TIMESTAMP(E.StartTime) AS StartTimeSecs, CASE WHEN E.EndTime IS NULL THEN (SELECT UNIX_TIMESTAMP(DATE_ADD(E.StartTime, Interval max(Delta)+0.5 Second)) FROM Frames F WHERE F.EventId=E.Id) ELSE UNIX_TIMESTAMP(E.EndTime) END AS CalcEndTimeSecs, E.Length, From 4d130b85958a02cf29745ded60c7ed08b33eafc6 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 11 Jul 2017 14:42:26 -0400 Subject: [PATCH 9/9] updates to do_debian_package --- utils/do_debian_package.sh | 31 +++++++++++++------------------ 1 file changed, 13 insertions(+), 18 deletions(-) diff --git a/utils/do_debian_package.sh b/utils/do_debian_package.sh index a825d0b62..5034f0fb9 100755 --- a/utils/do_debian_package.sh +++ b/utils/do_debian_package.sh @@ -259,23 +259,19 @@ fi if [ $TYPE == "binary" ]; then if [ "$INTERACTIVE" != "no" ]; then - read -p "Not doing dput since it's a binary release. Do you want to install it? (Y/N)" + read -p "Not doing dput since it's a binary release. Do you want to install it? (y/N)" if [[ $REPLY == [yY] ]]; then sudo dpkg -i $DIRECTORY*.deb - else - echo $REPLY; fi; - if [ "$DISTRO" == "jessie" ]; then - read -p "Do you want to upload this binary to zmrepo? (y/N)" - if [[ $REPLY == [yY] ]]; then - if [ "$RELEASE" != "" ]; then - scp "zoneminder_${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/stable/mini-dinstall/incoming/" + read -p "Do you want to upload this binary to zmrepo? (y/N)" + if [[ $REPLY == [yY] ]]; then + if [ "$RELEASE" != "" ]; then + scp "zoneminder_${VERSION}-${DISTRO}"* "zoneminder-doc_${VERSION}-${DISTRO}"* "zoneminder-dbg_${VERSION}-${DISTRO}"* "zoneminder_${VERSION}.orig.tar.gz" "zmrepo@zmrepo.connortechnology.com:debian/stable/mini-dinstall/incoming/" + else + if [ "$BRANCH" == "" ]; then + scp "zoneminder_${VERSION}-${DISTRO}"* "zoneminder-doc_${VERSION}-${DISTRO}"* "zoneminder-dbg_${VERSION}-${DISTRO}"* "zoneminder_${VERSION}.orig.tar.gz" "zmrepo@zmrepo.connortechnology.com:debian/master/mini-dinstall/incoming/" else - if [ "$BRANCH" == "" ]; then - scp "zoneminder_${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/master/mini-dinstall/incoming/" - else - scp "$DIRECTORY-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/${BRANCH}/mini-dinstall/incoming/" - fi; + scp "$DIRECTORY-${DISTRO}"* "zoneminder-doc_${VERSION}-${DISTRO}"* "zoneminder-dbg_${VERSION}-${DISTRO}"* "zoneminder_${VERSION}.orig.tar.gz" "zmrepo@zmrepo.connortechnology.com:debian/${BRANCH}/mini-dinstall/incoming/" fi; fi; fi; @@ -295,11 +291,10 @@ else dput="Y"; if [ "$INTERACTIVE" != "no" ]; then - echo "Ready to dput $SC to $PPA ? Y/N..."; - read dput - fi - if [ "$dput" == [Yy] ]; then - dput $PPA $SC + read -p "Ready to dput $SC to $PPA ? Y/N..."; + if [[ "$REPLY" == [yY] ]]; then + dput $PPA $SC + fi; fi; fi;