private void AddOpening(Company v) { var randomJob = JobService.GetAllJobs()[random.Next(100)]; var randomQualification = QualificationsService.GetAllQualifications()[random.Next(10)]; var newOpening = new Opening() { Company = v, Job = randomJob, RequiredQualification = randomQualification }; OpeningService.AddOpening(newOpening); }
public void Add() { var opening = new DataLayer.EfClasses.Opening { CompanyId = SelectedCompany.CompanyId, QualificationId = SelectedQualification.QualificationId, StartingDate = StartDate, AnticipatedEndDate = EndDate, HourlyPay = double.Parse(HourlyPay) }; _openingService.AddOpening(opening); AssociatedOpening = new OpeningViewModel(opening); }