From 2ee1efe5ea057bea5d99d3a955fca04f915bff59 Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Fri, 15 Dec 2017 17:51:48 -0500 Subject: #569 #563 event playback with warning for inprogress streams (will fail in video, so warning is needed) --- www/css/style.css | 4 ++++ www/js/DataModel.js | 2 ++ www/js/EventModalCtrl.js | 6 ++++++ www/lang/locale-en.json | 1 + www/templates/events-modal.html | 2 +- 5 files changed, 14 insertions(+), 1 deletion(-) (limited to 'www') diff --git a/www/css/style.css b/www/css/style.css index b856491a..934fe0ca 100644 --- a/www/css/style.css +++ b/www/css/style.css @@ -480,6 +480,10 @@ http://www.cssportal.com/tryit/index.php?file=blog/css-notification-badge */ padding-right: 3px; } +.events-range-modal-warning-text { + background-color:red; +} + .monitor-modal-text { position: absolute; bottom: 30px; diff --git a/www/js/DataModel.js b/www/js/DataModel.js index de09d8cc..a9602ed1 100755 --- a/www/js/DataModel.js +++ b/www/js/DataModel.js @@ -1860,6 +1860,8 @@ angular.module('zmApp.controllers') // monitorId == 0 means all monitors (ZM starts from 1) //----------------------------------------------------------------------------- + // new reminder + // https://zm/api/events.json?&sort=StartTime&direction=desc getEvents: function (monitorId, pageId, loadingStr, startTime, endTime) { //console.log("ZMData getEvents called with ID=" + monitorId + "and Page=" + pageId); diff --git a/www/js/EventModalCtrl.js b/www/js/EventModalCtrl.js index b8a7acbc..a450fe80 100644 --- a/www/js/EventModalCtrl.js +++ b/www/js/EventModalCtrl.js @@ -1591,6 +1591,12 @@ angular.module('zmApp.controllers').controller('EventModalCtrl', ['$scope', '$ro var event = success.data.event; currentEvent = event; + $scope.eventWarning = ''; + + if (!event.Event.EndTime) { + $scope.eventWarning = $translate.instant('kEventStillRecording'); + } + event.Event.BasePath = computeBasePath(event); event.Event.relativePath = computeRelativePath(event); diff --git a/www/lang/locale-en.json b/www/lang/locale-en.json index 137f6c57..1c0939bb 100644 --- a/www/lang/locale-en.json +++ b/www/lang/locale-en.json @@ -92,6 +92,7 @@ "kErrorRetrievingState" :"error retrieving state", "kErrorSave" :"Error - could not save", "kEvent" :"event", + "kEventStillRecording" :"still recording", "kEventHistFaster" :"faster", "kEventHistHrs" :"hours ago", "kEventHistPause" :"pause", diff --git a/www/templates/events-modal.html b/www/templates/events-modal.html index 68065e24..3458fb2e 100644 --- a/www/templates/events-modal.html +++ b/www/templates/events-modal.html @@ -96,7 +96,7 @@ -
{{mName}}  {{videoDynamicTime}} ({{humanizeTime}}) [{{d_eventId}}]
+
{{mName}}  {{videoDynamicTime}} ({{humanizeTime}}) [{{d_eventId}}] {{eventWarning}}