/// <reference path="jquery-1.10.2.min.js" />
//唯一销售QQ客服：530273675
function admin_btn() {
    var name = $.trim($("#admin_name").val());
    var pwd = $.trim($("#admin_pwd").val());
    if (name == "" || pwd == "") {

        alert("账号或密码不能为空");

    } else {
        $.post("/ajax/Admin_login.ashx",{ "type":1,"name": name, "pwd": pwd }, function (data) {

            var data = JSON.parse(data);
            if (data.Success == true) {

                alert("登陆成功");
                window.location.href = "Admin_index.aspx";
            } else {

                alert("账号或密码错误");

            }



        });
    }



}

















function Admin_btn() {
    var password = $.trim($("#Password").val());
    if (password == "") {
        alert("密码不能为空");

    } else {

        $.post("/ajax/Admin_login.ashx", { "type": 2, "password": password }, function (data) {

            var data = JSON.parse(data);
            if (data.Success == true) {

                alert("密码修改成功");
                window.location.href = "Admin_index.aspx";
            } else {

                alert("密码修改失败");
            }
        })
    }


}

//$(function () {
//    $.post("/ajax/BaseLoginAjax.ashx", { "cmd": "checkislogin" }, function (data) {
//        var data = eval('(' + data + ')');
//        if (data.Success) {
//            window.location.href = "Admin_index.aspx";
//        }
//    })



//})