public ActionResult sendemail(CommunicationModel emails) { Nahda_AttendanceEntities db = new Nahda_AttendanceEntities(); CommunicationGroupMaster mster = new CommunicationGroupMaster(); mster.Title = emails.Title; mster.Remarks = emails.Remarks; mster.CreatedBy = "Naveed"; mster.CreatedOn = DateTime.Now; mster.School = Convert.ToInt32(emails.SchlsId); List <CommunicationGroupDetail> list = new List <CommunicationGroupDetail>(); foreach (var i in emails.selecteditems) { string[] split = i.Split('/'); CommunicationGroupDetail obj = new CommunicationGroupDetail(); obj.CreatedBy = "Naveed"; obj.CreatedOn = DateTime.Now; obj.Email = split[1]; obj.StaffId = Convert.ToInt32(split[0]); list.Add(obj); } mster.CommunicationGroupDetails = list; db.CommunicationGroupMasters.Add(mster); db.SaveChanges(); return(RedirectToAction("Index")); }
public CommunicationController() { unitOfWork = new UnitOfWork(); service = new LessonPlanService(); mapping = new LessonPlanMapping(); model = new LessonPlanModel(); dmapping = new DigitalResourcesMapping(); db = new Nahda_AttendanceEntities(); }
public EmailControllerController() { db = new Nahda_AttendanceEntities(); }
public NewStaffController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public MaintenanceRequestFormController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public CleaningStaffLocationController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public StudentFeedBackReportController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public WeeklyMeetingScheduleController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public GenericRepository(Nahda_AttendanceEntities context) { this.context = context; this.dbSet = context.Set <TEntity>(); }
public LeaveRequestFormController() { unitOfWork = new UnitOfWork(); db = new Nahda_AttendanceEntities(); }
public ComplaintLogController() { db = new Nahda_AttendanceEntities(); unitofwork = new UnitOfWork(); }
public TestController() { db = new Nahda_AttendanceEntities(); }
public UnitOfWork() { _context = new Nahda_AttendanceEntities(); }