fhemweb.js: display results of the detailed view get command in a dialog

git-svn-id: https://svn.fhem.de/fhem/trunk@8623 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig
2015-05-24 08:43:42 +00:00
parent 0b57ca6e82
commit 958ea1ca6c

View File

@@ -118,6 +118,18 @@ FW_jqueryReadyFn()
});
*/
$("form input.get[type=submit]").click(function(e) { //"get" via XHR to dialog
e.preventDefault();
var cmd = "", el=this;
$(el).parent().find("input,[name]").each(function() {
cmd += (cmd?"&":"")+$(this).attr("name")+"="+$(this).val();
});
FW_cmd(FW_root+"?"+cmd+"&XHR=1", function(data) {
FW_okDialog('<pre>'+data+'</pre>', el);
});
});
$("#saveCheck")
.css("cursor", "pointer")
.click(function(){