public DashboardController(UserManager <IdentityUser> userMgr, SignInManager <IdentityUser> signInMgr, IChefRepository repo) { repository = repo; userManager = userMgr; signInManager = signInMgr; }
public ChefService(IChefRepository chefRepository, IUnitOfWork unitOfWork) { if (chefRepository == null) { throw new ArgumentNullException("chefRepository"); } if (unitOfWork == null) { throw new ArgumentNullException("unitOfWork"); } _chefRepository = chefRepository; _unitOfWork = unitOfWork; }
public ChefService(IChefRepository chefRepository, IUnitOfWork unitOfWork) { if (chefRepository == null) { throw new ArgumentNullException("chefRepository"); } if (unitOfWork == null) { throw new ArgumentNullException("unitOfWork"); } _chefRepository = chefRepository; _unitOfWork = unitOfWork; }
public Query(IChefRepository repository) { Field<ListGraphType<ChefType>>( "chefs", resolve: context => repository.GetAll() ); Field<ChefType>( "chef", arguments: new QueryArguments(new QueryArgument<NonNullGraphType<IdGraphType>> { Name = "id" }), resolve: context => { var id = context.GetArgument<string>("id"); return repository.GetById(id); } ); }
public MealController(IChefRepository chefRepository) { _chefRepository = chefRepository ?? throw new ArgumentNullException(nameof(chefRepository)); }
public MealController(IMealRepository mealRepo, IChefRepository chefRepo) { mealRepository = mealRepo; chefRepository = chefRepo; }
public HomeController(IChefRepository chefRepository, AppDbContext context) { _chefRepository = chefRepository; dbContext = context; }
public ChefController(IChefRepository chefRepo) { chefRepository = chefRepo; }