Ajax请求Controller跳转

前台页面Ajax请求后台Contrller请求另一个Controller返回页面跳转不成功时处理办法

$.ajax({
        type : "POST",
        url : "${basePath}OrderManageController/ostate.do",
        async : false,
        data: {orderid:id,orderstate:state},
        success : function(data) {
            **if (data.forwardUrl != null) {
                window.parent.showMessageBoxParent(data.message, 2000);
                window.location = data.forwardUrl;**
            }
        },
        dataType : "json"
    });

你可能感兴趣的:(Ajax,请求,跳转)