예제 #1
0
 public EventsController(IEventRepo EventRepository, IArtistEventRepo ArtistEventRepo, ISponsorEventRepo SponsorEventRepo, ILocationRepo LocationRepo)
 {
     _repo             = EventRepository;
     _ArtistEventRepo  = ArtistEventRepo;
     _SponsorEventRepo = SponsorEventRepo;
     _LocationRepo     = LocationRepo;
 }
예제 #2
0
 public AreaController(IUserReferenceRepo repoBase, ILookupCodeRepo repoLookup, IAreaRepo repoArea, ILocationRepo repoLocation, IRuteRepo repoRute)
     : base(repoBase, repoLookup)
 {
     RepoArea     = repoArea;
     RepoLocation = repoLocation;
     RepoRute     = repoRute;
 }
예제 #3
0
        public ActionResult EditOrganization(OrgVM o)
        {
            ILocationRepo locorepo = LocationRepoFactory.Create();
            IHeroRepo     herorepo = HeroRepoFactory.Create();
            IOrgRepo      orgrepo  = OrgRepoFactory.Create();

            if (ModelState.IsValid)
            {
                o.OrganizationHeroes = new List <Hero>();

                var orgToEdit = new Organization
                {
                    OrganizationID       = o.OrganizationID,
                    OganizationAddress   = o.OganizationAddress,
                    OrganizationLocation = locorepo.GetLocationById(o.OrganizationLocation.LocationID),
                    OrganizationName     = o.OrganizationName,
                    Phone = o.Phone,
                };
                foreach (var HeroID in o.SelectedHeroesID)
                {
                    orgToEdit.OrganizationHeroes.Add(herorepo.GetHereosByID(HeroID));
                }
                orgrepo.EditOrg(orgToEdit);
            }
            return(RedirectToAction("OrganizationList"));
        }
예제 #4
0
        public ActionResult LocationList()
        {
            ILocationRepo locorepo = LocationRepoFactory.Create();
            var           model    = locorepo.GetAllLocations();

            return(View(model.ToList()));
        }
예제 #5
0
        public ActionResult DeleteLocation(int LocationID)
        {
            ILocationRepo locorepo = LocationRepoFactory.Create();

            locorepo.DeleteLocation(LocationID);
            return(RedirectToAction("LocationList"));
        }
 public CustomerController(ILocationRepo locationRepo, ICustomerRepository customerRepo, IProductsRepository productsRepo, IOrdersRepository ordersRepo)
 {
     LocRepo  = locationRepo;
     CusRepo  = customerRepo;
     ProdRepo = productsRepo;
     OrdRepo  = ordersRepo;
 }
예제 #7
0
 public OrdersController(ILocationRepo locationRepo, ICustomerRepository customerRepo, IProductsRepository productsRepo, IOrdersRepository ordersRepo, ILogger <OrdersController> logger)
 {
     LocRepo  = locationRepo;
     CusRepo  = customerRepo;
     ProdRepo = productsRepo;
     OrdRepo  = ordersRepo;
     _logger  = logger;
 }
예제 #8
0
 public MasterPoolController(IUserReferenceRepo repoBase, ILookupCodeRepo repoLookup, IMasterPoolRepo repoPool, ILocationRepo repoLoc, IERPConfigRepo repoERPConfig,
                             Iac_mstrRepo repoac_mstr, Ibk_mstrRepo repobk_mstr)
     : base(repoBase, repoLookup)
 {
     RepoPool    = repoPool;
     RepoLoc     = repoLoc;
     Repoac_mstr = repoac_mstr;
     Repobk_mstr = repobk_mstr;
 }
 public ManagerLogin(Manager manager, lacrosseContext context, ICustomerRepo custRepo, ILocationRepo locRepo)
 {
     this.manager            = manager;
     this.custRepo           = custRepo;
     this.locRepo            = locRepo;
     this.custServices       = new CustomerServices(custRepo);
     this.locServices        = new LocationServices(locRepo);
     this.replenishInventory = new ReplenishInventory(manager, context, new DBRepo(context), new DBRepo(context), new DBRepo(context));
 }
예제 #10
0
 public RuteController(IUserReferenceRepo repoBase, ILookupCodeRepo repoLookup,
                       IRuteRepo repoRute, ILocationRepo repoLocation, IAreaRepo repoArea, IMultiDropRepo repoMultidrop)
     : base(repoBase, repoLookup)
 {
     RepoRute      = repoRute;
     RepoLocation  = repoLocation;
     RepoArea      = repoArea;
     RepoMultidrop = repoMultidrop;
 }
