Пример #1
0
        public IList<Gear> GetAllForUser(int userId)
        {
            UserServices userServices = new UserServices(new Repository<User>());
              User systemUser = userServices.FindUser("system");

              IList<Gear> gear = GearRepository.GetAllSystemAndUser(userId, systemUser.Id);

              return gear;
        }
Пример #2
0
 public IList<DiveShop> GetAllForUser(int userId)
 {
     UserServices userServices = new UserServices(new Repository<User>());
       User systemUser = userServices.FindUser("system");
       IList<DiveShop> diveShops = null;
       try {
     diveShops = DiveShopRepository.GetAllSystemAndUser(userId, systemUser.Id);
       } catch (Exception e) {
     log.Error("Error retrieving dive shops", e);
       }
       return diveShops;
 }
Пример #3
0
 public IList<Instructor> GetAllForUser(int userId)
 {
     UserServices userServices = new UserServices(new Repository<User>());
     User systemUser = userServices.FindUser("system");
     IList<Instructor> instructors = null;
     try
     {
         instructors = InstructorRepository. GetAll();
     }
     catch (Exception e)
     {
         log.Error("Error retrieving instructors",e);
     }
     return instructors;
 }
Пример #4
0
 public IList<Manufacturer> GetAllForUser(int userId)
 {
     UserServices userServices = new UserServices(new Repository<User>());
     User systemUser = userServices.FindUser("system");
     IList<Manufacturer> manufacturers = null;
     try
     {
         manufacturers = ManufacturerRepository.GetAllSystemAndUser(userId, systemUser.Id);
     }
     catch (Exception e)
     {
         log.Error("Error retrieving manufacturers",e);
     }
     return manufacturers;
 }