/// <summary>
        /// 对象编辑
        /// </summary>
        /// <param name="tSysPost_UpdateSet">UpdateSet用户对象</param>
        /// <param name="tSysPost_UpdateWhere">UpdateWhere用户对象</param>
        /// <returns>是否成功</returns>
        public bool Edit(TSysPostVo tSysPost_UpdateSet, TSysPostVo tSysPost_UpdateWhere)
        {
            string strSQL = SqlHelper.BuildUpdateExpress(tSysPost_UpdateSet, TSysPostVo.T_SYS_POST_TABLE);

            strSQL += this.BuildWhereStatement(tSysPost_UpdateWhere);
            return(SqlHelper.ExecuteNonQuery(CommandType.Text, strSQL) > 0 ? true : false);
        }
        /// <summary>
        /// 对象编辑
        /// </summary>
        /// <param name="tSysPost">用户对象</param>
        /// <returns>是否成功</returns>
        public bool Edit(TSysPostVo tSysPost)
        {
            string strSQL = SqlHelper.BuildUpdateExpress(tSysPost, TSysPostVo.T_SYS_POST_TABLE);

            strSQL += string.Format(" where ID='{0}' ", tSysPost.ID);
            return(SqlHelper.ExecuteNonQuery(CommandType.Text, strSQL) > 0 ? true : false);
        }
Beispiel #3
0
    private void GetPostStr(string strID, ref string strPostNames, ref string strPostIDs)
    {
        TSysUserPostVo objUserPost = new TSysUserPostVo();

        objUserPost.USER_ID = strID;
        DataTable dtUserPost = new TSysUserPostLogic().SelectByTable(objUserPost);

        TSysPostVo objPost = new TSysPostVo();

        objPost.IS_DEL = "0";
        //objPost.IS_HIDE = "0";
        DataTable dtPost = new TSysPostLogic().SelectByTable(objPost);

        for (int i = 0; i < dtUserPost.Rows.Count; i++)
        {
            for (int j = 0; j < dtPost.Rows.Count; j++)
            {
                if (dtPost.Rows[j]["ID"].ToString() == dtUserPost.Rows[i]["POST_ID"].ToString())
                {
                    strPostNames += (strPostNames.Length > 0 ? "," : "") + dtPost.Rows[j]["POST_NAME"].ToString();
                    strPostIDs   += (strPostIDs.Length > 0 ? "," : "") + dtPost.Rows[j]["ID"].ToString();
                }
            }
        }
    }
        /// <summary>
        /// 获取对象DataTable
        /// </summary>
        /// <param name="tSysPost">对象</param>
        /// <param name="iIndex">起始页码</param>
        /// <param name="iCount">每页数目</param>
        /// <returns>返回结果</returns>
        public DataTable SelectByTable(TSysPostVo tSysPost, int iIndex, int iCount)
        {
            string strSQL = " select * from T_SYS_POST {0} ";

            strSQL = String.Format(strSQL, BuildWhereStatement(tSysPost));
            return(SqlHelper.ExecuteDataTable(BuildPagerExpress <TSysPostVo>(tSysPost, strSQL, iIndex, iCount)));
        }
        /// <summary>
        /// 对象删除
        /// </summary>
        /// <param name="Id">ID</param>
        /// <returns>是否成功</returns>
        public bool Delete(TSysPostVo tSysPost)
        {
            string strSQL = "delete from T_SYS_POST ";

            strSQL += this.BuildWhereStatement(tSysPost);

            return(SqlHelper.ExecuteNonQuery(CommandType.Text, strSQL) > 0 ? true : false);
        }
Beispiel #6
0
    /// <summary>
    /// 拖动树节点
    /// </summary>
    /// <param name="strDragNodeID">被拖动的树节点id</param>
    /// <param name="strTargetNodeID">放置的父节点id</param>
    /// <returns>无返回</returns>
    private string DragTreeNode(string strDragNodeID, string strTargetNodeID)
    {
        TSysPostVo objPostVo = new TSysPostVo();

        objPostVo.PARENT_POST_ID = strTargetNodeID;
        objPostVo.ID             = strDragNodeID;
        new TSysPostLogic().Edit(objPostVo);

        base.WriteLog(i3.ValueObject.ObjectBase.LogType.EditUserPost, strDragNodeID, LogInfo.UserInfo.USER_NAME + "移动职位节点: " + strDragNodeID + " 及其子节点到" + strTargetNodeID + "之下成功!");
        return("");
    }
