mirror of
https://github.com/ZoneMinder/zoneminder.git
synced 2026-04-02 05:06:41 -04:00
Merge pull request #4078 from IgorA100/patch-148
Fix: Added getStat execution error handling Frame page
This commit is contained in:
@@ -54,6 +54,12 @@ function getStat(params) {
|
||||
$j.getJSON(thisUrl + '?view=request&request=stats&raw=true', params)
|
||||
.done(function(data) {
|
||||
$j('#frameStatsTable').empty().append('<tbody>');
|
||||
if (data.result == "Error") {
|
||||
console.log(`Error running getStat function: ${data.message}`);
|
||||
statsBtn.prop('disabled', true);
|
||||
statsBtn.prop('title', 'No statistics available for this frame');
|
||||
return;
|
||||
}
|
||||
if (!data.raw.length) {
|
||||
statsBtn.prop('disabled', true);
|
||||
statsBtn.prop('title', 'No statistics available for this frame');
|
||||
|
||||
Reference in New Issue
Block a user