예제 #1
0
        public ActionResult AddSpecialityFromDetails(int stylistId, int specialityId)
        {
            Stylist    foundStylist    = Stylist.Find(stylistId);
            Speciality foundSpeciality = Speciality.Find(specialityId);

            if (!foundSpeciality.CheckIfExists(foundStylist.GetId()))
            {
                foundStylist.AddSpeciality(foundSpeciality);
            }
            return(RedirectToAction("Details", new { id = stylistId }));
        }