예제 #1
0
        public ApiResultObject <List <Employee> > GetResult(PcsEmployeeFilterQuery filter)
        {
            ApiResultObject <List <Employee> > result = null;

            try
            {
                bool valid = true;
                valid = valid && IsNotNull(param);
                valid = valid && IsNotNull(filter);
                List <Employee> resultData = null;
                if (valid)
                {
                    resultData = new PcsEmployeeGet(param).Get(filter);
                }
                result = this.PackResult(resultData);
                this.FailLog(result.Success, filter, result.Data);
            }
            catch (Exception ex)
            {
                LogSystem.Error(ex);
                param.HasException = true;
                result             = null;
            }
            return(result);
        }
예제 #2
0
 internal Employee GetByLoginname(string loginname, PcsEmployeeFilterQuery filter)
 {
     try
     {
         return(DAOWorker.PcsEmployeeDAO.GetByLoginname(loginname, filter.Query()));
     }
     catch (Exception ex)
     {
         LogSystem.Error(ex);
         param.HasException = true;
         return(null);
     }
 }
예제 #3
0
 internal List <Employee> Get(PcsEmployeeFilterQuery filter)
 {
     try
     {
         return(DAOWorker.PcsEmployeeDAO.Get(filter.Query(), param));
     }
     catch (Exception ex)
     {
         LogSystem.Error(ex);
         param.HasException = true;
         return(null);
     }
 }
예제 #4
0
        public List <Employee> Get(PcsEmployeeFilterQuery filter)
        {
            List <Employee> result = null;

            try
            {
                result = new PcsEmployeeGet(param).Get(filter);
            }
            catch (Exception ex)
            {
                LogSystem.Error(ex);
                param.HasException = true;
                result             = null;
            }
            return(result);
        }