Skip to content
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

Created network configuration page #8692

Merged
merged 8 commits into from
Sep 4, 2024
Merged

Created network configuration page #8692

merged 8 commits into from
Sep 4, 2024

Conversation

DGabri
Copy link
Contributor

@DGabri DGabri commented Sep 2, 2024

Please sign (check) the below before submitting the Pull Request:

Link to the related issue:

Describe changes:

  • Created network configuration page. (IP:3000/lua/admin/network_configuration.lua)
  • Add the new entry for this page in the menu: scripts/lua/modules/page_utils.lua
  • Remove the input box in the current behavioural checks (This was not done as it would break the current ntopng until this REST is completed)
  • GET and POST RESTs are at: /lua/rest/v2/set/network/config.lua /lua/rest/v2/get/network/config.lua

local res = {}

-- Get data from redis: expected format, array of objects with keys:
res = {{key= "unexpected_dhcp", value_description="192.168.2.85, 192.168.2.45" or "", is_enabled=true or false}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is_enabled is not necessary


data.forEach(item => {
const key = Object.keys(check_name).find(k => k === item.key);
if (key && item.is_enabled === true) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not necessary

@lucaderi lucaderi merged commit 658887a into ntop:dev Sep 4, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants