ajax 请求超时
ajax请求默认是异步的。
把请求改成同步
async: false
pack
import java.io.Serializable;
import java.util.List;
@SuppressWarnings("serial")
public class PageData implements Serializable {
private int code;
private String msg;
private int count;
private List<?> data;
public int getCode() {
return code;
}
public void setCode(int code) {
this.code = code;
}
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
public int getCount() {
return count;
}
public void setCount(int count) {
this.count = count;
}
public List<?> getData() {
return data;
}
public void setData(List<?> data) {
this.data = data;
}
public static PageData successData(List<?> data,int count) {
return new PageData(data,count);
}
public PageData(List<?> data,int count) {
this.count = count;
this.msg = "";
this.code = 0;
this.data = data;
}
}