var searchJson==[{propertyName:"start_time",propertyType:"STRING",propertyValue:start_time,matchType:"GE"},{propertyName:"end_time",propertyValue:end_time,matchType:"LE"}];
$.ajax({
url:"<%=request.getContextPath()%>/test/test_test.action",
data:{searchJson:searchJson},
type:"POST",
success:function(data){}
});
POST传值如下:
这个一定不是想要的格式啊。网上各种查。。data代码修改如下:
data:{:JSON.stringify(searchJson)},
JSON.stringify的作用是:将value(Object,Array,String,Number...)序列化为JSON字符串
原文链接:https://www.f2er.com/json/290440.html