luci-mod-system: flash.js: fix passing sysupgrade opts
authorJo-Philipp Wich <jo@mein.io>
Mon, 7 Oct 2019 17:55:31 +0000 (19:55 +0200)
committerJo-Philipp Wich <jo@mein.io>
Mon, 7 Oct 2019 17:55:31 +0000 (19:55 +0200)
commit5ccbda54e810f51d7ab343815c6b80928eecfcbd
tree1129413c50e29d48c403ba1fd76eeed1460ddf25
parente7ca163d7c227c573620d08b7c86a9e739c070ed
luci-mod-system: flash.js: fix passing sysupgrade opts

Instead of binding the checked state to the button handler function,
bind the underlying checkboxes instead to observe the actual user
choice instead of the initial value.

This fixes forcing sysupgrade or deselecting keep settings.

Reported-by: Hannu Nyman <hannu.nyman@iki.fi>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
modules/luci-mod-system/htdocs/luci-static/resources/view/system/flash.js