//获取代理信息
    private string getProxyList()
    {
        string strSortname  = Request.Params["sortname"];
        string strSortorder = Request.Params["sortorder"];
        //当前页面
        int intPageIndex = Convert.ToInt32(Request.Params["page"]);
        //每页记录数
        int intPageSize = Convert.ToInt32(Request.Params["pagesize"]);

        if (strSortname == null || strSortname.Length < 0)
        {
            strSortname = TSysUserProxyVo.ID_FIELD;
        }

        TSysUserProxyVo objProxy = new TSysUserProxyVo();

        if (strIsAdmin.Length == 0)
        {
            objProxy.USER_ID = LogInfo.UserInfo.ID;
        }
        objProxy.SORT_FIELD = strSortname;
        objProxy.SORT_TYPE  = strSortorder;

        int       intTotalCount = new TSysUserProxyLogic().GetSelectResultCount(objProxy);
        DataTable dt            = new TSysUserProxyLogic().SelectByTable(objProxy, intPageIndex, intPageSize);

        string strJson = CreateToJson(dt, intTotalCount);

        return(strJson);
    }
    public static string deleteData(string strDelIDs)
    {
        if (strDelIDs.Length == 0)
        {
            return("0");
        }

        string[] arrDelIDs = strDelIDs.Split(',');

        bool isSuccess = true;

        for (int i = 0; i < arrDelIDs.Length; i++)
        {
            isSuccess = new TSysUserProxyLogic().Delete(arrDelIDs[i]);
        }

        if (isSuccess)
        {
            new PageBase().WriteLog("删除代理", "", new UserLogInfo().UserInfo.USER_NAME + "删除代理" + strDelIDs);
            return("1");
        }
        else
        {
            return("0");
        }
    }
    public static string EditData(string strID, string strUSER_ID, string strProxyID)
    {
        bool isSuccess = true;

        new TSysUserProxyLogic().Delete(strID);

        TSysUserProxyVo objProxyDel = new TSysUserProxyVo();

        objProxyDel.USER_ID = strUSER_ID;
        new TSysUserProxyLogic().Delete(objProxyDel);

        TSysUserProxyVo objProxy = new TSysUserProxyVo();

        objProxy.ID            = GetSerialNumber("t_sys_user_proxy_id");
        objProxy.USER_ID       = strUSER_ID;
        objProxy.PROXY_USER_ID = strProxyID;

        isSuccess = new TSysUserProxyLogic().Create(objProxy);

        if (isSuccess)
        {
            new PageBase().WriteLog("编辑代理", "", new UserLogInfo().UserInfo.USER_NAME + "编辑代理" + objProxy.ID);
            return("1");
        }
        else
        {
            return("0");
        }
    }
    public static string getProxyOfUser(string strUserID)
    {
        TSysUserProxyVo objProxyWhere = new TSysUserProxyVo();

        objProxyWhere.USER_ID = strUserID;
        TSysUserProxyVo objProxy = new TSysUserProxyLogic().Details(objProxyWhere);
        TSysUserVo      objUser  = new TSysUserLogic().Details(objProxy.PROXY_USER_ID);

        return(objProxy.PROXY_USER_ID + "|" + objUser.REAL_NAME);
    }
    public static string SaveData(string strUserID, string strProxyID)
    {
        bool isSuccess = true;

        TSysUserProxyVo objProxy = new TSysUserProxyVo();

        TSysUserProxyVo objProxyWhere = new TSysUserProxyVo();

        objProxyWhere.USER_ID = strUserID;
        List <TSysUserProxyVo> lst = new TSysUserProxyLogic().SelectByObject(objProxyWhere, 0, 0);

        if (lst.Count > 0)
        {
            objProxy.ID            = lst[0].ID;
            objProxy.USER_ID       = strUserID;
            objProxy.PROXY_USER_ID = strProxyID;

            isSuccess = new TSysUserProxyLogic().Edit(objProxy);
            if (isSuccess)
            {
                new PageBase().WriteLog("编辑代理设置", "", new UserLogInfo().UserInfo.USER_NAME + "编辑代理设置" + objProxy.ID);
            }
        }
        else
        {
            objProxy.ID            = GetSerialNumber("t_sys_user_proxy_id");
            objProxy.USER_ID       = strUserID;
            objProxy.PROXY_USER_ID = strProxyID;

            isSuccess = new TSysUserProxyLogic().Create(objProxy);
            if (isSuccess)
            {
                new PageBase().WriteLog("添加代理设置", "", new UserLogInfo().UserInfo.USER_NAME + "添加代理设置" + objProxy.ID);
            }
        }

        if (isSuccess)
        {
            return("1");
        }
        else
        {
            return("0");
        }
    }