-
Notifications
You must be signed in to change notification settings - Fork 645
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added verbose parameter to add historical flow info to the response #8484
Conversation
@@ -3,9 +3,12 @@ | |||
-- | |||
local dirs = ntop.getDirs() | |||
package.path = dirs.installdir .. "/scripts/lua/modules/alert_store/?.lua;" .. package.path | |||
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path | |||
package.path = dirs.installdir .. "/scripts/lua/pro/modules/flow_db/?.lua;" .. package.path |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please add "if ntop.isPro()"
@@ -904,6 +894,47 @@ function flow_alert_store:format_record(value, no_html) | |||
end | |||
end | |||
|
|||
-- add additional flow related info | |||
if (verbose == "true") then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please use "if verbose then" (do not use a string, convert the string to a boolean in the caller)
@@ -69,7 +70,7 @@ if not download then | |||
|
|||
for _, _value in ipairs(alerts or {}) do | |||
-- tprint(_value) | |||
res[#res + 1] = flow_alert_store:format_record(_value, no_html) | |||
res[#res + 1] = flow_alert_store:format_record(_value, no_html, verbose) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use toboolean(verbose)
Please sign (check) the below before submitting the Pull Request:
Link to the related issue:
Describe changes:
Added verbose parameter to add historical flow info to the response