Beispiel #7
0
    /// <summary>
    /// 绑定职位树,获取json数据
    /// </summary>
    private void BindPostTree()
    {
        TSysPostVo objPostVo = new TSysPostVo();

        objPostVo.IS_DEL = "0";
        DataTable dt = new TSysPostLogic().SelectByTable(objPostVo);

        if (dt.Rows.Count < 1)
        {
            return;
        }

        BindTreeRoot(dt, "0", 1);// 绑定根节点,获取json数据
    }
Beispiel #8
0
    private string EditTreeNode(string strID, string strPOST_NAME, string strPOST_LEVEL_ID, string strPOST_DEPT_ID, string strROLE_NOTE)
    {
        TSysPostVo objPostVo = new TSysPostVo();

        objPostVo.ID            = strID;
        objPostVo.POST_NAME     = strPOST_NAME;
        objPostVo.POST_LEVEL_ID = strPOST_LEVEL_ID;
        objPostVo.POST_DEPT_ID  = strPOST_DEPT_ID;
        objPostVo.ROLE_NOTE     = strROLE_NOTE;
        new TSysPostLogic().Edit(objPostVo);

        base.WriteLog(i3.ValueObject.ObjectBase.LogType.EditSysPost, strID, LogInfo.UserInfo.USER_NAME + "编辑职位: " + strID + " 成功!");

        return("");
    }
    //获取职位
    private void GetPost()
    {
        string strSortname  = "NUM";
        string strSortorder = Request.Params["sortorder"];

        TSysPostVo objVo = new TSysPostVo();

        objVo.IS_DEL     = "0";
        objVo.IS_HIDE    = "0";
        objVo.SORT_FIELD = strSortname;
        objVo.SORT_TYPE  = strSortorder;
        DataTable dt            = new TSysPostLogic().SelectByTable(objVo, 0, 0);
        int       intTotalCount = new TSysPostLogic().GetSelectResultCount(objVo);

        string strJson = CreateToJson(dt, intTotalCount);

        Response.Write(strJson);
        Response.End();
    }
Beispiel #10
0
    private string AddTreeNode(string strParentID, string strPOST_NAME, string strPOST_LEVEL_ID, string strPOST_DEPT_ID, string strROLE_NOTE)
    {
        string     strResult = "";
        TSysPostVo objPostVo = new TSysPostVo();

        objPostVo.ID             = GetSerialNumber("t_sys_post_id");
        objPostVo.PARENT_POST_ID = strParentID;
        objPostVo.POST_NAME      = strPOST_NAME;
        objPostVo.POST_LEVEL_ID  = strPOST_LEVEL_ID;
        objPostVo.POST_DEPT_ID   = strPOST_DEPT_ID;
        objPostVo.ROLE_NOTE      = strROLE_NOTE;
        objPostVo.IS_DEL         = "0";
        objPostVo.CREATE_ID      = "";
        objPostVo.CREATE_TIME    = System.DateTime.Now.ToShortDateString();
        new TSysPostLogic().Create(objPostVo);
        strResult = objPostVo.ID;

        base.WriteLog(i3.ValueObject.ObjectBase.LogType.AddSysPost, strResult, LogInfo.UserInfo.USER_NAME + "增加职位节点: " + strResult + " 到" + strParentID + "之下成功!");

        return(strResult);
    }
