Пример #1
0
        public static ARAgentRateCollection Search(SearchFilter SearchKey)
        {
            ARAgentRateCollection collection = new ARAgentRateCollection();

            using (var reader = SqlHelper.ExecuteReader("ARAgentRate_Search", SearchFilterManager.SqlSearchParam(SearchKey)))
            {
                while (reader.Read())
                {
                    ARAgentRate obj = new ARAgentRate();
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }
Пример #2
0
        public static ARAgentRateCollection GetAllItem(int CompanyID, string CustomerID)
        {
            ARAgentRateCollection collection = new ARAgentRateCollection();

            var sqlParams = new SqlParameter[]
            {
                new SqlParameter("@CompanyID", CompanyID),
                new SqlParameter("@CustomerID", CustomerID),
            };

            using (var reader = SqlHelper.ExecuteReader("ARAgentRate_GetAll", sqlParams))
            {
                while (reader.Read())
                {
                    ARAgentRate obj = new ARAgentRate();
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }