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

FS#3287 - Can't save changes to interface with type MAP in LuCI #8206

Closed
openwrt-bot opened this issue Aug 16, 2020 · 1 comment
Closed

FS#3287 - Can't save changes to interface with type MAP in LuCI #8206

openwrt-bot opened this issue Aug 16, 2020 · 1 comment
Labels

Comments

@openwrt-bot
Copy link

RemiNV:

Observed on LuCI openwrt-19.07 branch (git-20.136.49537-fb2f363) / OpenWrt 19.07.3 r11063-85e04e9f46, on Chrome browser

Repro steps:

  • Install packages map, luci-proto-ipv6
  • Add interface with protocol type "MAP / LW4over6"
  • Try to edit the interface options in LuCI, and click save

Expected: Changes are saved and dialog is dismissed
Actual: "Save" button gets greyed out but dialog stays there. Chrome console says:

form.js?v=git-20.136.49537-fb2f363:formatted:1399 Uncaught TypeError: elem.isChecked is not a function
at ClassConstructor.formvalue (form.js?v=git-20.136.49537-fb2f363:formatted:1399)
at ClassConstructor.parse (form.js?v=git-20.136.49537-fb2f363:formatted:1410)
at ClassConstructor.parse (form.js?v=git-20.136.49537-fb2f363:formatted:386)
at ClassConstructor.parse (form.js?v=git-20.136.49537-fb2f363:formatted:237)
at ClassConstructor.save (form.js?v=git-20.136.49537-fb2f363:formatted:242)
at ClassConstructor.handleModalSave (form.js?v=git-20.136.49537-fb2f363:formatted:1043)
at ClassConstructor.super (luci.js?v=git-20.136.49537-fb2f363:22)
at ClassConstructor.handleModalSave (form.js?v=git-20.136.49537-fb2f363:formatted:1107)
at ClassConstructor.eval (ui.js?v=git-20.136.49537-fb2f363:300)

It appears that LuCI is confused by the fact that there are two controls for the "type" option:

It does not seem correct to have "type" be both a common option for all protocols, and have a different option with the same name for MAP: this makes the configuration ambiguous (which is why LuCI gets confused). I think renaming "type" to "maptype" (for example) for MAP would be the best solution.

@openwrt-bot
Copy link
Author

RemiNV:

Proposed patches in:
#3314

and:
openwrt/luci@9282df6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant