public List <Entity.ElevatorMaintenanceResponse> GetUpComingList(Entity.ElevatorMaintenanceRequest request)
        {
            List <Entity.ElevatorMaintenanceResponse> result = new List <Entity.ElevatorMaintenanceResponse>();

            try
            {
                logger.InfoLog(Constants.ACTION_ENTRY, "ElevatorMaintenanceRepository.GetUpComingList");
                using (var sqlDataAccess = new SqlDataAccess(ConnectionString))
                {
                    List <DbParameter> parameters = sqlDataAccess.CreateParams(component.helper.SolutionConfiguration.CurrentUserId, "v1");
                    parameters.Add(sqlDataAccess.CreateParameter("companyguid", component.helper.SolutionConfiguration.CompanyId, DbType.Guid, ParameterDirection.Input));
                    if (request.BuildingGuid.HasValue)
                    {
                        parameters.Add(sqlDataAccess.CreateParameter("entityGuid", request.BuildingGuid, DbType.Guid, ParameterDirection.Input));
                    }
                    if (request.ElevatorGuid.HasValue)
                    {
                        parameters.Add(sqlDataAccess.CreateParameter("guid", request.ElevatorGuid, DbType.Guid, ParameterDirection.Input));
                    }
                    parameters.Add(sqlDataAccess.CreateParameter("count", DbType.Int32, ParameterDirection.Output, 16));
                    DbDataReader dbDataReader = sqlDataAccess.ExecuteReader(sqlDataAccess.CreateCommand("[ElevatorMaintenance_UpComingList]", CommandType.StoredProcedure, null), parameters.ToArray());
                    result = DataUtils.DataReaderToList <Entity.ElevatorMaintenanceResponse>(dbDataReader, null);
                }
                logger.InfoLog(Constants.ACTION_EXIT, "ElevatorMaintenanceRepository.GetUpComingList");
            }
            catch (Exception ex)
            {
                logger.ErrorLog(Constants.ACTION_EXCEPTION, ex);
            }
            return(result);
        }
 public List <Entity.ElevatorMaintenanceResponse> GetUpComingList(Entity.ElevatorMaintenanceRequest request)
 {
     try
     {
         return(_elevatorMaintenanceRepository.GetUpComingList(request));
     }
     catch (Exception ex)
     {
         _logger.Error(Constants.ACTION_EXCEPTION, $"ElevatorMaintenanceService.List, Error: {ex.Message}");
         return(new List <Entity.ElevatorMaintenanceResponse>());
     }
 }