コード例 #1
0
        public async Task <IActionResult> Create(StyleViewModel style)
        {
            if (ModelState.IsValid)
            {
                var dto = style.GetDTO();
                await this.styleService.CreateStyleAsync(dto);

                return(RedirectToAction(nameof(Index)));
            }
            return(View(style));
        }