Beispiel #1
0
        public DataTable Query(string resTypeId, string codes, string names, string specification, string technicalParameter, string brand, string priceType, string minPrice, string maxPrice, int pageSize, int pageIndex)
        {
            cn.justwin.resourceDAL.Resource resource = new cn.justwin.resourceDAL.Resource();
            string condition          = this.GetConditionString(resTypeId, codes, names, specification, technicalParameter, brand);
            string priceTypeCondition = this.GetPriceConditionString(priceType, minPrice, maxPrice);

            return(resource.Query(pageSize, pageIndex, condition, priceTypeCondition));
        }
Beispiel #2
0
        private DataTable Query(string userCode, string typeName, string codes, string names, string specification, string technicalParameter, string brand)
        {
            IList <string> allResourceTypeId = this.GetAllResourceTypeId(typeName);
            string         condition         = DBHelper.GetQuerySql("ResourceCode", codes) + DBHelper.GetQuerySql("ResourceName", names) + DBHelper.GetQuerySql("Specification", specification) + DBHelper.GetQuerySql("TechnicalParameter", technicalParameter) + DBHelper.GetQuerySql("r.Brand", brand);

            if (allResourceTypeId.Count > 0)
            {
                condition = condition + string.Format(" AND ResourceType IN ({0})", DBHelper.GetInParameterSql(allResourceTypeId.ToArray <string>()));
            }
            cn.justwin.resourceDAL.Resource resource = new cn.justwin.resourceDAL.Resource();
            IList <string> priceTypeNameList         = this.GetPriceTypeNameList(userCode);

            return(resource.Query(priceTypeNameList, condition));
        }
Beispiel #3
0
 public DataTable Query(int pageSize, int pageIndex, string condition, string priceTypeCondition)
 {
     cn.justwin.resourceDAL.Resource resource = new cn.justwin.resourceDAL.Resource();
     return(resource.Query(pageSize, pageIndex, condition, priceTypeCondition));
 }