Beispiel #11
0
    //页面初始化
    private void InitPage()
    {
        BindDataDictToControl("dept", this.PlanDept);

        TSysUserPostVo UserPostVo = new TSysUserPostVo();

        UserPostVo.USER_ID = LogInfo.UserInfo.ID;
        TSysPostVo PostVo = new TSysPostVo();

        PostVo = new TSysPostLogic().Details(((TSysUserPostVo) new TSysUserPostLogic().SelectByObject(UserPostVo, 0, 0)[0]).POST_ID);
        this.PlanDept.SelectedValue = PostVo.POST_DEPT_ID;

        this.hidUserID.Value  = LogInfo.UserInfo.ID;
        this.PlanDate.Value   = DateTime.Now.ToString("yyyy-MM-dd");
        this.PlanPerson.Value = LogInfo.UserInfo.REAL_NAME;

        if (!string.IsNullOrEmpty(this.hidId.Value))
        {
            TOaPartBuyRequstVo objPartBuyRequst = new TOaPartBuyRequstLogic().Details(this.hidId.Value);

            this.PlanBt.Value           = objPartBuyRequst.APPLY_TITLE;
            this.PlanDept.SelectedValue = objPartBuyRequst.APPLY_DEPT_ID;
            this.PlanPerson.Value       = !string.IsNullOrEmpty(objPartBuyRequst.APPLY_USER_ID) ? new TSysUserLogic().Details(objPartBuyRequst.APPLY_USER_ID).REAL_NAME : "";
            this.PlanDate.Value         = !string.IsNullOrEmpty(objPartBuyRequst.APPLY_DATE) ? DateTime.Parse(objPartBuyRequst.APPLY_DATE).ToShortDateString() : "";
            this.PlanContent.Value      = objPartBuyRequst.APPLY_CONTENT;
            this.TestOption.Value       = objPartBuyRequst.APP_DEPT_INFO;
            this.TestName.Value         = !string.IsNullOrEmpty(objPartBuyRequst.APP_DEPT_ID) ? new TSysUserLogic().Details(objPartBuyRequst.APP_DEPT_ID).REAL_NAME : LogInfo.UserInfo.REAL_NAME;
            this.TestDate.Value         = !string.IsNullOrEmpty(objPartBuyRequst.APP_DEPT_DATE) ? DateTime.Parse(objPartBuyRequst.APP_DEPT_DATE).ToShortDateString() : DateTime.Now.ToShortDateString();
            this.OfficeOption.Value     = objPartBuyRequst.APP_OFFER_INFO;
            this.OfficeName.Value       = !string.IsNullOrEmpty(objPartBuyRequst.APP_OFFER_ID) ? new TSysUserLogic().Details(objPartBuyRequst.APP_OFFER_ID).REAL_NAME : LogInfo.UserInfo.REAL_NAME;
            this.OfficeDate.Value       = !string.IsNullOrEmpty(objPartBuyRequst.APP_OFFER_TIME) ? DateTime.Parse(objPartBuyRequst.APP_OFFER_TIME).ToShortDateString() : DateTime.Now.ToShortDateString();
            this.TechOption.Value       = objPartBuyRequst.APP_MANAGER_INFO;
            this.TechName.Value         = !string.IsNullOrEmpty(objPartBuyRequst.APP_MANAGER_ID) ? new TSysUserLogic().Details(objPartBuyRequst.APP_MANAGER_ID).REAL_NAME : LogInfo.UserInfo.REAL_NAME;
            this.TechDate.Value         = !string.IsNullOrEmpty(objPartBuyRequst.APP_MANAGER_DATE) ? DateTime.Parse(objPartBuyRequst.APP_MANAGER_DATE).ToShortDateString() : DateTime.Now.ToShortDateString();
            this.hidStatus.Value        = objPartBuyRequst.STATUS;
        }
        //根据当前状态设置控件可不可用
        DisableControls();
    }
 /// <summary>
 /// 对象删除
 /// </summary>
 /// <param name="Id">ID</param>
 /// <returns>是否成功</returns>
 public bool Delete(TSysPostVo tSysPost)
 {
     return(access.Delete(tSysPost));
 }
 /// <summary>
 /// 对象编辑
 /// </summary>
 /// <param name="tSysPost_UpdateSet">UpdateSet用户对象</param>
 /// <param name="tSysPost_UpdateWhere">UpdateWhere用户对象</param>
 /// <returns>是否成功</returns>
 public bool Edit(TSysPostVo tSysPost_UpdateSet, TSysPostVo tSysPost_UpdateWhere)
 {
     return(access.Edit(tSysPost_UpdateSet, tSysPost_UpdateWhere));
 }
 /// <summary>
 /// 对象编辑
 /// </summary>
 /// <param name="tSysPost">用户对象</param>
 /// <returns>是否成功</returns>
 public bool Edit(TSysPostVo tSysPost)
 {
     return(access.Edit(tSysPost));
 }
 /// <summary>
 /// 对象添加
 /// </summary>
 /// <param name="sysRole">对象</param>
 /// <returns>是否成功</returns>
 public bool Create(TSysPostVo tSysPost)
 {
     return(access.Create(tSysPost));
 }
 /// <summary>
 /// 根据对象特征获取单一对象
 /// </summary>
 /// <param name="tSysPost">对象</param>
 /// <returns></returns>
 public TSysPostVo SelectByObject(TSysPostVo tSysPost)
 {
     return(access.SelectByObject(tSysPost));
 }
    private string GetUserId_InDept()
    {
        TSysUserVo tUserV = new TSysUserVo();

        tUserV.IS_DEL  = "0";
        tUserV.IS_HIDE = "0";
        tUserV.IS_USE  = "1";
        DataTable dtUser = new TSysUserLogic().SelectByTable(tUserV);

        TSysPostVo tPostV = new TSysPostVo();

        tPostV.IS_DEL  = "0";
        tPostV.IS_HIDE = "0";
        DataTable dtPost = new TSysPostLogic().SelectByTable(tPostV);

        DataTable dtUserPost = new TSysUserPostLogic().SelectByTable(new TSysUserPostVo());

        string strLocalUserId  = base.LogInfo.UserInfo.ID;
        string strReturnUserId = "'" + strLocalUserId + "'";

        //用户的所有职位
        DataRow[] drLocalUserPost = dtUserPost.Select("USER_ID='" + strLocalUserId + "'");
        string    strLocalPostIDs = "";

        for (int i = 0; i < drLocalUserPost.Length; i++)
        {
            strLocalPostIDs += (strLocalPostIDs.Length > 0 ? "," : "") + "'" + drLocalUserPost[i]["POST_ID"].ToString() + "'";
        }
        if (strLocalPostIDs.Length == 0)
        {
            return(strReturnUserId);
        }

        //用户的所有职位为部门主任或副主任的部门id
        DataRow[] drLocalPost     = dtPost.Select("ID in (" + strLocalPostIDs + ") and POST_LEVEL_ID in ('Director','DirectorEx')");
        string    strLocalDeptIDs = "";

        for (int i = 0; i < drLocalPost.Length; i++)
        {
            strLocalDeptIDs += (strLocalDeptIDs.Length > 0 ? "," : "") + "'" + drLocalPost[i]["POST_DEPT_ID"].ToString() + "'";
        }
        if (strLocalDeptIDs.Length == 0)
        {
            return(strReturnUserId);
        }

        //用户的职位为部门主任或副主任,的部门的所有职位
        DataRow[] drSrhPost     = dtPost.Select("POST_DEPT_ID in (" + strLocalDeptIDs + ")");
        string    strSrhPostIDs = "";

        for (int i = 0; i < drSrhPost.Length; i++)
        {
            strSrhPostIDs += (strSrhPostIDs.Length > 0 ? "," : "") + "'" + drSrhPost[i]["ID"].ToString() + "'";
        }
        if (strSrhPostIDs.Length == 0)
        {
            return(strReturnUserId);
        }

        //用户的职位为部门主任或副主任,的部门的所有职位对应的用户
        DataRow[] drSrhUserPost = dtUserPost.Select("POST_ID in (" + strSrhPostIDs + ")");
        string    strSrhUSerIDs = "";

        for (int i = 0; i < drSrhUserPost.Length; i++)
        {
            strSrhUSerIDs += (strSrhUSerIDs.Length > 0 ? "," : "") + "'" + drSrhUserPost[i]["USER_ID"].ToString() + "'";
        }
        if (strSrhUSerIDs.Length == 0)
        {
            return(strReturnUserId);
        }

        return(strSrhUSerIDs);
    }
 /// <summary>
 /// 对象明细
 /// </summary>
 /// <param name="tSysPost">对象条件</param>
 /// <returns>对象</returns>
 public TSysPostVo Details(TSysPostVo tSysPost)
 {
     return(access.Details(tSysPost));
 }
        /// <summary>
        /// 根据对象获取全部数据,用Table承载
        ///  数据量较小时使用【不推荐】
        /// </summary>
        /// <param name="tSysPost"></param>
        /// <returns></returns>
        public DataTable SelectByTable(TSysPostVo tSysPost)
        {
            string strSQL = "select * from T_SYS_POST " + this.BuildWhereStatement(tSysPost);

            return(SqlHelper.ExecuteDataTable(strSQL));
        }
        /// <summary>
        /// 获取对象List
        /// </summary>
        /// <param name="tSysPost">对象</param>
        /// <param name="iIndex">起始页码</param>
        /// <param name="iCount">每页数目</param>
        /// <returns>返回结果</returns>
        public List <TSysPostVo> SelectByObject(TSysPostVo tSysPost, int iIndex, int iCount)
        {
            string strSQL = String.Format("select * from  T_SYS_POST " + this.BuildWhereStatement(tSysPost));

            return(SqlHelper.ExecuteObjectList(tSysPost, BuildPagerExpress(strSQL, iIndex, iCount)));
        }
        /// <summary>
        /// 对象明细
        /// </summary>
        /// <param name="tSysPost">对象条件</param>
        /// <returns>对象</returns>
        public TSysPostVo Details(TSysPostVo tSysPost)
        {
            string strSQL = String.Format("select * from  T_SYS_POST " + this.BuildWhereStatement(tSysPost));

            return(SqlHelper.ExecuteObject(new TSysPostVo(), strSQL));
        }
        /// <summary>
        /// 获得查询结果总行数,用于分页
        /// </summary>
        /// <param name="tSysPost">对象</param>
        /// <returns>返回行数</returns>
        public int GetSelectResultCount(TSysPostVo tSysPost)
        {
            string strSQL = "select Count(*) from T_SYS_POST " + this.BuildWhereStatement(tSysPost);

            return(Convert.ToInt32(SqlHelper.ExecuteScalar(strSQL)));
        }
        /// <summary>
        /// 根据对象构造条件语句
        /// </summary>
        /// <param name="tSysPost"></param>
        /// <returns></returns>
        public string BuildWhereStatement(TSysPostVo tSysPost)
        {
            StringBuilder strWhereStatement = new StringBuilder(" Where 1=1 ");

            if (null != tSysPost)
            {
                //角色编号
                if (!String.IsNullOrEmpty(tSysPost.ID.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND ID = '{0}'", tSysPost.ID.ToString()));
                }
                //职位名
                if (!String.IsNullOrEmpty(tSysPost.POST_NAME.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND POST_NAME = '{0}'", tSysPost.POST_NAME.ToString()));
                }
                //上级职位ID
                if (!String.IsNullOrEmpty(tSysPost.PARENT_POST_ID.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND PARENT_POST_ID = '{0}'", tSysPost.PARENT_POST_ID.ToString()));
                }
                //行政级别
                if (!String.IsNullOrEmpty(tSysPost.POST_LEVEL_ID.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND POST_LEVEL_ID = '{0}'", tSysPost.POST_LEVEL_ID.ToString()));
                }
                //所属部门
                if (!String.IsNullOrEmpty(tSysPost.POST_DEPT_ID.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND POST_DEPT_ID = '{0}'", tSysPost.POST_DEPT_ID.ToString()));
                }
                //角色说明
                if (!String.IsNullOrEmpty(tSysPost.ROLE_NOTE.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND ROLE_NOTE = '{0}'", tSysPost.ROLE_NOTE.ToString()));
                }
                //树深度编号
                if (!String.IsNullOrEmpty(tSysPost.TREE_LEVEL.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND TREE_LEVEL = '{0}'", tSysPost.TREE_LEVEL.ToString()));
                }
                //排序
                if (!String.IsNullOrEmpty(tSysPost.NUM.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND NUM = '{0}'", tSysPost.NUM.ToString()));
                }
                //删除标记,1为删除
                if (!String.IsNullOrEmpty(tSysPost.IS_DEL.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND IS_DEL = '{0}'", tSysPost.IS_DEL.ToString()));
                }
                //创建人ID
                if (!String.IsNullOrEmpty(tSysPost.CREATE_ID.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND CREATE_ID = '{0}'", tSysPost.CREATE_ID.ToString()));
                }
                //创建时间
                if (!String.IsNullOrEmpty(tSysPost.CREATE_TIME.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND CREATE_TIME = '{0}'", tSysPost.CREATE_TIME.ToString()));
                }
                //隐藏标记,对用户屏蔽
                if (!String.IsNullOrEmpty(tSysPost.IS_HIDE.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND IS_HIDE = '{0}'", tSysPost.IS_HIDE.ToString()));
                }
                //备注
                if (!String.IsNullOrEmpty(tSysPost.REMARK.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK = '{0}'", tSysPost.REMARK.ToString()));
                }
                //备注1
                if (!String.IsNullOrEmpty(tSysPost.REMARK1.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK1 = '{0}'", tSysPost.REMARK1.ToString()));
                }
                //备注2
                if (!String.IsNullOrEmpty(tSysPost.REMARK2.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK2 = '{0}'", tSysPost.REMARK2.ToString()));
                }
                //备注3
                if (!String.IsNullOrEmpty(tSysPost.REMARK3.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK3 = '{0}'", tSysPost.REMARK3.ToString()));
                }
                //备注4
                if (!String.IsNullOrEmpty(tSysPost.REMARK4.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK4 = '{0}'", tSysPost.REMARK4.ToString()));
                }
                //备注5
                if (!String.IsNullOrEmpty(tSysPost.REMARK5.ToString().Trim()))
                {
                    strWhereStatement.Append(string.Format(" AND REMARK5 = '{0}'", tSysPost.REMARK5.ToString()));
                }
            }
            return(strWhereStatement.ToString());
        }
 public TSysPostLogic(TSysPostVo _tSysPost)
 {
     tSysPost = _tSysPost;
     access   = new TSysPostAccess();
 }
 /// <summary>
 /// 获得查询结果总行数,用于分页
 /// </summary>
 /// <param name="tSysPost">对象</param>
 /// <returns>返回行数</returns>
 public int GetSelectResultCount(TSysPostVo tSysPost)
 {
     return(access.GetSelectResultCount(tSysPost));
 }
 /// <summary>
 /// 获取对象DataTable
 /// </summary>
 /// <param name="tSysPost">对象</param>
 /// <param name="iIndex">起始页码</param>
 /// <param name="iCount">每页数目</param>
 /// <returns>返回结果</returns>
 public DataTable SelectByTable(TSysPostVo tSysPost, int iIndex, int iCount)
 {
     return(access.SelectByTable(tSysPost, iIndex, iCount));
 }
 /// <summary>
 /// 获取对象List
 /// </summary>
 /// <param name="tSysPost">对象</param>
 /// <param name="iIndex">起始页码</param>
 /// <param name="iCount">每页数目</param>
 /// <returns>返回结果</returns>
 public List <TSysPostVo> SelectByObject(TSysPostVo tSysPost, int iIndex, int iCount)
 {
     return(access.SelectByObject(tSysPost, iIndex, iCount));
 }
        /// <summary>
        /// 对象添加
        /// </summary>
        /// <param name="tSysPost">对象</param>
        /// <returns>是否成功</returns>
        public bool Create(TSysPostVo tSysPost)
        {
            string strSQL = SqlHelper.BuildInsertExpress(tSysPost, TSysPostVo.T_SYS_POST_TABLE);

            return(SqlHelper.ExecuteNonQuery(CommandType.Text, strSQL) > 0 ? true : false);
        }
 /// <summary>
 /// 根据对象获取全部数据,用Table承载
 ///  数据量较小时使用【不推荐】
 /// </summary>
 /// <param name="tSysPost"></param>
 /// <returns></returns>
 public DataTable SelectByTable(TSysPostVo tSysPost)
 {
     return(access.SelectByTable(tSysPost));
 }
        /// <summary>
        /// 根据对象特征获取单一对象
        /// </summary>
        /// <param name="tSysPost">对象</param>
        /// <returns></returns>
        public TSysPostVo SelectByObject(TSysPostVo tSysPost)
        {
            string strSQL = "select * from T_SYS_POST " + this.BuildWhereStatement(tSysPost);

            return(SqlHelper.ExecuteObject(new TSysPostVo(), strSQL));
        }