예제 #1
0
    /// <summary>
    /// 用户类型值
    /// </summary>
    public void GetUserTypeInfo()
    {
        var roleId = PageRequest.GetQueryString("RoleId");
        List <Sys.Model.DicModel> lisAgentType, lisInstallerTypeList;

        new Sys.BLL.Account().RegisterInit(out lisAgentType, out lisInstallerTypeList);

        var json = string.Empty;

        if (roleId.Equals("1"))
        {
            json = PluSoft.Utils.JSON.Encode(lisAgentType);
        }
        else if (roleId.Equals("2"))
        {
            json = PluSoft.Utils.JSON.Encode(lisInstallerTypeList);
        }
        Response.Write(json);
    }
예제 #2
0
    /// <summary>
    /// 区域信息
    /// </summary>
    public void GetAreaInfo()
    {
        var dataType = PageRequest.GetQueryString("dataType");
        List <Sys.Model.DicModel> lisProvice, lisCity, lisArea;

        new Sys.BLL.UserInfo().AreaInit(out lisProvice, out lisCity, out lisArea);

        var json = string.Empty;

        if (dataType.Equals("p"))
        {
            json = PluSoft.Utils.JSON.Encode(lisProvice);
        }
        else if (dataType.Equals("c"))
        {
            json = PluSoft.Utils.JSON.Encode(lisCity);
        }
        else if (dataType.Equals("a"))
        {
            json = PluSoft.Utils.JSON.Encode(lisArea);
        }
        Response.Write(json);
    }
예제 #3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        string token   = PageRequest.GetQueryString("token");
        int    orderId = PageRequest.GetQueryInt("orderId", 0);
        //orderId = 31;
        var result = new Sys.BLL.Account().CheckToken(token);

        if (result)
        {
            //userLoginId = token.Split('|')[0];
        }
        else
        {
            Response.Write("<script>alert('Token验证失败');history.back(-1);</script>");
        }

        orderModel    = new Sys.BLL.Orders().GetModel(orderId);
        orderTypeList = new Sys.BLL.OrderType().GetModelList("OrderId=" + orderId);
        dtFlow        = new Sys.BLL.OrderStatusFlow().GetList(1000, "OrderId=" + orderId, "FlowId desc").Tables[0];

        new Sys.BLL.Orders().OrdersStatusInit(out lis);

        dtComment = new Sys.BLL.OrderComment().GetList("OrderId=" + orderId).Tables[0];
    }
예제 #4
0
    /// <summary>
    /// 检测管理员登陆,如果失败并做相应
    /// </summary>
    /// <param name="frmName">main:主操作区,menu:左边导航,top:上面导航,frame:框架</param>
    public static void CheckAdminLogin(string frmName)
    {
        if (Sys.BLL.Account.GetLoginAdminID() < 1)
        {
            frmName = frmName.ToLower();

            string js = "";
            if (frmName == "frame")
            {
                js = "alert('登陆已超时,请重新登录。');window.top.location.href = '/manage/login.aspx?url=" + Utils.UrlEncode(PageRequest.GetQueryString()) + "';";
            }
            else if (frmName == "main")
            {
                js = "alert('登陆已超时,请重新登录。');window.top.location.href = '/manage/login.aspx?url=" + Utils.UrlEncode(PageRequest.GetRawUrl()) + "';";
            }
            else
            {
                js = @"document.write('<input type=""button"" value=""登陆已超时,请重新登录。"" onclick=""window.top.location.href =\'/manage/login.aspx\'"" />');";
            }

            HttpContext.Current.Response.Write("<html><head><script language='javascript' type='text/javascript'>" + js + "</script></head></html>");
            HttpContext.Current.Response.End();
        }
    }