Ejemplo n.º 1
0
        /// <summary>
        /// 构造查询条件
        /// <param name="clienterFinanceAccountPm">参数实体</param>
        /// </summary>
        public static string BindQueryCriteria(ClienterFinanceAccountPM clienterFinanceAccountPm)
        {
            var stringBuilder = new StringBuilder(" where 1=1 ");

            if (clienterFinanceAccountPm == null)
            {
                return(stringBuilder.ToString());
            }
            //TODO:在此加入查询条件构建代码
            return(stringBuilder.ToString());
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 根据条件查询
        /// </summary>
        /// <param name="clienterFinanceAccountPm">参数实体</param>
        /// <returns></returns>
        public IList <ClienterFinanceAccount> Query(ClienterFinanceAccountPM clienterFinanceAccountPm)
        {
            IList <ClienterFinanceAccount> models = new List <ClienterFinanceAccount>();
            string    condition = BindQueryCriteria(clienterFinanceAccountPm);
            string    querysql  = @"
select  Id,ClienterId,TrueName,AccountNo,IsEnable,AccountType,OpenBank,OpenSubBank,CreateBy,CreateTime,UpdateBy,UpdateTime
from  ClienterFinanceAccount (nolock)" + condition;
            DataTable dt        = DataTableHelper.GetTable(DbHelper.ExecuteDataset(SuperMan_Read, querysql));

            if (DataTableHelper.CheckDt(dt))
            {
                models = DataTableHelper.ConvertDataTableList <ClienterFinanceAccount>(dt);
            }
            return(models);
        }
 /// <summary>
 /// 查询方法
 /// </summary>
 /// <param name="clienterFinanceAccountPm">参数实体</param>
 /// <returns></returns>
 public IList <ClienterFinanceAccount> Query(ClienterFinanceAccountPM clienterFinanceAccountPm)
 {
     return(_clienterFinanceAccountDao.Query(clienterFinanceAccountPm));
 }