修改wechat配置

This commit is contained in:
guange 2016-03-01 15:32:44 +08:00
parent d1e29220da
commit b1a95d4a53
1 changed files with 7 additions and 2 deletions

View File

@ -11,10 +11,15 @@
<script type="text/javascript"> <script type="text/javascript">
$(function(){ $(function(){
$("#submitForm").click(function(){ $("#submitForm").click(function(){
var data = {};
$("#main_login_form").serializeArray().map(function(x){data[x.name] = x.value;});
console.log(data);
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: $(this).parent("form").attr("action") + "?&authenticity_token=" + "<%=form_authenticity_token%>", url: $(this).parent("form").attr("action"),
data:$(this).parent("form").serialize(), data:data,
dataType: "json" dataType: "json"
}); });
return false; return false;