public async Task <IActionResult> Add(StudentAddViewModel model)
        {
            if (ModelState.IsValid)
            {
                //var student = new Student
                //{
                //    Avatar = faker.Internet.Avatar(),
                //    FirstName = model.FirstName,
                //    LastName = model.LastName,
                //    Email = model.Email,
                //    Address = new Address
                //    {
                //        Street = model.Street,
                //        City = model.City,
                //        ZipCode = model.ZipCode
                //    }
                //};

                var student = mapper.Map <Student>(model);
                student.Avatar = faker.Internet.Avatar();

                _context.Add(student);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(model));
        }
        public async Task <IActionResult> Create([Bind("Id,Title,EnrollmentId")] Course course)
        {
            if (ModelState.IsValid)
            {
                _context.Add(course);
                await _context.SaveChangesAsync();

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