예제 #1
0
        ///<Summary>
        ///CollectionCount
        ///This method returns the collection count of BOSuppliers objects, filtered by optional criteria
        ///</Summary>
        ///<returns>
        ///Int32
        ///</returns>
        ///<parameters>
        ///ICriteria icriteria
        ///</parameters>
        public virtual Int32 CollectionCount(object o)
        {
            Doing(this);
            try
            {
                ICriteria              icriteria             = (ICriteria)o;
                List <IBOSuppliers>    boSuppliersCollection = new List <IBOSuppliers>();
                IList <IDataCriterion> lstDataCriteria       = (icriteria == null) ? null : icriteria.ListDataCriteria();
                Int32 objCount = _iSuppliersRepository.SelectAllByCriteriaCount(lstDataCriteria);

                return(objCount);
            }
            catch (Exception ex)
            {
                Failed(this, ex);
                Handle(this, ex);
                return(-1);
            }
        }