libs/cbi: Added "Save & Apply" button to CBI forms
[project/luci.git] / libs / cbi / luasrc / cbi.lua
index 6aec2fb..e695289 100644 (file)
@@ -154,6 +154,9 @@ end
 function Map.parse(self, ...)
        Node.parse(self, ...)
        uci.save(self.config)
+       if luci.http.formvalue("cbi.apply") then
+               uci.commit(self.config)
+       end
        uci.unload(self.config)
 end