/**
 * Created by Administrator on 2016/10/10.
 */
var ajaxJS = function(url, data, async, type, successfn) {
    // showLoading();
    async = (async == null || async == "" || typeof (async) == "undefined") ? "true"
        : async;
    type = (type == null || type == "" || typeof (type) == "undefined") ? "post"
        : type;
    data = (data == null || data == "" || typeof (data) == "undefined") ?
        // {
        // "date" : new Date().getTime()
        // }
        ""
        : data;
    $.ajax({
        type : type,
        async : async,
        data : data,
        // url : "http://weix.mehos.cn/mhj/get/"+url,
        // url : "http://172.16.0.242:10016/mhj/get/"+url,
        // url : "http://172.16.0.241:10016/mhj/get/"+url,
        // url : "http://172.16.0.33:8088/mhj-console/get/"+url,
        // url : "http://172.16.0.34:8080/mhj-console/get/"+url,
        // url : "http://172.16.0.37:8888/mhj-console/get/"+url,
        // url : "http://172.16.0.188:8080/mhj-console/get/"+url,
        // url : "http://172.16.0.169:8080/get/"+url,
        dataType : "json",
        // beforeSend : function(request) {
        //     $(".lt").show()
        //     request.setRequestHeader("X-Token", "asdasdasdasdasdasdadsa");
        // },
        success : function(d) {
            $(".tem").fadeOut()
            // $(".lt").hide()
            successfn(d);
        },
        error : function(e) {

        }
    });
};