예제 #11
0
 public ReplenishInventory(Manager manager, lacrosseContext context, ILocationRepo locationRepo, IInventoryRepo inventoryRepo, IProductRepo productRepo)
 {
     this.manager           = manager;
     this.context           = context;
     this.locationRepo      = locationRepo;
     this.inventoryRepo     = inventoryRepo;
     this.productRepo       = productRepo;
     this.locationServices  = new LocationServices(locationRepo);
     this.inventoryServices = new InventoryServices(inventoryRepo);
     this.productServices   = new ProductServices(productRepo);
 }
예제 #12
0
        public LocationMenu(models.Customer customer, ILocationRepo locationRepo, IMessagingService service)
        {
            this.customer = customer;
            this.service  = service;


            this.locationService  = new LocationService(locationRepo);
            this.inventoryService = new InventoryService((IInventoryRepo)locationRepo);
            this.orderService     = new OrderService((IOrderRepo)locationRepo);
            this.productService   = new ProductService((IProductRepo)locationRepo);
            //this.customerService = new CustomerService((ICustomerRepo) locationRepo);
        }
        public CustomerController(ICustomerRepo customerRepo, ILocationRepo locationRepo,
                                  IOrderItemRepo orderItemRepo, IOrderRepo orderRepo, ICupcakeRepo cupcakeRepo,
                                  ILogger <CustomerController> logger)
        {
            LocRepo       = locationRepo;
            CustomerRepo  = customerRepo;
            OrderItemRepo = orderItemRepo;
            OrderRepo     = orderRepo;
            CupcakeRepo   = cupcakeRepo;

            _logger = logger;
        }
예제 #14
0
 public LaunchMenu(lacrosseContext context, ICustomerRepo custRepo, IManagerRepo managerRepo, ILocationRepo locRepo, ICartRepo cartRepo)
 {
     this.context          = context;
     this.custRepo         = custRepo;
     this.locRepo          = locRepo;
     this.cartRepo         = cartRepo;
     this.managerRepo      = managerRepo;
     this.customerServices = new CustomerServices(custRepo);
     this.locationServices = new LocationServices(locRepo);
     this.cartServices     = new CartServices(cartRepo);
     this.managerServices  = new ManagerServices(managerRepo);
 }
 public OrderHistoryMenu(Customer customer, lacrosseContext context, ICustomerRepo customerRepo, IInventoryRepo inventoryRepo, IProductRepo productRepo, IOrderRepo orderRepo, ILocationRepo locationRepo)
 {
     this.customer         = customer;
     this.customerRepo     = customerRepo;
     this.productRepo      = productRepo;
     this.orderRepo        = orderRepo;
     this.inventoryRepo    = inventoryRepo;
     this.locationRepo     = locationRepo;
     this.customerServices = new CustomerServices(customerRepo);
     this.locationService  = new LocationServices(locationRepo);
     this.productServices  = new ProductServices(productRepo);
     this.orderService     = new OrderServices(orderRepo);
     this.inventoryService = new InventoryServices(inventoryRepo);
 }
예제 #16
0
        public OrderController(ICustomerRepo customerRepo, ILocationRepo locationRepo,
                               IOrderRepo orderRepo, ICupcakeRepo cupcakeRepo, IOrderItemRepo orderItemRepo,
                               ILocationInventoryRepo locationInventoryRepo, IRecipeItemRepo recipeItemRepo,
                               ILogger <OrderController> logger)
        {
            LocRepo               = locationRepo;
            CustomerRepo          = customerRepo;
            OrderRepo             = orderRepo;
            CupcakeRepo           = cupcakeRepo;
            OrderItemRepo         = orderItemRepo;
            LocationInventoryRepo = locationInventoryRepo;
            RecipeItemRepo        = recipeItemRepo;

            _logger = logger;
        }
예제 #17
0
        public ActionResult EditLocation(int id)
        {
            ILocationRepo locorepo = LocationRepoFactory.Create();
            var           location = locorepo.GetLocationById(id);
            var           model    = new LocationVM
            {
                LocationID          = location.LocationID,
                LocationName        = location.LocationName,
                LocationAddress     = location.LocationAddress,
                LocationDescription = location.LocationDescription,
                LatitudeCoordinate  = location.LatitudeCoordinate,
                LongitudeCoordinate = location.LongitudeCoordinate,
            };

            locorepo.EditLocation(location);
            return(View(model));
        }
예제 #18
0
        public ActionResult EditLocation(LocationVM l)
        {
            ILocationRepo locorepo = LocationRepoFactory.Create();

            if (ModelState.IsValid)
            {
                var location = new Location
                {
                    LocationID          = l.LocationID,
                    LocationName        = l.LocationName,
                    LocationAddress     = l.LocationAddress,
                    LocationDescription = l.LocationDescription,
                    LatitudeCoordinate  = l.LatitudeCoordinate,
                    LongitudeCoordinate = l.LongitudeCoordinate,
                };
                locorepo.EditLocation(location);
            }
            return(RedirectToAction("LocationList"));
        }
