Exemple #1
0
        private void AddEducation()
        {
            var ent = _kernel.Get <IEducationEntity>();

            ent.Institution = Institution;
            ent.Credential  = Credential;
            repos.Add(ent);

            EducationAdded?.Invoke(this, new EventArgs());
        }
        public ActionResult Create([Bind(Include = "EducationId,Name,SchoolName,From,Until,Information,PersonId")] Education education)
        {
            if (ModelState.IsValid)
            {
                _educationRepository.Add(education);
                _educationRepository.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.PersonId = new SelectList(_personRepository.All, "PersonId", "Firstname", education.PersonId);
            return(View(education));
        }
        public void Insert(EducationViewModel model)
        {
            var contractType = AutoMapper.Mapper.Map <EducationViewModel, Education>(model);

            _repository.Add(contractType);
        }
Exemple #4
0
 public void Add(Education model)
 {
     _education.Add(model);
 }
Exemple #5
0
 public int AddEducation(BLModel.Education education)
 {
     return(_eduRepository.Add((DLModel.Education) new DLModel.Education().InjectFrom(education)).EducationID);
 }