예제 #1
0
        public List <DelegationsTypesBLL> GetDelegationsTypes()
        {
            try
            {
                List <DelegationsTypes>    DelegationsTypesList    = new DelegationsTypesDAL().GetDelegationsTypes();
                List <DelegationsTypesBLL> DelegationsTypesBLLList = new List <DelegationsTypesBLL>();
                if (DelegationsTypesList.Count > 0)
                {
                    foreach (var item in DelegationsTypesList)
                    {
                        DelegationsTypesBLLList.Add(new DelegationsTypesBLL()
                        {
                            DelegationTypeID   = item.DelegationTypeID,
                            DelegationTypeName = item.DelegationTypeName
                        });
                    }
                }

                return(DelegationsTypesBLLList);
            }
            catch
            {
                throw;
            }
        }
예제 #2
0
 public DelegationsTypesBLL GetByDelegationTypeID(int DelegationTypeID)
 {
     try
     {
         DelegationsTypes DelegationType = new DelegationsTypesDAL().GetByDelegationTypeID(DelegationTypeID);
         return(new DelegationsTypesBLL()
         {
             DelegationTypeID = DelegationType.DelegationTypeID,
             DelegationTypeName = DelegationType.DelegationTypeName
         });
     }
     catch
     {
         throw;
     }
 }