var list = [];var length = $(\"input[name=\'name\']\").lengthfor (var i=0;i< length;i++){var arr = new Object();arr.id= $(\"#id\").val();arr.name=$(\"#name\"+i).val();arr.count = $(\"#count\"+i).val();list.push(arr);}var arr=JSON.stringify(list);//Ajax提交数据至后台$.post( \'/****/****/save\',{\'siteAreaList\':arr},function(result){
数据接收
@PostMapping(value = \"/save\")@ResponseBodypublic Object saveConfig(String siteAreaList) {*************************}