Ejemplo n.º 1
0
        private async Task <MenuSection> CreateMenuSection(Category category, Menu menu)
        {
            var section   = MenuSection.CreateMenuSectionWithCategory(category.Name, menu, category);
            var sectionId = await _menuManager.AddSectionAsync(section);

            if (section.Id == 0)
            {
                section = _menuSectionRepository.FirstOrDefault(sectionId);
            }
            return(section);
        }