diff --git a/src/classes/logstreamdisk.class.php b/src/classes/logstreamdisk.class.php index 9ab00f4..3eefe23 100644 --- a/src/classes/logstreamdisk.class.php +++ b/src/classes/logstreamdisk.class.php @@ -259,7 +259,9 @@ class LogStreamDisk extends LogStream { // This may display a warning message, so the user knows we stopped reading records because of the script timeout. $content['logstream_warning'] = "false"; $content['logstream_warning_details'] = $content['LN_WARNING_LOGSTREAMDISK_TIMEOUT']; - + $content['logstream_warning_code'] = ERROR_FILE_NOMORETIME; + + // Return error code return ERROR_FILE_NOMORETIME; } diff --git a/src/include/constants_errors.php b/src/include/constants_errors.php index 7952356..b36cd5d 100644 --- a/src/include/constants_errors.php +++ b/src/include/constants_errors.php @@ -51,6 +51,7 @@ define('ERROR_UNDEFINED', 6); define('ERROR_EOS', 7); define('ERROR_NOMORERECORDS', 8); define('ERROR_FILTER_NOT_MATCH', 9); +define('ERROR_SOURCENOTFOUND', 24); define('ERROR_DB_CONNECTFAILED', 10); define('ERROR_DB_CANNOTSELECTDB', 11); diff --git a/src/include/functions_common.php b/src/include/functions_common.php index 3bb90c4..add4c3b 100644 --- a/src/include/functions_common.php +++ b/src/include/functions_common.php @@ -1341,6 +1341,10 @@ function GetErrorMessage($errorCode) case ERROR_CHARTS_NOTCONFIGURED: return $content['LN_ERROR_CHARTS_NOTCONFIGURED']; + case ERROR_FILE_NOMORETIME: + return $content['LN_ERROR_FILE_NOMORETIME']; + case ERROR_SOURCENOTFOUND: + return $content['LN_GEN_ERROR_SOURCENOTFOUND']; default: return GetAndReplaceLangStr( $content['LN_ERROR_UNKNOWN'], $errorCode ); diff --git a/src/index.php b/src/index.php index 211fe63..546c4b4 100644 --- a/src/index.php +++ b/src/index.php @@ -268,6 +268,7 @@ if ( isset($content['Sources'][$currentSourceID]) ) // This will disable to Main SyslogView and show an error message $content['syslogmessagesenabled'] = "false"; $content['detailederror'] = $content['LN_ERROR_NORECORDS']; + $content['detailederror_code'] = ERROR_NOMORERECORDS; } // --- @@ -934,6 +935,7 @@ if ( isset($content['Sources'][$currentSourceID]) ) // This will disable to Main SyslogView and show an error message $content['syslogmessagesenabled'] = "false"; $content['detailederror'] = GetErrorMessage($res); + $content['detailederror_code'] = $res; if ( isset($extraErrorDescription) ) $content['detailederror'] .= "

" . GetAndReplaceLangStr( $content['LN_SOURCES_ERROR_EXTRAMSG'], $extraErrorDescription); @@ -946,6 +948,7 @@ else { $content['syslogmessagesenabled'] = "false"; $content['detailederror'] = GetAndReplaceLangStr( $content['LN_GEN_ERROR_SOURCENOTFOUND'], $currentSourceID); + $content['detailederror_code'] = ERROR_SOURCENOTFOUND; } // --- diff --git a/src/lang/en/main.php b/src/lang/en/main.php index 620585f..afc7f14 100644 --- a/src/lang/en/main.php +++ b/src/lang/en/main.php @@ -96,6 +96,7 @@ $content['LN_ERROR_DB_DBFIELDNOTFOUND'] = "Database Field mapping for at least o $content['LN_FOOTER_SECONDS'] = "seconds"; $content['LN_WARNING_LOGSTREAMTITLE'] = "Logstream Warning"; $content['LN_WARNING_LOGSTREAMDISK_TIMEOUT'] = "While reading the logstream, the php script timeout forced me to abort at this point.

If you want to avoid this, please increase the phpLogCon script timeout in your config.php. If the user system is installed, you can do that in Admin center."; + $content['LN_ERROR_FILE_NOMORETIME'] = "No more time for processing left"; // Topmenu Entries $content['LN_MENU_SEARCH'] = "Search"; diff --git a/src/templates/index.html b/src/templates/index.html index b2bd465..16c6b41 100644 --- a/src/templates/index.html +++ b/src/templates/index.html @@ -369,7 +369,13 @@
{LN_ERROR_NORECORDS} - {LN_GEN_ERRORDETAILS}
-

{detailederror}

+

{detailederror}

+

+ + + {LN_GEN_MOREINFORMATION} + +



@@ -382,6 +388,12 @@
{LN_WARNING_LOGSTREAMTITLE}

{logstream_warning_details}

+

+ + + {LN_GEN_MOREINFORMATION} + +