Пример #1
0
        public RecipeController(IRecipeRepository recipeRepository,
                                ICategoryRepository categoryRepository,
                                IIngredientDetailRepository ingredientDetailRepository,
                                IRecipeIngredientRepository recipeIngredientRepository,
                                IReviewCommentDetailRepository reviewCommentDetailRepository,
                                IRecipeReviewCommentRepository recipeReviewCommentRepository
                                )
        {
            Recipes              = recipeRepository.Recipes;
            IngredientDetails    = ingredientDetailRepository.IngredientDetails;
            RecipeIngredients    = recipeIngredientRepository.RecipeIngredients;
            ReviewCommentDetails = reviewCommentDetailRepository.ReviewCommentDetails;
            RecipeReviewComments = recipeReviewCommentRepository.RecipeReviewComments;
            Categories           = categoryRepository.Categories;

            iRecipeReviewCommentRepository = recipeReviewCommentRepository;
            iReviewCommentDetailRepository = reviewCommentDetailRepository;
        }
 public DataController(IHostingEnvironment ihostingEnvironment,
                       ICategoryRepository categoryRepository,
                       IRecipeRepository recipeRepository,
                       IIngredientDetailRepository ingredientDetailRepository,
                       IRecipeModalRepository recipeModalRepository,
                       IModalDetailRepository modalDetailRepository,
                       IRecipeIngredientRepository recipeIngredientRepository,
                       IRecipeReviewCommentRepository recipeReviewCommentRepository,
                       IReviewCommentDetailRepository reviewCommentDetailRepository
                       )
 {
     this.ihostingEnvironment      = ihostingEnvironment;
     this.iCategoryRepo            = categoryRepository;
     this.iRecipeRepo              = recipeRepository;
     this.iIngredientDetailRepo    = ingredientDetailRepository;
     this.iModalDetailRepo         = modalDetailRepository;
     this.iRecipeModalRepo         = recipeModalRepository;
     this.iRecipeIngredientRepo    = recipeIngredientRepository;
     this.iRecipeReviewCommentRepo = recipeReviewCommentRepository;
     this.iReviewCommentDetailRepo = reviewCommentDetailRepository;
 }