예제 #19
0
 public CheckoutMenu(Customer customer, lacrosseContext context, ICustomerRepo customerRepo, ILocationRepo locationRepo, IInventoryRepo inventoryRepo, IProductRepo productRepo, ICartRepo cartRepo, ICartItemsRepo cartItemsRepo, IOrderRepo orderRepo, ILineItemRepo lineItemRepo)
 {
     this.customer          = customer;
     this.customerRepo      = customerRepo;
     this.inventoryRepo     = inventoryRepo;
     this.locationRepo      = locationRepo;
     this.productRepo       = productRepo;
     this.orderRepo         = orderRepo;
     this.cartRepo          = cartRepo;
     this.cartItemsRepo     = cartItemsRepo;
     this.lineItemRepo      = lineItemRepo;
     this.customerServices  = new CustomerServices(customerRepo);
     this.locationServices  = new LocationServices(locationRepo);
     this.inventoryServices = new InventoryServices(inventoryRepo);
     this.productServices   = new ProductServices(productRepo);
     this.cartServices      = new CartServices(cartRepo);
     this.cartItemServices  = new CartItemServices(cartItemsRepo);
     this.orderServices     = new OrderServices(orderRepo);
     this.lineItemServices  = new lineItemServices(lineItemRepo);
 }
예제 #20
0
        public ActionResult EditSighting(SightingVM s)
        {
            IHeroRepo     herorepo     = HeroRepoFactory.Create();
            ISightingRepo repo         = SightingRepoFactory.Create();
            ILocationRepo locationrepo = LocationRepoFactory.Create();

            if (ModelState.IsValid)
            {
                foreach (var hero in s.SightingHeroes)
                {
                    s.SightingObject.SightingHeroes.Remove(hero);
                }

                foreach (var HeroID in s.SightingObject.SelectedHeroesID)
                {
                    s.SightingObject.SightingHeroes.Add(herorepo.GetHereosByID(HeroID));
                }

                s.SightingObject.SightingLocation = locationrepo.GetLocationById(s.SightingObject.SightingLocation.LocationID);

                Sighting sighting = new Sighting
                {
                    Ispublished         = true,
                    SightingHeroes      = s.SightingObject.SightingHeroes,
                    SightingID          = s.SightingObject.SightingID,
                    SightingLocation    = s.SightingObject.SightingLocation,
                    SightingDescription = s.SightingObject.SightingDescription,
                    Date = s.SightingObject.Date
                };
                repo.EditSighting(sighting);
            }
            else
            {
                return(View(s));
            }
            return(RedirectToAction("Index", "Home"));
        }
예제 #21
0
 public LocationController(ILocationRepo repo) => _repo = repo ?? throw new ArgumentNullException(nameof(repo));
 public LocationsController(ILocationRepo repo)
 {
     _repository = repo;
 }
예제 #23
0
        public IndexModel(ILocationRepo repositoryLocation)
        {
            LocationRepo = repositoryLocation;

            SortableLocationList = LocationRepo.GetAllLocations();
        }
예제 #24
0
 public LocationService(ILocationRepo locationRepo)
 {
     _locationRepo = locationRepo;
 }
예제 #25
0
 public CarDetalisController(ICarDetalistRepo _repo, ILocationRepo _locationRepo, ICarRepo _carRepo)
 {
     repo         = _repo;
     repoLocation = _locationRepo;
     repoCar      = _carRepo;
 }
 public EditLocationModel(ILocationRepo repository)
 {
     repo = repository;
 }
예제 #27
0
 public LocationController(IUserReferenceRepo repoBase, ILookupCodeRepo repoLookup, ILocationRepo repoLocation)
     : base(repoBase, repoLookup)
 {
     RepoLocation = repoLocation;
 }
 public CreateSpeedMeasurementModel(ISpeedMeasurementRepo repo, ILocationRepo locationRepo)
 {
     _measurements = repo;
     _locations    = locationRepo;
 }
 public EditLocationModel(ILocationRepo locationRepo)
 {
     _locationRepo = locationRepo;
 }
예제 #30
0
 public EventsController(IEventRepo eventRepository, ILocationRepo locationRepository, IEventTypeRepo eventTypeRepository)
 {
     _eventRepository = eventRepository;
     _locationRepository = locationRepository;
     _eventTypeRepository = eventTypeRepository;
 }
예제 #31
0
 public EditLocationModel(ILocationRepo locations)
 {
     _locations = locations;
 }
예제 #32
0
 public LocationsController(ILocationRepo repository)
 {
     _repository = repository;
 }