luci-base: form.js: trigger validation before saving cbi map
authorJo-Philipp Wich <jo@mein.io>
Thu, 6 Jun 2019 19:04:04 +0000 (21:04 +0200)
committerJo-Philipp Wich <jo@mein.io>
Sun, 7 Jul 2019 13:36:25 +0000 (15:36 +0200)
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
modules/luci-base/htdocs/luci-static/resources/form.js

index c4f3b8aece638fdeea371c25aff35ba01c67a55f..61518b749d097b768d6b6f7d06f3c8f4e99af568 100644 (file)
@@ -116,6 +116,8 @@ var CBIMap = CBINode.extend({
        },
 
        save: function() {
+               this.checkDepends();
+
                return this.parse()
                        .then(uci.save.bind(uci))
                        .then(this.load.bind(this))